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

[It broke]: ntfy nofications use *** for authentication instead of the user input #171

Closed
nickconway opened this issue Apr 22, 2024 · 8 comments
Labels
bug Something isn't working

Comments

@nickconway
Copy link

What is broken?

When an episode is downloaded and the API container tries to send a notification via ntfy that requires authentication, it uses '***' for the auth parameter instead of what the user inputs, resulting in a 500 error.

Log-output

[04/22/2024 18:29:16.207]          Ntfy | Sending notification: Chapter downloaded - Hunter X Hunter - 1
[04/22/2024 18:29:16.569]          Ntfy | InternalServerError: {"code":50001,"http":500,"error":"internal server error"}

Additional stuff

ntfy gives this error:
2024/04/22 14:29:16 INFO Connection closed with HTTP 500 (ntfy error 50001) (error=illegal base64 data at input byte 0, http_method=POST, http_path=/tranga?auth=***, tag=http, visitor_auth_limiter_limit=0.016666666666666666, visitor_auth_limiter_tokens=30, visitor_id=ip:172.18.0.1, visitor_ip=172.18.0.1, visitor_messages=0, visitor_messages_limit=17280, visitor_messages_remaining=17280, visitor_request_limiter_limit=0.2, visitor_request_limiter_tokens=60, visitor_seen=2024-04-22T14:29:16.567-04:00)

@nickconway nickconway added the bug Something isn't working label Apr 22, 2024
@C9Glax
Copy link
Owner

C9Glax commented Apr 22, 2024

@db-2001 the *** sounds suspiciously much like the placeholder on the website...?

@db-2001
Copy link
Collaborator

db-2001 commented Apr 22, 2024

It does...but that should be a placeholder in the text box and not the value that we would use when configuring Ntfy. @nickconway have you tried to reconfigure Ntfy from the frontend?

@nickconway
Copy link
Author

I noticed that as well. I was doing everything from the frontend, I think what's happening is hitting apply when the textbox is filled with *** sets the auth value to *** instead of using the previous value. I've got the notification working now after making sure not to apply anything twice.

@C9Glax
Copy link
Owner

C9Glax commented Apr 22, 2024

I think I see the exact problem, instead of the placeholder tag, you set the value tag of textboxes, triggering an update. I'll just push a change in a sec.

C9Glax added a commit to C9Glax/tranga-website that referenced this issue Apr 22, 2024
@C9Glax
Copy link
Owner

C9Glax commented Apr 22, 2024

Okay when it finishes building in a second, the cuttingedge branch should have the fix.

@C9Glax
Copy link
Owner

C9Glax commented Apr 22, 2024

you might have to hard refresh (ctrl+f5) to clear the website cache, but its fixed for me :)

@C9Glax C9Glax closed this as completed Apr 22, 2024
@db-2001
Copy link
Collaborator

db-2001 commented Apr 22, 2024

I think I see the exact problem, instead of the placeholder tag, you set the value tag of textboxes, triggering an update. I'll just push a change in a sec.

I'll take a look and fix this on the front end too, it thought I had checked to set the placeholder but ill check for the other connectors too

@C9Glax
Copy link
Owner

C9Glax commented Apr 22, 2024

I fixed it on the frontend, since that it where the problem was.
See here:
C9Glax/tranga-website@38572a3

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

3 participants