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

Token authentication doesn't work if default user credentials are defined in client.yml #650

Closed
Xinayder opened this issue Mar 3, 2023 · 0 comments
Labels
🪲 bug Something isn't working

Comments

@Xinayder
Copy link
Contributor

Xinayder commented Mar 3, 2023

🐞 Describe the bug

Trying to use ntfy CLI with token authentication seems to fail if the client.yml settings file has default user credentials configured, i.e., the fields default-user and default-password are set.

💻 Components impacted

ntfy server

💡 Screenshots and/or logs

Setting client.yml with default-user: user and default-password: password:

$ ntfy pub -d --token=<redacted> https://notify.mydomain.com/teste testing message

2023/03/03 16:30:53 DEBUG notify.mydomain.com/teste Publishing message with headers map[Authorization:[Basic <redacted>]]
{"code":40101,"http":401,"error":"unauthorized","link":"https://ntfy.sh/docs/publish/#authentication"}

🔮 Additional context

$ ntfy token list

user user
- <redacted>, never expires, accessed from 0.0.0.0 at 03 Mar 23 16:29 UTC
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

No branches or pull requests

1 participant