Short URLs
Currently, URLs to posts on here are incredibly long, and it would be nice to have "shortcuts" (ex. t.co/XJK98Y)
Woo! Congrats to being the first bug reporter to FeoBlog other than myself. Welcome! 🎉
Currently, the URLs are long because they contain the cryptographic public key of the user who posted something, and the cryptographic signature that you can use to verify their post.
This means that anyone viewing a post can be sure that that post is by the original author, and hasn't been modified.
For example, the post at https://blog.nfnitloop.com/u/A719rvsCkuN2SC5W2vz5hypDE2SpevNTUsEXrVFe9XQ7/i/2hdowtL5knweb5yvejx4XhSRRWpFrJX7Fn8AUrdAMpCxa5oTWYo6nR1itv2UV67EURPKCnix9qZY8tQFrnbasqnu/
Is by the userID A719rvsCkuN2SC5W2vz5hypDE2SpevNTUsEXrVFe9XQ7, and if you grab its binary protobuf representation from
You can use the signature 2hdowtL5knweb5yvejx4XhSRRWpFrJX7Fn8AUrdAMpCxa5oTWYo6nR1itv2UV67EURPKCnix9qZY8tQFrnbasqnu to validate its authenticity.
(Actually, you don't have to do this manually. The built-in web client will do so automatically before displaying any posts/comments/profiles to you.)
The other nice thing is that those two pieces of information together act as a globally unique ID for that content, so you could use /u/A719rvsCkuN2SC5W2vz5hypDE2SpevNTUsEXrVFe9XQ7/i/2hdowtL5knweb5yvejx4XhSRRWpFrJX7Fn8AUrdAMpCxa5oTWYo6nR1itv2UV67EURPKCnix9qZY8tQFrnbasqnu/ to look up the same content on another FeoBlog server.
I'm not sure how to provide link shortening that still allows for all of those features, but I'm open to suggestions!
Until then, keep in mind that places like Twitter will automatically shorten long links for you, so the length shouldn't matter too much there, I hope.
OK, was thinking about this a bit.
the signatures are probably going to be essentially globally unique, so I could create an index on those.
Then I could create a short URL based on only the first N bytes of the signature (enough to be unique). The server could look up the signature, and issue a redirect to the full /u/${uid}/i/${sig}/ path. (This is sort of like what git/GitHub does with short commit IDs.) In the case where the short ID ever becomes ambiguous, the server could instead show a disambiguation page.