aboutsummaryrefslogtreecommitdiff
AgeCommit message (Collapse)Author
2019-06-20tests: Use Unicode literals in the Unicode decoding tests.Damir Jelić
This is needed because the function returns Unicode strings and the comparison will fail under python2 unless Unicode literals are used.
2019-06-20_compat: Make the encoding argument explicit in to_unicode_str().Damir Jelić
2019-06-20olm: Rename the errors function argument in the decryption functions.Damir Jelić
2019-06-19_compat: Remove the now unused native_str.Damir Jelić
2019-06-19_compat: Change the to_native_str into a to_unicode_str function.Damir Jelić
The to_native_str function was supposed to produce Unicode decoded native strings for python2 and python3. Upon further consideration this doesn't make much sense since under python2 it would need to decode the bytes into a Unicode string and turn it back into a python2 str. The ability to use the replacement character requires us to use a Unicode string under python2 as well.
2019-06-19_compat: Remove unused import.Damir Jelić
2019-06-18Makefile: Add an isort target.Damir Jelić
2019-06-18olm: Allow decryption functions to define how to handle unicode decode errors.Damir Jelić
This patch changes the decryption functions not to fail if there was an unicode decode error while converting the decrypted bytes plaintext into a native python string. Characters that cannot be decoded as unicode are now replaced with the unicode replacement character (U+FFFD). The old behaviour of raising an UnicodeDecodeError can be achieved by passing the "strict" error handling scheme to the decrypt function.
2019-06-18compat: Add a method to convert bytes to a string that handles unicode errors.Damir Jelić
2019-04-28Merge branch 'poljar/cmake_sas' into 'master'Hubert Chathi
cmake: Add the SAS functions to the CMake build. See merge request matrix-org/olm!1
2019-04-28cmake: Add the SAS functions to the CMake build.Damir Jelić
Signed-off-by: Damir Jelić <poljar@termina.org.uk>
2019-04-22update changelog3.1.0Hubert Chathi
2019-04-22include the C++ string library in unit testsHubert Chathi
to fix compilation errors in some compilers
2019-04-22don't use variable length or zero-length arrays in test filesHubert Chathi
as some compilers don't handle that
2019-04-22remove some debugging output from testsHubert Chathi
2019-04-19Merge pull request #89 from matrix-org/manuroe/cocoapods_updateHubert Chathi
OLMKit: Make podspec point to new https://gitlab.matrix.org/matrix-org/olm
2019-04-19OLMKit: Make podspec point to new https://gitlab.matrix.org/matrix-org/olmmanuroe
2019-04-17update changelog links to point to new repoHubert Chathi
2019-04-17prepare for 3.1.0 releaseHubert Chathi
2019-04-12Merge pull request #86 from matrix-org/add_python_pk_signingHubert Chathi
add python bindings for PK signing
2019-04-12more isortHubert Chathi
2019-04-12Merge pull request #88 from matrix-org/manuroe/sas_pksigningHubert Chathi
OLMKit: add Short Authentication String verification
2019-04-12isort python/olm/pk.pyHubert Chathi
2019-04-12OLMKit: OMLPkSigning: Zero mutableSeedmanuroe
2019-04-10OLMKit: OlmPkEncryption: Fix typos in sanity checksmanuroe
(cherry picked from commit add1bd6e4250012dcfa30a40d763dba82f53c254)
2019-04-10OLMKit: SAS: Add PK signingmanuroe
(cherry picked from commit ff31d489c68d5d9e597bd55a6f6a64f3fe4c7ecc)
2019-04-10OLMKit: SAS: Added macLongKdf supportmanuroe
(cherry picked from commit 934d516eb35c488ee197e1bab78a4c81e3c8241d)
2019-04-10OLMKit: add Short Authentication String verificationmanuroe
(cherry picked from commit 3e954ca2729d3333ea853c878602d1696f616573)
2019-04-10Fix arg name in commentsmanuroe
(cherry picked from commit c0a53ebaeda420f636698b99c393868d2bf8f905)
2019-04-10Merge branch 'python-sas'Damir Jelić
2019-04-10Merge pull request #83 from matrix-org/BillCarsonFr/java_sasValere
Java binding for SAS
2019-04-10Return string instead of byte array for b64 encoded dataValere
2019-04-10Added macLongKdf supportValere
2019-04-10E2E: SAS Verification (olm) Valere
Fix / missing free() on some errors Added doc regarding string encoding for keys cleaning
2019-04-09python: Add the SAS header to the manifest.Damir Jelić
The SAS header is required to build the package therefore it needs to be shipped with the source distribution of the package. Adding it to the manifest achieves this.
2019-04-09python: Add support for the long KDF MAC calculation.Damir Jelić
2019-04-09python: Remove an unneeded and old copyright header.Damir Jelić
2019-04-08add python bindings for PK signingHubert Chathi
2019-04-08re-add null termination in javascriptHubert Chathi
because older versions of emscripten don't support the length argument to UTF8ToString.
2019-04-08javascript: Switch from deprecated Pointer_stringify() to UTF8toString().Damir Jelić
The Pointer_stringify() function is deprecated and has a couple of issues because it tries to guess the encoding of the buffer. In some cases it can ignore the length parameter which could end up in inconsistencies. Switch to UTF8toString() that takes a length parameter and respects, that way we don't need to allocate an additional byte for a NULL byte.
2019-04-08Merge branch 'master' into poljar/python-sasHubert Chathi
2019-04-08python: Build the build headers with setup.py.Damir Jelić
This allows downstream users to install this python module with pip as well as allowing people to declare it as a dependency in their setup.py. Signed-off-by: Damir Jelić <poljar@termina.org.uk>
2019-04-08python: Fix the MANIFEST file.Damir Jelić
This patch adds the Olm header files to the manifest, this results in the header files being added to source distributions of the python-olm module. The headers are required to build the module. Including them in the source distribution is the easiest way to make sure that builds from the source distribution will succeed provided that the Olm C library is already installed. Signed-off-by: Damir Jelić <poljar@termina.org.uk>
2019-04-08python: Add PK bindings.Damir Jelić
This patch adds bindings to the PK part of the Olm library contained in the pk.h header file. Encryption, decryption as well as pickling/unpickling of the decryption object is supported. Signed-off-by: Damir Jelić <poljar@termina.org.uk>
2019-04-08python: Make the typing module a requirement only for old python versions.Damir Jelić
Typing is part of standard library from python 3.5 and from python 3.7 onwards trying to install it results in an error. This patch disables typing installation on python versions that are newer than 3.5. Signed-off-by: Damir Jelić <poljar@termina.org.uk>
2019-04-04add missing OlmPkSigning classHubert Chathi
2019-04-02add support for an incorrect KDF that snuck into Riot 1.0Hubert Chathi
2019-04-02python: Expose the sha256() function in the utilities.Damir Jelić
Signed-off-by: Damir Jelić <poljar@termina.org.uk>
2019-04-02python: Add Short Authentication String bindings.Damir Jelić
This patch adds bindings to the SAS part of the Olm library contained in the sas.h header file. Signed-off-by: Damir Jelić <poljar@termina.org.uk>
2019-03-28update unit test to match function name changeHubert Chathi