Commit Graph
57 Commits
Author SHA1 Message Date
Renee Vandervelde bd3cbb1662 Cleanup deprecated methods.
Noticed a handful of deprecated methods and minor warnings while looking around.
Replaces with recommended methods
2024-07-02 09:50:45 -05:00
Ugljesa Jovanovic 1424db0336 Remove xchacha20 streaming API for now, as they are not available on apple builds 2024-04-06 18:56:26 +02:00
Ugljesa Jovanovic 59c5f958ca Fix for #42, add check for values returned by libsodium that signal failure, reintroduce xChaCha20 stream API since iosArm32 is not supported any more, use forked resource loader that deletes tmp folders properly 2024-04-06 11:46:28 +02:00
Ugljesa Jovanovic 194994f5b2 Update kotlin to 1.9.10, update library versions, use latest libsodium stable, clean up Deps, remove deprecated targets, change PasswordHash str related functions to use String 2023-09-23 11:54:02 +02:00
Ugljesa Jovanovic 7625a2d103 Remove logging from loader, stream exception 2022-03-25 15:56:36 +01:00
Ugljesa Jovanovic cdb6ecb8f9 Revert "Workaround inline class not allowed in external interfaces in JS https://youtrack.jetbrains.com/issue/KT-43224 still need to verify there is no narrowing or truncation when not using unsinged inline classes"
Left the checks for UInt in password hash

This reverts commit ce868fc598.
2022-03-25 15:00:57 +01:00
Ugljesa Jovanovic 80c84a25d4 Remove check narrowing todos, they are handled 2022-03-25 12:54:47 +01:00
Ugljesa Jovanovic cd3ec109a3 Handle ULong -> UInt conversions, update api to reflect stream_chacha20_ietf takes UInt for initial counter 2022-03-25 12:47:22 +01:00
Ugljesa Jovanovic ce868fc598 Workaround inline class not allowed in external interfaces in JS https://youtrack.jetbrains.com/issue/KT-43224 still need to verify there is no narrowing or truncation when not using unsinged inline classes 2022-03-25 11:51:23 +01:00
Luca Spinazzola e16167a08e JS fixes.
Use libsodium-sumo module for ready and _sodium_init, and libsodium-wrapper-sumo for JsSodiumInterface

Load JsSodiumInterface as external object

Clean up JsSodiumLoader: remove storeSodium (not needed anymore)
Clean up LibsodiumInitializer: remove sodiumPointer (not needed anymore)
2022-03-25 02:43:10 -04:00
Ugljesa Jovanovic 310e86695d Prevent JS name mangling when using libsodium, remove randombytes duplicate definition 2021-07-20 14:25:37 +02:00
Ugljesa Jovanovic a10faf1967 Init is done automatically by libsodium.js 2021-05-28 15:15:08 +02:00
Ugljesa Jovanovic e000d13b79 Call sodium init in js and jvm 2021-05-01 12:43:29 +02:00
Ugljesa Jovanovic da85fefb9b Use UInt in kdf derivation, because that's the most js can support more or less. I'll try to figure out if we can use all 52bits lates. Also dont show arm build to intellij as it is checking if there is coroutines build for arm and fails with the most unusefull and misleading error I have seen so far. 2021-04-30 22:10:02 +02:00
Ugljesa Jovanovic 8249881eb1 Disable xchacha20 stream for now, as it seems to be missing on ios32arm build. Fix android sdk path 2021-02-23 23:27:37 +01:00
Ugljesa Jovanovic 574377da3c Added a bunch, also added xchacha20 ic and xor 2021-02-23 19:54:07 +01:00
Ugljesa Jovanovic 1cfff4dd43 Started adding Auth doc, added aead doc for specific functions 2020-11-18 22:28:57 +01:00
Ugljesa Jovanovic 6c940fe6f2 Added js and jvm _scalarmult_ 2020-10-15 20:58:55 +02:00
Ugljesa Jovanovic 67d80beb34 Added _steam_ jvm and js implementations 2020-10-12 20:00:17 +02:00
Ugljesa Jovanovic a19602a92f Added js and jvm implementations of _kx_ 2020-10-09 17:17:17 +02:00
Ugljesa Jovanovic 0431f27e3e Completed random support functions 2020-10-03 18:16:26 +02:00
Ugljesa Jovanovic 2d63215c70 Completed jvm implementation, there are some issues in lazysodium-java that I've worked around 2020-09-27 19:20:22 +02:00
Ugljesa Jovanovic 4af1477c90 Added js _util functions 2020-09-26 23:58:45 +02:00
Ugljesa Jovanovic a44935a10e Added js _pwhash_ 2020-09-22 20:54:02 +02:00
Ugljesa Jovanovic 8b26764938 Added _kdf_ all implementations and a simple and probably pointless test, also noted which functions are not available as they are not part of LazySodium 2020-09-16 14:09:14 +02:00
Ugljesa Jovanovic a24fa34296 Added _sign_ js implementation 2020-09-15 14:00:03 +02:00
Ugljesa Jovanovic 03a17f5b6a Added js box implementation 2020-09-11 19:27:54 +02:00
Ugljesa Jovanovic 1894a5d995 Added jvm and js implementation for sha256/512 2020-08-31 20:56:36 +02:00
Ugljesa Jovanovic 15be707114 Added sha2 hashes in common and native and test 2020-08-31 20:44:37 +02:00
Ugljesa Jovanovic 1878144b8f Added generichash keygen 2020-08-31 19:39:19 +02:00
Ugljesa Jovanovic 16cb5c2dee Completed crypto auth and added tests 2020-08-30 19:02:40 +02:00
Ugljesa Jovanovic 0c8de7b5c5 Adding crypto_auth 2020-08-30 17:56:12 +02:00
Ugljesa Jovanovic dd0895b5f3 Completed cha cha aead variants 2020-08-30 13:10:31 +02:00
Ugljesa Jovanovic 3de04749ba Change all occurences of additionalData to associatedData 2020-08-30 11:56:18 +02:00
Ugljesa Jovanovic 54489ef6cb Start work on _aead_ 2020-08-30 11:21:53 +02:00
Ugljesa Jovanovic 99b9ee5e9d Added secretbox functions and constants 2020-08-29 21:53:17 +02:00
Ugljesa Jovanovic d5b1e7f7f3 Added rekey and keygen to secretstream 2020-08-29 17:25:59 +02:00
Ugljesa Jovanovic 91cd41c8c1 Short hash implementation and test, updated cbc tests as they ignored padding 2020-08-28 22:35:33 +02:00
Ugljesa Jovanovic 89e5ae62e4 Fixed native (i forgot to account for tag length. Added debug list of js functions, can be usefull when defining interface 2020-08-27 22:07:03 +02:00
Ugljesa Jovanovic 2c92a8142f Add generic hash tests, add templates for secret stream jvm and js 2020-08-26 22:33:55 +02:00
Ugljesa Jovanovic 39f0817308 Adding secret stream impl, completed generichash impl 2020-08-26 22:15:03 +02:00
Ugljesa Jovanovic 231a84af67 Comment out old debug generated code, but keep for short term reference, add android/jvm wrappers, seemingly solve android unit test problems 2020-08-23 13:39:59 +02:00
Ugljesa Jovanovic 9962198aad Comment out old debug generated code, but keep for short term reference, add android/jvm wrappers, seemingly solve android unit test problems 2020-08-22 13:53:01 +02:00
Ugljesa Jovanovic 92058a7ba5 Added generic hash 2020-08-21 19:21:40 +02:00
Ugljesa Jovanovic be4468785d Slow progress. 2020-08-21 18:55:17 +02:00
Ugljesa Jovanovic cd90f964ab Update kotlin version, need to fix secretstream pull, at least in js if not everywhere 2020-08-18 23:32:50 +02:00
Ugljesa Jovanovic df87dae376 Adding pull secretstream definition 2020-08-15 11:53:11 +02:00
Ugljesa Jovanovic 28995c065f Adding secretstream push definition and neccessary changes 2020-08-14 16:00:30 +02:00
Ugljesa Jovanovic efe9661c30 Adding custom code blocks 2020-08-14 14:25:26 +02:00
Ugljesa Jovanovic a5b20daf5a Adding data classes 2020-08-14 12:39:27 +02:00