AnthyG / ThunderWave

A chat for ZeroNet
http://127.0.0.1:43110/1CWkZv7fQAKxTVjZVrLZ8VHcrN6YGGcdky/
15 stars 3 forks source link

Groups with too short ID's don't work #100

Closed AnthyG closed 6 years ago

AnthyG commented 6 years ago

Group-chat's with a too short ID don't work because the IV and Key needed for the AES-Functions won't be long enough if the group's ID is for example 0.

This can be fixed by adding some extra stuff to the ID, either a random-generated string, or based on a seed or so, which would mean that the too short ID would always redirect to the same longer one.

AnthyG commented 6 years ago

When it should be a random string, the user should probably be redirected to the new ID.

AnthyG commented 6 years ago

Fixed with commit 03912d5236eaffdb3e51ead7ef1dc2050571357d. So for example /thunderwave.bit/?GC:0 should now act as if it was /thunderwave.bit/?GC:04533867633317641N`, though I have deactivated the redirect on purpose, as I don't think, that it's really needed/ necessary.

I'm also not completely sure, on how good the method I used actually is, when thinking about cross-platform/ cross-browser implementation, but it should work. If you experience any issues, please leave a comment here, or create a new issue!