Skip to content
ADscan Docs

Guest SMB sessions

How ADscan checks for guest access over SMB, the adscan- name a client's logs will show for those sign-ins, and why that name cannot lock an account.

Some Windows hosts and file servers still let anyone in as a guest. A share that opens to a guest opens to every device on the network, so ADscan checks for it. It tries a guest session against the hosts it finds, lists the shares that session can see, and on a domain controller that allows it, uses the session to list accounts.

This page is for the person who will read the logs afterwards. It says what those sign-ins look like and why they are safe.

The name ADscan signs in with

A guest session is asked for by signing in with a name and no password. A server that allows guest access maps any name it does not know to its guest account. So the name matters. If a real account happened to carry it, the server would see a failed sign-in for that account.

From 15.0.0 ADscan uses a name made for the engagement, adscan- followed by eight random hexadecimal characters.

shell
adscan-3f9a1c7e

The name is generated once per workspace and kept in the workspace, in smb_guest_identity.json. Every guest probe of that engagement uses it, on the first day and after a resume, so a client sees one name they can attribute to the assessment. On the Enterprise platform it is one name per workspace as well, shared by every scan of that workspace.

Why it cannot lock an account

Before ADscan sends the first guest sign-in in a domain, it establishes that no account there carries the name.

  1. It looks at what it already knows, the user lists and the directory inventory it has collected.
  2. In a real environment it asks the domain controller's Kerberos service about the name, once per workspace and domain. The question carries no password, so it cannot count as a failed sign-in on anyone. The answer "no such account" is proof that the name is free.
  3. If an account did carry the name, ADscan would throw the name away and generate another.

With that proof, a guest probe that a host refuses is a refused sign-in for a name that does not exist. No account's bad-password count moves and nobody is locked out, however many hosts are asked.

When the Kerberos service does not answer, ADscan is more careful. The name is still eight random characters behind a prefix no directory uses, but its absence is not proven. So in a real environment guest probing stops after three refusals. The hosts that were not asked are stated in the report as not checked, with the count, and are never shown as hosts that refused guest access. Under a lab policy there is no such limit.

No domain, no guest probe

A guest sign-in is only sent with a domain. Without one, the server would compare the name with its own local accounts, which nothing ADscan can read covers.

What a client's logs show

Search the logs for adscan-. From the address of the machine that runs ADscan you will find these.

  • On a domain controller. One Kerberos request for the name, answered as an unknown account. This is the check described above.
  • On a host that allows guest access. A network sign-in under the name with an empty password, accepted as a guest session, followed by the share listing.
  • On a host that does not. The same sign-in, refused, for a user name that does not exist.

None of these is a failed sign-in on one of your accounts. If your monitoring raises an alert for sign-ins with unknown user names, expect one burst of them from the scanner's address while the hosts are being checked, all carrying the same name.

In the results

A host that grants guest access is reported with the shares the guest session could reach, and the share view states which identity each session used, the guest name or a real account. A host that refuses guest access is reported as refusing it. A host that was never asked is reported as not checked.

Using a name of your own

If a client wants a particular name in their logs, set ADSCAN_SMB_GUEST_USERNAME before the scan. ADscan holds that name to a stricter test than its own. It sends it only when the domain controller's Kerberos service has confirmed that no account carries it. A name written with a domain, in front of it or after it, or with a trailing $ is refused, and so is a name that turns out to be an account. In those cases no guest sign-in is sent, and the message says to remove the setting so the generated name is used.

Find this useful?
Pass it to the next pentester running an AD engagement
Running 2+ AD engagements/year?
First PRO assessment free·Free in exchange for feedback
Automated PDF reports. Save ≥1 day per engagement.

ADscan — AD pentest automation for security consultants