Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Blank XDG_CONFIG_HOME not handled correctly #239

Open
vulns-are-features-too opened this issue Jan 29, 2022 · 2 comments · May be fixed by #242
Open

Blank XDG_CONFIG_HOME not handled correctly #239

vulns-are-features-too opened this issue Jan 29, 2022 · 2 comments · May be fixed by #242
Labels
bug Something isn't working

Comments

@vulns-are-features-too
Copy link

vulns-are-features-too commented Jan 29, 2022

Bug Description

XDG_CONFIG_HOME is not set but running pwncat without -c doesn't apply ~/.config/pwncat/pwncatrc.

pwncat version

I'm using Arch Linux, installed using the BlackArch package pwncat-caleb

$ pwncat --version
0.5.1

Steps to Reproduce

  1. XDG_CONFIG_HOME is blank
  2. Run pwncat without specifying -c.

Expected Behavior

~/.config/pwncat/pwncatrc is used

Actual behavior

~/.config/pwncat/pwncatrc not used. Tested by having alias q exit123 in pwncatrc and seeing pwncat not complaining about it.

@vulns-are-features-too vulns-are-features-too added the bug Something isn't working label Jan 29, 2022
@vulns-are-features-too vulns-are-features-too changed the title XDG_CONFIG_HOME not used correctly Blank XDG_CONFIG_HOME not handled correctly Jan 29, 2022
@calebstewart calebstewart linked a pull request Feb 2, 2022 that will close this issue
5 tasks
@calebstewart
Copy link
Owner

I can replicate this. It seems I was incorrectly using $XDG_DATA_HOME by mistake (which means it was looking in ~/.local/share/pwncatrc which is incorrect).

I've implemented some updates to fix this, and improve configuration and custom module handling in general over in #242. If you have the time/ability to check out that branch and let me know if it addresses your issue, I'd appreciate it! If not, I understand. I have tested that (at least for me) it loads configurations correctly now from ~/.config/pwncat/pwncatrc as it should (and also from places like /etc/pwncat/pwncatrc since it is obeying the XDG spec now).

@AnubisSec
Copy link

So this fixed some of the issues I was having, unrelated to OP. I see this branch properly parses the config file within ~/.config/pwncat/, but the only thing i still can't get to work is the function on_load.

image

image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants