主机
主机是用户、服务的载体,清晰了解每个主机的作用十分重要。在进入域后,我们可以记下每个主机的IP、FQDN是个好习惯 IP、操作系统、FQDN 等信息。
FQDN
获得FQDN:FQDN 的形式是 主机名与完整域名的接合,是在域内定位一台域主机的方法之一。在 PowerView 中,dnshostname 属性即主机的 FQDN。
Get-NetComputer | select dnshostname
获当前域,有 3 个主机,其中 2 个为 Windows 主机,dev01 为 Linux 主机。
我们再看看其他域的情况:
RAVEN-MED 域有 2 个主机
PROD 域有 4 个主机
其实我们可以根据 FQDN 来推测目标主机在域中的作用和角色是什么。web01,web02 确实都是 Web 应用服务器,file01 推测是作为文件服务器。
IP 地址
除了 FQDN,在域内定位域主机的另一种方式则是 IP,我们可以使用 Windows 命令 nslookup.exe 来得IP:到目标主机的 IP 地址。
nslookup [主机名]
我们可以指定 FQDN,查看其他域的域主机 IP。前提是 DNS 是相互同步的,通常在建立有域信任的情况下。
Windows主操作系统
虽然活动目录原生为 Windows 系统打造,但后来,也增加了对 Linux,Mac 等系统的支持。我们的靶场里没有 Mac 系统主机,但有一些 Linux 系统主机,我们可以根据 operatingsystem 属性来查看。
在 PROD 域中,也有一台 Linux 域主机:
Windows 主机
Windows 主机的属性更加复杂,因为 Windows 主机不仅作为主机,而且主机对应的主机帐号也享有着一些类似于用户帐号的特性。单纯作为主机而言,Windows 主机可以被设置委派、GPO等会紧接着被介绍,因此没有额外需要提醒GPO 实施的对象等。我们在后续内容中详细展开。
Linux主Linux 主机
默认情况下,Linux的Linux 的域主机是允许SSH访 SSH 访问的,除非指定禁止特定用户访问。这点不像在Windows上 Windows 上,如果需要配置 RDP、WinRM访问权,需要给用户单独设置特定权限。因此,有了明文凭证后,我们可以尝试使用域账户登录到Linux主 Linux 主机上。但系统管理员也可能会修改此默认配置。
root@ts:~# proxychains ssh serveradm@white-bird.local@172.16.1.53
ProxyChains-3.1 (http://proxychains.sf.net)
|S-chain|-<>-127.0.0.1:1080-<><>-172.16.1.53:22-<><>-OK
The authenticity of host '172.16.1.53 (172.16.1.53)' can't be established.
ECDSA key fingerprint is SHA256:P29afmXbT4KB5pYj0TbtWcjvEnMvl1ye0vYvFDf9UJE.
Are you sure you want to continue connecting (yes/no/[fingerprint])? yes
Warning: Permanently added '172.16.1.53' (ECDSA) to the list of known hosts.
serveradm@white-bird.local@172.16.1.53's password:
Welcome to Ubuntu 20.04.5 LTS (GNU/Linux 5.15.0-58-generic x86_64)
* Documentation: https://help.ubuntu.com
* Management: https://landscape.canonical.com
* Support: https://ubuntu.com/advantage
0 updates can be applied immediately.
The list of available updates is more than a week old.
To check for new updates run: sudo apt update
Your Hardware Enablement Stack (HWE) is supported until April 2025.
The programs included with the Ubuntu system are free software;
the exact distribution terms for each program are described in the
individual files in /usr/share/doc/*/copyright.
Ubuntu comes with ABSOLUTELY NO WARRANTY, to the extent permitted by
applicable law.
To run a command as administrator (user "root"), use "sudo <command>".
See "man sudo_root" for details.
serveradm@dev01:~$ whoami
serveradm