• 0 Posts
  • 10 Comments
Joined 8 months ago
cake
Cake day: September 14th, 2024

help-circle
  • Spit out a random e-mail address and record which e-mail address was given to each IP.

    The author mentions it’s a violation of GDPR to record visitors’ IP addresses. I’m not sure that’s correct, but even so, it could be possible to make a custom encoding of literally every ipv4 address through some kind of lookup table with 256 entries, and just string together 4 of those random words to represent the entire 32-bit address space, such that “correct horse battery staple” corresponds to 192.168.1.100 or whatever.


  • Base64 encoding of a text representation of an IP address and date seems inefficient.

    There are 4 octets in a ipv4 address, where each octet is one of 2^8 possible integers. The entire 32-bit ipv4 address space should therefore be possible to encode in 6 characters in base64.

    Similarly, a timestamp with a precision/resolution in seconds can generally be represented by a 32-bit integer, at least up through 2038. So that can be represented by another 6 characters.

    Or, if you know you’re always going to be encoding these two numbers together, you can put together a 64-bit number and encode that in base64, in just 11 characters. Maybe even use some kind of custom timestamp format that uses fewer bits and counts from a more recent epoch, as an unsigned integer (since you’re not going to have site visitors from the past), and get that down to even fewer characters.

    That seems to run less risk of the email address getting cut off at some arbitrary length as it gets passed around.


  • The use of a “+” convention is just a convention popularized by Gmail and the other major providers. If you have your own domain, you should be able to do this with any arbitrary text schema, and encode some information in the address itself, especially if you don’t care about sending email from those aliases: set up your email service to have a catchall inbox that can further be filtered/forwarded based on other rules.

    It can be cumbersome but I could see it working at getting the information you’re looking for.