segmentio / ksuid

K-Sortable Globally Unique IDs
https://segment.com/blog/a-brief-history-of-the-uuid/
MIT License
4.82k stars 174 forks source link

Parse accepts argument containing non-alphanumeric characters #74

Open nwt opened 1 year ago

nwt commented 1 year ago

Parse is happy to accept some arguments that contain non-alphanumeric characters.

Here's an example:

$ go run ./cmd/ksuid 0??????????????????????????
022222222222222222222222222

Is this by design? (I was expecting an error for an argument that isn't valid base62.)

nwt commented 1 year ago

By the way, if this is indeed a bug, I'm happy to contribute a PR to fix it!