Skip to content

load server apikey if configured#73

Merged
2e3s merged 1 commit into2e3s:mainfrom
0xbrayo:load-apikeys
Apr 27, 2026
Merged

load server apikey if configured#73
2e3s merged 1 commit into2e3s:mainfrom
0xbrayo:load-apikeys

Conversation

@0xbrayo
Copy link
Copy Markdown
Contributor

@0xbrayo 0xbrayo commented Apr 25, 2026

Adds support for auth, which will be released in the new version of AW.

@2e3s
Copy link
Copy Markdown
Owner

2e3s commented Apr 26, 2026

Hello, thank you for the update! This needs to be implemented indeed. Just a couple things

  • What if the server is not local? (docker/VM/another host)
  • Not sure about taking in aw-server (outside of the bundle) just to read the existing TOML file... Might just read the file in the expected place, take auth_key and be done with it.

@0xbrayo
Copy link
Copy Markdown
Contributor Author

0xbrayo commented Apr 26, 2026

* What if the server is not local? (docker/VM/another host)

You can have user set the apikey and host in a config file. With that apikey taking precedence over any discovered apikeys.

I thought directly depending on aw-server would be cleaner, incase the paths or any other config related stuff changes, directly reading the apikey works too :).

@0xbrayo 0xbrayo force-pushed the load-apikeys branch 4 times, most recently from 3730433 to fdf0bf4 Compare April 26, 2026 10:00
Signed-off-by: Brayo <vukubrian@gmail.com>
@0xbrayo
Copy link
Copy Markdown
Contributor Author

0xbrayo commented Apr 26, 2026

perhaps even support for a cli flag --apikey or --authkey, feel free to modify the PR

@2e3s
Copy link
Copy Markdown
Owner

2e3s commented Apr 27, 2026

Okay, thank you, I'll reflect on it and adjust the code later, with a following release.

@2e3s 2e3s merged commit ef0eee1 into 2e3s:main Apr 27, 2026
4 checks passed
@2e3s
Copy link
Copy Markdown
Owner

2e3s commented Apr 27, 2026

I thought directly depending on aw-server would be cleaner
incase the paths or any other config related stuff changes

  • It might involve more work for distro packaging,
  • also inflate the binary size for the simplest functionality
  • the compatibility would still be vulnerable because aw::config::whatever_method may change its signature or go private
  • even the config path would depend on the aw-server commit hash, e.g. if you update the server, awatcher would still read it from the old place until you update the referenced commit hash. Might as well update the new path reading instead of updating the referenced hash.

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

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants