react-native-quick-crypto 1.0.0-beta.2 → 1.0.0-beta.20
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/QuickCrypto.podspec +80 -7
- package/README.md +12 -6
- package/android/CMakeLists.txt +51 -20
- package/android/build.gradle +47 -4
- package/android/src/main/cpp/cpp-adapter.cpp +3 -10
- package/android/src/main/java/com/margelo/nitro/quickcrypto/QuickCryptoPackage.java +13 -10
- package/app.plugin.js +3 -0
- package/cpp/cipher/CCMCipher.cpp +199 -0
- package/cpp/cipher/CCMCipher.hpp +26 -0
- package/cpp/cipher/ChaCha20Cipher.cpp +97 -0
- package/cpp/cipher/ChaCha20Cipher.hpp +25 -0
- package/cpp/cipher/ChaCha20Poly1305Cipher.cpp +170 -0
- package/cpp/cipher/ChaCha20Poly1305Cipher.hpp +30 -0
- package/cpp/cipher/HybridCipher.cpp +322 -0
- package/cpp/cipher/HybridCipher.hpp +68 -0
- package/cpp/cipher/HybridCipherFactory.hpp +92 -0
- package/cpp/cipher/OCBCipher.cpp +55 -0
- package/cpp/cipher/OCBCipher.hpp +19 -0
- package/cpp/cipher/XSalsa20Cipher.cpp +61 -0
- package/cpp/cipher/XSalsa20Cipher.hpp +33 -0
- package/cpp/ed25519/HybridEdKeyPair.cpp +226 -0
- package/cpp/ed25519/HybridEdKeyPair.hpp +56 -0
- package/cpp/hash/HybridHash.cpp +151 -0
- package/cpp/hash/HybridHash.hpp +41 -0
- package/cpp/hmac/HybridHmac.cpp +95 -0
- package/cpp/hmac/HybridHmac.hpp +31 -0
- package/cpp/pbkdf2/HybridPbkdf2.cpp +51 -0
- package/cpp/pbkdf2/HybridPbkdf2.hpp +24 -0
- package/cpp/random/HybridRandom.cpp +32 -18
- package/cpp/random/HybridRandom.hpp +18 -30
- package/cpp/utils/Utils.hpp +26 -1
- package/deps/fastpbkdf2/fastpbkdf2.c +356 -0
- package/deps/fastpbkdf2/fastpbkdf2.h +68 -0
- package/ios/libsodium-stable/.github/workflows/autocloser.yml +12 -0
- package/ios/libsodium-stable/.github/workflows/ci.yml +180 -0
- package/ios/libsodium-stable/.github/workflows/cifuzz.yml +32 -0
- package/ios/libsodium-stable/.github/workflows/codeql-analysis.yml +48 -0
- package/ios/libsodium-stable/.github/workflows/dotnet-core.yml +388 -0
- package/ios/libsodium-stable/AUTHORS +144 -0
- package/ios/libsodium-stable/CITATION.cff +18 -0
- package/ios/libsodium-stable/ChangeLog +677 -0
- package/ios/libsodium-stable/LICENSE +18 -0
- package/ios/libsodium-stable/Makefile.am +23 -0
- package/ios/libsodium-stable/README.markdown +76 -0
- package/ios/libsodium-stable/THANKS +92 -0
- package/ios/libsodium-stable/appveyor.yml +24 -0
- package/ios/libsodium-stable/autogen.sh +117 -0
- package/ios/libsodium-stable/azure-pipelines.yml +122 -0
- package/ios/libsodium-stable/build.zig +281 -0
- package/ios/libsodium-stable/builds/Makefile.am +81 -0
- package/ios/libsodium-stable/builds/msvc/build/buildall.bat +18 -0
- package/ios/libsodium-stable/builds/msvc/build/buildbase.bat +132 -0
- package/ios/libsodium-stable/builds/msvc/properties/ARM64.props +23 -0
- package/ios/libsodium-stable/builds/msvc/properties/Common.props +21 -0
- package/ios/libsodium-stable/builds/msvc/properties/DLL.props +16 -0
- package/ios/libsodium-stable/builds/msvc/properties/Debug.props +29 -0
- package/ios/libsodium-stable/builds/msvc/properties/DebugDEXE.props +21 -0
- package/ios/libsodium-stable/builds/msvc/properties/DebugDLL.props +20 -0
- package/ios/libsodium-stable/builds/msvc/properties/DebugLEXE.props +20 -0
- package/ios/libsodium-stable/builds/msvc/properties/DebugLIB.props +21 -0
- package/ios/libsodium-stable/builds/msvc/properties/DebugLTCG.props +20 -0
- package/ios/libsodium-stable/builds/msvc/properties/DebugSEXE.props +21 -0
- package/ios/libsodium-stable/builds/msvc/properties/EXE.props +17 -0
- package/ios/libsodium-stable/builds/msvc/properties/LIB.props +16 -0
- package/ios/libsodium-stable/builds/msvc/properties/LTCG.props +13 -0
- package/ios/libsodium-stable/builds/msvc/properties/Link.props +21 -0
- package/ios/libsodium-stable/builds/msvc/properties/Messages.props +15 -0
- package/ios/libsodium-stable/builds/msvc/properties/Output.props +30 -0
- package/ios/libsodium-stable/builds/msvc/properties/Release.props +41 -0
- package/ios/libsodium-stable/builds/msvc/properties/ReleaseDEXE.props +20 -0
- package/ios/libsodium-stable/builds/msvc/properties/ReleaseDLL.props +19 -0
- package/ios/libsodium-stable/builds/msvc/properties/ReleaseLEXE.props +20 -0
- package/ios/libsodium-stable/builds/msvc/properties/ReleaseLIB.props +19 -0
- package/ios/libsodium-stable/builds/msvc/properties/ReleaseLTCG.props +19 -0
- package/ios/libsodium-stable/builds/msvc/properties/ReleaseSEXE.props +20 -0
- package/ios/libsodium-stable/builds/msvc/properties/Win32.props +23 -0
- package/ios/libsodium-stable/builds/msvc/properties/x64.props +26 -0
- package/ios/libsodium-stable/builds/msvc/resource.h +14 -0
- package/ios/libsodium-stable/builds/msvc/resource.rc +65 -0
- package/ios/libsodium-stable/builds/msvc/version.h +33 -0
- package/ios/libsodium-stable/builds/msvc/vs2010/libsodium/libsodium.props +48 -0
- package/ios/libsodium-stable/builds/msvc/vs2010/libsodium/libsodium.vcxproj +346 -0
- package/ios/libsodium-stable/builds/msvc/vs2010/libsodium/libsodium.vcxproj.filters +1088 -0
- package/ios/libsodium-stable/builds/msvc/vs2010/libsodium/libsodium.xml +15 -0
- package/ios/libsodium-stable/builds/msvc/vs2010/libsodium.import.props +52 -0
- package/ios/libsodium-stable/builds/msvc/vs2010/libsodium.import.xml +17 -0
- package/ios/libsodium-stable/builds/msvc/vs2010/libsodium.sln +50 -0
- package/ios/libsodium-stable/builds/msvc/vs2012/libsodium/libsodium.props +48 -0
- package/ios/libsodium-stable/builds/msvc/vs2012/libsodium/libsodium.vcxproj +346 -0
- package/ios/libsodium-stable/builds/msvc/vs2012/libsodium/libsodium.vcxproj.filters +1088 -0
- package/ios/libsodium-stable/builds/msvc/vs2012/libsodium/libsodium.xml +15 -0
- package/ios/libsodium-stable/builds/msvc/vs2012/libsodium.import.props +52 -0
- package/ios/libsodium-stable/builds/msvc/vs2012/libsodium.import.xml +17 -0
- package/ios/libsodium-stable/builds/msvc/vs2012/libsodium.sln +50 -0
- package/ios/libsodium-stable/builds/msvc/vs2013/libsodium/libsodium.props +48 -0
- package/ios/libsodium-stable/builds/msvc/vs2013/libsodium/libsodium.vcxproj +346 -0
- package/ios/libsodium-stable/builds/msvc/vs2013/libsodium/libsodium.vcxproj.filters +1088 -0
- package/ios/libsodium-stable/builds/msvc/vs2013/libsodium/libsodium.xml +15 -0
- package/ios/libsodium-stable/builds/msvc/vs2013/libsodium.import.props +52 -0
- package/ios/libsodium-stable/builds/msvc/vs2013/libsodium.import.xml +17 -0
- package/ios/libsodium-stable/builds/msvc/vs2013/libsodium.sln +52 -0
- package/ios/libsodium-stable/builds/msvc/vs2015/libsodium/libsodium.props +48 -0
- package/ios/libsodium-stable/builds/msvc/vs2015/libsodium/libsodium.vcxproj +346 -0
- package/ios/libsodium-stable/builds/msvc/vs2015/libsodium/libsodium.vcxproj.filters +1088 -0
- package/ios/libsodium-stable/builds/msvc/vs2015/libsodium/libsodium.xml +15 -0
- package/ios/libsodium-stable/builds/msvc/vs2015/libsodium.import.props +52 -0
- package/ios/libsodium-stable/builds/msvc/vs2015/libsodium.import.xml +17 -0
- package/ios/libsodium-stable/builds/msvc/vs2015/libsodium.sln +52 -0
- package/ios/libsodium-stable/builds/msvc/vs2017/libsodium/libsodium.props +48 -0
- package/ios/libsodium-stable/builds/msvc/vs2017/libsodium/libsodium.vcxproj +346 -0
- package/ios/libsodium-stable/builds/msvc/vs2017/libsodium/libsodium.vcxproj.filters +1088 -0
- package/ios/libsodium-stable/builds/msvc/vs2017/libsodium/libsodium.xml +15 -0
- package/ios/libsodium-stable/builds/msvc/vs2017/libsodium.import.props +52 -0
- package/ios/libsodium-stable/builds/msvc/vs2017/libsodium.import.xml +17 -0
- package/ios/libsodium-stable/builds/msvc/vs2017/libsodium.sln +52 -0
- package/ios/libsodium-stable/builds/msvc/vs2019/libsodium/libsodium.props +48 -0
- package/ios/libsodium-stable/builds/msvc/vs2019/libsodium/libsodium.vcxproj +370 -0
- package/ios/libsodium-stable/builds/msvc/vs2019/libsodium/libsodium.vcxproj.filters +1088 -0
- package/ios/libsodium-stable/builds/msvc/vs2019/libsodium/libsodium.xml +15 -0
- package/ios/libsodium-stable/builds/msvc/vs2019/libsodium.import.props +52 -0
- package/ios/libsodium-stable/builds/msvc/vs2019/libsodium.import.xml +17 -0
- package/ios/libsodium-stable/builds/msvc/vs2019/libsodium.sln +52 -0
- package/ios/libsodium-stable/builds/msvc/vs2022/libsodium/libsodium.props +48 -0
- package/ios/libsodium-stable/builds/msvc/vs2022/libsodium/libsodium.vcxproj +370 -0
- package/ios/libsodium-stable/builds/msvc/vs2022/libsodium/libsodium.vcxproj.filters +1088 -0
- package/ios/libsodium-stable/builds/msvc/vs2022/libsodium/libsodium.xml +15 -0
- package/ios/libsodium-stable/builds/msvc/vs2022/libsodium.import.props +52 -0
- package/ios/libsodium-stable/builds/msvc/vs2022/libsodium.import.xml +17 -0
- package/ios/libsodium-stable/builds/msvc/vs2022/libsodium.sln +70 -0
- package/ios/libsodium-stable/ci/appveyor/libsodium.sln +40 -0
- package/ios/libsodium-stable/ci/appveyor/libsodium.vcxproj +594 -0
- package/ios/libsodium-stable/ci/appveyor/libsodium.vcxproj.filters +813 -0
- package/ios/libsodium-stable/ci/appveyor/msvc-scripts/process.bat +5 -0
- package/ios/libsodium-stable/ci/appveyor/msvc-scripts/rep.vbs +12 -0
- package/ios/libsodium-stable/ci/appveyor/msvc-scripts/sodium.props +29 -0
- package/ios/libsodium-stable/configure.ac +1004 -0
- package/ios/libsodium-stable/contrib/Findsodium.cmake +297 -0
- package/ios/libsodium-stable/contrib/Makefile.am +3 -0
- package/ios/libsodium-stable/dist-build/Makefile.am +14 -0
- package/ios/libsodium-stable/dist-build/android-aar.sh +194 -0
- package/ios/libsodium-stable/dist-build/android-armv7-a.sh +5 -0
- package/ios/libsodium-stable/dist-build/android-armv8-a.sh +5 -0
- package/ios/libsodium-stable/dist-build/android-build.sh +95 -0
- package/ios/libsodium-stable/dist-build/android-x86.sh +5 -0
- package/ios/libsodium-stable/dist-build/android-x86_64.sh +5 -0
- package/ios/libsodium-stable/dist-build/apple-xcframework.sh +628 -0
- package/ios/libsodium-stable/dist-build/emscripten-symbols.def +651 -0
- package/ios/libsodium-stable/dist-build/emscripten.sh +206 -0
- package/ios/libsodium-stable/dist-build/generate-emscripten-symbols.sh +59 -0
- package/ios/libsodium-stable/dist-build/macos.sh +26 -0
- package/ios/libsodium-stable/dist-build/msys2-win32.sh +18 -0
- package/ios/libsodium-stable/dist-build/msys2-win64.sh +18 -0
- package/ios/libsodium-stable/dist-build/wasm32-wasi.sh +45 -0
- package/ios/libsodium-stable/lgtm.yml +6 -0
- package/ios/libsodium-stable/libsodium-uninstalled.pc.in +7 -0
- package/ios/libsodium-stable/libsodium.pc.in +12 -0
- package/ios/libsodium-stable/logo.png +0 -0
- package/ios/libsodium-stable/m4/ax_add_fortify_source.m4 +119 -0
- package/ios/libsodium-stable/m4/ax_check_catchable_abrt.m4 +57 -0
- package/ios/libsodium-stable/m4/ax_check_catchable_segv.m4 +47 -0
- package/ios/libsodium-stable/m4/ax_check_compile_flag.m4 +55 -0
- package/ios/libsodium-stable/m4/ax_check_define.m4 +73 -0
- package/ios/libsodium-stable/m4/ax_check_gnu_make.m4 +95 -0
- package/ios/libsodium-stable/m4/ax_check_link_flag.m4 +75 -0
- package/ios/libsodium-stable/m4/ax_pthread.m4 +522 -0
- package/ios/libsodium-stable/m4/ax_tls.m4 +71 -0
- package/ios/libsodium-stable/m4/ax_valgrind_check.m4 +239 -0
- package/ios/libsodium-stable/m4/ld-output-def.m4 +29 -0
- package/ios/libsodium-stable/packaging/dotnet-core/libsodium.pkgproj +49 -0
- package/ios/libsodium-stable/packaging/dotnet-core/test.cs +43 -0
- package/ios/libsodium-stable/packaging/nuget/package.bat +13 -0
- package/ios/libsodium-stable/packaging/nuget/package.config +4 -0
- package/ios/libsodium-stable/packaging/nuget/package.gsl +260 -0
- package/ios/libsodium-stable/regen-msvc/libsodium.vcxproj +326 -0
- package/ios/libsodium-stable/regen-msvc/libsodium.vcxproj.filters +23 -0
- package/ios/libsodium-stable/regen-msvc/libsodium.vcxproj.filters.tpl +35 -0
- package/ios/libsodium-stable/regen-msvc/libsodium.vcxproj.tpl +37 -0
- package/ios/libsodium-stable/regen-msvc/regen-msvc.py +240 -0
- package/ios/libsodium-stable/regen-msvc/tl_libsodium.vcxproj.filters.tpl +23 -0
- package/ios/libsodium-stable/regen-msvc/tl_libsodium.vcxproj.tpl +332 -0
- package/ios/libsodium-stable/src/Makefile.am +3 -0
- package/ios/libsodium-stable/src/libsodium/Makefile.am +314 -0
- package/ios/libsodium-stable/src/libsodium/crypto_aead/aegis128l/aead_aegis128l.c +159 -0
- package/ios/libsodium-stable/src/libsodium/crypto_aead/aegis128l/aegis128l_aesni.c +70 -0
- package/ios/libsodium-stable/src/libsodium/crypto_aead/aegis128l/aegis128l_aesni.h +8 -0
- package/ios/libsodium-stable/src/libsodium/crypto_aead/aegis128l/aegis128l_armcrypto.c +72 -0
- package/ios/libsodium-stable/src/libsodium/crypto_aead/aegis128l/aegis128l_armcrypto.h +8 -0
- package/ios/libsodium-stable/src/libsodium/crypto_aead/aegis128l/aegis128l_common.h +248 -0
- package/ios/libsodium-stable/src/libsodium/crypto_aead/aegis128l/aegis128l_soft.c +59 -0
- package/ios/libsodium-stable/src/libsodium/crypto_aead/aegis128l/aegis128l_soft.h +8 -0
- package/ios/libsodium-stable/src/libsodium/crypto_aead/aegis128l/implementations.h +17 -0
- package/ios/libsodium-stable/src/libsodium/crypto_aead/aegis256/aead_aegis256.c +158 -0
- package/ios/libsodium-stable/src/libsodium/crypto_aead/aegis256/aegis256_aesni.c +65 -0
- package/ios/libsodium-stable/src/libsodium/crypto_aead/aegis256/aegis256_aesni.h +8 -0
- package/ios/libsodium-stable/src/libsodium/crypto_aead/aegis256/aegis256_armcrypto.c +70 -0
- package/ios/libsodium-stable/src/libsodium/crypto_aead/aegis256/aegis256_armcrypto.h +8 -0
- package/ios/libsodium-stable/src/libsodium/crypto_aead/aegis256/aegis256_common.h +231 -0
- package/ios/libsodium-stable/src/libsodium/crypto_aead/aegis256/aegis256_soft.c +54 -0
- package/ios/libsodium-stable/src/libsodium/crypto_aead/aegis256/aegis256_soft.h +8 -0
- package/ios/libsodium-stable/src/libsodium/crypto_aead/aegis256/implementations.h +17 -0
- package/ios/libsodium-stable/src/libsodium/crypto_aead/aes256gcm/aead_aes256gcm.c +157 -0
- package/ios/libsodium-stable/src/libsodium/crypto_aead/aes256gcm/aesni/aead_aes256gcm_aesni.c +1015 -0
- package/ios/libsodium-stable/src/libsodium/crypto_aead/aes256gcm/armcrypto/aead_aes256gcm_armcrypto.c +1033 -0
- package/ios/libsodium-stable/src/libsodium/crypto_aead/chacha20poly1305/aead_chacha20poly1305.c +400 -0
- package/ios/libsodium-stable/src/libsodium/crypto_aead/xchacha20poly1305/aead_xchacha20poly1305.c +262 -0
- package/ios/libsodium-stable/src/libsodium/crypto_auth/crypto_auth.c +41 -0
- package/ios/libsodium-stable/src/libsodium/crypto_auth/hmacsha256/auth_hmacsha256.c +118 -0
- package/ios/libsodium-stable/src/libsodium/crypto_auth/hmacsha512/auth_hmacsha512.c +118 -0
- package/ios/libsodium-stable/src/libsodium/crypto_auth/hmacsha512256/auth_hmacsha512256.c +93 -0
- package/ios/libsodium-stable/src/libsodium/crypto_box/crypto_box.c +114 -0
- package/ios/libsodium-stable/src/libsodium/crypto_box/crypto_box_easy.c +115 -0
- package/ios/libsodium-stable/src/libsodium/crypto_box/crypto_box_seal.c +68 -0
- package/ios/libsodium-stable/src/libsodium/crypto_box/curve25519xchacha20poly1305/box_curve25519xchacha20poly1305.c +204 -0
- package/ios/libsodium-stable/src/libsodium/crypto_box/curve25519xchacha20poly1305/box_seal_curve25519xchacha20poly1305.c +79 -0
- package/ios/libsodium-stable/src/libsodium/crypto_box/curve25519xsalsa20poly1305/box_curve25519xsalsa20poly1305.c +156 -0
- package/ios/libsodium-stable/src/libsodium/crypto_core/ed25519/core_ed25519.c +225 -0
- package/ios/libsodium-stable/src/libsodium/crypto_core/ed25519/core_ristretto255.c +156 -0
- package/ios/libsodium-stable/src/libsodium/crypto_core/ed25519/ref10/ed25519_ref10.c +2873 -0
- package/ios/libsodium-stable/src/libsodium/crypto_core/ed25519/ref10/fe_25_5/base.h +1344 -0
- package/ios/libsodium-stable/src/libsodium/crypto_core/ed25519/ref10/fe_25_5/base2.h +40 -0
- package/ios/libsodium-stable/src/libsodium/crypto_core/ed25519/ref10/fe_25_5/constants.h +40 -0
- package/ios/libsodium-stable/src/libsodium/crypto_core/ed25519/ref10/fe_25_5/fe.h +220 -0
- package/ios/libsodium-stable/src/libsodium/crypto_core/ed25519/ref10/fe_51/base.h +1344 -0
- package/ios/libsodium-stable/src/libsodium/crypto_core/ed25519/ref10/fe_51/base2.h +40 -0
- package/ios/libsodium-stable/src/libsodium/crypto_core/ed25519/ref10/fe_51/constants.h +41 -0
- package/ios/libsodium-stable/src/libsodium/crypto_core/ed25519/ref10/fe_51/fe.h +116 -0
- package/ios/libsodium-stable/src/libsodium/crypto_core/hchacha20/core_hchacha20.c +93 -0
- package/ios/libsodium-stable/src/libsodium/crypto_core/hsalsa20/core_hsalsa20.c +21 -0
- package/ios/libsodium-stable/src/libsodium/crypto_core/hsalsa20/ref2/core_hsalsa20_ref2.c +95 -0
- package/ios/libsodium-stable/src/libsodium/crypto_core/salsa/ref/core_salsa_ref.c +195 -0
- package/ios/libsodium-stable/src/libsodium/crypto_core/softaes/softaes.c +340 -0
- package/ios/libsodium-stable/src/libsodium/crypto_generichash/blake2b/generichash_blake2.c +55 -0
- package/ios/libsodium-stable/src/libsodium/crypto_generichash/blake2b/ref/blake2.h +106 -0
- package/ios/libsodium-stable/src/libsodium/crypto_generichash/blake2b/ref/blake2b-compress-avx2.c +52 -0
- package/ios/libsodium-stable/src/libsodium/crypto_generichash/blake2b/ref/blake2b-compress-avx2.h +142 -0
- package/ios/libsodium-stable/src/libsodium/crypto_generichash/blake2b/ref/blake2b-compress-ref.c +93 -0
- package/ios/libsodium-stable/src/libsodium/crypto_generichash/blake2b/ref/blake2b-compress-sse41.c +91 -0
- package/ios/libsodium-stable/src/libsodium/crypto_generichash/blake2b/ref/blake2b-compress-sse41.h +106 -0
- package/ios/libsodium-stable/src/libsodium/crypto_generichash/blake2b/ref/blake2b-compress-ssse3.c +95 -0
- package/ios/libsodium-stable/src/libsodium/crypto_generichash/blake2b/ref/blake2b-compress-ssse3.h +106 -0
- package/ios/libsodium-stable/src/libsodium/crypto_generichash/blake2b/ref/blake2b-load-avx2.h +340 -0
- package/ios/libsodium-stable/src/libsodium/crypto_generichash/blake2b/ref/blake2b-load-sse2.h +164 -0
- package/ios/libsodium-stable/src/libsodium/crypto_generichash/blake2b/ref/blake2b-load-sse41.h +307 -0
- package/ios/libsodium-stable/src/libsodium/crypto_generichash/blake2b/ref/blake2b-ref.c +438 -0
- package/ios/libsodium-stable/src/libsodium/crypto_generichash/blake2b/ref/generichash_blake2b.c +116 -0
- package/ios/libsodium-stable/src/libsodium/crypto_generichash/crypto_generichash.c +91 -0
- package/ios/libsodium-stable/src/libsodium/crypto_hash/crypto_hash.c +20 -0
- package/ios/libsodium-stable/src/libsodium/crypto_hash/sha256/cp/hash_sha256_cp.c +256 -0
- package/ios/libsodium-stable/src/libsodium/crypto_hash/sha256/hash_sha256.c +13 -0
- package/ios/libsodium-stable/src/libsodium/crypto_hash/sha512/cp/hash_sha512_cp.c +284 -0
- package/ios/libsodium-stable/src/libsodium/crypto_hash/sha512/hash_sha512.c +13 -0
- package/ios/libsodium-stable/src/libsodium/crypto_kdf/blake2b/kdf_blake2b.c +52 -0
- package/ios/libsodium-stable/src/libsodium/crypto_kdf/crypto_kdf.c +49 -0
- package/ios/libsodium-stable/src/libsodium/crypto_kdf/hkdf/kdf_hkdf_sha256.c +123 -0
- package/ios/libsodium-stable/src/libsodium/crypto_kdf/hkdf/kdf_hkdf_sha512.c +123 -0
- package/ios/libsodium-stable/src/libsodium/crypto_kx/crypto_kx.c +143 -0
- package/ios/libsodium-stable/src/libsodium/crypto_onetimeauth/crypto_onetimeauth.c +71 -0
- package/ios/libsodium-stable/src/libsodium/crypto_onetimeauth/poly1305/donna/poly1305_donna.c +124 -0
- package/ios/libsodium-stable/src/libsodium/crypto_onetimeauth/poly1305/donna/poly1305_donna.h +12 -0
- package/ios/libsodium-stable/src/libsodium/crypto_onetimeauth/poly1305/donna/poly1305_donna32.h +235 -0
- package/ios/libsodium-stable/src/libsodium/crypto_onetimeauth/poly1305/donna/poly1305_donna64.h +221 -0
- package/ios/libsodium-stable/src/libsodium/crypto_onetimeauth/poly1305/onetimeauth_poly1305.c +90 -0
- package/ios/libsodium-stable/src/libsodium/crypto_onetimeauth/poly1305/onetimeauth_poly1305.h +21 -0
- package/ios/libsodium-stable/src/libsodium/crypto_onetimeauth/poly1305/sse2/poly1305_sse2.c +957 -0
- package/ios/libsodium-stable/src/libsodium/crypto_onetimeauth/poly1305/sse2/poly1305_sse2.h +12 -0
- package/ios/libsodium-stable/src/libsodium/crypto_pwhash/argon2/argon2-core.c +556 -0
- package/ios/libsodium-stable/src/libsodium/crypto_pwhash/argon2/argon2-core.h +271 -0
- package/ios/libsodium-stable/src/libsodium/crypto_pwhash/argon2/argon2-encoding.c +306 -0
- package/ios/libsodium-stable/src/libsodium/crypto_pwhash/argon2/argon2-encoding.h +34 -0
- package/ios/libsodium-stable/src/libsodium/crypto_pwhash/argon2/argon2-fill-block-avx2.c +243 -0
- package/ios/libsodium-stable/src/libsodium/crypto_pwhash/argon2/argon2-fill-block-avx512f.c +251 -0
- package/ios/libsodium-stable/src/libsodium/crypto_pwhash/argon2/argon2-fill-block-ref.c +234 -0
- package/ios/libsodium-stable/src/libsodium/crypto_pwhash/argon2/argon2-fill-block-ssse3.c +244 -0
- package/ios/libsodium-stable/src/libsodium/crypto_pwhash/argon2/argon2.c +283 -0
- package/ios/libsodium-stable/src/libsodium/crypto_pwhash/argon2/argon2.h +305 -0
- package/ios/libsodium-stable/src/libsodium/crypto_pwhash/argon2/blake2b-long.c +79 -0
- package/ios/libsodium-stable/src/libsodium/crypto_pwhash/argon2/blake2b-long.h +8 -0
- package/ios/libsodium-stable/src/libsodium/crypto_pwhash/argon2/blamka-round-avx2.h +150 -0
- package/ios/libsodium-stable/src/libsodium/crypto_pwhash/argon2/blamka-round-avx512f.h +145 -0
- package/ios/libsodium-stable/src/libsodium/crypto_pwhash/argon2/blamka-round-ref.h +40 -0
- package/ios/libsodium-stable/src/libsodium/crypto_pwhash/argon2/blamka-round-ssse3.h +124 -0
- package/ios/libsodium-stable/src/libsodium/crypto_pwhash/argon2/pwhash_argon2i.c +294 -0
- package/ios/libsodium-stable/src/libsodium/crypto_pwhash/argon2/pwhash_argon2id.c +238 -0
- package/ios/libsodium-stable/src/libsodium/crypto_pwhash/crypto_pwhash.c +212 -0
- package/ios/libsodium-stable/src/libsodium/crypto_pwhash/scryptsalsa208sha256/crypto_scrypt-common.c +268 -0
- package/ios/libsodium-stable/src/libsodium/crypto_pwhash/scryptsalsa208sha256/crypto_scrypt.h +92 -0
- package/ios/libsodium-stable/src/libsodium/crypto_pwhash/scryptsalsa208sha256/nosse/pwhash_scryptsalsa208sha256_nosse.c +318 -0
- package/ios/libsodium-stable/src/libsodium/crypto_pwhash/scryptsalsa208sha256/pbkdf2-sha256.c +96 -0
- package/ios/libsodium-stable/src/libsodium/crypto_pwhash/scryptsalsa208sha256/pbkdf2-sha256.h +45 -0
- package/ios/libsodium-stable/src/libsodium/crypto_pwhash/scryptsalsa208sha256/pwhash_scryptsalsa208sha256.c +301 -0
- package/ios/libsodium-stable/src/libsodium/crypto_pwhash/scryptsalsa208sha256/scrypt_platform.c +112 -0
- package/ios/libsodium-stable/src/libsodium/crypto_pwhash/scryptsalsa208sha256/sse/pwhash_scryptsalsa208sha256_sse.c +406 -0
- package/ios/libsodium-stable/src/libsodium/crypto_scalarmult/crypto_scalarmult.c +33 -0
- package/ios/libsodium-stable/src/libsodium/crypto_scalarmult/curve25519/ref10/x25519_ref10.c +182 -0
- package/ios/libsodium-stable/src/libsodium/crypto_scalarmult/curve25519/ref10/x25519_ref10.h +10 -0
- package/ios/libsodium-stable/src/libsodium/crypto_scalarmult/curve25519/sandy2x/consts.S +25 -0
- package/ios/libsodium-stable/src/libsodium/crypto_scalarmult/curve25519/sandy2x/consts_namespace.h +20 -0
- package/ios/libsodium-stable/src/libsodium/crypto_scalarmult/curve25519/sandy2x/curve25519_sandy2x.c +71 -0
- package/ios/libsodium-stable/src/libsodium/crypto_scalarmult/curve25519/sandy2x/curve25519_sandy2x.h +9 -0
- package/ios/libsodium-stable/src/libsodium/crypto_scalarmult/curve25519/sandy2x/fe.h +26 -0
- package/ios/libsodium-stable/src/libsodium/crypto_scalarmult/curve25519/sandy2x/fe51.h +35 -0
- package/ios/libsodium-stable/src/libsodium/crypto_scalarmult/curve25519/sandy2x/fe51_invert.c +58 -0
- package/ios/libsodium-stable/src/libsodium/crypto_scalarmult/curve25519/sandy2x/fe51_mul.S +200 -0
- package/ios/libsodium-stable/src/libsodium/crypto_scalarmult/curve25519/sandy2x/fe51_namespace.h +16 -0
- package/ios/libsodium-stable/src/libsodium/crypto_scalarmult/curve25519/sandy2x/fe51_nsquare.S +174 -0
- package/ios/libsodium-stable/src/libsodium/crypto_scalarmult/curve25519/sandy2x/fe51_pack.S +228 -0
- package/ios/libsodium-stable/src/libsodium/crypto_scalarmult/curve25519/sandy2x/fe_frombytes_sandy2x.c +78 -0
- package/ios/libsodium-stable/src/libsodium/crypto_scalarmult/curve25519/sandy2x/ladder.S +1442 -0
- package/ios/libsodium-stable/src/libsodium/crypto_scalarmult/curve25519/sandy2x/ladder.h +18 -0
- package/ios/libsodium-stable/src/libsodium/crypto_scalarmult/curve25519/sandy2x/ladder_namespace.h +8 -0
- package/ios/libsodium-stable/src/libsodium/crypto_scalarmult/curve25519/sandy2x/sandy2x.S +16 -0
- package/ios/libsodium-stable/src/libsodium/crypto_scalarmult/curve25519/scalarmult_curve25519.c +60 -0
- package/ios/libsodium-stable/src/libsodium/crypto_scalarmult/curve25519/scalarmult_curve25519.h +11 -0
- package/ios/libsodium-stable/src/libsodium/crypto_scalarmult/ed25519/ref10/scalarmult_ed25519_ref10.c +121 -0
- package/ios/libsodium-stable/src/libsodium/crypto_scalarmult/ristretto255/ref10/scalarmult_ristretto255_ref10.c +63 -0
- package/ios/libsodium-stable/src/libsodium/crypto_secretbox/crypto_secretbox.c +67 -0
- package/ios/libsodium-stable/src/libsodium/crypto_secretbox/crypto_secretbox_easy.c +145 -0
- package/ios/libsodium-stable/src/libsodium/crypto_secretbox/xchacha20poly1305/secretbox_xchacha20poly1305.c +177 -0
- package/ios/libsodium-stable/src/libsodium/crypto_secretbox/xsalsa20poly1305/secretbox_xsalsa20poly1305.c +89 -0
- package/ios/libsodium-stable/src/libsodium/crypto_secretstream/xchacha20poly1305/secretstream_xchacha20poly1305.c +313 -0
- package/ios/libsodium-stable/src/libsodium/crypto_shorthash/crypto_shorthash.c +34 -0
- package/ios/libsodium-stable/src/libsodium/crypto_shorthash/siphash24/ref/shorthash_siphash24_ref.c +71 -0
- package/ios/libsodium-stable/src/libsodium/crypto_shorthash/siphash24/ref/shorthash_siphash_ref.h +24 -0
- package/ios/libsodium-stable/src/libsodium/crypto_shorthash/siphash24/ref/shorthash_siphashx24_ref.c +77 -0
- package/ios/libsodium-stable/src/libsodium/crypto_shorthash/siphash24/shorthash_siphash24.c +11 -0
- package/ios/libsodium-stable/src/libsodium/crypto_shorthash/siphash24/shorthash_siphashx24.c +11 -0
- package/ios/libsodium-stable/src/libsodium/crypto_sign/crypto_sign.c +115 -0
- package/ios/libsodium-stable/src/libsodium/crypto_sign/ed25519/ref10/keypair.c +84 -0
- package/ios/libsodium-stable/src/libsodium/crypto_sign/ed25519/ref10/obsolete.c +118 -0
- package/ios/libsodium-stable/src/libsodium/crypto_sign/ed25519/ref10/open.c +98 -0
- package/ios/libsodium-stable/src/libsodium/crypto_sign/ed25519/ref10/sign.c +128 -0
- package/ios/libsodium-stable/src/libsodium/crypto_sign/ed25519/ref10/sign_ed25519_ref10.h +18 -0
- package/ios/libsodium-stable/src/libsodium/crypto_sign/ed25519/sign_ed25519.c +97 -0
- package/ios/libsodium-stable/src/libsodium/crypto_stream/chacha20/dolbeau/chacha20_dolbeau-avx2.c +180 -0
- package/ios/libsodium-stable/src/libsodium/crypto_stream/chacha20/dolbeau/chacha20_dolbeau-avx2.h +8 -0
- package/ios/libsodium-stable/src/libsodium/crypto_stream/chacha20/dolbeau/chacha20_dolbeau-ssse3.c +176 -0
- package/ios/libsodium-stable/src/libsodium/crypto_stream/chacha20/dolbeau/chacha20_dolbeau-ssse3.h +8 -0
- package/ios/libsodium-stable/src/libsodium/crypto_stream/chacha20/dolbeau/u0.h +86 -0
- package/ios/libsodium-stable/src/libsodium/crypto_stream/chacha20/dolbeau/u1.h +98 -0
- package/ios/libsodium-stable/src/libsodium/crypto_stream/chacha20/dolbeau/u4.h +177 -0
- package/ios/libsodium-stable/src/libsodium/crypto_stream/chacha20/dolbeau/u8.h +326 -0
- package/ios/libsodium-stable/src/libsodium/crypto_stream/chacha20/ref/chacha20_ref.c +312 -0
- package/ios/libsodium-stable/src/libsodium/crypto_stream/chacha20/ref/chacha20_ref.h +8 -0
- package/ios/libsodium-stable/src/libsodium/crypto_stream/chacha20/stream_chacha20.c +184 -0
- package/ios/libsodium-stable/src/libsodium/crypto_stream/chacha20/stream_chacha20.h +22 -0
- package/ios/libsodium-stable/src/libsodium/crypto_stream/crypto_stream.c +49 -0
- package/ios/libsodium-stable/src/libsodium/crypto_stream/salsa20/ref/salsa20_ref.c +120 -0
- package/ios/libsodium-stable/src/libsodium/crypto_stream/salsa20/ref/salsa20_ref.h +8 -0
- package/ios/libsodium-stable/src/libsodium/crypto_stream/salsa20/stream_salsa20.c +100 -0
- package/ios/libsodium-stable/src/libsodium/crypto_stream/salsa20/stream_salsa20.h +16 -0
- package/ios/libsodium-stable/src/libsodium/crypto_stream/salsa20/xmm6/salsa20_xmm6-asm.S +965 -0
- package/ios/libsodium-stable/src/libsodium/crypto_stream/salsa20/xmm6/salsa20_xmm6.c +31 -0
- package/ios/libsodium-stable/src/libsodium/crypto_stream/salsa20/xmm6/salsa20_xmm6.h +8 -0
- package/ios/libsodium-stable/src/libsodium/crypto_stream/salsa20/xmm6int/salsa20_xmm6int-avx2.c +134 -0
- package/ios/libsodium-stable/src/libsodium/crypto_stream/salsa20/xmm6int/salsa20_xmm6int-avx2.h +8 -0
- package/ios/libsodium-stable/src/libsodium/crypto_stream/salsa20/xmm6int/salsa20_xmm6int-sse2.c +128 -0
- package/ios/libsodium-stable/src/libsodium/crypto_stream/salsa20/xmm6int/salsa20_xmm6int-sse2.h +8 -0
- package/ios/libsodium-stable/src/libsodium/crypto_stream/salsa20/xmm6int/u0.h +195 -0
- package/ios/libsodium-stable/src/libsodium/crypto_stream/salsa20/xmm6int/u1.h +207 -0
- package/ios/libsodium-stable/src/libsodium/crypto_stream/salsa20/xmm6int/u4.h +547 -0
- package/ios/libsodium-stable/src/libsodium/crypto_stream/salsa20/xmm6int/u8.h +477 -0
- package/ios/libsodium-stable/src/libsodium/crypto_stream/salsa2012/ref/stream_salsa2012_ref.c +106 -0
- package/ios/libsodium-stable/src/libsodium/crypto_stream/salsa2012/stream_salsa2012.c +26 -0
- package/ios/libsodium-stable/src/libsodium/crypto_stream/salsa208/ref/stream_salsa208_ref.c +106 -0
- package/ios/libsodium-stable/src/libsodium/crypto_stream/salsa208/stream_salsa208.c +26 -0
- package/ios/libsodium-stable/src/libsodium/crypto_stream/xchacha20/stream_xchacha20.c +69 -0
- package/ios/libsodium-stable/src/libsodium/crypto_stream/xsalsa20/stream_xsalsa20.c +66 -0
- package/ios/libsodium-stable/src/libsodium/crypto_verify/verify.c +103 -0
- package/ios/libsodium-stable/src/libsodium/include/Makefile.am +76 -0
- package/ios/libsodium-stable/src/libsodium/include/sodium/core.h +28 -0
- package/ios/libsodium-stable/src/libsodium/include/sodium/crypto_aead_aegis128l.h +92 -0
- package/ios/libsodium-stable/src/libsodium/include/sodium/crypto_aead_aegis256.h +92 -0
- package/ios/libsodium-stable/src/libsodium/include/sodium/crypto_aead_aes256gcm.h +179 -0
- package/ios/libsodium-stable/src/libsodium/include/sodium/crypto_aead_chacha20poly1305.h +180 -0
- package/ios/libsodium-stable/src/libsodium/include/sodium/crypto_aead_xchacha20poly1305.h +100 -0
- package/ios/libsodium-stable/src/libsodium/include/sodium/crypto_auth.h +46 -0
- package/ios/libsodium-stable/src/libsodium/include/sodium/crypto_auth_hmacsha256.h +70 -0
- package/ios/libsodium-stable/src/libsodium/include/sodium/crypto_auth_hmacsha512.h +68 -0
- package/ios/libsodium-stable/src/libsodium/include/sodium/crypto_auth_hmacsha512256.h +65 -0
- package/ios/libsodium-stable/src/libsodium/include/sodium/crypto_box.h +177 -0
- package/ios/libsodium-stable/src/libsodium/include/sodium/crypto_box_curve25519xchacha20poly1305.h +164 -0
- package/ios/libsodium-stable/src/libsodium/include/sodium/crypto_box_curve25519xsalsa20poly1305.h +112 -0
- package/ios/libsodium-stable/src/libsodium/include/sodium/crypto_core_ed25519.h +100 -0
- package/ios/libsodium-stable/src/libsodium/include/sodium/crypto_core_hchacha20.h +36 -0
- package/ios/libsodium-stable/src/libsodium/include/sodium/crypto_core_hsalsa20.h +36 -0
- package/ios/libsodium-stable/src/libsodium/include/sodium/crypto_core_ristretto255.h +100 -0
- package/ios/libsodium-stable/src/libsodium/include/sodium/crypto_core_salsa20.h +36 -0
- package/ios/libsodium-stable/src/libsodium/include/sodium/crypto_core_salsa2012.h +36 -0
- package/ios/libsodium-stable/src/libsodium/include/sodium/crypto_core_salsa208.h +40 -0
- package/ios/libsodium-stable/src/libsodium/include/sodium/crypto_generichash.h +84 -0
- package/ios/libsodium-stable/src/libsodium/include/sodium/crypto_generichash_blake2b.h +122 -0
- package/ios/libsodium-stable/src/libsodium/include/sodium/crypto_hash.h +40 -0
- package/ios/libsodium-stable/src/libsodium/include/sodium/crypto_hash_sha256.h +60 -0
- package/ios/libsodium-stable/src/libsodium/include/sodium/crypto_hash_sha512.h +60 -0
- package/ios/libsodium-stable/src/libsodium/include/sodium/crypto_kdf.h +53 -0
- package/ios/libsodium-stable/src/libsodium/include/sodium/crypto_kdf_blake2b.h +44 -0
- package/ios/libsodium-stable/src/libsodium/include/sodium/crypto_kdf_hkdf_sha256.h +74 -0
- package/ios/libsodium-stable/src/libsodium/include/sodium/crypto_kdf_hkdf_sha512.h +75 -0
- package/ios/libsodium-stable/src/libsodium/include/sodium/crypto_kx.h +66 -0
- package/ios/libsodium-stable/src/libsodium/include/sodium/crypto_onetimeauth.h +65 -0
- package/ios/libsodium-stable/src/libsodium/include/sodium/crypto_onetimeauth_poly1305.h +72 -0
- package/ios/libsodium-stable/src/libsodium/include/sodium/crypto_pwhash.h +147 -0
- package/ios/libsodium-stable/src/libsodium/include/sodium/crypto_pwhash_argon2i.h +122 -0
- package/ios/libsodium-stable/src/libsodium/include/sodium/crypto_pwhash_argon2id.h +122 -0
- package/ios/libsodium-stable/src/libsodium/include/sodium/crypto_pwhash_scryptsalsa208sha256.h +120 -0
- package/ios/libsodium-stable/src/libsodium/include/sodium/crypto_scalarmult.h +46 -0
- package/ios/libsodium-stable/src/libsodium/include/sodium/crypto_scalarmult_curve25519.h +42 -0
- package/ios/libsodium-stable/src/libsodium/include/sodium/crypto_scalarmult_ed25519.h +51 -0
- package/ios/libsodium-stable/src/libsodium/include/sodium/crypto_scalarmult_ristretto255.h +43 -0
- package/ios/libsodium-stable/src/libsodium/include/sodium/crypto_secretbox.h +93 -0
- package/ios/libsodium-stable/src/libsodium/include/sodium/crypto_secretbox_xchacha20poly1305.h +70 -0
- package/ios/libsodium-stable/src/libsodium/include/sodium/crypto_secretbox_xsalsa20poly1305.h +69 -0
- package/ios/libsodium-stable/src/libsodium/include/sodium/crypto_secretstream_xchacha20poly1305.h +108 -0
- package/ios/libsodium-stable/src/libsodium/include/sodium/crypto_shorthash.h +41 -0
- package/ios/libsodium-stable/src/libsodium/include/sodium/crypto_shorthash_siphash24.h +50 -0
- package/ios/libsodium-stable/src/libsodium/include/sodium/crypto_sign.h +107 -0
- package/ios/libsodium-stable/src/libsodium/include/sodium/crypto_sign_ed25519.h +124 -0
- package/ios/libsodium-stable/src/libsodium/include/sodium/crypto_sign_edwards25519sha512batch.h +55 -0
- package/ios/libsodium-stable/src/libsodium/include/sodium/crypto_stream.h +59 -0
- package/ios/libsodium-stable/src/libsodium/include/sodium/crypto_stream_chacha20.h +106 -0
- package/ios/libsodium-stable/src/libsodium/include/sodium/crypto_stream_salsa20.h +61 -0
- package/ios/libsodium-stable/src/libsodium/include/sodium/crypto_stream_salsa2012.h +53 -0
- package/ios/libsodium-stable/src/libsodium/include/sodium/crypto_stream_salsa208.h +56 -0
- package/ios/libsodium-stable/src/libsodium/include/sodium/crypto_stream_xchacha20.h +61 -0
- package/ios/libsodium-stable/src/libsodium/include/sodium/crypto_stream_xsalsa20.h +61 -0
- package/ios/libsodium-stable/src/libsodium/include/sodium/crypto_verify_16.h +23 -0
- package/ios/libsodium-stable/src/libsodium/include/sodium/crypto_verify_32.h +23 -0
- package/ios/libsodium-stable/src/libsodium/include/sodium/crypto_verify_64.h +23 -0
- package/ios/libsodium-stable/src/libsodium/include/sodium/export.h +57 -0
- package/ios/libsodium-stable/src/libsodium/include/sodium/private/asm_cet.h +11 -0
- package/ios/libsodium-stable/src/libsodium/include/sodium/private/chacha20_ietf_ext.h +16 -0
- package/ios/libsodium-stable/src/libsodium/include/sodium/private/common.h +296 -0
- package/ios/libsodium-stable/src/libsodium/include/sodium/private/ed25519_ref10.h +142 -0
- package/ios/libsodium-stable/src/libsodium/include/sodium/private/ed25519_ref10_fe_25_5.h +1030 -0
- package/ios/libsodium-stable/src/libsodium/include/sodium/private/ed25519_ref10_fe_51.h +508 -0
- package/ios/libsodium-stable/src/libsodium/include/sodium/private/implementations.h +13 -0
- package/ios/libsodium-stable/src/libsodium/include/sodium/private/mutex.h +7 -0
- package/ios/libsodium-stable/src/libsodium/include/sodium/private/softaes.h +56 -0
- package/ios/libsodium-stable/src/libsodium/include/sodium/private/sse2_64_32.h +50 -0
- package/ios/libsodium-stable/src/libsodium/include/sodium/randombytes.h +72 -0
- package/ios/libsodium-stable/src/libsodium/include/sodium/randombytes_internal_random.h +22 -0
- package/ios/libsodium-stable/src/libsodium/include/sodium/randombytes_sysrandom.h +19 -0
- package/ios/libsodium-stable/src/libsodium/include/sodium/runtime.h +55 -0
- package/ios/libsodium-stable/src/libsodium/include/sodium/utils.h +179 -0
- package/ios/libsodium-stable/src/libsodium/include/sodium/version.h.in +33 -0
- package/ios/libsodium-stable/src/libsodium/include/sodium.h +75 -0
- package/ios/libsodium-stable/src/libsodium/randombytes/internal/randombytes_internal_random.c +648 -0
- package/ios/libsodium-stable/src/libsodium/randombytes/randombytes.c +200 -0
- package/ios/libsodium-stable/src/libsodium/randombytes/sysrandom/randombytes_sysrandom.c +396 -0
- package/ios/libsodium-stable/src/libsodium/sodium/codecs.c +335 -0
- package/ios/libsodium-stable/src/libsodium/sodium/core.c +216 -0
- package/ios/libsodium-stable/src/libsodium/sodium/runtime.c +391 -0
- package/ios/libsodium-stable/src/libsodium/sodium/utils.c +809 -0
- package/ios/libsodium-stable/src/libsodium/sodium/version.c +30 -0
- package/ios/libsodium-stable/test/Makefile.am +5 -0
- package/ios/libsodium-stable/test/constcheck.sh +22 -0
- package/ios/libsodium-stable/test/default/Makefile.am +525 -0
- package/ios/libsodium-stable/test/default/aead_aegis128l.c +642 -0
- package/ios/libsodium-stable/test/default/aead_aegis128l.exp +1 -0
- package/ios/libsodium-stable/test/default/aead_aegis256.c +723 -0
- package/ios/libsodium-stable/test/default/aead_aegis256.exp +1 -0
- package/ios/libsodium-stable/test/default/aead_aes256gcm.c +3328 -0
- package/ios/libsodium-stable/test/default/aead_aes256gcm.exp +1 -0
- package/ios/libsodium-stable/test/default/aead_aes256gcm2.c +276 -0
- package/ios/libsodium-stable/test/default/aead_aes256gcm2.exp +1 -0
- package/ios/libsodium-stable/test/default/aead_chacha20poly1305.c +372 -0
- package/ios/libsodium-stable/test/default/aead_chacha20poly1305.exp +63 -0
- package/ios/libsodium-stable/test/default/aead_chacha20poly13052.c +1046 -0
- package/ios/libsodium-stable/test/default/aead_chacha20poly13052.exp +1 -0
- package/ios/libsodium-stable/test/default/aead_xchacha20poly1305.c +203 -0
- package/ios/libsodium-stable/test/default/aead_xchacha20poly1305.exp +51 -0
- package/ios/libsodium-stable/test/default/auth.c +141 -0
- package/ios/libsodium-stable/test/default/auth.exp +30 -0
- package/ios/libsodium-stable/test/default/auth2.c +34 -0
- package/ios/libsodium-stable/test/default/auth2.exp +4 -0
- package/ios/libsodium-stable/test/default/auth3.c +36 -0
- package/ios/libsodium-stable/test/default/auth3.exp +1 -0
- package/ios/libsodium-stable/test/default/auth5.c +41 -0
- package/ios/libsodium-stable/test/default/auth5.exp +0 -0
- package/ios/libsodium-stable/test/default/auth6.c +23 -0
- package/ios/libsodium-stable/test/default/auth6.exp +8 -0
- package/ios/libsodium-stable/test/default/auth7.c +41 -0
- package/ios/libsodium-stable/test/default/auth7.exp +0 -0
- package/ios/libsodium-stable/test/default/box.c +112 -0
- package/ios/libsodium-stable/test/default/box.exp +38 -0
- package/ios/libsodium-stable/test/default/box2.c +80 -0
- package/ios/libsodium-stable/test/default/box2.exp +34 -0
- package/ios/libsodium-stable/test/default/box7.c +50 -0
- package/ios/libsodium-stable/test/default/box7.exp +0 -0
- package/ios/libsodium-stable/test/default/box8.c +58 -0
- package/ios/libsodium-stable/test/default/box8.exp +0 -0
- package/ios/libsodium-stable/test/default/box_easy.c +72 -0
- package/ios/libsodium-stable/test/default/box_easy.exp +3 -0
- package/ios/libsodium-stable/test/default/box_easy2.c +149 -0
- package/ios/libsodium-stable/test/default/box_easy2.exp +7 -0
- package/ios/libsodium-stable/test/default/box_seal.c +165 -0
- package/ios/libsodium-stable/test/default/box_seal.exp +8 -0
- package/ios/libsodium-stable/test/default/box_seed.c +30 -0
- package/ios/libsodium-stable/test/default/box_seed.exp +8 -0
- package/ios/libsodium-stable/test/default/chacha20.c +186 -0
- package/ios/libsodium-stable/test/default/chacha20.exp +64 -0
- package/ios/libsodium-stable/test/default/cmptest.h +238 -0
- package/ios/libsodium-stable/test/default/codecs.c +251 -0
- package/ios/libsodium-stable/test/default/codecs.exp +30 -0
- package/ios/libsodium-stable/test/default/core1.c +41 -0
- package/ios/libsodium-stable/test/default/core1.exp +4 -0
- package/ios/libsodium-stable/test/default/core2.c +38 -0
- package/ios/libsodium-stable/test/default/core2.exp +4 -0
- package/ios/libsodium-stable/test/default/core3.c +115 -0
- package/ios/libsodium-stable/test/default/core3.exp +3 -0
- package/ios/libsodium-stable/test/default/core4.c +36 -0
- package/ios/libsodium-stable/test/default/core4.exp +8 -0
- package/ios/libsodium-stable/test/default/core5.c +33 -0
- package/ios/libsodium-stable/test/default/core5.exp +4 -0
- package/ios/libsodium-stable/test/default/core6.c +52 -0
- package/ios/libsodium-stable/test/default/core6.exp +4 -0
- package/ios/libsodium-stable/test/default/core_ed25519.c +545 -0
- package/ios/libsodium-stable/test/default/core_ed25519.exp +55 -0
- package/ios/libsodium-stable/test/default/core_ristretto255.c +271 -0
- package/ios/libsodium-stable/test/default/core_ristretto255.exp +8 -0
- package/ios/libsodium-stable/test/default/ed25519_convert.c +70 -0
- package/ios/libsodium-stable/test/default/ed25519_convert.exp +3 -0
- package/ios/libsodium-stable/test/default/generichash.c +1406 -0
- package/ios/libsodium-stable/test/default/generichash.exp +65 -0
- package/ios/libsodium-stable/test/default/generichash2.c +62 -0
- package/ios/libsodium-stable/test/default/generichash2.exp +64 -0
- package/ios/libsodium-stable/test/default/generichash3.c +176 -0
- package/ios/libsodium-stable/test/default/generichash3.exp +75 -0
- package/ios/libsodium-stable/test/default/hash.c +47 -0
- package/ios/libsodium-stable/test/default/hash.exp +4 -0
- package/ios/libsodium-stable/test/default/hash3.c +20 -0
- package/ios/libsodium-stable/test/default/hash3.exp +1 -0
- package/ios/libsodium-stable/test/default/index.html.tpl +98 -0
- package/ios/libsodium-stable/test/default/kdf.c +71 -0
- package/ios/libsodium-stable/test/default/kdf.exp +77 -0
- package/ios/libsodium-stable/test/default/kdf_hkdf.c +102 -0
- package/ios/libsodium-stable/test/default/kdf_hkdf.exp +205 -0
- package/ios/libsodium-stable/test/default/keygen.c +67 -0
- package/ios/libsodium-stable/test/default/keygen.exp +1 -0
- package/ios/libsodium-stable/test/default/kx.c +149 -0
- package/ios/libsodium-stable/test/default/kx.exp +7 -0
- package/ios/libsodium-stable/test/default/metamorphic.c +187 -0
- package/ios/libsodium-stable/test/default/metamorphic.exp +1 -0
- package/ios/libsodium-stable/test/default/misuse.c +187 -0
- package/ios/libsodium-stable/test/default/misuse.exp +0 -0
- package/ios/libsodium-stable/test/default/onetimeauth.c +63 -0
- package/ios/libsodium-stable/test/default/onetimeauth.exp +4 -0
- package/ios/libsodium-stable/test/default/onetimeauth2.c +33 -0
- package/ios/libsodium-stable/test/default/onetimeauth2.exp +1 -0
- package/ios/libsodium-stable/test/default/onetimeauth7.c +36 -0
- package/ios/libsodium-stable/test/default/onetimeauth7.exp +0 -0
- package/ios/libsodium-stable/test/default/pre.js.inc +22 -0
- package/ios/libsodium-stable/test/default/pwhash_argon2i.c +467 -0
- package/ios/libsodium-stable/test/default/pwhash_argon2i.exp +11 -0
- package/ios/libsodium-stable/test/default/pwhash_argon2id.c +517 -0
- package/ios/libsodium-stable/test/default/pwhash_argon2id.exp +14 -0
- package/ios/libsodium-stable/test/default/pwhash_scrypt.c +393 -0
- package/ios/libsodium-stable/test/default/pwhash_scrypt.exp +37 -0
- package/ios/libsodium-stable/test/default/pwhash_scrypt_ll.c +59 -0
- package/ios/libsodium-stable/test/default/pwhash_scrypt_ll.exp +15 -0
- package/ios/libsodium-stable/test/default/randombytes.c +164 -0
- package/ios/libsodium-stable/test/default/randombytes.exp +2 -0
- package/ios/libsodium-stable/test/default/run.sh +9 -0
- package/ios/libsodium-stable/test/default/scalarmult.c +77 -0
- package/ios/libsodium-stable/test/default/scalarmult.exp +5 -0
- package/ios/libsodium-stable/test/default/scalarmult2.c +22 -0
- package/ios/libsodium-stable/test/default/scalarmult2.exp +1 -0
- package/ios/libsodium-stable/test/default/scalarmult5.c +30 -0
- package/ios/libsodium-stable/test/default/scalarmult5.exp +1 -0
- package/ios/libsodium-stable/test/default/scalarmult6.c +54 -0
- package/ios/libsodium-stable/test/default/scalarmult6.exp +4 -0
- package/ios/libsodium-stable/test/default/scalarmult7.c +34 -0
- package/ios/libsodium-stable/test/default/scalarmult7.exp +1 -0
- package/ios/libsodium-stable/test/default/scalarmult8.c +580 -0
- package/ios/libsodium-stable/test/default/scalarmult8.exp +65 -0
- package/ios/libsodium-stable/test/default/scalarmult_ed25519.c +134 -0
- package/ios/libsodium-stable/test/default/scalarmult_ed25519.exp +1 -0
- package/ios/libsodium-stable/test/default/scalarmult_ristretto255.c +51 -0
- package/ios/libsodium-stable/test/default/scalarmult_ristretto255.exp +18 -0
- package/ios/libsodium-stable/test/default/secretbox.c +84 -0
- package/ios/libsodium-stable/test/default/secretbox.exp +38 -0
- package/ios/libsodium-stable/test/default/secretbox2.c +55 -0
- package/ios/libsodium-stable/test/default/secretbox2.exp +17 -0
- package/ios/libsodium-stable/test/default/secretbox7.c +36 -0
- package/ios/libsodium-stable/test/default/secretbox7.exp +0 -0
- package/ios/libsodium-stable/test/default/secretbox8.c +41 -0
- package/ios/libsodium-stable/test/default/secretbox8.exp +0 -0
- package/ios/libsodium-stable/test/default/secretbox_easy.c +124 -0
- package/ios/libsodium-stable/test/default/secretbox_easy.exp +9 -0
- package/ios/libsodium-stable/test/default/secretbox_easy2.c +72 -0
- package/ios/libsodium-stable/test/default/secretbox_easy2.exp +5 -0
- package/ios/libsodium-stable/test/default/secretstream_xchacha20poly1305.c +329 -0
- package/ios/libsodium-stable/test/default/secretstream_xchacha20poly1305.exp +1 -0
- package/ios/libsodium-stable/test/default/shorthash.c +35 -0
- package/ios/libsodium-stable/test/default/shorthash.exp +64 -0
- package/ios/libsodium-stable/test/default/sign.c +1324 -0
- package/ios/libsodium-stable/test/default/sign.exp +5 -0
- package/ios/libsodium-stable/test/default/siphashx24.c +33 -0
- package/ios/libsodium-stable/test/default/siphashx24.exp +64 -0
- package/ios/libsodium-stable/test/default/sodium_core.c +43 -0
- package/ios/libsodium-stable/test/default/sodium_core.exp +1 -0
- package/ios/libsodium-stable/test/default/sodium_utils.c +224 -0
- package/ios/libsodium-stable/test/default/sodium_utils.exp +25 -0
- package/ios/libsodium-stable/test/default/sodium_utils2.c +120 -0
- package/ios/libsodium-stable/test/default/sodium_utils2.exp +3 -0
- package/ios/libsodium-stable/test/default/sodium_utils3.c +90 -0
- package/ios/libsodium-stable/test/default/sodium_utils3.exp +2 -0
- package/ios/libsodium-stable/test/default/sodium_version.c +18 -0
- package/ios/libsodium-stable/test/default/sodium_version.exp +3 -0
- package/ios/libsodium-stable/test/default/stream.c +84 -0
- package/ios/libsodium-stable/test/default/stream.exp +83 -0
- package/ios/libsodium-stable/test/default/stream2.c +59 -0
- package/ios/libsodium-stable/test/default/stream2.exp +2 -0
- package/ios/libsodium-stable/test/default/stream3.c +32 -0
- package/ios/libsodium-stable/test/default/stream3.exp +4 -0
- package/ios/libsodium-stable/test/default/stream4.c +51 -0
- package/ios/libsodium-stable/test/default/stream4.exp +17 -0
- package/ios/libsodium-stable/test/default/verify1.c +76 -0
- package/ios/libsodium-stable/test/default/verify1.exp +2 -0
- package/ios/libsodium-stable/test/default/wasi-test-wrapper.sh +98 -0
- package/ios/libsodium-stable/test/default/wintest.bat +61 -0
- package/ios/libsodium-stable/test/default/xchacha20.c +428 -0
- package/ios/libsodium-stable/test/default/xchacha20.exp +5 -0
- package/ios/libsodium-stable/test/quirks/quirks.h +34 -0
- package/lib/commonjs/cipher.js +180 -0
- package/lib/commonjs/cipher.js.map +1 -0
- package/lib/commonjs/ed.js +42 -0
- package/lib/commonjs/ed.js.map +1 -0
- package/lib/commonjs/expo-plugin/@types.js +2 -0
- package/lib/commonjs/expo-plugin/@types.js.map +1 -0
- package/lib/commonjs/expo-plugin/withRNQC.js +25 -0
- package/lib/commonjs/expo-plugin/withRNQC.js.map +1 -0
- package/lib/commonjs/expo-plugin/withSodiumAndroid.js +25 -0
- package/lib/commonjs/expo-plugin/withSodiumAndroid.js.map +1 -0
- package/lib/commonjs/expo-plugin/withSodiumIos.js +26 -0
- package/lib/commonjs/expo-plugin/withSodiumIos.js.map +1 -0
- package/lib/commonjs/expo-plugin/withXCode.js +51 -0
- package/lib/commonjs/expo-plugin/withXCode.js.map +1 -0
- package/lib/commonjs/hash.js +168 -0
- package/lib/commonjs/hash.js.map +1 -0
- package/lib/commonjs/hmac.js +109 -0
- package/lib/commonjs/hmac.js.map +1 -0
- package/lib/commonjs/index.js +100 -30
- package/lib/commonjs/index.js.map +1 -1
- package/lib/commonjs/keys/classes.js +191 -0
- package/lib/commonjs/keys/classes.js.map +1 -0
- package/lib/commonjs/keys/generateKeyPair.js +148 -0
- package/lib/commonjs/keys/generateKeyPair.js.map +1 -0
- package/lib/commonjs/keys/index.js +62 -0
- package/lib/commonjs/keys/index.js.map +1 -0
- package/lib/commonjs/keys/signVerify.js +41 -0
- package/lib/commonjs/keys/signVerify.js.map +1 -0
- package/lib/commonjs/keys/utils.js +118 -0
- package/lib/commonjs/keys/utils.js.map +1 -0
- package/lib/commonjs/pbkdf2.js +89 -0
- package/lib/commonjs/pbkdf2.js.map +1 -0
- package/lib/commonjs/random.js +9 -3
- package/lib/commonjs/random.js.map +1 -1
- package/lib/commonjs/specs/cipher.nitro.js +6 -0
- package/lib/commonjs/specs/cipher.nitro.js.map +1 -0
- package/lib/commonjs/specs/edKeyPair.nitro.js +6 -0
- package/lib/commonjs/specs/edKeyPair.nitro.js.map +1 -0
- package/lib/commonjs/specs/hash.nitro.js +6 -0
- package/lib/commonjs/specs/hash.nitro.js.map +1 -0
- package/lib/commonjs/specs/hmac.nitro.js +6 -0
- package/lib/commonjs/specs/hmac.nitro.js.map +1 -0
- package/lib/commonjs/specs/keyObjectHandle.nitro.js +6 -0
- package/lib/commonjs/specs/keyObjectHandle.nitro.js.map +1 -0
- package/lib/commonjs/specs/pbkdf2.nitro.js +6 -0
- package/lib/commonjs/specs/pbkdf2.nitro.js.map +1 -0
- package/lib/commonjs/utils/cipher.js +64 -0
- package/lib/commonjs/utils/cipher.js.map +1 -0
- package/lib/commonjs/utils/conversion.js +117 -6
- package/lib/commonjs/utils/conversion.js.map +1 -1
- package/lib/commonjs/utils/errors.js +14 -0
- package/lib/commonjs/utils/errors.js.map +1 -0
- package/lib/commonjs/utils/hashnames.js +90 -0
- package/lib/commonjs/utils/hashnames.js.map +1 -0
- package/lib/commonjs/utils/index.js +54 -5
- package/lib/commonjs/utils/index.js.map +1 -1
- package/lib/commonjs/utils/types.js +40 -0
- package/lib/commonjs/utils/types.js.map +1 -1
- package/lib/commonjs/utils/validation.js +25 -0
- package/lib/commonjs/utils/validation.js.map +1 -0
- package/lib/module/cipher.js +173 -0
- package/lib/module/cipher.js.map +1 -0
- package/lib/module/ed.js +37 -0
- package/lib/module/ed.js.map +1 -0
- package/lib/module/expo-plugin/@types.js +2 -0
- package/lib/module/expo-plugin/@types.js.map +1 -0
- package/lib/module/expo-plugin/withRNQC.js +21 -0
- package/lib/module/expo-plugin/withRNQC.js.map +1 -0
- package/lib/module/expo-plugin/withSodiumAndroid.js +20 -0
- package/lib/module/expo-plugin/withSodiumAndroid.js.map +1 -0
- package/lib/module/expo-plugin/withSodiumIos.js +20 -0
- package/lib/module/expo-plugin/withSodiumIos.js.map +1 -0
- package/lib/module/expo-plugin/withXCode.js +46 -0
- package/lib/module/expo-plugin/withXCode.js.map +1 -0
- package/lib/module/hash.js +162 -0
- package/lib/module/hash.js.map +1 -0
- package/lib/module/hmac.js +104 -0
- package/lib/module/hmac.js.map +1 -0
- package/lib/module/index.js +25 -29
- package/lib/module/index.js.map +1 -1
- package/lib/module/keys/classes.js +182 -0
- package/lib/module/keys/classes.js.map +1 -0
- package/lib/module/keys/generateKeyPair.js +148 -0
- package/lib/module/keys/generateKeyPair.js.map +1 -0
- package/lib/module/keys/index.js +29 -0
- package/lib/module/keys/index.js.map +1 -0
- package/lib/module/keys/signVerify.js +41 -0
- package/lib/module/keys/signVerify.js.map +1 -0
- package/lib/module/keys/utils.js +110 -0
- package/lib/module/keys/utils.js.map +1 -0
- package/lib/module/pbkdf2.js +83 -0
- package/lib/module/pbkdf2.js.map +1 -0
- package/lib/module/random.js +7 -1
- package/lib/module/random.js.map +1 -1
- package/lib/module/specs/cipher.nitro.js +4 -0
- package/lib/module/specs/cipher.nitro.js.map +1 -0
- package/lib/module/specs/edKeyPair.nitro.js +4 -0
- package/lib/module/specs/edKeyPair.nitro.js.map +1 -0
- package/lib/module/specs/hash.nitro.js +4 -0
- package/lib/module/specs/hash.nitro.js.map +1 -0
- package/lib/module/specs/hmac.nitro.js +4 -0
- package/lib/module/specs/hmac.nitro.js.map +1 -0
- package/lib/module/specs/keyObjectHandle.nitro.js +4 -0
- package/lib/module/specs/keyObjectHandle.nitro.js.map +1 -0
- package/lib/module/specs/pbkdf2.nitro.js +4 -0
- package/lib/module/specs/pbkdf2.nitro.js.map +1 -0
- package/lib/module/utils/cipher.js +56 -0
- package/lib/module/utils/cipher.js.map +1 -0
- package/lib/module/utils/conversion.js +115 -8
- package/lib/module/utils/conversion.js.map +1 -1
- package/lib/module/utils/errors.js +10 -0
- package/lib/module/utils/errors.js.map +1 -0
- package/lib/module/utils/hashnames.js +88 -0
- package/lib/module/utils/hashnames.js.map +1 -0
- package/lib/module/utils/index.js +5 -5
- package/lib/module/utils/index.js.map +1 -1
- package/lib/module/utils/types.js +44 -0
- package/lib/module/utils/types.js.map +1 -1
- package/lib/module/utils/validation.js +19 -0
- package/lib/module/utils/validation.js.map +1 -0
- package/lib/tsconfig.tsbuildinfo +1 -1
- package/lib/typescript/cipher.d.ts +60 -0
- package/lib/typescript/cipher.d.ts.map +1 -0
- package/lib/typescript/ed.d.ts +17 -0
- package/lib/typescript/ed.d.ts.map +1 -0
- package/lib/typescript/expo-plugin/@types.d.ts +8 -0
- package/lib/typescript/expo-plugin/@types.d.ts.map +1 -0
- package/lib/typescript/expo-plugin/withRNQC.d.ts +4 -0
- package/lib/typescript/expo-plugin/withRNQC.d.ts.map +1 -0
- package/lib/typescript/expo-plugin/withSodiumAndroid.d.ts +4 -0
- package/lib/typescript/expo-plugin/withSodiumAndroid.d.ts.map +1 -0
- package/lib/typescript/expo-plugin/withSodiumIos.d.ts +4 -0
- package/lib/typescript/expo-plugin/withSodiumIos.d.ts.map +1 -0
- package/lib/typescript/expo-plugin/withXCode.d.ts +9 -0
- package/lib/typescript/expo-plugin/withXCode.d.ts.map +1 -0
- package/lib/typescript/hash.d.ts +109 -0
- package/lib/typescript/hash.d.ts.map +1 -0
- package/lib/typescript/hmac.d.ts +66 -0
- package/lib/typescript/hmac.d.ts.map +1 -0
- package/lib/typescript/index.d.ts +67 -10
- package/lib/typescript/index.d.ts.map +1 -1
- package/lib/typescript/keys/classes.d.ts +38 -0
- package/lib/typescript/keys/classes.d.ts.map +1 -0
- package/lib/typescript/keys/generateKeyPair.d.ts +1 -0
- package/lib/typescript/keys/generateKeyPair.d.ts.map +1 -0
- package/lib/typescript/keys/index.d.ts +4 -0
- package/lib/typescript/keys/index.d.ts.map +1 -0
- package/lib/typescript/keys/signVerify.d.ts +1 -0
- package/lib/typescript/keys/signVerify.d.ts.map +1 -0
- package/lib/typescript/keys/utils.d.ts +32 -0
- package/lib/typescript/keys/utils.d.ts.map +1 -0
- package/lib/typescript/pbkdf2.d.ts +12 -0
- package/lib/typescript/pbkdf2.d.ts.map +1 -0
- package/lib/typescript/random.d.ts +11 -5
- package/lib/typescript/random.d.ts.map +1 -1
- package/lib/typescript/specs/cipher.nitro.d.ts +29 -0
- package/lib/typescript/specs/cipher.nitro.d.ts.map +1 -0
- package/lib/typescript/specs/edKeyPair.nitro.d.ts +16 -0
- package/lib/typescript/specs/edKeyPair.nitro.d.ts.map +1 -0
- package/lib/typescript/specs/hash.nitro.d.ts +12 -0
- package/lib/typescript/specs/hash.nitro.d.ts.map +1 -0
- package/lib/typescript/specs/hmac.nitro.d.ts +10 -0
- package/lib/typescript/specs/hmac.nitro.d.ts.map +1 -0
- package/lib/typescript/specs/keyObjectHandle.nitro.d.ts +15 -0
- package/lib/typescript/specs/keyObjectHandle.nitro.d.ts.map +1 -0
- package/lib/typescript/specs/pbkdf2.nitro.d.ts +9 -0
- package/lib/typescript/specs/pbkdf2.nitro.d.ts.map +1 -0
- package/lib/typescript/utils/cipher.d.ts +7 -0
- package/lib/typescript/utils/cipher.d.ts.map +1 -0
- package/lib/typescript/utils/conversion.d.ts +23 -2
- package/lib/typescript/utils/conversion.d.ts.map +1 -1
- package/lib/typescript/utils/errors.d.ts +7 -0
- package/lib/typescript/utils/errors.d.ts.map +1 -0
- package/lib/typescript/utils/hashnames.d.ts +11 -0
- package/lib/typescript/utils/hashnames.d.ts.map +1 -0
- package/lib/typescript/utils/index.d.ts +5 -5
- package/lib/typescript/utils/index.d.ts.map +1 -1
- package/lib/typescript/utils/types.d.ts +168 -2
- package/lib/typescript/utils/types.d.ts.map +1 -1
- package/lib/typescript/utils/validation.d.ts +8 -0
- package/lib/typescript/utils/validation.d.ts.map +1 -0
- package/nitrogen/generated/.gitattributes +1 -0
- package/nitrogen/generated/android/QuickCrypto+autolinking.cmake +44 -4
- package/nitrogen/generated/android/QuickCrypto+autolinking.gradle +4 -3
- package/nitrogen/generated/android/QuickCryptoOnLoad.cpp +104 -0
- package/nitrogen/generated/android/QuickCryptoOnLoad.hpp +25 -0
- package/nitrogen/generated/android/kotlin/com/margelo/nitro/crypto/QuickCryptoOnLoad.kt +35 -0
- package/nitrogen/generated/ios/QuickCrypto+autolinking.rb +11 -8
- package/nitrogen/generated/ios/QuickCrypto-Swift-Cxx-Bridge.cpp +11 -3
- package/nitrogen/generated/ios/QuickCrypto-Swift-Cxx-Bridge.hpp +5 -3
- package/nitrogen/generated/ios/QuickCrypto-Swift-Cxx-Umbrella.hpp +15 -7
- package/nitrogen/generated/ios/QuickCryptoAutolinking.mm +95 -0
- package/nitrogen/generated/ios/QuickCryptoAutolinking.swift +12 -0
- package/nitrogen/generated/shared/c++/CFRGKeyPairType.hpp +86 -0
- package/nitrogen/generated/shared/c++/CipherArgs.hpp +88 -0
- package/nitrogen/generated/shared/c++/HybridCipherFactorySpec.cpp +21 -0
- package/nitrogen/generated/shared/c++/HybridCipherFactorySpec.hpp +67 -0
- package/nitrogen/generated/shared/c++/HybridCipherSpec.cpp +28 -0
- package/nitrogen/generated/shared/c++/HybridCipherSpec.hpp +76 -0
- package/nitrogen/generated/shared/c++/HybridEdKeyPairSpec.cpp +29 -0
- package/nitrogen/generated/shared/c++/HybridEdKeyPairSpec.hpp +74 -0
- package/nitrogen/generated/shared/c++/HybridHashSpec.cpp +25 -0
- package/nitrogen/generated/shared/c++/HybridHashSpec.hpp +74 -0
- package/nitrogen/generated/shared/c++/HybridHmacSpec.cpp +23 -0
- package/nitrogen/generated/shared/c++/HybridHmacSpec.hpp +66 -0
- package/nitrogen/generated/shared/c++/HybridKeyObjectHandleSpec.cpp +27 -0
- package/nitrogen/generated/shared/c++/HybridKeyObjectHandleSpec.hpp +93 -0
- package/nitrogen/generated/shared/c++/HybridPbkdf2Spec.cpp +22 -0
- package/nitrogen/generated/shared/c++/HybridPbkdf2Spec.hpp +66 -0
- package/nitrogen/generated/shared/c++/HybridRandomSpec.cpp +2 -3
- package/nitrogen/generated/shared/c++/HybridRandomSpec.hpp +9 -6
- package/nitrogen/generated/shared/c++/JWK.hpp +163 -0
- package/nitrogen/generated/shared/c++/JWKkty.hpp +86 -0
- package/nitrogen/generated/shared/c++/JWKuse.hpp +78 -0
- package/nitrogen/generated/shared/c++/KFormatType.hpp +65 -0
- package/nitrogen/generated/shared/c++/KeyDetail.hpp +94 -0
- package/nitrogen/generated/shared/c++/KeyEncoding.hpp +66 -0
- package/nitrogen/generated/shared/c++/KeyType.hpp +65 -0
- package/nitrogen/generated/shared/c++/KeyUsage.hpp +102 -0
- package/nitrogen/generated/shared/c++/NamedCurve.hpp +82 -0
- package/package.json +61 -37
- package/src/cipher.ts +335 -0
- package/src/ed.ts +79 -0
- package/src/expo-plugin/@types.ts +7 -0
- package/src/expo-plugin/withRNQC.ts +23 -0
- package/src/expo-plugin/withSodiumAndroid.ts +24 -0
- package/src/expo-plugin/withSodiumIos.ts +30 -0
- package/src/expo-plugin/withXCode.ts +55 -0
- package/src/hash.ts +208 -0
- package/src/hmac.ts +135 -0
- package/src/index.ts +24 -29
- package/src/keys/classes.ts +211 -0
- package/src/keys/generateKeyPair.ts +146 -0
- package/src/keys/index.ts +42 -0
- package/src/keys/signVerify.ts +39 -0
- package/src/keys/utils.ts +184 -0
- package/src/pbkdf2.ts +154 -0
- package/src/random.ts +26 -23
- package/src/specs/cipher.nitro.ts +25 -0
- package/src/specs/edKeyPair.nitro.ts +41 -0
- package/src/specs/hash.nitro.ts +9 -0
- package/src/specs/hmac.nitro.ts +7 -0
- package/src/specs/keyObjectHandle.nitro.ts +32 -0
- package/src/specs/pbkdf2.nitro.ts +18 -0
- package/src/specs/random.nitro.ts +2 -2
- package/src/utils/cipher.ts +60 -0
- package/src/utils/conversion.ts +137 -9
- package/src/utils/errors.ts +15 -0
- package/src/utils/hashnames.ts +96 -0
- package/src/utils/index.ts +5 -6
- package/src/utils/types.ts +301 -3
- package/src/utils/validation.ts +35 -0
- package/ios/QuickCryptoOnLoad.mm +0 -19
- package/lib/module/package.json +0 -1
|
@@ -0,0 +1,206 @@
|
|
|
1
|
+
#! /bin/sh
|
|
2
|
+
|
|
3
|
+
export MAKE_FLAGS='-j4'
|
|
4
|
+
export EXPORTED_FUNCTIONS_STANDARD='["_malloc","_free","_crypto_aead_aegis128l_abytes","_crypto_aead_aegis128l_decrypt","_crypto_aead_aegis128l_decrypt_detached","_crypto_aead_aegis128l_encrypt","_crypto_aead_aegis128l_encrypt_detached","_crypto_aead_aegis128l_keybytes","_crypto_aead_aegis128l_keygen","_crypto_aead_aegis128l_messagebytes_max","_crypto_aead_aegis128l_npubbytes","_crypto_aead_aegis128l_nsecbytes","_crypto_aead_aegis256_abytes","_crypto_aead_aegis256_decrypt","_crypto_aead_aegis256_decrypt_detached","_crypto_aead_aegis256_encrypt","_crypto_aead_aegis256_encrypt_detached","_crypto_aead_aegis256_keybytes","_crypto_aead_aegis256_keygen","_crypto_aead_aegis256_messagebytes_max","_crypto_aead_aegis256_npubbytes","_crypto_aead_aegis256_nsecbytes","_crypto_aead_aes256gcm_is_available","_crypto_aead_chacha20poly1305_abytes","_crypto_aead_chacha20poly1305_decrypt","_crypto_aead_chacha20poly1305_decrypt_detached","_crypto_aead_chacha20poly1305_encrypt","_crypto_aead_chacha20poly1305_encrypt_detached","_crypto_aead_chacha20poly1305_ietf_abytes","_crypto_aead_chacha20poly1305_ietf_decrypt","_crypto_aead_chacha20poly1305_ietf_decrypt_detached","_crypto_aead_chacha20poly1305_ietf_encrypt","_crypto_aead_chacha20poly1305_ietf_encrypt_detached","_crypto_aead_chacha20poly1305_ietf_keybytes","_crypto_aead_chacha20poly1305_ietf_keygen","_crypto_aead_chacha20poly1305_ietf_messagebytes_max","_crypto_aead_chacha20poly1305_ietf_npubbytes","_crypto_aead_chacha20poly1305_ietf_nsecbytes","_crypto_aead_chacha20poly1305_keybytes","_crypto_aead_chacha20poly1305_keygen","_crypto_aead_chacha20poly1305_messagebytes_max","_crypto_aead_chacha20poly1305_npubbytes","_crypto_aead_chacha20poly1305_nsecbytes","_crypto_aead_xchacha20poly1305_ietf_abytes","_crypto_aead_xchacha20poly1305_ietf_decrypt","_crypto_aead_xchacha20poly1305_ietf_decrypt_detached","_crypto_aead_xchacha20poly1305_ietf_encrypt","_crypto_aead_xchacha20poly1305_ietf_encrypt_detached","_crypto_aead_xchacha20poly1305_ietf_keybytes","_crypto_aead_xchacha20poly1305_ietf_keygen","_crypto_aead_xchacha20poly1305_ietf_messagebytes_max","_crypto_aead_xchacha20poly1305_ietf_npubbytes","_crypto_aead_xchacha20poly1305_ietf_nsecbytes","_crypto_auth","_crypto_auth_bytes","_crypto_auth_keybytes","_crypto_auth_keygen","_crypto_auth_verify","_crypto_box_beforenm","_crypto_box_beforenmbytes","_crypto_box_detached","_crypto_box_detached_afternm","_crypto_box_easy","_crypto_box_easy_afternm","_crypto_box_keypair","_crypto_box_macbytes","_crypto_box_messagebytes_max","_crypto_box_noncebytes","_crypto_box_open_detached","_crypto_box_open_detached_afternm","_crypto_box_open_easy","_crypto_box_open_easy_afternm","_crypto_box_publickeybytes","_crypto_box_seal","_crypto_box_seal_open","_crypto_box_sealbytes","_crypto_box_secretkeybytes","_crypto_box_seed_keypair","_crypto_box_seedbytes","_crypto_generichash","_crypto_generichash_bytes","_crypto_generichash_bytes_max","_crypto_generichash_bytes_min","_crypto_generichash_final","_crypto_generichash_init","_crypto_generichash_keybytes","_crypto_generichash_keybytes_max","_crypto_generichash_keybytes_min","_crypto_generichash_keygen","_crypto_generichash_statebytes","_crypto_generichash_update","_crypto_hash","_crypto_hash_bytes","_crypto_kdf_bytes_max","_crypto_kdf_bytes_min","_crypto_kdf_contextbytes","_crypto_kdf_derive_from_key","_crypto_kdf_hkdf_sha256_bytes_max","_crypto_kdf_hkdf_sha256_bytes_min","_crypto_kdf_hkdf_sha256_expand","_crypto_kdf_hkdf_sha256_extract","_crypto_kdf_hkdf_sha256_extract_final","_crypto_kdf_hkdf_sha256_extract_init","_crypto_kdf_hkdf_sha256_extract_update","_crypto_kdf_hkdf_sha256_keybytes","_crypto_kdf_hkdf_sha256_keygen","_crypto_kdf_hkdf_sha256_statebytes","_crypto_kdf_hkdf_sha512_bytes_max","_crypto_kdf_hkdf_sha512_bytes_min","_crypto_kdf_hkdf_sha512_expand","_crypto_kdf_hkdf_sha512_extract","_crypto_kdf_hkdf_sha512_extract_final","_crypto_kdf_hkdf_sha512_extract_init","_crypto_kdf_hkdf_sha512_extract_update","_crypto_kdf_hkdf_sha512_keybytes","_crypto_kdf_hkdf_sha512_keygen","_crypto_kdf_hkdf_sha512_statebytes","_crypto_kdf_keybytes","_crypto_kdf_keygen","_crypto_kx_client_session_keys","_crypto_kx_keypair","_crypto_kx_publickeybytes","_crypto_kx_secretkeybytes","_crypto_kx_seed_keypair","_crypto_kx_seedbytes","_crypto_kx_server_session_keys","_crypto_kx_sessionkeybytes","_crypto_scalarmult","_crypto_scalarmult_base","_crypto_scalarmult_bytes","_crypto_scalarmult_scalarbytes","_crypto_secretbox_detached","_crypto_secretbox_easy","_crypto_secretbox_keybytes","_crypto_secretbox_keygen","_crypto_secretbox_macbytes","_crypto_secretbox_messagebytes_max","_crypto_secretbox_noncebytes","_crypto_secretbox_open_detached","_crypto_secretbox_open_easy","_crypto_secretstream_xchacha20poly1305_abytes","_crypto_secretstream_xchacha20poly1305_headerbytes","_crypto_secretstream_xchacha20poly1305_init_pull","_crypto_secretstream_xchacha20poly1305_init_push","_crypto_secretstream_xchacha20poly1305_keybytes","_crypto_secretstream_xchacha20poly1305_keygen","_crypto_secretstream_xchacha20poly1305_messagebytes_max","_crypto_secretstream_xchacha20poly1305_pull","_crypto_secretstream_xchacha20poly1305_push","_crypto_secretstream_xchacha20poly1305_rekey","_crypto_secretstream_xchacha20poly1305_statebytes","_crypto_secretstream_xchacha20poly1305_tag_final","_crypto_secretstream_xchacha20poly1305_tag_message","_crypto_secretstream_xchacha20poly1305_tag_push","_crypto_secretstream_xchacha20poly1305_tag_rekey","_crypto_shorthash","_crypto_shorthash_bytes","_crypto_shorthash_keybytes","_crypto_shorthash_keygen","_crypto_sign","_crypto_sign_bytes","_crypto_sign_detached","_crypto_sign_ed25519_pk_to_curve25519","_crypto_sign_ed25519_sk_to_curve25519","_crypto_sign_final_create","_crypto_sign_final_verify","_crypto_sign_init","_crypto_sign_keypair","_crypto_sign_messagebytes_max","_crypto_sign_open","_crypto_sign_publickeybytes","_crypto_sign_secretkeybytes","_crypto_sign_seed_keypair","_crypto_sign_seedbytes","_crypto_sign_statebytes","_crypto_sign_update","_crypto_sign_verify_detached","_randombytes","_randombytes_buf","_randombytes_buf_deterministic","_randombytes_close","_randombytes_random","_randombytes_seedbytes","_randombytes_stir","_randombytes_uniform","_sodium_base642bin","_sodium_base64_encoded_len","_sodium_bin2base64","_sodium_bin2hex","_sodium_hex2bin","_sodium_init","_sodium_library_minimal","_sodium_library_version_major","_sodium_library_version_minor","_sodium_pad","_sodium_unpad","_sodium_version_string"]'
|
|
5
|
+
export EXPORTED_FUNCTIONS_SUMO='["_malloc","_free","_crypto_aead_aegis128l_abytes","_crypto_aead_aegis128l_decrypt","_crypto_aead_aegis128l_decrypt_detached","_crypto_aead_aegis128l_encrypt","_crypto_aead_aegis128l_encrypt_detached","_crypto_aead_aegis128l_keybytes","_crypto_aead_aegis128l_keygen","_crypto_aead_aegis128l_messagebytes_max","_crypto_aead_aegis128l_npubbytes","_crypto_aead_aegis128l_nsecbytes","_crypto_aead_aegis256_abytes","_crypto_aead_aegis256_decrypt","_crypto_aead_aegis256_decrypt_detached","_crypto_aead_aegis256_encrypt","_crypto_aead_aegis256_encrypt_detached","_crypto_aead_aegis256_keybytes","_crypto_aead_aegis256_keygen","_crypto_aead_aegis256_messagebytes_max","_crypto_aead_aegis256_npubbytes","_crypto_aead_aegis256_nsecbytes","_crypto_aead_aes256gcm_is_available","_crypto_aead_chacha20poly1305_abytes","_crypto_aead_chacha20poly1305_decrypt","_crypto_aead_chacha20poly1305_decrypt_detached","_crypto_aead_chacha20poly1305_encrypt","_crypto_aead_chacha20poly1305_encrypt_detached","_crypto_aead_chacha20poly1305_ietf_abytes","_crypto_aead_chacha20poly1305_ietf_decrypt","_crypto_aead_chacha20poly1305_ietf_decrypt_detached","_crypto_aead_chacha20poly1305_ietf_encrypt","_crypto_aead_chacha20poly1305_ietf_encrypt_detached","_crypto_aead_chacha20poly1305_ietf_keybytes","_crypto_aead_chacha20poly1305_ietf_keygen","_crypto_aead_chacha20poly1305_ietf_messagebytes_max","_crypto_aead_chacha20poly1305_ietf_npubbytes","_crypto_aead_chacha20poly1305_ietf_nsecbytes","_crypto_aead_chacha20poly1305_keybytes","_crypto_aead_chacha20poly1305_keygen","_crypto_aead_chacha20poly1305_messagebytes_max","_crypto_aead_chacha20poly1305_npubbytes","_crypto_aead_chacha20poly1305_nsecbytes","_crypto_aead_xchacha20poly1305_ietf_abytes","_crypto_aead_xchacha20poly1305_ietf_decrypt","_crypto_aead_xchacha20poly1305_ietf_decrypt_detached","_crypto_aead_xchacha20poly1305_ietf_encrypt","_crypto_aead_xchacha20poly1305_ietf_encrypt_detached","_crypto_aead_xchacha20poly1305_ietf_keybytes","_crypto_aead_xchacha20poly1305_ietf_keygen","_crypto_aead_xchacha20poly1305_ietf_messagebytes_max","_crypto_aead_xchacha20poly1305_ietf_npubbytes","_crypto_aead_xchacha20poly1305_ietf_nsecbytes","_crypto_auth","_crypto_auth_bytes","_crypto_auth_hmacsha256","_crypto_auth_hmacsha256_bytes","_crypto_auth_hmacsha256_final","_crypto_auth_hmacsha256_init","_crypto_auth_hmacsha256_keybytes","_crypto_auth_hmacsha256_keygen","_crypto_auth_hmacsha256_statebytes","_crypto_auth_hmacsha256_update","_crypto_auth_hmacsha256_verify","_crypto_auth_hmacsha512","_crypto_auth_hmacsha512256","_crypto_auth_hmacsha512256_bytes","_crypto_auth_hmacsha512256_final","_crypto_auth_hmacsha512256_init","_crypto_auth_hmacsha512256_keybytes","_crypto_auth_hmacsha512256_keygen","_crypto_auth_hmacsha512256_statebytes","_crypto_auth_hmacsha512256_update","_crypto_auth_hmacsha512256_verify","_crypto_auth_hmacsha512_bytes","_crypto_auth_hmacsha512_final","_crypto_auth_hmacsha512_init","_crypto_auth_hmacsha512_keybytes","_crypto_auth_hmacsha512_keygen","_crypto_auth_hmacsha512_statebytes","_crypto_auth_hmacsha512_update","_crypto_auth_hmacsha512_verify","_crypto_auth_keybytes","_crypto_auth_keygen","_crypto_auth_primitive","_crypto_auth_verify","_crypto_box","_crypto_box_afternm","_crypto_box_beforenm","_crypto_box_beforenmbytes","_crypto_box_boxzerobytes","_crypto_box_curve25519xchacha20poly1305_beforenm","_crypto_box_curve25519xchacha20poly1305_beforenmbytes","_crypto_box_curve25519xchacha20poly1305_detached","_crypto_box_curve25519xchacha20poly1305_detached_afternm","_crypto_box_curve25519xchacha20poly1305_easy","_crypto_box_curve25519xchacha20poly1305_easy_afternm","_crypto_box_curve25519xchacha20poly1305_keypair","_crypto_box_curve25519xchacha20poly1305_macbytes","_crypto_box_curve25519xchacha20poly1305_messagebytes_max","_crypto_box_curve25519xchacha20poly1305_noncebytes","_crypto_box_curve25519xchacha20poly1305_open_detached","_crypto_box_curve25519xchacha20poly1305_open_detached_afternm","_crypto_box_curve25519xchacha20poly1305_open_easy","_crypto_box_curve25519xchacha20poly1305_open_easy_afternm","_crypto_box_curve25519xchacha20poly1305_publickeybytes","_crypto_box_curve25519xchacha20poly1305_seal","_crypto_box_curve25519xchacha20poly1305_seal_open","_crypto_box_curve25519xchacha20poly1305_sealbytes","_crypto_box_curve25519xchacha20poly1305_secretkeybytes","_crypto_box_curve25519xchacha20poly1305_seed_keypair","_crypto_box_curve25519xchacha20poly1305_seedbytes","_crypto_box_curve25519xsalsa20poly1305","_crypto_box_curve25519xsalsa20poly1305_afternm","_crypto_box_curve25519xsalsa20poly1305_beforenm","_crypto_box_curve25519xsalsa20poly1305_beforenmbytes","_crypto_box_curve25519xsalsa20poly1305_boxzerobytes","_crypto_box_curve25519xsalsa20poly1305_keypair","_crypto_box_curve25519xsalsa20poly1305_macbytes","_crypto_box_curve25519xsalsa20poly1305_messagebytes_max","_crypto_box_curve25519xsalsa20poly1305_noncebytes","_crypto_box_curve25519xsalsa20poly1305_open","_crypto_box_curve25519xsalsa20poly1305_open_afternm","_crypto_box_curve25519xsalsa20poly1305_publickeybytes","_crypto_box_curve25519xsalsa20poly1305_secretkeybytes","_crypto_box_curve25519xsalsa20poly1305_seed_keypair","_crypto_box_curve25519xsalsa20poly1305_seedbytes","_crypto_box_curve25519xsalsa20poly1305_zerobytes","_crypto_box_detached","_crypto_box_detached_afternm","_crypto_box_easy","_crypto_box_easy_afternm","_crypto_box_keypair","_crypto_box_macbytes","_crypto_box_messagebytes_max","_crypto_box_noncebytes","_crypto_box_open","_crypto_box_open_afternm","_crypto_box_open_detached","_crypto_box_open_detached_afternm","_crypto_box_open_easy","_crypto_box_open_easy_afternm","_crypto_box_primitive","_crypto_box_publickeybytes","_crypto_box_seal","_crypto_box_seal_open","_crypto_box_sealbytes","_crypto_box_secretkeybytes","_crypto_box_seed_keypair","_crypto_box_seedbytes","_crypto_box_zerobytes","_crypto_core_ed25519_add","_crypto_core_ed25519_bytes","_crypto_core_ed25519_from_uniform","_crypto_core_ed25519_hashbytes","_crypto_core_ed25519_is_valid_point","_crypto_core_ed25519_nonreducedscalarbytes","_crypto_core_ed25519_random","_crypto_core_ed25519_scalar_add","_crypto_core_ed25519_scalar_complement","_crypto_core_ed25519_scalar_invert","_crypto_core_ed25519_scalar_mul","_crypto_core_ed25519_scalar_negate","_crypto_core_ed25519_scalar_random","_crypto_core_ed25519_scalar_reduce","_crypto_core_ed25519_scalar_sub","_crypto_core_ed25519_scalarbytes","_crypto_core_ed25519_sub","_crypto_core_ed25519_uniformbytes","_crypto_core_hchacha20","_crypto_core_hchacha20_constbytes","_crypto_core_hchacha20_inputbytes","_crypto_core_hchacha20_keybytes","_crypto_core_hchacha20_outputbytes","_crypto_core_hsalsa20","_crypto_core_hsalsa20_constbytes","_crypto_core_hsalsa20_inputbytes","_crypto_core_hsalsa20_keybytes","_crypto_core_hsalsa20_outputbytes","_crypto_core_ristretto255_add","_crypto_core_ristretto255_bytes","_crypto_core_ristretto255_from_hash","_crypto_core_ristretto255_hashbytes","_crypto_core_ristretto255_is_valid_point","_crypto_core_ristretto255_nonreducedscalarbytes","_crypto_core_ristretto255_random","_crypto_core_ristretto255_scalar_add","_crypto_core_ristretto255_scalar_complement","_crypto_core_ristretto255_scalar_invert","_crypto_core_ristretto255_scalar_mul","_crypto_core_ristretto255_scalar_negate","_crypto_core_ristretto255_scalar_random","_crypto_core_ristretto255_scalar_reduce","_crypto_core_ristretto255_scalar_sub","_crypto_core_ristretto255_scalarbytes","_crypto_core_ristretto255_sub","_crypto_core_salsa20","_crypto_core_salsa2012","_crypto_core_salsa2012_constbytes","_crypto_core_salsa2012_inputbytes","_crypto_core_salsa2012_keybytes","_crypto_core_salsa2012_outputbytes","_crypto_core_salsa208","_crypto_core_salsa208_constbytes","_crypto_core_salsa208_inputbytes","_crypto_core_salsa208_keybytes","_crypto_core_salsa208_outputbytes","_crypto_core_salsa20_constbytes","_crypto_core_salsa20_inputbytes","_crypto_core_salsa20_keybytes","_crypto_core_salsa20_outputbytes","_crypto_generichash","_crypto_generichash_blake2b","_crypto_generichash_blake2b_bytes","_crypto_generichash_blake2b_bytes_max","_crypto_generichash_blake2b_bytes_min","_crypto_generichash_blake2b_final","_crypto_generichash_blake2b_init","_crypto_generichash_blake2b_init_salt_personal","_crypto_generichash_blake2b_keybytes","_crypto_generichash_blake2b_keybytes_max","_crypto_generichash_blake2b_keybytes_min","_crypto_generichash_blake2b_keygen","_crypto_generichash_blake2b_personalbytes","_crypto_generichash_blake2b_salt_personal","_crypto_generichash_blake2b_saltbytes","_crypto_generichash_blake2b_statebytes","_crypto_generichash_blake2b_update","_crypto_generichash_bytes","_crypto_generichash_bytes_max","_crypto_generichash_bytes_min","_crypto_generichash_final","_crypto_generichash_init","_crypto_generichash_keybytes","_crypto_generichash_keybytes_max","_crypto_generichash_keybytes_min","_crypto_generichash_keygen","_crypto_generichash_primitive","_crypto_generichash_statebytes","_crypto_generichash_update","_crypto_hash","_crypto_hash_bytes","_crypto_hash_primitive","_crypto_hash_sha256","_crypto_hash_sha256_bytes","_crypto_hash_sha256_final","_crypto_hash_sha256_init","_crypto_hash_sha256_statebytes","_crypto_hash_sha256_update","_crypto_hash_sha512","_crypto_hash_sha512_bytes","_crypto_hash_sha512_final","_crypto_hash_sha512_init","_crypto_hash_sha512_statebytes","_crypto_hash_sha512_update","_crypto_kdf_blake2b_bytes_max","_crypto_kdf_blake2b_bytes_min","_crypto_kdf_blake2b_contextbytes","_crypto_kdf_blake2b_derive_from_key","_crypto_kdf_blake2b_keybytes","_crypto_kdf_bytes_max","_crypto_kdf_bytes_min","_crypto_kdf_contextbytes","_crypto_kdf_derive_from_key","_crypto_kdf_hkdf_sha256_bytes_max","_crypto_kdf_hkdf_sha256_bytes_min","_crypto_kdf_hkdf_sha256_expand","_crypto_kdf_hkdf_sha256_extract","_crypto_kdf_hkdf_sha256_extract_final","_crypto_kdf_hkdf_sha256_extract_init","_crypto_kdf_hkdf_sha256_extract_update","_crypto_kdf_hkdf_sha256_keybytes","_crypto_kdf_hkdf_sha256_keygen","_crypto_kdf_hkdf_sha256_statebytes","_crypto_kdf_hkdf_sha512_bytes_max","_crypto_kdf_hkdf_sha512_bytes_min","_crypto_kdf_hkdf_sha512_expand","_crypto_kdf_hkdf_sha512_extract","_crypto_kdf_hkdf_sha512_extract_final","_crypto_kdf_hkdf_sha512_extract_init","_crypto_kdf_hkdf_sha512_extract_update","_crypto_kdf_hkdf_sha512_keybytes","_crypto_kdf_hkdf_sha512_keygen","_crypto_kdf_hkdf_sha512_statebytes","_crypto_kdf_keybytes","_crypto_kdf_keygen","_crypto_kdf_primitive","_crypto_kx_client_session_keys","_crypto_kx_keypair","_crypto_kx_primitive","_crypto_kx_publickeybytes","_crypto_kx_secretkeybytes","_crypto_kx_seed_keypair","_crypto_kx_seedbytes","_crypto_kx_server_session_keys","_crypto_kx_sessionkeybytes","_crypto_onetimeauth","_crypto_onetimeauth_bytes","_crypto_onetimeauth_final","_crypto_onetimeauth_init","_crypto_onetimeauth_keybytes","_crypto_onetimeauth_keygen","_crypto_onetimeauth_poly1305","_crypto_onetimeauth_poly1305_bytes","_crypto_onetimeauth_poly1305_final","_crypto_onetimeauth_poly1305_init","_crypto_onetimeauth_poly1305_keybytes","_crypto_onetimeauth_poly1305_keygen","_crypto_onetimeauth_poly1305_statebytes","_crypto_onetimeauth_poly1305_update","_crypto_onetimeauth_poly1305_verify","_crypto_onetimeauth_primitive","_crypto_onetimeauth_statebytes","_crypto_onetimeauth_update","_crypto_onetimeauth_verify","_crypto_pwhash","_crypto_pwhash_alg_argon2i13","_crypto_pwhash_alg_argon2id13","_crypto_pwhash_alg_default","_crypto_pwhash_argon2i","_crypto_pwhash_argon2i_alg_argon2i13","_crypto_pwhash_argon2i_bytes_max","_crypto_pwhash_argon2i_bytes_min","_crypto_pwhash_argon2i_memlimit_interactive","_crypto_pwhash_argon2i_memlimit_max","_crypto_pwhash_argon2i_memlimit_min","_crypto_pwhash_argon2i_memlimit_moderate","_crypto_pwhash_argon2i_memlimit_sensitive","_crypto_pwhash_argon2i_opslimit_interactive","_crypto_pwhash_argon2i_opslimit_max","_crypto_pwhash_argon2i_opslimit_min","_crypto_pwhash_argon2i_opslimit_moderate","_crypto_pwhash_argon2i_opslimit_sensitive","_crypto_pwhash_argon2i_passwd_max","_crypto_pwhash_argon2i_passwd_min","_crypto_pwhash_argon2i_saltbytes","_crypto_pwhash_argon2i_str","_crypto_pwhash_argon2i_str_needs_rehash","_crypto_pwhash_argon2i_str_verify","_crypto_pwhash_argon2i_strbytes","_crypto_pwhash_argon2i_strprefix","_crypto_pwhash_argon2id","_crypto_pwhash_argon2id_alg_argon2id13","_crypto_pwhash_argon2id_bytes_max","_crypto_pwhash_argon2id_bytes_min","_crypto_pwhash_argon2id_memlimit_interactive","_crypto_pwhash_argon2id_memlimit_max","_crypto_pwhash_argon2id_memlimit_min","_crypto_pwhash_argon2id_memlimit_moderate","_crypto_pwhash_argon2id_memlimit_sensitive","_crypto_pwhash_argon2id_opslimit_interactive","_crypto_pwhash_argon2id_opslimit_max","_crypto_pwhash_argon2id_opslimit_min","_crypto_pwhash_argon2id_opslimit_moderate","_crypto_pwhash_argon2id_opslimit_sensitive","_crypto_pwhash_argon2id_passwd_max","_crypto_pwhash_argon2id_passwd_min","_crypto_pwhash_argon2id_saltbytes","_crypto_pwhash_argon2id_str","_crypto_pwhash_argon2id_str_needs_rehash","_crypto_pwhash_argon2id_str_verify","_crypto_pwhash_argon2id_strbytes","_crypto_pwhash_argon2id_strprefix","_crypto_pwhash_bytes_max","_crypto_pwhash_bytes_min","_crypto_pwhash_memlimit_interactive","_crypto_pwhash_memlimit_max","_crypto_pwhash_memlimit_min","_crypto_pwhash_memlimit_moderate","_crypto_pwhash_memlimit_sensitive","_crypto_pwhash_opslimit_interactive","_crypto_pwhash_opslimit_max","_crypto_pwhash_opslimit_min","_crypto_pwhash_opslimit_moderate","_crypto_pwhash_opslimit_sensitive","_crypto_pwhash_passwd_max","_crypto_pwhash_passwd_min","_crypto_pwhash_primitive","_crypto_pwhash_saltbytes","_crypto_pwhash_scryptsalsa208sha256","_crypto_pwhash_scryptsalsa208sha256_bytes_max","_crypto_pwhash_scryptsalsa208sha256_bytes_min","_crypto_pwhash_scryptsalsa208sha256_ll","_crypto_pwhash_scryptsalsa208sha256_memlimit_interactive","_crypto_pwhash_scryptsalsa208sha256_memlimit_max","_crypto_pwhash_scryptsalsa208sha256_memlimit_min","_crypto_pwhash_scryptsalsa208sha256_memlimit_sensitive","_crypto_pwhash_scryptsalsa208sha256_opslimit_interactive","_crypto_pwhash_scryptsalsa208sha256_opslimit_max","_crypto_pwhash_scryptsalsa208sha256_opslimit_min","_crypto_pwhash_scryptsalsa208sha256_opslimit_sensitive","_crypto_pwhash_scryptsalsa208sha256_passwd_max","_crypto_pwhash_scryptsalsa208sha256_passwd_min","_crypto_pwhash_scryptsalsa208sha256_saltbytes","_crypto_pwhash_scryptsalsa208sha256_str","_crypto_pwhash_scryptsalsa208sha256_str_needs_rehash","_crypto_pwhash_scryptsalsa208sha256_str_verify","_crypto_pwhash_scryptsalsa208sha256_strbytes","_crypto_pwhash_scryptsalsa208sha256_strprefix","_crypto_pwhash_str","_crypto_pwhash_str_alg","_crypto_pwhash_str_needs_rehash","_crypto_pwhash_str_verify","_crypto_pwhash_strbytes","_crypto_pwhash_strprefix","_crypto_scalarmult","_crypto_scalarmult_base","_crypto_scalarmult_bytes","_crypto_scalarmult_curve25519","_crypto_scalarmult_curve25519_base","_crypto_scalarmult_curve25519_bytes","_crypto_scalarmult_curve25519_scalarbytes","_crypto_scalarmult_ed25519","_crypto_scalarmult_ed25519_base","_crypto_scalarmult_ed25519_base_noclamp","_crypto_scalarmult_ed25519_bytes","_crypto_scalarmult_ed25519_noclamp","_crypto_scalarmult_ed25519_scalarbytes","_crypto_scalarmult_primitive","_crypto_scalarmult_ristretto255","_crypto_scalarmult_ristretto255_base","_crypto_scalarmult_ristretto255_bytes","_crypto_scalarmult_ristretto255_scalarbytes","_crypto_scalarmult_scalarbytes","_crypto_secretbox","_crypto_secretbox_boxzerobytes","_crypto_secretbox_detached","_crypto_secretbox_easy","_crypto_secretbox_keybytes","_crypto_secretbox_keygen","_crypto_secretbox_macbytes","_crypto_secretbox_messagebytes_max","_crypto_secretbox_noncebytes","_crypto_secretbox_open","_crypto_secretbox_open_detached","_crypto_secretbox_open_easy","_crypto_secretbox_primitive","_crypto_secretbox_xchacha20poly1305_detached","_crypto_secretbox_xchacha20poly1305_easy","_crypto_secretbox_xchacha20poly1305_keybytes","_crypto_secretbox_xchacha20poly1305_macbytes","_crypto_secretbox_xchacha20poly1305_messagebytes_max","_crypto_secretbox_xchacha20poly1305_noncebytes","_crypto_secretbox_xchacha20poly1305_open_detached","_crypto_secretbox_xchacha20poly1305_open_easy","_crypto_secretbox_xsalsa20poly1305","_crypto_secretbox_xsalsa20poly1305_boxzerobytes","_crypto_secretbox_xsalsa20poly1305_keybytes","_crypto_secretbox_xsalsa20poly1305_keygen","_crypto_secretbox_xsalsa20poly1305_macbytes","_crypto_secretbox_xsalsa20poly1305_messagebytes_max","_crypto_secretbox_xsalsa20poly1305_noncebytes","_crypto_secretbox_xsalsa20poly1305_open","_crypto_secretbox_xsalsa20poly1305_zerobytes","_crypto_secretbox_zerobytes","_crypto_secretstream_xchacha20poly1305_abytes","_crypto_secretstream_xchacha20poly1305_headerbytes","_crypto_secretstream_xchacha20poly1305_init_pull","_crypto_secretstream_xchacha20poly1305_init_push","_crypto_secretstream_xchacha20poly1305_keybytes","_crypto_secretstream_xchacha20poly1305_keygen","_crypto_secretstream_xchacha20poly1305_messagebytes_max","_crypto_secretstream_xchacha20poly1305_pull","_crypto_secretstream_xchacha20poly1305_push","_crypto_secretstream_xchacha20poly1305_rekey","_crypto_secretstream_xchacha20poly1305_statebytes","_crypto_secretstream_xchacha20poly1305_tag_final","_crypto_secretstream_xchacha20poly1305_tag_message","_crypto_secretstream_xchacha20poly1305_tag_push","_crypto_secretstream_xchacha20poly1305_tag_rekey","_crypto_shorthash","_crypto_shorthash_bytes","_crypto_shorthash_keybytes","_crypto_shorthash_keygen","_crypto_shorthash_primitive","_crypto_shorthash_siphash24","_crypto_shorthash_siphash24_bytes","_crypto_shorthash_siphash24_keybytes","_crypto_shorthash_siphashx24","_crypto_shorthash_siphashx24_bytes","_crypto_shorthash_siphashx24_keybytes","_crypto_sign","_crypto_sign_bytes","_crypto_sign_detached","_crypto_sign_ed25519","_crypto_sign_ed25519_bytes","_crypto_sign_ed25519_detached","_crypto_sign_ed25519_keypair","_crypto_sign_ed25519_messagebytes_max","_crypto_sign_ed25519_open","_crypto_sign_ed25519_pk_to_curve25519","_crypto_sign_ed25519_publickeybytes","_crypto_sign_ed25519_secretkeybytes","_crypto_sign_ed25519_seed_keypair","_crypto_sign_ed25519_seedbytes","_crypto_sign_ed25519_sk_to_curve25519","_crypto_sign_ed25519_sk_to_pk","_crypto_sign_ed25519_sk_to_seed","_crypto_sign_ed25519_verify_detached","_crypto_sign_ed25519ph_final_create","_crypto_sign_ed25519ph_final_verify","_crypto_sign_ed25519ph_init","_crypto_sign_ed25519ph_statebytes","_crypto_sign_ed25519ph_update","_crypto_sign_final_create","_crypto_sign_final_verify","_crypto_sign_init","_crypto_sign_keypair","_crypto_sign_messagebytes_max","_crypto_sign_open","_crypto_sign_primitive","_crypto_sign_publickeybytes","_crypto_sign_secretkeybytes","_crypto_sign_seed_keypair","_crypto_sign_seedbytes","_crypto_sign_statebytes","_crypto_sign_update","_crypto_sign_verify_detached","_crypto_stream","_crypto_stream_chacha20","_crypto_stream_chacha20_ietf","_crypto_stream_chacha20_ietf_keybytes","_crypto_stream_chacha20_ietf_keygen","_crypto_stream_chacha20_ietf_messagebytes_max","_crypto_stream_chacha20_ietf_noncebytes","_crypto_stream_chacha20_ietf_xor","_crypto_stream_chacha20_ietf_xor_ic","_crypto_stream_chacha20_keybytes","_crypto_stream_chacha20_keygen","_crypto_stream_chacha20_messagebytes_max","_crypto_stream_chacha20_noncebytes","_crypto_stream_chacha20_xor","_crypto_stream_chacha20_xor_ic","_crypto_stream_keybytes","_crypto_stream_keygen","_crypto_stream_messagebytes_max","_crypto_stream_noncebytes","_crypto_stream_primitive","_crypto_stream_salsa20","_crypto_stream_salsa2012","_crypto_stream_salsa2012_keybytes","_crypto_stream_salsa2012_keygen","_crypto_stream_salsa2012_messagebytes_max","_crypto_stream_salsa2012_noncebytes","_crypto_stream_salsa2012_xor","_crypto_stream_salsa208","_crypto_stream_salsa208_keybytes","_crypto_stream_salsa208_keygen","_crypto_stream_salsa208_messagebytes_max","_crypto_stream_salsa208_noncebytes","_crypto_stream_salsa208_xor","_crypto_stream_salsa20_keybytes","_crypto_stream_salsa20_keygen","_crypto_stream_salsa20_messagebytes_max","_crypto_stream_salsa20_noncebytes","_crypto_stream_salsa20_xor","_crypto_stream_salsa20_xor_ic","_crypto_stream_xchacha20","_crypto_stream_xchacha20_keybytes","_crypto_stream_xchacha20_keygen","_crypto_stream_xchacha20_messagebytes_max","_crypto_stream_xchacha20_noncebytes","_crypto_stream_xchacha20_xor","_crypto_stream_xchacha20_xor_ic","_crypto_stream_xor","_crypto_stream_xsalsa20","_crypto_stream_xsalsa20_keybytes","_crypto_stream_xsalsa20_keygen","_crypto_stream_xsalsa20_messagebytes_max","_crypto_stream_xsalsa20_noncebytes","_crypto_stream_xsalsa20_xor","_crypto_stream_xsalsa20_xor_ic","_crypto_verify_16","_crypto_verify_16_bytes","_crypto_verify_32","_crypto_verify_32_bytes","_crypto_verify_64","_crypto_verify_64_bytes","_randombytes","_randombytes_buf","_randombytes_buf_deterministic","_randombytes_close","_randombytes_implementation_name","_randombytes_random","_randombytes_seedbytes","_randombytes_stir","_randombytes_uniform","_sodium_base642bin","_sodium_base64_encoded_len","_sodium_bin2base64","_sodium_bin2hex","_sodium_hex2bin","_sodium_init","_sodium_library_minimal","_sodium_library_version_major","_sodium_library_version_minor","_sodium_pad","_sodium_unpad","_sodium_version_string"]'
|
|
6
|
+
export EXPORTED_RUNTIME_METHODS='["UTF8ToString","getValue","setValue"]'
|
|
7
|
+
export JS_RESERVED_MEMORY_STANDARD=16MB
|
|
8
|
+
export JS_RESERVED_MEMORY_SUMO=48MB
|
|
9
|
+
export JS_RESERVED_MEMORY_TESTS=16MB
|
|
10
|
+
export WASM_INITIAL_MEMORY=4MB
|
|
11
|
+
export LDFLAGS="-s RESERVED_FUNCTION_POINTERS=8"
|
|
12
|
+
export LDFLAGS="${LDFLAGS} -s ALLOW_MEMORY_GROWTH=1"
|
|
13
|
+
export LDFLAGS="${LDFLAGS} -s SINGLE_FILE=1"
|
|
14
|
+
export LDFLAGS="${LDFLAGS} -s ASSERTIONS=0"
|
|
15
|
+
export LDFLAGS="${LDFLAGS} -s AGGRESSIVE_VARIABLE_ELIMINATION=1 -s ALIASING_FUNCTION_POINTERS=1"
|
|
16
|
+
export LDFLAGS="${LDFLAGS} -s DISABLE_EXCEPTION_CATCHING=1"
|
|
17
|
+
export LDFLAGS="${LDFLAGS} -s ELIMINATE_DUPLICATE_FUNCTIONS=1"
|
|
18
|
+
export LDFLAGS="${LDFLAGS} -s NODEJS_CATCH_EXIT=0"
|
|
19
|
+
export LDFLAGS="${LDFLAGS} -s NODEJS_CATCH_REJECTION=0"
|
|
20
|
+
|
|
21
|
+
echo
|
|
22
|
+
if [ "$1" = "--standard" ]; then
|
|
23
|
+
export EXPORTED_FUNCTIONS="$EXPORTED_FUNCTIONS_STANDARD"
|
|
24
|
+
export LDFLAGS="${LDFLAGS} ${LDFLAGS_DIST}"
|
|
25
|
+
export LDFLAGS_JS="-s TOTAL_MEMORY=${JS_RESERVED_MEMORY_STANDARD}"
|
|
26
|
+
export PREFIX="$(pwd)/libsodium-js"
|
|
27
|
+
export DONE_FILE="$(pwd)/js.done"
|
|
28
|
+
export CONFIG_EXTRA="--enable-minimal"
|
|
29
|
+
export DIST='yes'
|
|
30
|
+
echo "Building a standard distribution in [${PREFIX}]"
|
|
31
|
+
elif [ "$1" = "--sumo" ]; then
|
|
32
|
+
export EXPORTED_FUNCTIONS="$EXPORTED_FUNCTIONS_SUMO"
|
|
33
|
+
export LDFLAGS="${LDFLAGS} ${LDFLAGS_DIST}"
|
|
34
|
+
export LDFLAGS_JS="-s TOTAL_MEMORY=${JS_RESERVED_MEMORY_SUMO}"
|
|
35
|
+
export PREFIX="$(pwd)/libsodium-js-sumo"
|
|
36
|
+
export DONE_FILE="$(pwd)/js-sumo.done"
|
|
37
|
+
export DIST='yes'
|
|
38
|
+
echo "Building a sumo distribution in [${PREFIX}]"
|
|
39
|
+
elif [ "$1" = "--browser-tests" ]; then
|
|
40
|
+
export EXPORTED_FUNCTIONS="$EXPORTED_FUNCTIONS_SUMO"
|
|
41
|
+
export CPPFLAGS="${CPPFLAGS} -s FORCE_FILESYSTEM=1"
|
|
42
|
+
export LDFLAGS="${LDFLAGS}"
|
|
43
|
+
export LDFLAGS_JS="-s TOTAL_MEMORY=${JS_RESERVED_MEMORY_TESTS}"
|
|
44
|
+
export PREFIX="$(pwd)/libsodium-js-tests"
|
|
45
|
+
export DONE_FILE="$(pwd)/js-tests-browser.done"
|
|
46
|
+
export BROWSER_TESTS='yes'
|
|
47
|
+
export DIST='no'
|
|
48
|
+
echo "Building tests for web browsers in [${PREFIX}]"
|
|
49
|
+
elif [ "$1" = "--tests" ]; then
|
|
50
|
+
echo "Building for testing"
|
|
51
|
+
export EXPORTED_FUNCTIONS="$EXPORTED_FUNCTIONS_SUMO"
|
|
52
|
+
export CPPFLAGS="${CPPFLAGS} -s FORCE_FILESYSTEM=1 -DBENCHMARKS -DITERATIONS=10"
|
|
53
|
+
export LDFLAGS="${LDFLAGS}"
|
|
54
|
+
export LDFLAGS_JS="-s TOTAL_MEMORY=${JS_RESERVED_MEMORY_TESTS}"
|
|
55
|
+
export PREFIX="$(pwd)/libsodium-js-tests"
|
|
56
|
+
export DONE_FILE="$(pwd)/js-tests.done"
|
|
57
|
+
export DIST='no'
|
|
58
|
+
echo "Building for testing in [${PREFIX}]"
|
|
59
|
+
else
|
|
60
|
+
echo "Usage: $0 <build_type>"
|
|
61
|
+
echo "<build_type> := --standard | --sumo | --browser-tests | --tests"
|
|
62
|
+
echo
|
|
63
|
+
exit 1
|
|
64
|
+
fi
|
|
65
|
+
export JS_EXPORTS_FLAGS="-s EXPORTED_FUNCTIONS=${EXPORTED_FUNCTIONS} -s EXPORTED_RUNTIME_METHODS=${EXPORTED_RUNTIME_METHODS}"
|
|
66
|
+
|
|
67
|
+
rm -f "$DONE_FILE"
|
|
68
|
+
|
|
69
|
+
echo
|
|
70
|
+
|
|
71
|
+
emconfigure ./configure $CONFIG_EXTRA --disable-shared --prefix="$PREFIX" \
|
|
72
|
+
--without-pthreads \
|
|
73
|
+
--disable-ssp --disable-asm --disable-pie &&
|
|
74
|
+
emmake make clean
|
|
75
|
+
[ $? = 0 ] || exit 1
|
|
76
|
+
|
|
77
|
+
if [ "$DIST" = yes ]; then
|
|
78
|
+
emccLibsodium() {
|
|
79
|
+
outFile="${1}"
|
|
80
|
+
shift
|
|
81
|
+
emcc "$CFLAGS" --llvm-lto 1 $CPPFLAGS $LDFLAGS $JS_EXPORTS_FLAGS "${@}" \
|
|
82
|
+
"${PREFIX}/lib/libsodium.a" -o "${outFile}" || exit 1
|
|
83
|
+
}
|
|
84
|
+
emmake make $MAKE_FLAGS install || exit 1
|
|
85
|
+
emccLibsodium "${PREFIX}/lib/libsodium.asm.tmp.js" -Oz -s WASM=0 $LDFLAGS_JS
|
|
86
|
+
emccLibsodium "${PREFIX}/lib/libsodium.wasm.tmp.js" -O3 -s WASM=1 -s EVAL_CTORS=1 -s INITIAL_MEMORY=${WASM_INITIAL_MEMORY}
|
|
87
|
+
|
|
88
|
+
cat >"${PREFIX}/lib/libsodium.js" <<-EOM
|
|
89
|
+
var Module;
|
|
90
|
+
if (typeof Module === 'undefined') {
|
|
91
|
+
Module = {};
|
|
92
|
+
}
|
|
93
|
+
var root = Module;
|
|
94
|
+
if (typeof root['sodium'] !== 'object') {
|
|
95
|
+
if (typeof global === 'object') {
|
|
96
|
+
root = global;
|
|
97
|
+
} else if (typeof window === 'object') {
|
|
98
|
+
root = window;
|
|
99
|
+
}
|
|
100
|
+
}
|
|
101
|
+
var _Module = Module;
|
|
102
|
+
Module.ready = new Promise(function(resolve, reject) {
|
|
103
|
+
var Module = _Module;
|
|
104
|
+
Module.onAbort = reject;
|
|
105
|
+
Module.print = function(what) {
|
|
106
|
+
typeof(console) !== 'undefined' && console.log(what);
|
|
107
|
+
}
|
|
108
|
+
Module.printErr = function(what) {
|
|
109
|
+
typeof(console) !== 'undefined' && console.warn(what);
|
|
110
|
+
}
|
|
111
|
+
Module.onRuntimeInitialized = function() {
|
|
112
|
+
try {
|
|
113
|
+
/* Test arbitrary wasm function */
|
|
114
|
+
Module._crypto_secretbox_keybytes();
|
|
115
|
+
resolve();
|
|
116
|
+
} catch (err) {
|
|
117
|
+
reject(err);
|
|
118
|
+
}
|
|
119
|
+
};
|
|
120
|
+
Module.useBackupModule = function() {
|
|
121
|
+
return new Promise(function(resolve, reject) {
|
|
122
|
+
var Module = {};
|
|
123
|
+
Module.onAbort = reject;
|
|
124
|
+
|
|
125
|
+
Module.onRuntimeInitialized = function() {
|
|
126
|
+
Object.keys(_Module).forEach(function(k) {
|
|
127
|
+
if (k !== 'getRandomValue') {
|
|
128
|
+
delete _Module[k];
|
|
129
|
+
}
|
|
130
|
+
});
|
|
131
|
+
Object.keys(Module).forEach(function(k) {
|
|
132
|
+
_Module[k] = Module[k];
|
|
133
|
+
});
|
|
134
|
+
resolve();
|
|
135
|
+
};
|
|
136
|
+
|
|
137
|
+
$(sed "s|use asm||g" "${PREFIX}/lib/libsodium.asm.tmp.js")
|
|
138
|
+
});
|
|
139
|
+
};
|
|
140
|
+
$(cat "${PREFIX}/lib/libsodium.wasm.tmp.js")
|
|
141
|
+
}).catch(function() {
|
|
142
|
+
return _Module.useBackupModule();
|
|
143
|
+
});
|
|
144
|
+
EOM
|
|
145
|
+
|
|
146
|
+
rm "${PREFIX}/lib/libsodium.asm.tmp.js" "${PREFIX}/lib/libsodium.wasm.tmp.js"
|
|
147
|
+
touch -r "${PREFIX}/lib/libsodium.js" "$DONE_FILE"
|
|
148
|
+
ls -l "${PREFIX}/lib/libsodium.js"
|
|
149
|
+
exit 0
|
|
150
|
+
fi
|
|
151
|
+
|
|
152
|
+
if test "$NODE" = ""; then
|
|
153
|
+
for candidate in bun nodejs node /usr/local/bin/bun /usr/local/bin/nodejs /usr/local/bin/node; do
|
|
154
|
+
case $($candidate --version 2>&1) in #(
|
|
155
|
+
v*)
|
|
156
|
+
NODE=$candidate
|
|
157
|
+
break
|
|
158
|
+
;;
|
|
159
|
+
esac
|
|
160
|
+
done
|
|
161
|
+
fi
|
|
162
|
+
|
|
163
|
+
if [ "x$BROWSER_TESTS" != "x" ]; then
|
|
164
|
+
echo 'Compiling the test suite for web browsers...' &&
|
|
165
|
+
emmake make $MAKE_FLAGS CPPFLAGS="$CPPFLAGS -DBROWSER_TESTS=1" check >/dev/null 2>&1
|
|
166
|
+
else
|
|
167
|
+
if test "$NODE" = ""; then
|
|
168
|
+
echo 'node.js not found - test suite skipped' >&2
|
|
169
|
+
exit 1
|
|
170
|
+
fi
|
|
171
|
+
echo "Using [${NODE}] as a Javascript runtime"
|
|
172
|
+
echo 'Compiling the test suite...' &&
|
|
173
|
+
emmake make $MAKE_FLAGS check >/dev/null 2>&1
|
|
174
|
+
fi
|
|
175
|
+
|
|
176
|
+
if [ "x$BROWSER_TESTS" != "x" ]; then
|
|
177
|
+
echo 'Creating the test suite for web browsers'
|
|
178
|
+
(
|
|
179
|
+
cd test/default &&
|
|
180
|
+
mkdir -p browser &&
|
|
181
|
+
rm -f browser/tests.txt &&
|
|
182
|
+
for file in *.js; do
|
|
183
|
+
grep -Fv "#! /usr/bin/env ${NODE}" "$file" >"browser/${file}"
|
|
184
|
+
tname=$(echo "$file" | sed 's/.js$//')
|
|
185
|
+
cp -f "${tname}.exp" "browser/${tname}.exp"
|
|
186
|
+
sed "s/{{tname}}/${tname}/" index.html.tpl >"browser/${tname}.html"
|
|
187
|
+
echo "${tname}.html" >>"browser/tests.txt"
|
|
188
|
+
done
|
|
189
|
+
touch "$DONE_FILE"
|
|
190
|
+
)
|
|
191
|
+
else
|
|
192
|
+
echo 'Running the test suite'
|
|
193
|
+
(
|
|
194
|
+
cd test/default &&
|
|
195
|
+
for file in *.js; do
|
|
196
|
+
echo "#! /usr/bin/env ${NODE}" >"${file}.tmp"
|
|
197
|
+
grep -Fv "#! /usr/bin/env ${NODE}" "$file" >>"${file}.tmp"
|
|
198
|
+
chmod +x "${file}.tmp"
|
|
199
|
+
mv -f "${file}.tmp" "$file"
|
|
200
|
+
done
|
|
201
|
+
)
|
|
202
|
+
make $MAKE_FLAGS check || exit 1
|
|
203
|
+
touch "$DONE_FILE"
|
|
204
|
+
fi
|
|
205
|
+
|
|
206
|
+
echo 'Done.'
|
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
#! /bin/sh
|
|
2
|
+
|
|
3
|
+
set -e
|
|
4
|
+
|
|
5
|
+
LIBSODIUM=${LIBSODIUM:-/tmp/sodium/lib/libsodium.26.dylib}
|
|
6
|
+
|
|
7
|
+
symbols() {
|
|
8
|
+
{
|
|
9
|
+
SUMO="$1"
|
|
10
|
+
while read symbol standard sumo; do
|
|
11
|
+
found="$standard"
|
|
12
|
+
if [ "x$SUMO" = "xsumo" ]; then
|
|
13
|
+
found="$sumo"
|
|
14
|
+
fi
|
|
15
|
+
if [ "$found" = "1" ]; then
|
|
16
|
+
eval "defined_${symbol}=yes"
|
|
17
|
+
else
|
|
18
|
+
eval "defined_${symbol}=no"
|
|
19
|
+
fi
|
|
20
|
+
done <emscripten-symbols.def
|
|
21
|
+
|
|
22
|
+
/usr/bin/nm "$LIBSODIUM" |
|
|
23
|
+
fgrep ' T _' |
|
|
24
|
+
cut -d' ' -f3 | {
|
|
25
|
+
while read symbol; do
|
|
26
|
+
eval "found=\$defined_${symbol}"
|
|
27
|
+
if [ "$found" = "yes" ]; then
|
|
28
|
+
echo "$symbol"
|
|
29
|
+
elif [ "$found" != "no" ]; then
|
|
30
|
+
echo >&2
|
|
31
|
+
echo "*** [$symbol] was not expected ***" >&2
|
|
32
|
+
echo >&2
|
|
33
|
+
exit 1
|
|
34
|
+
fi
|
|
35
|
+
done
|
|
36
|
+
}
|
|
37
|
+
} |
|
|
38
|
+
sort |
|
|
39
|
+
{
|
|
40
|
+
out='"_malloc","_free"'
|
|
41
|
+
while read symbol; do
|
|
42
|
+
if [ ! -z "$out" ]; then
|
|
43
|
+
out="${out},"
|
|
44
|
+
fi
|
|
45
|
+
out="${out}\"${symbol}\""
|
|
46
|
+
done
|
|
47
|
+
echo "[${out}]"
|
|
48
|
+
}
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
out=$(symbols standard)
|
|
52
|
+
sed s/EXPORTED_FUNCTIONS_STANDARD=\'.*\'/EXPORTED_FUNCTIONS_STANDARD=\'${out}\'/ <emscripten.sh >emscripten.sh.tmp &&
|
|
53
|
+
mv -f emscripten.sh.tmp emscripten.sh
|
|
54
|
+
|
|
55
|
+
out=$(symbols sumo)
|
|
56
|
+
sed s/EXPORTED_FUNCTIONS_SUMO=\'.*\'/EXPORTED_FUNCTIONS_SUMO=\'${out}\'/ <emscripten.sh >emscripten.sh.tmp &&
|
|
57
|
+
mv -f emscripten.sh.tmp emscripten.sh
|
|
58
|
+
|
|
59
|
+
chmod +x emscripten.sh
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
#! /bin/sh
|
|
2
|
+
|
|
3
|
+
export PREFIX="$(pwd)/libsodium-osx"
|
|
4
|
+
export MACOS_VERSION_MIN=${MACOS_VERSION_MIN-"10.10"}
|
|
5
|
+
|
|
6
|
+
if [ -z "$LIBSODIUM_FULL_BUILD" ]; then
|
|
7
|
+
export LIBSODIUM_ENABLE_MINIMAL_FLAG="--enable-minimal"
|
|
8
|
+
else
|
|
9
|
+
export LIBSODIUM_ENABLE_MINIMAL_FLAG=""
|
|
10
|
+
fi
|
|
11
|
+
|
|
12
|
+
NPROCESSORS=$(getconf NPROCESSORS_ONLN 2>/dev/null || getconf _NPROCESSORS_ONLN 2>/dev/null)
|
|
13
|
+
PROCESSORS=${NPROCESSORS:-3}
|
|
14
|
+
|
|
15
|
+
mkdir -p $PREFIX || exit 1
|
|
16
|
+
|
|
17
|
+
export CFLAGS="-mmacosx-version-min=${MACOS_VERSION_MIN} -O3"
|
|
18
|
+
export LDFLAGS="-mmacosx-version-min=${MACOS_VERSION_MIN}"
|
|
19
|
+
|
|
20
|
+
make distclean >/dev/null
|
|
21
|
+
./configure ${LIBSODIUM_ENABLE_MINIMAL_FLAG} \
|
|
22
|
+
--prefix="$PREFIX" || exit 1
|
|
23
|
+
make -j${PROCESSORS} check && make -j${PROCESSORS} install || exit 1
|
|
24
|
+
|
|
25
|
+
# Cleanup
|
|
26
|
+
make distclean >/dev/null
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
#! /bin/sh
|
|
2
|
+
|
|
3
|
+
export CFLAGS="-O3 -fomit-frame-pointer -m32 -march=pentium3 -mtune=westmere"
|
|
4
|
+
export PREFIX="$(pwd)/libsodium-win32"
|
|
5
|
+
|
|
6
|
+
if (i686-w64-mingw32-gcc --version >/dev/null 2>&1); then
|
|
7
|
+
echo MinGW found
|
|
8
|
+
else
|
|
9
|
+
echo Please install mingw-w64-i686-gcc >&2
|
|
10
|
+
exit
|
|
11
|
+
fi
|
|
12
|
+
|
|
13
|
+
./configure --prefix="$PREFIX" --exec-prefix="$PREFIX" \
|
|
14
|
+
--host=i686-w64-mingw32 &&
|
|
15
|
+
make clean &&
|
|
16
|
+
make &&
|
|
17
|
+
make check &&
|
|
18
|
+
make install
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
#! /bin/sh
|
|
2
|
+
|
|
3
|
+
export CFLAGS="-O3 -fomit-frame-pointer -m64 -mtune=westmere"
|
|
4
|
+
export PREFIX="$(pwd)/libsodium-win64"
|
|
5
|
+
|
|
6
|
+
if (x86_64-w64-mingw32-gcc --version >/dev/null 2>&1); then
|
|
7
|
+
echo MinGW found
|
|
8
|
+
else
|
|
9
|
+
echo Please install mingw-w64-x86_64-gcc >&2
|
|
10
|
+
exit
|
|
11
|
+
fi
|
|
12
|
+
|
|
13
|
+
./configure --prefix="$PREFIX" --exec-prefix="$PREFIX" \
|
|
14
|
+
--host=x86_64-w64-mingw32 &&
|
|
15
|
+
make clean &&
|
|
16
|
+
make &&
|
|
17
|
+
make check &&
|
|
18
|
+
make install
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
#! /bin/sh
|
|
2
|
+
|
|
3
|
+
export PATH="/opt/zig/bin:/opt/zig:/opt/homebrew/bin:$PATH"
|
|
4
|
+
|
|
5
|
+
export PREFIX="$(pwd)/libsodium-wasm32-wasi"
|
|
6
|
+
|
|
7
|
+
mkdir -p $PREFIX || exit 1
|
|
8
|
+
|
|
9
|
+
export CC="zig cc"
|
|
10
|
+
export CFLAGS="--target=wasm32-wasi -O3"
|
|
11
|
+
export LDFLAGS="-s"
|
|
12
|
+
export AR="zig ar"
|
|
13
|
+
export RANLIB="zig ranlib"
|
|
14
|
+
|
|
15
|
+
make distclean >/dev/null
|
|
16
|
+
|
|
17
|
+
if [ "x$1" = "x--bench" ]; then
|
|
18
|
+
export BENCHMARKS=1
|
|
19
|
+
export CPPFLAGS="-DBENCHMARKS -DITERATIONS=200"
|
|
20
|
+
else
|
|
21
|
+
export CPPFLAGS="-DED25519_NONDETERMINISTIC=1"
|
|
22
|
+
fi
|
|
23
|
+
|
|
24
|
+
if [ -n "$LIBSODIUM_MINIMAL_BUILD" ]; then
|
|
25
|
+
export LIBSODIUM_ENABLE_MINIMAL_FLAG="--enable-minimal"
|
|
26
|
+
else
|
|
27
|
+
export LIBSODIUM_ENABLE_MINIMAL_FLAG=""
|
|
28
|
+
fi
|
|
29
|
+
|
|
30
|
+
if ! ./configure ${LIBSODIUM_ENABLE_MINIMAL_FLAG} \
|
|
31
|
+
--prefix="$PREFIX" \
|
|
32
|
+
--host=wasm32-wasi \
|
|
33
|
+
--disable-pie --disable-ssp --disable-shared --without-pthreads; then
|
|
34
|
+
cat config.log
|
|
35
|
+
exit 1
|
|
36
|
+
fi
|
|
37
|
+
|
|
38
|
+
NPROCESSORS=$(getconf NPROCESSORS_ONLN 2>/dev/null || getconf _NPROCESSORS_ONLN 2>/dev/null)
|
|
39
|
+
PROCESSORS=${NPROCESSORS:-3}
|
|
40
|
+
|
|
41
|
+
if [ -z "$BENCHMARKS" ]; then
|
|
42
|
+
make -j${PROCESSORS} check && make install && make distclean >/dev/null
|
|
43
|
+
else
|
|
44
|
+
make -j${PROCESSORS} && make check
|
|
45
|
+
fi
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
Name: @PACKAGE_NAME@
|
|
2
|
+
Version: @PACKAGE_VERSION@
|
|
3
|
+
Description: A modern and easy-to-use crypto library
|
|
4
|
+
|
|
5
|
+
Libs: -L${pcfiledir}/src/libsodium -lsodium
|
|
6
|
+
Libs.private: @PKGCONFIG_LIBS_PRIVATE@
|
|
7
|
+
Cflags: -I${pcfiledir}/src/libsodium/include -I@top_srcdir@/src/libsodium/include -I@top_srcdir@/src/libsodium/include/sodium
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
prefix=@prefix@
|
|
2
|
+
exec_prefix=@exec_prefix@
|
|
3
|
+
libdir=@libdir@
|
|
4
|
+
includedir=@includedir@
|
|
5
|
+
|
|
6
|
+
Name: @PACKAGE_NAME@
|
|
7
|
+
Version: @PACKAGE_VERSION@
|
|
8
|
+
Description: A modern and easy-to-use crypto library
|
|
9
|
+
|
|
10
|
+
Libs: -L${libdir} -lsodium
|
|
11
|
+
Libs.private: @PKGCONFIG_LIBS_PRIVATE@
|
|
12
|
+
Cflags: -I${includedir}
|
|
Binary file
|
|
@@ -0,0 +1,119 @@
|
|
|
1
|
+
# ===========================================================================
|
|
2
|
+
# https://www.gnu.org/software/autoconf-archive/ax_add_fortify_source.html
|
|
3
|
+
# ===========================================================================
|
|
4
|
+
#
|
|
5
|
+
# SYNOPSIS
|
|
6
|
+
#
|
|
7
|
+
# AX_ADD_FORTIFY_SOURCE
|
|
8
|
+
#
|
|
9
|
+
# DESCRIPTION
|
|
10
|
+
#
|
|
11
|
+
# Check whether -D_FORTIFY_SOURCE=2 can be added to CPPFLAGS without macro
|
|
12
|
+
# redefinition warnings, other cpp warnings or linker. Some distributions
|
|
13
|
+
# (such as Ubuntu or Gentoo Linux) enable _FORTIFY_SOURCE globally in
|
|
14
|
+
# their compilers, leading to unnecessary warnings in the form of
|
|
15
|
+
#
|
|
16
|
+
# <command-line>:0:0: error: "_FORTIFY_SOURCE" redefined [-Werror]
|
|
17
|
+
# <built-in>: note: this is the location of the previous definition
|
|
18
|
+
#
|
|
19
|
+
# which is a problem if -Werror is enabled. This macro checks whether
|
|
20
|
+
# _FORTIFY_SOURCE is already defined, and if not, adds -D_FORTIFY_SOURCE=2
|
|
21
|
+
# to CPPFLAGS.
|
|
22
|
+
#
|
|
23
|
+
# Newer mingw-w64 msys2 package comes with a bug in
|
|
24
|
+
# headers-git-7.0.0.5546.d200317d-1. It broke -D_FORTIFY_SOURCE support,
|
|
25
|
+
# and would need -lssp or -fstack-protector. See
|
|
26
|
+
# https://github.com/msys2/MINGW-packages/issues/5803. Try to actually
|
|
27
|
+
# link it.
|
|
28
|
+
#
|
|
29
|
+
# LICENSE
|
|
30
|
+
#
|
|
31
|
+
# Copyright (c) 2017 David Seifert <soap@gentoo.org>
|
|
32
|
+
# Copyright (c) 2019, 2023 Reini Urban <rurban@cpan.org>
|
|
33
|
+
#
|
|
34
|
+
# Copying and distribution of this file, with or without modification, are
|
|
35
|
+
# permitted in any medium without royalty provided the copyright notice
|
|
36
|
+
# and this notice are preserved. This file is offered as-is, without any
|
|
37
|
+
# warranty.
|
|
38
|
+
|
|
39
|
+
#serial 10
|
|
40
|
+
|
|
41
|
+
AC_DEFUN([AX_ADD_FORTIFY_SOURCE],[
|
|
42
|
+
ac_save_cflags=$CFLAGS
|
|
43
|
+
ac_cwerror_flag=yes
|
|
44
|
+
AX_CHECK_COMPILE_FLAG([-Werror],[CFLAGS="$CFLAGS -Werror"])
|
|
45
|
+
ax_add_fortify_3_failed=
|
|
46
|
+
AC_MSG_CHECKING([whether to add -D_FORTIFY_SOURCE=3 to CPPFLAGS])
|
|
47
|
+
AC_LINK_IFELSE([
|
|
48
|
+
AC_LANG_PROGRAM([],
|
|
49
|
+
[[
|
|
50
|
+
#ifndef _FORTIFY_SOURCE
|
|
51
|
+
return 0;
|
|
52
|
+
#else
|
|
53
|
+
_FORTIFY_SOURCE_already_defined;
|
|
54
|
+
#endif
|
|
55
|
+
]]
|
|
56
|
+
)],
|
|
57
|
+
AC_LINK_IFELSE([
|
|
58
|
+
AC_LANG_SOURCE([[
|
|
59
|
+
#define _FORTIFY_SOURCE 3
|
|
60
|
+
#include <string.h>
|
|
61
|
+
int main(void) {
|
|
62
|
+
char *s = " ";
|
|
63
|
+
strcpy(s, "x");
|
|
64
|
+
return strlen(s)-1;
|
|
65
|
+
}
|
|
66
|
+
]]
|
|
67
|
+
)],
|
|
68
|
+
[
|
|
69
|
+
AC_MSG_RESULT([yes])
|
|
70
|
+
CFLAGS=$ac_save_cflags
|
|
71
|
+
CPPFLAGS="$CPPFLAGS -D_FORTIFY_SOURCE=3"
|
|
72
|
+
], [
|
|
73
|
+
AC_MSG_RESULT([no])
|
|
74
|
+
ax_add_fortify_3_failed=1
|
|
75
|
+
],
|
|
76
|
+
),
|
|
77
|
+
[
|
|
78
|
+
AC_MSG_RESULT([no])
|
|
79
|
+
ax_add_fortify_3_failed=1
|
|
80
|
+
])
|
|
81
|
+
if test -n "$ax_add_fortify_3_failed"
|
|
82
|
+
then
|
|
83
|
+
AC_MSG_CHECKING([whether to add -D_FORTIFY_SOURCE=2 to CPPFLAGS])
|
|
84
|
+
AC_LINK_IFELSE([
|
|
85
|
+
AC_LANG_PROGRAM([],
|
|
86
|
+
[[
|
|
87
|
+
#ifndef _FORTIFY_SOURCE
|
|
88
|
+
return 0;
|
|
89
|
+
#else
|
|
90
|
+
_FORTIFY_SOURCE_already_defined;
|
|
91
|
+
#endif
|
|
92
|
+
]]
|
|
93
|
+
)],
|
|
94
|
+
AC_LINK_IFELSE([
|
|
95
|
+
AC_LANG_SOURCE([[
|
|
96
|
+
#define _FORTIFY_SOURCE 2
|
|
97
|
+
#include <string.h>
|
|
98
|
+
int main(void) {
|
|
99
|
+
char *s = " ";
|
|
100
|
+
strcpy(s, "x");
|
|
101
|
+
return strlen(s)-1;
|
|
102
|
+
}
|
|
103
|
+
]]
|
|
104
|
+
)],
|
|
105
|
+
[
|
|
106
|
+
AC_MSG_RESULT([yes])
|
|
107
|
+
CFLAGS=$ac_save_cflags
|
|
108
|
+
CPPFLAGS="$CPPFLAGS -D_FORTIFY_SOURCE=2"
|
|
109
|
+
], [
|
|
110
|
+
AC_MSG_RESULT([no])
|
|
111
|
+
CFLAGS=$ac_save_cflags
|
|
112
|
+
],
|
|
113
|
+
),
|
|
114
|
+
[
|
|
115
|
+
AC_MSG_RESULT([no])
|
|
116
|
+
CFLAGS=$ac_save_cflags
|
|
117
|
+
])
|
|
118
|
+
fi
|
|
119
|
+
])
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
# SYNOPSIS
|
|
2
|
+
#
|
|
3
|
+
# AX_CHECK_CATCHABLE_ABRT
|
|
4
|
+
#
|
|
5
|
+
# DESCRIPTION
|
|
6
|
+
#
|
|
7
|
+
# Check whether SIGABRT can be caught using signal handlers.
|
|
8
|
+
|
|
9
|
+
#serial 1
|
|
10
|
+
|
|
11
|
+
AC_DEFUN([AX_CHECK_CATCHABLE_ABRT], [dnl
|
|
12
|
+
AC_PREREQ(2.64)
|
|
13
|
+
AS_VAR_PUSHDEF([CACHEVAR], [ax_cv_check_[]_AC_LANG_ABBREV[]CATCHABLE_ABRT])dnl
|
|
14
|
+
AC_CACHE_CHECK([whether SIGABRT can be caught], CACHEVAR, [
|
|
15
|
+
AC_RUN_IFELSE([
|
|
16
|
+
AC_LANG_PROGRAM([[
|
|
17
|
+
#include <signal.h>
|
|
18
|
+
#include <stdlib.h>
|
|
19
|
+
|
|
20
|
+
#ifndef SIGABRT
|
|
21
|
+
# error SIGABRT is not defined
|
|
22
|
+
#endif
|
|
23
|
+
|
|
24
|
+
static void sigabrt_handler_3(int _)
|
|
25
|
+
{
|
|
26
|
+
exit(0);
|
|
27
|
+
}
|
|
28
|
+
|
|
29
|
+
static void sigabrt_handler_2(int _)
|
|
30
|
+
{
|
|
31
|
+
signal(SIGABRT, sigabrt_handler_3);
|
|
32
|
+
abort();
|
|
33
|
+
exit(1);
|
|
34
|
+
}
|
|
35
|
+
|
|
36
|
+
static void sigabrt_handler_1(int _)
|
|
37
|
+
{
|
|
38
|
+
signal(SIGABRT, sigabrt_handler_2);
|
|
39
|
+
abort();
|
|
40
|
+
exit(1);
|
|
41
|
+
}
|
|
42
|
+
]], [[
|
|
43
|
+
signal(SIGABRT, sigabrt_handler_1);
|
|
44
|
+
abort();
|
|
45
|
+
exit(1);
|
|
46
|
+
]])],
|
|
47
|
+
[AS_VAR_SET(CACHEVAR, [yes])],
|
|
48
|
+
[AS_VAR_SET(CACHEVAR, [no])],
|
|
49
|
+
[AS_VAR_SET(CACHEVAR, [unknown])]
|
|
50
|
+
)
|
|
51
|
+
])
|
|
52
|
+
AS_VAR_IF(CACHEVAR, yes,
|
|
53
|
+
[AC_DEFINE([HAVE_CATCHABLE_ABRT], [1], [Define if SIGABRT can be caught using signal handlers])],
|
|
54
|
+
[AC_MSG_WARN([On this platform, SIGABRT cannot be caught using signal handlers.])]
|
|
55
|
+
)
|
|
56
|
+
AS_VAR_POPDEF([CACHEVAR])dnl
|
|
57
|
+
])
|