SpecterOps / SpecterOps/SharpHound

Add Deleted Objects Collection

Open
#194 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
C#
Stars
1.3k
Forks
266
Avg merge
2d 7h
Merged PRs (30d)
3

Description

As it turns out, SharpHound does not collect CN=Deleted Objects.

Manually, it can be viewed using ldapsearch:

ldapsearch -H ldap://<DC_IP> \
  -x -D "user@domain.local" -w '<PASSWORD>' \
  -b "CN=Deleted Objects,DC=domain,DC=local" \
  -E 1.2.840.113556.1.4.417 \
  "(sAMAccountName=*)" '*'

NOTE: LDAP_SERVER_SHOW_DELETED OID - 1.2.840.113556.1.4.417 is required.

Ref: https://learn.microsoft.com/en-gb/previous-versions/windows/desktop/ldap/ldap-server-show-deleted-oid

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

No source file or test is named. Start by tracing SharpHound's existing LDAP collection entry points and compare their searches with the provided ldapsearch command, including the Deleted Objects base and LDAP_SERVER_SHOW_DELETED control. Done means CN=Deleted Objects entries are collected through the normal SharpHound output.

Written by the indexing model from the issue text.

Assessment

Tech stack
csharp
Domain
security
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
42/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.