{
  "Module 29: LDAP and Active Directory": [
    {
      "question": "1. What is the main purpose of NTLM?",
      "options": [
        "A. To provide secure authentication over a network",
        "B. To manage network traffic",
        "C. To encrypt data transmissions",
        "D. To provide remote access to a network"
      ],
      "num_answers": 1,
      "answer": "A. To provide secure authentication over a network",
      "answer_keys": ["A"],
      "explanations": {
        "A": "✅ NTLM (NT LAN Manager) is a Microsoft authentication protocol used to authenticate users and computers over a network.",
        "B": "❌ NTLM does not manage network traffic; routing/switching devices do.",
        "C": "❌ NTLM may use cryptographic operations, but its primary purpose is authentication, not bulk data encryption.",
        "D": "❌ Remote access can use NTLM for auth, but NTLM itself is not a remote access protocol."
      }
    },
    {
      "question": "2. Which of the following is an effective countermeasure against LDAP enumeration?",
      "options": [
        "A. Use NTLM or other authentication mechanisms to limit access to legitimate users",
        "B. Allow unlimited search results to be returned from the LDAP server",
        "C. Disable access control mechanisms on the LDAP server",
        "D. Use clear-text communication for LDAP traffic"
      ],
      "num_answers": 1,
      "answer": "A. Use NTLM or other authentication mechanisms to limit access to legitimate users",
      "answer_keys": ["A"],
      "explanations": {
        "A": "✅ Requiring authentication (e.g., NTLM/Kerberos) and proper ACLs helps prevent anonymous LDAP enumeration.",
        "B": "❌ Unlimited searches make enumeration easier, not harder.",
        "C": "❌ Disabling access controls completely exposes the directory.",
        "D": "❌ Clear-text LDAP (no TLS) leaks information and credentials."
      }
    },
    {
      "question": "3. Which of the following protocols is best suited to limit access to an LDAP server in a Windows/AD environment?",
      "options": [
        "A. NTLM",
        "B. WPA",
        "C. WEP",
        "D. WPA2"
      ],
      "num_answers": 1,
      "answer": "A. NTLM",
      "answer_keys": ["A"],
      "explanations": {
        "A": "✅ NTLM (and Kerberos) are used for authenticating access to directory services such as LDAP in AD.",
        "B": "❌ WPA secures Wi-Fi, not LDAP directly.",
        "C": "❌ WEP is obsolete and insecure Wi-Fi encryption.",
        "D": "❌ WPA2 is also Wi-Fi security, not an LDAP access-control protocol."
      }
    },
    {
      "question": "4. Which of the following protocols will help prevent unauthorized use or queries of LDAP services by requiring authenticated access?",
      "options": [
        "A. SNMP",
        "B. FTP",
        "C. NTLM",
        "D. ICMP"
      ],
      "num_answers": 1,
      "answer": "C. NTLM",
      "answer_keys": ["C"],
      "explanations": {
        "C": "✅ NTLM can be used as an authentication mechanism for LDAP binds in Windows environments, reducing anonymous queries.",
        "A": "❌ SNMP is for network management and is not used to secure LDAP queries.",
        "B": "❌ FTP is a file transfer protocol, unrelated to LDAP auth.",
        "D": "❌ ICMP is used for diagnostics (ping), not authentication."
      }
    },
    {
      "question": "5. Identify the tool from the description: It provides a GUI to query remote LDAP servers, can anonymously query for sensitive info (usernames, addresses), offers an LDAP browser, and is open source.",
      "options": [
        "A. Nmap",
        "B. Wireshark",
        "C. JXplorer",
        "D. Google search operator"
      ],
      "num_answers": 1,
      "answer": "C. JXplorer",
      "answer_keys": ["C"],
      "explanations": {
        "C": "✅ JXplorer is an open-source LDAP browser/editor that can query remote LDAP directories.",
        "A": "❌ Nmap is a network scanner, not a dedicated LDAP browser.",
        "B": "❌ Wireshark is a packet sniffer, not an LDAP GUI browser.",
        "D": "❌ Google operators are for web search, not LDAP queries."
      }
    },
    {
      "question": "6. Which of the following services commonly runs on TCP port 389?",
      "options": [
        "A. HTTPS",
        "B. HTTP",
        "C. LDAP",
        "D. LDAPS"
      ],
      "num_answers": 1,
      "answer": "C. LDAP",
      "answer_keys": ["C"],
      "explanations": {
        "C": "✅ Port 389/TCP is the default port for LDAP (unencrypted).",
        "A": "❌ HTTPS commonly uses port 443.",
        "B": "❌ HTTP commonly uses port 80.",
        "D": "❌ LDAPS usually listens on port 636."
      }
    },
    {
      "question": "7. Which of the following services commonly runs on TCP port 636?",
      "options": [
        "A. HTTPS",
        "B. HTTP",
        "C. LDAP",
        "D. LDAPS"
      ],
      "num_answers": 1,
      "answer": "D. LDAPS",
      "answer_keys": ["D"],
      "explanations": {
        "D": "✅ Port 636/TCP is the default port for LDAP over SSL/TLS (LDAPS).",
        "A": "❌ HTTPS typically uses port 443.",
        "B": "❌ HTTP typically uses port 80.",
        "C": "❌ Plain LDAP uses port 389."
      }
    },
    {
      "question": "8. Which port is primarily used for standard (unencrypted) LDAP traffic?",
      "options": [
        "A. 21",
        "B. 25",
        "C. 389",
        "D. 636"
      ],
      "num_answers": 1,
      "answer": "C. 389",
      "answer_keys": ["C"],
      "explanations": {
        "C": "✅ TCP 389 is the well-known port for LDAP.",
        "A": "❌ Port 21 is used by FTP.",
        "B": "❌ Port 25 is used by SMTP.",
        "D": "❌ Port 636 is used by LDAPS (secure LDAP)."
      }
    },
    {
      "question": "9. Which port is primarily used for LDAPS (LDAP over SSL/TLS) traffic?",
      "options": [
        "A. 21",
        "B. 25",
        "C. 389",
        "D. 636"
      ],
      "num_answers": 1,
      "answer": "D. 636",
      "answer_keys": ["D"],
      "explanations": {
        "D": "✅ TCP 636 is the default port for LDAPS.",
        "A": "❌ Port 21 is FTP.",
        "B": "❌ Port 25 is SMTP.",
        "C": "❌ Port 389 is plain LDAP."
      }
    },
    {
      "question": "10. In an Active Directory environment, which service is primarily responsible for storing and providing access to directory information via LDAP?",
      "options": [
        "A. DNS Server role",
        "B. Active Directory Domain Services (AD DS)",
        "C. DHCP Server role",
        "D. File and Print Services"
      ],
      "num_answers": 1,
      "answer": "B. Active Directory Domain Services (AD DS)",
      "answer_keys": ["B"],
      "explanations": {
        "B": "✅ AD DS stores directory objects and exposes them via LDAP, Kerberos, and related protocols.",
        "A": "❌ DNS assists AD, but does not store user/computer objects.",
        "C": "❌ DHCP hands out IP addresses.",
        "D": "❌ File/Print Services share files and printers, not directory info."
      }
    },
    {
      "question": "11. Which of the following is NOT a typical object type stored in Active Directory?",
      "options": [
        "A. User",
        "B. Computer",
        "C. Organizational Unit (OU)",
        "D. IP Packet"
      ],
      "num_answers": 1,
      "answer": "D. IP Packet",
      "answer_keys": ["D"],
      "explanations": {
        "D": "✅ AD stores logical directory objects, not network packets.",
        "A": "❌ User accounts are core AD objects.",
        "B": "❌ Computer accounts are AD objects.",
        "C": "❌ OUs are containers used to group objects and apply GPOs."
      }
    },
    {
      "question": "12. Which query would a hacker MOST likely use an LDAP browser for during AD reconnaissance?",
      "options": [
        "A. Enumerating wireless SSIDs",
        "B. Enumerating user accounts and group memberships",
        "C. Capturing VoIP calls",
        "D. Sniffing raw Ethernet frames"
      ],
      "num_answers": 1,
      "answer": "B. Enumerating user accounts and group memberships",
      "answer_keys": ["B"],
      "explanations": {
          "B": "✅ LDAP browsers are commonly used to list users, groups, OUs, and other directory objects.",
          "A": "❌ SSID enumeration is done with wireless tools (e.g., airodump-ng).",
          "C": "❌ VoIP capture is done with network sniffers, not LDAP.",
          "D": "❌ Raw frames are captured with tools like Wireshark/tcpdump."
      }
    },
    {
      "question": "13. Which of the following BEST describes an Active Directory Domain Controller (DC)?",
      "options": [
        "A. A server that only handles email routing",
        "B. A server that hosts the AD database and handles authentication/authorization",
        "C. A dedicated firewall device for the domain",
        "D. A network time protocol (NTP) appliance"
      ],
      "num_answers": 1,
      "answer": "B. A server that hosts the AD database and handles authentication/authorization",
      "answer_keys": ["B"],
      "explanations": {
        "B": "✅ Domain Controllers store the AD database (NTDS.dit) and service logons, LDAP, and Kerberos.",
        "A": "❌ Email is handled by mail servers (e.g., Exchange).",
        "C": "❌ A firewall is not inherently a DC.",
        "D": "❌ While DCs often provide time sync, that is not their main purpose."
      }
    },
    {
      "question": "14. Which protocol is primarily used by Active Directory for authentication instead of NTLM in modern domains?",
      "options": [
        "A. RADIUS",
        "B. Kerberos",
        "C. TACACS+",
        "D. PAP"
      ],
      "num_answers": 1,
      "answer": "B. Kerberos",
      "answer_keys": ["B"],
      "explanations": {
        "B": "✅ Kerberos is the default authentication protocol for AD domains (Ticket-based).",
        "A": "❌ RADIUS is used for network access control, VPNs, Wi-Fi.",
        "C": "❌ TACACS+ is common on network devices, not for AD auth.",
        "D": "❌ PAP is insecure clear-text password auth."
      }
    },
    {
      "question": "15. Which Nmap NSE script is MOST appropriate for enumerating LDAP information from an Active Directory server?",
      "options": [
        "A. smb-enum-shares",
        "B. ldap-rootdse",
        "C. http-enum",
        "D. ftp-anon"
      ],
      "num_answers": 1,
      "answer": "B. ldap-rootdse",
      "answer_keys": ["B"],
      "explanations": {
        "B": "✅ ldap-rootdse retrieves useful info from the LDAP Root DSE, such as naming contexts.",
        "A": "❌ smb-enum-shares is for SMB share enumeration, not LDAP.",
        "C": "❌ http-enum is for HTTP directory and app enumeration.",
        "D": "❌ ftp-anon checks anonymous FTP access."
      }
    },
    {
      "question": "16. Which of the following attacks specifically abuses Active Directory permissions to replicate password hashes from a Domain Controller, similar to the DC’s own replication?",
      "options": [
        "A. Kerberoasting",
        "B. DCSync attack",
        "C. Pass-the-Hash attack",
        "D. Golden Ticket attack"
      ],
      "num_answers": 1,
      "answer": "B. DCSync attack",
      "answer_keys": ["B"],
      "explanations": {
        "B": "✅ DCSync leverages replication permissions to request password data from a DC.",
        "A": "❌ Kerberoasting targets service tickets for offline cracking.",
        "C": "❌ Pass-the-Hash uses captured NTLM hashes to authenticate, not to replicate from DCs.",
        "D": "❌ Golden Ticket forges TGTs using the KRBTGT hash."
      }
    },
    {
      "question": "17. In Active Directory, which object type is typically used as a container to organize users, computers, and groups for easier management and Group Policy application?",
      "options": [
        "A. Group Policy Object (GPO)",
        "B. Organizational Unit (OU)",
        "C. Domain Controller (DC)",
        "D. Schema"
      ],
      "num_answers": 1,
      "answer": "B. Organizational Unit (OU)",
      "answer_keys": ["B"],
      "explanations": {
        "B": "✅ OUs are logical containers used to group objects and apply GPOs.",
        "A": "❌ GPOs are policy objects linked to OUs, sites, or domains.",
        "C": "❌ DC is a server role, not a container.",
        "D": "❌ The schema defines object classes and attributes."
      }
    },
    {
      "question": "18. Which tool is widely used by attackers and defenders to visualize and analyze Active Directory relationships and attack paths (e.g., identifying paths to Domain Admin)?",
      "options": [
        "A. BloodHound",
        "B. Wireshark",
        "C. John the Ripper",
        "D. Nikto"
      ],
      "num_answers": 1,
      "answer": "A. BloodHound",
      "answer_keys": ["A"],
      "explanations": {
        "A": "✅ BloodHound maps AD trust relationships and privileges to highlight attack paths.",
        "B": "❌ Wireshark analyzes network packets, not AD graph relationships.",
        "C": "❌ John is a password cracker, not an AD graph tool.",
        "D": "❌ Nikto is a web server scanner."
      }
    },
    {
      "question": "19. Which of the following configuration issues MOST increases the risk of LDAP/AD enumeration by anonymous users?",
      "options": [
        "A. Requiring LDAPS for all binds",
        "B. Allowing anonymous or null LDAP binds with broad search permissions",
        "C. Enforcing strong password policies for all domain users",
        "D. Limiting LDAP queries to specific service accounts"
      ],
      "num_answers": 1,
      "answer": "B. Allowing anonymous or null LDAP binds with broad search permissions",
      "answer_keys": ["B"],
      "explanations": {
        "B": "✅ Anonymous binds with wide permissions allow attackers to enumerate AD objects without credentials.",
        "A": "❌ LDAPS improves confidentiality, not enumeration risk.",
        "C": "❌ Strong passwords help, but do not directly control LDAP search scope.",
        "D": "❌ Restricting queries to service accounts reduces risk, not increases it."
      }
    },
    {
      "question": "20. Which Windows process is MOST associated with handling authentication requests (NTLM/Kerberos) and storing credentials in memory on Domain Controllers and member servers?",
      "options": [
        "A. svchost.exe",
        "B. lsass.exe",
        "C. winlogon.exe",
        "D. explorer.exe"
      ],
      "num_answers": 1,
      "answer": "B. lsass.exe",
      "answer_keys": ["B"],
      "explanations": {
        "B": "✅ LSASS (Local Security Authority Subsystem Service) manages local security policy, auth, and stores credential material.",
        "A": "❌ svchost.exe is a generic service host.",
        "C": "❌ winlogon.exe handles logon session startup, but LSASS holds the secrets.",
        "D": "❌ explorer.exe is the user shell."
      }
    },
    {
      "question": "21. Which attack typically targets service accounts in Active Directory by requesting their Kerberos service tickets and then performing offline brute force against the ticket’s encrypted portion?",
      "options": [
        "A. DCSync attack",
        "B. Kerberoasting",
        "C. AS-REP roasting",
        "D. LLMNR poisoning"
      ],
      "num_answers": 1,
      "answer": "B. Kerberoasting",
      "answer_keys": ["B"],
      "explanations": {
        "B": "✅ Kerberoasting abuses SPN-configured accounts to obtain crackable service tickets.",
        "A": "❌ DCSync abuses replication rights to pull hashes.",
        "C": "❌ AS-REP roasting targets users without pre-auth, different step in Kerberos.",
        "D": "❌ LLMNR poisoning is a network-level spoofing attack, not Kerberos ticket abuse."
      }
    },
    {
      "question": "22. Which of the following BEST describes an Active Directory Group Policy Object (GPO)?",
      "options": [
        "A. A database that stores all directory objects",
        "B. A set of configurations applied to users and computers via OUs, sites, or domains",
        "C. A role that promotes a server to a Domain Controller",
        "D. A backup file used for AD restore"
      ],
      "num_answers": 1,
      "answer": "B. A set of configurations applied to users and computers via OUs, sites, or domains",
      "answer_keys": ["B"],
      "explanations": {
        "B": "✅ GPOs define security and configuration settings applied to AD objects.",
        "A": "❌ The AD database (NTDS.dit) stores objects, not GPOs themselves.",
        "C": "❌ Promotion to DC is done via roles/services, not a GPO.",
        "D": "❌ Backups are separate (e.g., system state)."
      }
    },
    {
      "question": "23. Which of the following ports/services should a CEH pay close attention to when scanning an environment for exposed Active Directory-related services?",
      "options": [
        "A. 80 (HTTP) only",
        "B. 21 (FTP) and 23 (Telnet) only",
        "C. 88 (Kerberos), 389/636 (LDAP/LDAPS), 445 (SMB), 3268/3269 (Global Catalog)",
        "D. 110 (POP3) and 143 (IMAP) only"
      ],
      "num_answers": 1,
      "answer": "C. 88 (Kerberos), 389/636 (LDAP/LDAPS), 445 (SMB), 3268/3269 (Global Catalog)",
      "answer_keys": ["C"],
      "explanations": {
        "C": "✅ These ports are closely tied to AD authentication and directory services and are critical for assessment.",
        "A": "❌ HTTP may be in use, but not specifically AD core services.",
        "B": "❌ FTP/Telnet are legacy clear-text protocols, not AD-specific.",
        "D": "❌ POP3/IMAP relate to email retrieval, not AD services."
      }
    },
    {
      "question": "24. Which tool is commonly used on Linux/Kali to enumerate Active Directory information (users, groups, shares) over SMB and sometimes LDAP?",
      "options": [
        "A. enum4linux",
        "B. Aircrack-ng",
        "C. Nikto",
        "D. Dirbuster"
      ],
      "num_answers": 1,
      "answer": "A. enum4linux",
      "answer_keys": ["A"],
      "explanations": {
        "A": "✅ enum4linux is designed for SMB/NetBIOS/AD enumeration on Windows domains.",
        "B": "❌ Aircrack-ng is for Wi-Fi cracking.",
        "C": "❌ Nikto scans web servers for vulnerabilities.",
        "D": "❌ Dirbuster brute-forces web directories, not AD."
      }
    },
    {
      "question": "25. From a defensive perspective, which countermeasure is MOST effective to reduce the impact of AD-based attacks such as DCSync and Golden Ticket?",
      "options": [
        "A. Grant Domain Admin rights to all IT staff for convenience",
        "B. Regularly rotate KRBTGT account password and restrict replication permissions",
        "C. Disable all logging on Domain Controllers",
        "D. Place Domain Controllers directly on the internet with public IPs"
      ],
      "num_answers": 1,
      "answer": "B. Regularly rotate KRBTGT account password and restrict replication permissions",
      "answer_keys": ["B"],
      "explanations": {
        "B": "✅ Rotating KRBTGT reduces Golden Ticket lifetime; limiting replication rights mitigates DCSync abuse.",
        "A": "❌ Excessive Domain Admin rights massively increase risk.",
        "C": "❌ Disabling logs removes detection capability.",
        "D": "❌ Exposing DCs directly to the internet is extremely dangerous."
      }
    }
  ]
}
