Git Product home page Git Product logo

adspraygen's Introduction

Release Go Report Card GitHub go.mod Go version License

ADSprayGen

ADSprayGen a command-line utility written in Go that leverages LDAP (Lightweight Directory Access Protocol) to retrieve user attributes. These attributes can then be used to generate possible passwords for the users. A mask is required to generate the passwords, which can contain user attribute placeholders and modifiers for them.

Installation

Option 1: Prebuilt Binary

Prebuilt binaries of ADSprayGen are provided on the releases page.

Option 2: Install Using Go

Requirements: go1.21 or higher

go install -v github.com/m10x/adspraygen@latest

Usage

Example: adspraygen -d domain.local -u m10x -p m10x -s 10.10.10.10 -m 'Foobar{givenName#Reverse}{MonthGerman}{YYYY}!'

Mask Placeholders

  • {cn} : Full Name
  • {givenName} : First Name
  • {sn} : Last Name
  • {sAMAccountName} : Logon Name (Pre Windows 2000)
  • {rPrincipalName} : Logon Name
  • {description} : Description
  • {info} : Notes
  • {department} : Department
  • {I} : City
  • {postcalCode} : Postal Code
  • Last password change
    • {YYYY} : e.g. 2024
    • {YY} : e.g. 24
    • {MM} : e.g. 01
    • {M} : e.g. 1
    • {SeasonGerman} : e.g. Herbst
    • {SeasonAmerican} : e.g. Fall
    • {SeasonBritish} : e.g. Autumn
    • {MonthGerman} : e.g. Januar
    • {MonthEnglish} : e.g. January

Mask Placeholder Transformators

  • #Reverse : Reverse the string
  • #LeetBasic : Subsitute e:3, o:0, i:1, a:4
  • #LeetBasicPlus : Subsitute e:3, o:0, i:1, a:@, t:7

TODOs

  • dump LDAP user attributes
  • import dumped LDAP user attributes instead of querying the LDAP server
  • handling of unknown mask attribute and unknown mask transformator
  • netexec format + kerbrute format
  • dump pw policy / fine grained policy
  • dump Hostnames
  • handling of givenName with multiple names

Common LDAP Errors

  • LDAP Result Code 1 "Operations Error": 000004DC: LdapErr: DSID-0C090A5C, comment: In order to perform this operation a successful bind must be completed on the connection. - Anonymous/Unauthenticated bind is not possible. Specify a password or NTLM hash.
  • LDAP Result Code 49 "Invalid Credentials": 80090308: LdapErr: DSID-0C090439, comment: AcceptSecurityContext error - The specified credentials are invalid
  • LDAP Result Code 49 "Invalid Credentials": 8009030C: LdapErr: DSID-0C0906B5, comment: AcceptSecurityContext error - Unauthenticated NTLM bind is not possible or specified credentials are not valid.

adspraygen's People

Contributors

m10x avatar

Stargazers

 avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.