Skip to content

Add functionality to the output flag to output to a directory #16

Open

Description

@SoftAndoWetto

If possible, to add functionality to the output flag to specify the path to output to as well as the name

E.g.:
ghosthound -d lab.local -u blwasp -p 'Password123!' -o /home/htb-ac-1565529/Downloads/GhostHound.json --dc-ip 10.129.228.236 --disable-ldaps

Currently there is the message:
{ code: 21, kind: IsADirectory, message: "Is a directory" }

Activity

  1. self-assigned this
    on Aug 9, 2026
  2. added
    enhancementNew feature or request
    rustPull requests that update rust code
    on Aug 9, 2026
  3. JVBotelho commented on Aug 9, 2026

    @JVBotelho
    Owner

    Hey hey @SoftAndoWetto !
    Thanks for the report. I’ve prepared a fix in #17 and would appreciate validation in the same environment where you originally encountered the error before releasing it.

    Could you please test these two forms?

    1. Explicit output file:
    -o /home/htb-ac-1565529/Downloads/GhostHound.json

    Expected: writes exactly to /home/htb-ac-1565529/Downloads/GhostHound.json

    1. Existing output directory:
    -o /home/htb-ac-1565529/Downloads

    Expected: writes to /home/htb-ac-1565529/Downloads/ghosthound_output.json

    If you have Cargo installed, you can test the PR in isolation with:

    cargo install \
      --git https://github.com/JVBotelho/ghosthound \
      --rev 71538227f9c537e2f6af946b35c67b7249d18fec \
      --root /tmp/ghosthound-pr17 \
      ghosthound

    The test binary will be at:

    /tmp/ghosthound-pr17/bin/ghosthound

    It would also help if you could confirm whether the explicit full-file path failed originally, or whether the failing command passed only the directory to -o

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

Labels

enhancementNew feature or requestrustPull requests that update rust code

Projects

No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions