6 - Learning Object 6️
Tasks
1 - Abuse an overly permissive Group Policy to get admin access on dcorp-ci.
Flag 9 [Student VM] - Name of the Group Policy attribute that is modified 🚩
Solutions
1 - Abuse an overly permissive Group Policy to get admin access on dcorp-ci.
Start InviShell and PowerView
and check info regarding GPO for DCORP-CI
It appartains to DevOps Policy, we can confirm it using Get-DomainGPO -Identity 'DevOps Policy'
command.
Now, we need to run ntlmrelayx (regarding impacket tool) on windows machine (using wsl.exe), to relay the LDAP service on the DC: sudo ntlmrelayx.py -t ldaps://<IP_DC> -wh <IP_VM> --http-port '80,8080' -i --no-smb-server
I obtain DC's IP pinging it
ping DOLLARCORP.MONEYCORP.LOCAL
-> 172.16.2.1
Now we need to establish the authentication on student machine, go there and create a Shortcut that connects to the ntlmrelayx listener:
Go to C:\AD\Tools -> Right Click -> New -> Shortcut. Copy the following command in the Shortcut location -> Next and Save it as studentx.lnk
Copy the studentx.lnk script to \\dcorp-ci\AI
Run it with double click and we establish the connection:
Now, we need to connect to this Ldap shell using nc 127.0.0.1 11000
and assign it permissions regarding DevOps GPO: {0BF8D01C-1F62-4BDC-958C-57140B67D147}
, do it using a new wsl shell:
Stop the ldap shell and ntlmrelayx using Ctrl + C.
Now, we need to run the GPOddity command to create the new template:
Keep it running, meanwhile open another wsl shell and create and share the std687-gp directory:
Great, now open a new windows shell as administrator to create a share (std687-gp) ad assign privileges for everyone:
Now, we can verify if the gPCfileSysPath has been modified for the DevOps Policy running this command:
The update for this policy is configured to be every 2 minutes in the lab and after waiting for 2 minutes, student867 should be added to the local administrators group on dcorp-ci:
Flag 9 [Student VM] - Name of the Group Policy attribute that is modified 🚩
The GPO attributed modified on DevOps Policy is: gPCfileSysPath
Last updated