lazd / mdn.io

The "I'm feeling lucky" URL shortener
http://mdn.io
215 stars 9 forks source link

No path should take viewers to docs about mdn.io #24

Open adamhotep opened 2 years ago

adamhotep commented 2 years ago

I suggest pointing https://mdn.io and https://mdn.io/ to something informational about the redirector service, like https://github.com/lazd/mdn.io (at a bare minimum). This would ideally be self-served rather than redirected (e.g. a small description plus a link to this repository). That'll give alternative deployments the ability to claim authorship and responsibility rather than accidentally deferring it to you.

It also seems prudent to force local serving of any path starting with /.well-known/ (note the second slash, which removes at least some ambiguity vs searches). This lets you set up a local https://mdn.io/.well-known/security.txt for abuse contact info (see https://securitytxt.org/) and Keybase proofs. See also well-known URI.

You might also want to do something smarter about /robots.txt (for example, look for "Gecko" in the user agent string and actually serve a robots.txt file if you can't find it). This seems less important since this script gives a 303 HTTP response to every query.