mikelindner.com

powering the Internet since 1995

| Photography | Computing | Cooking |

My TinyURL

January 12th, 2024

After talking with a friend about building a secure site to shorten links I came up with this thing I called “Bill Shorten”

It’s pretty simple if you use AWS command line, and it’s as secure as your AWS account, so all the best there 😅.

The basic parts, other than the script and associated files, is an S3 static hosting bucket and a static list of “random” numbers, words or whatever you like for your final short link. This way no code is needed to generate short links, and more importantly to prevent double usage. In the event of double usage however, the new location simply overwrites the old.

The script pops the top value off that list and creates a sub-bucket with it’s own index page, a clone of all the other index pages in the bucket, with the redirect URL pointing to a different end location, your link you wanted to shorten.

https://github.com/mikelindner/bill.shorten

just say “mikes.link/929” and your day is away…