brainboxdotcc / DPP

C++ Discord API Bot Library - D++ is Lightweight and scalable for small and huge bots!
https://dpp.dev/
Apache License 2.0
1.04k stars 158 forks source link

Add support for other encryption / decryption methods supported by discord #1134

Open Kaydax opened 4 months ago

Kaydax commented 4 months ago

Is your feature request related to a problem? Please describe. Currently DPP only supports xsalsa20_poly1305, however discord supports all of these other types:

Describe the solution you'd like I would like to see all modes supported, or at least rtpsize be implemented.

There is full documentation on how rtpsize works here: https://git.kaydax.xyz/w/algos/src/branch/main/doc/crypt.md

Describe alternatives you've considered None

Additional context This has also been implemented into BetterDisco here: https://github.com/elderlabs/BetterDisco/commit/d988d6a8

braindigitalis commented 4 months ago

we cant use that example code and really we shouldnt even look at it - it is LGPL 3.0 only. Similarly we should not reference betterdiscord or any unofficial client fork. I'm sure we can figure something out though.

Kaydax commented 4 months ago

we cant use that example code and really we shouldnt even look at it - it is LGPL 3.0 only. Similarly we should not reference betterdiscord or any unofficial client fork. I'm sure we can figure something out though.

I removed the link to the example code from algos because of the license, however the crypt documentation is CC-BY-SA meaning its allowed to be used. Also BetterDisco is not a client modification, its a continuation of disco, the discord bot python library made by b1nzy

Kaydax commented 4 months ago

We just relicensed the code that is referenced in the docs to be LGPL OR Apache 2.0, so there is no longer any licensing problems: https://git.kaydax.xyz/w/algos/src/branch/main/src/module/util/crypt_impl.cc

braindigitalis commented 4 months ago

great to hear :D

github-actions[bot] commented 1 month ago

This issue has had no activity and is being marked as stale. If you still wish to continue with this issue please comment to reopen it.