caronc / apprise-api

A lightweight REST framework that wraps the Apprise Notification Library
https://hub.docker.com/r/caronc/apprise
MIT License
580 stars 50 forks source link

How to secure requests to a public Apprise instance #126

Closed kingp0dd closed 11 months ago

kingp0dd commented 12 months ago

:question: Question I don't know if there's already a way for this:

End goal is:

curl -XPOST -H "Content-type: application/json" -d '{ "urls" : "matrixs://user:pass@test.com/!V12312Eblxy:localhost" , "body" : "test" }' 'http://192.168.0.179:8000/notify/TOKENHERE'

But it seems that the URL saved in the Persistent Config file cannot be overridden.

Is there another way to make notify requests secure?

caronc commented 12 months ago

Place an Nginx/lighthttp/Apache proxy in front and just set up basic auth. You can also secure the connection this way too with https:// .

As per the dynamic room, this is similar to another request i saw where the notification credentials would be kept remotely, but the parameters to them could be passed in during a call to the API. This does not exist at this time, but is technically doable.

kingp0dd commented 12 months ago

That basic auth in reverse proxy is a viable option. Thanks for pointing it out and for your work!

On Wed, Jul 19, 2023 at 6:11 PM Chris Caron @.***> wrote:

Place an Nginx/lighthttp/Apache proxy in front and just set up basic auth. You can also secure the connection this way too with https:// .

As per the dynamic room, this is similar to another request i saw where the notification credentials would be kept remotely, but the parameters to them could be passed in during a call to the API. This does not exist at this time, but is technically doable.

— Reply to this email directly, view it on GitHub https://github.com/caronc/apprise-api/issues/126, or unsubscribe https://github.com/notifications/unsubscribe-auth/ACGD6KUGKRW25SV7TCYPLUTXQ6XGHANCNFSM6AAAAAA2PRQH3E . You are receiving this because you authored the thread.Message ID: @.***>

caronc commented 11 months ago

Did you end up getting this working; would you be okay if i close the ticket?

kingp0dd commented 11 months ago

Oh yes i did! Thanks again