OSEP

https://github.com/r0r0x-xx/OSEP-Prearrow-up-right

OSEP-Prearrow-up-right

Prior knowledge for OSEP (Guide)

This is a repository of notes and material that I consider necessary in advance to opt for the course and the OSEP certification (Techniques of Evasion and Breaching Defenses)

This compilation of material is very much influenced by nullg0re (GIT) and more!

         ########    #####   ########    #####   ##     ##
         ##     ##  ##   ##  ##     ##  ##   ##   ##   ##
         ##     ## ##     ## ##     ## ##     ##   ## ##
         ########  ##     ## ########  ##     ##    ###
         ##   ##   ##     ## ##   ##   ##     ##   ## ##
         ##    ##   ##   ##  ##    ##   ##   ##   ##   ##
         ##     ##   #####   ##     ##   #####   ##     ##

Contents

Programming languages

For this certification it is very important to have a knowledge base in the following programming languages:

Bash: https://www.youtube.com/watch?v=smbeKPDVs2Iarrow-up-right

Python: https://www.youtube.com/playlist?list=PLBf0hzazHTGM_dncTqO9l-0zUQYP0nNPUarrow-up-right

PowerShel: https://resources.infosecinstitute.com/topic/powershell-for-pentesters-part-1-introduction-to-powershell-and-cmdlets/arrow-up-right

C#: https://www.youtube.com/watch?v=GhQdlIFylQ8arrow-up-right

Introduction to VBA: https://docs.microsoft.com/en-us/office/vba/library-reference/concepts/getting-started-with-vba-in-officearrow-up-right

Operating System

Win32 API's

Offensive P/Invoke: https://posts.specterops.io/offensive-p-invoke-leveraging-the-win32-api-from-managed-code-7eef4fdef16darrow-up-right

Process Injection: https://rastamouse.me/blog/process-injection-dinvoke/arrow-up-right

Wiki for .NET developers: https://www.pinvoke.net/arrow-up-right

Windows Registry

Win register: https://docs.microsoft.com/en-us/troubleshoot/windows-server/performance/windows-registry-advanced-usersarrow-up-right

Client Side Code Execution

Staged VS Stageless handlers (Payloads): https://buffered.io/posts/staged-vs-stageless-handlers/arrow-up-right

HTML Smuggling: https://outflank.nl/blog/2018/08/14/html-smuggling-explained/arrow-up-right

Embed in HTML: https://github.com/Arno0x/EmbedInHTMLarrow-up-right

Macro Malware: https://docs.microsoft.com/en-us/windows/security/threat-protection/intelligence/macro-malwarearrow-up-right

Automatically Macro: https://support.microsoft.com/en-us/office/automatically-run-a-macro-when-opening-a-workbook-1e55959b-e077-4c88-a696-c3017600db44arrow-up-right

Working Windows API in VBA: https://www.aeternus.sg/how-to-use-windows-api-in-vba/arrow-up-right

Powershell Shellcode: https://www.powershellgallery.com/packages/PowerSploit/1.0.0.0/Content/CodeExecution%5CInvoke-Shellcode.ps1arrow-up-right

Code Execution in VBA Macro: https://www.bitdam.com/2018/05/22/propertybomb-an-old-new-technique-for-arbitrary-code-execution-in-vba-macro/arrow-up-right

MSBuild Generator: https://github.com/infosecn1nja/MaliciousMacroMSBuildarrow-up-right

PowerShell & Windows API: https://devblogs.microsoft.com/scripting/use-powershell-to-interact-with-the-windows-api-part-1/arrow-up-right

PowerSploit: https://github.com/PowerShellMafia/PowerSploitarrow-up-right

PowerShell in Memory: https://isc.sans.edu/forums/diary/Fileless+Malicious+PowerShell+Sample/23081/arrow-up-right

DelegateType Reflection: https://docs.microsoft.com/en-us/dotnet/framework/reflection-and-codedom/how-to-hook-up-a-delegate-using-reflectionarrow-up-right

Get Delegate: https://www.powershellgallery.com/packages/poke/1.0.0.2/Content/delegate.ps1arrow-up-right

Proxy-Aware PowerShell Communications: https://powershell.org/forums/topic/set-dsclocalconfigurationmanager-and-proxy-awareness/arrow-up-right

PowerShell Proxy with Authentication: https://medium.com/river-yang/powershell-working-behind-a-proxy-with-authentication-eb68a337f222arrow-up-right

JScript Execution: https://docs.microsoft.com/en-us/previous-versions/windows/desktop/indexsrv/running-a-jscript-queryarrow-up-right

JScript Basic Dropper: https://github.com/hlldz/SpookFlarearrow-up-right

Payload Creation and Obfuscation: https://github.com/tyranid/DotNetToJScriptarrow-up-right

SharpShooter: https://github.com/mdsecactivebreach/SharpShooterarrow-up-right

Process Injection and Migration

Process Injection:

https://github.com/3xpl01tc0d3r/ProcessInjectionarrow-up-right https://rastamouse.me/blog/process-injection-dinvoke/arrow-up-right

DLL Injection:

http://blog.opensecurityresearch.com/2013/01/windows-dll-injection-basics.htmlarrow-up-right

https://medium.com/bug-bounty-hunting/dll-injection-attacks-in-a-nutshell-71bc84ac59bdarrow-up-right

Reflective DLL Injection: https://github.com/stephenfewer/ReflectiveDLLInjectionarrow-up-right

DLL Injection via PowerShell: https://clymb3r.wordpress.com/2013/04/06/reflective-dll-injection-with-powershell/arrow-up-right

Process Hollowing: https://gist.github.com/smgorelik/9a80565d44178771abf1e4da4e2a0e75arrow-up-right

Introduction to Antivirus Evasion

Metasploit Encryptors: https://blog.rapid7.com/2019/11/21/metasploit-shellcode-grows-up-encrypted-and-authenticated-c-shells/arrow-up-right

Payload Encryption: https://sevrosecurity.com/2019/05/25/bypass-windows-defender-with-a-simple-shell-loader/arrow-up-right

Advanced Antivirus Evasion

Antiscan.me: https://antiscan.me/arrow-up-right

ASB Bbypass:

https://rastamouse.me/blog/asb-bypass-pt2/arrow-up-right https://rastamouse.me/blog/asb-bypass-pt3/arrow-up-right https://rastamouse.me/blog/asb-bypass-pt4/arrow-up-right

Application Whitelisting

Intro: https://searchsecurity.techtarget.com/definition/application-whitelistingarrow-up-right

Bypasses: https://github.com/api0cradle/UltimateAppLockerByPassListarrow-up-right

Bypassing Network Filters

Domain Fronting:

https://attack.mitre.org/techniques/T1090/004/arrow-up-right

https://medium.com/@malcomvetter/simplifying-domain-fronting-8d23dcb694a0arrow-up-right

DNS Tunneling

https://www.paloaltonetworks.com/cyberpedia/what-is-dns-tunnelingarrow-up-right

https://unit42.paloaltonetworks.com/dns-tunneling-how-dns-can-be-abused-by-malicious-actors/arrow-up-right

Linux Post-Exploitation

Command List: https://github.com/mubix/post-exploitation/wiki/Linux-Post-Exploitation-Command-Listarrow-up-right

Kiosk Breakouts

Kiosk Breakouts / Attacks: https://www.trustedsec.com/blog/kioskpos-breakout-keys-in-windows/arrow-up-right

Kiosk Windows: https://www.engetsu-consulting.com/blog/kiosk-breakout-windowsarrow-up-right

Shared DLL Hijacking: : https://www.boiteaklou.fr/Abusing-Shared-Libraries.htmlarrow-up-right

Windows Credentials

MITRE: https://attack.mitre.org/tactics/TA0006/arrow-up-right

SAM Dump: https://www.hackingarticles.in/credential-dumping-sam/arrow-up-right

Hardening the Local Admin Account (LAPS):

https://rastamouse.me/blog/laps-pt1/arrow-up-right https://rastamouse.me/blog/laps-pt2/arrow-up-right

LAPSPasswords: https://github.com/kfosaaen/Get-LAPSPasswordsarrow-up-right

Windows Lateral Movement

Microsoft Defender Lateral Movement Paths: https://docs.microsoft.com/en-us/defender-for-identity/use-case-lateral-movement-patharrow-up-right

Offensive Lateral Movement: https://posts.specterops.io/offensive-lateral-movement-1744ae62b14farrow-up-right

Restricting SMB: https://medium.com/palantir/restricting-smb-based-lateral-movement-in-a-windows-environment-ed033b888721arrow-up-right

Linux Lateral Movement

MITRE: https://attack.mitre.org/matrices/enterprise/linux/arrow-up-right

Lateral Movement with shell: https://redcanary.com/blog/lateral-movement-with-secure-shell/arrow-up-right

Post exploit: https://mrw0r57.github.io/2020-05-31-linux-post-exploitation-10-4/arrow-up-right

Microsoft SQL Attacks

MS SQL Enumeration:

https://www.mssqltips.com/sqlservertip/2013/find-sql-server-instances-across-your-network-using-windows-powershell/arrow-up-right

https://www.mssqltips.com/sqlservertip/4181/inventory-sql-logins-on-a-sql-server-with-powershell/arrow-up-right

NC Path Injection

https://gist.github.com/nullbind/7dfca2a6309a4209b5aeef181b676c6earrow-up-right

https://blog.netspi.com/executing-smb-relay-attacks-via-sql-server-using-metasploit/arrow-up-right

https://hackingandsecurity.blogspot.com/2017/07/10-places-to-stick-your-unc-path.htmlarrow-up-right

https://secure360.org/wp-content/uploads/2017/05/SQL-Server-Hacking-on-Scale-UsingPowerShell_S.Sutherland.pdfarrow-up-right

Active Directory Exploitation

BloodHound: https://github.com/BloodHoundAD/BloodHoundarrow-up-right

Ingestors: https://github.com/BloodHoundAD/SharpHoundarrow-up-right

https://github.com/BloodHoundAD/BloodHound/blob/master/Collectors/AzureHound.ps1arrow-up-right

https://github.com/BloodHoundAD/BloodHound/blob/master/Collectors/SharpHound.ps1arrow-up-right

Abusing Object Security Permissions: https://www.ired.team/offensive-security-experiments/active-directory-kerberos-abuse/abusing-active-directory-acls-acesarrow-up-right

Unconstrained Delegation:

https://posts.specterops.io/hunting-in-active-directory-unconstrained-delegation-forests-trusts-71f2b33688e1arrow-up-right

https://dirkjanm.io/krbrelayx-unconstrained-delegation-abuse-toolkit/arrow-up-right

https://www.qomplx.com/qomplx-knowledge-kerberos-delegation-attacks-explained/arrow-up-right

Constrained Delegation:

https://www.guidepointsecurity.com/delegating-like-a-boss-abusing-kerberos-delegation-in-active-directory/arrow-up-right

https://stealthbits.com/blog/constrained-delegation-abuse-abusing-constrained-delegation-to-achieve-elevated-access/arrow-up-right

Resource-Based Constrained Delegation:

https://shenaniganslabs.io/2019/01/28/Wagging-the-Dog.htmlarrow-up-right

https://www.ired.team/offensive-security-experiments/active-directory-kerberos-abuse/resource-based-constrained-delegation-ad-computer-object-take-over-and-privilged-code-executionarrow-up-right

Active Directoy Inter-Forest Exploitation:

http://www.harmj0y.net/blog/redteaming/a-guide-to-attacking-domain-trusts/arrow-up-right

https://www.harmj0y.net/blog/redteaming/not-a-security-boundary-breaking-forest-trusts/arrow-up-right

https://adsecurity.org/?p=1588arrow-up-right

https://github.com/S1ckB0y1337/Active-Directory-Exploitation-Cheat-Sheetarrow-up-right

https://book.hacktricks.xyz/windows/active-directory-methodology/acl-persistence-abusearrow-up-right

##Tools & Scripts:

BloodHoundL: https://github.com/BloodHoundAD/BloodHoundarrow-up-right

CrackMapExec: https://github.com/byt3bl33d3r/CrackMapExecarrow-up-right

JAWS: https://github.com/411Hall/JAWSarrow-up-right

Linux priv checker: https://github.com/sleventyeleven/linuxprivcheckerarrow-up-right

Last updated