Replaces `/` with `%2F` for all SSB public keys on the `/scuttlebutt/profile` route.
This addresses https://git.coopcloud.tech/PeachCloud/peach-workspace/issues/91 and https://git.coopcloud.tech/PeachCloud/peach-workspace/issues/96.
is there some type of encoding that we could use that would be more general than just replacing / with %2F , or is the only possible character that needs to be changed?
Otherwise looks good!
is there some type of encoding that we could use that would be more general than just replacing / with %2F , or is the only possible character that needs to be changed?
Otherwise looks good!
One thing I like about the /-only solution is that the key remains fairly readable and recognisable as an SSB ID. I'm tempted to stick with that solution and only implement the more complete encoding if we run into another issue.
@notplants
The `/` seemed to be the only character causing issues for the route handler so I went with the simplest solution.
A more general approach would be to URL-encode the entire key. Here's an example:
`@Sur8RwcDh6kBjub8pLZpHNWDfuuRpYVyCHrVo+TdA/4=.ed25519`
becomes...
`%40Sur8RwcDh6kBjub8pLZpHNWDfuuRpYVyCHrVo%2BTdA%2F4%3D%2Eed25519`
One thing I like about the `/`-only solution is that the key remains fairly readable and recognisable as an SSB ID. I'm tempted to stick with that solution and only implement the more complete encoding if we run into another issue.
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
Replaces
/with%2Ffor all SSB public keys on the/scuttlebutt/profileroute.This addresses #91 and #96.
is there some type of encoding that we could use that would be more general than just replacing / with %2F , or is the only possible character that needs to be changed?
Otherwise looks good!
@notplants
The
/seemed to be the only character causing issues for the route handler so I went with the simplest solution.A more general approach would be to URL-encode the entire key. Here's an example:
@Sur8RwcDh6kBjub8pLZpHNWDfuuRpYVyCHrVo+TdA/4=.ed25519becomes...
%40Sur8RwcDh6kBjub8pLZpHNWDfuuRpYVyCHrVo%2BTdA%2F4%3D%2Eed25519One thing I like about the
/-only solution is that the key remains fairly readable and recognisable as an SSB ID. I'm tempted to stick with that solution and only implement the more complete encoding if we run into another issue.