about summary refs log tree commit diff stats
path: root/src/omemo/omemo.c
Commit message (Collapse)AuthorAgeFilesLines
* User proper ellipsis charMartin Dosch2023-04-091-1/+1
| | | | | | | As stated in https://github.com/profanity-im/profanity/pull/1820#issuecomment-1498083383 profanity uses "..." (three dots) in a lot of places instead the proper ellipsis char "…".
* fix #1797Steffen Jaeckel2023-03-121-1/+1
| | | | Signed-off-by: Steffen Jaeckel <jaeckel-floss@eyet-services.de>
* Add macro for possible NULL prints and use it on known sportsthe xhr2023-01-261-2/+2
| | | | | The macro is effective on OpenBSD and basically a no op on other platforms. Use it for one existing and the other known debug statements.
* Check if string is NULL and print placeholder insteadthe xhr2023-01-261-1/+1
| | | | OpenBSD's kernel warns about NULL printfs. Fix this with a standard check.
* fix memory leaks in OMEMOSteffen Jaeckel2023-01-181-25/+41
| | | | Signed-off-by: Steffen Jaeckel <jaeckel-floss@eyet-services.de>
* Update copyright yearMichael Vetter2023-01-101-1/+1
|
* Fix typo in omemo commandMichael Vetter2022-06-051-1/+1
|
* Use our omemo sid/fingerprint in qr codeMichael Vetter2022-05-311-0/+18
| | | | | | | Current clients sid/fingerprint will be shown in following format: `xmpp:<user@server>?omemo-sid-<numerical-sid>=<omemo-fingerprint-hex-string>` Fix https://github.com/profanity-im/profanity/issues/1320
* Update copyright yearMichael Vetter2022-05-091-1/+1
|
* add `files_file_in_account_data_path()`Steffen Jaeckel2022-03-131-12/+5
| | | | | | | | | | | | As all parts of the code invoking the `files_get_account_data_path()` function did the same afterwards, a function has been added with the same behavior. 1. create path 2. `mkdir` of that path 3. return final path Signed-off-by: Steffen Jaeckel <jaeckel-floss@eyet-services.de>
* auto-formatSteffen Jaeckel2022-02-011-1/+3
| | | | Signed-off-by: Steffen Jaeckel <jaeckel-floss@eyet-services.de>
* Refined sender device acquirementnandesu-utils2021-10-291-5/+7
| | | | | Now the sender devices are acknowledged only after omemo is loaded. That is, after key generation has been completed or identity has been loaded.
* Acquire sender's device list on connectionnandesu-utils2021-10-281-4/+8
| | | | | | | | After generation of an identity we observe that `omemo_ctx.device_list` has an entry for sender's jid. But on application restart it is absent thus messages are not encrypted for the rest set of sender devices. This commit fixes this by applying code for acquiring the aforementioned device list after the connection.
* Format code correctlyMichael Vetter2021-10-051-10/+10
|
* omemo: always free error and print warningMichael Vetter2021-07-221-0/+9
| | | | Fix https://github.com/profanity-im/profanity/issues/1584
* Fix segfault when aesgcm url isn't the expected sizeMichael Vetter2021-06-301-0/+1
| | | | | | | | Fixes the bug mentioned in https://github.com/profanity-im/profanity/issues/1478#issuecomment-794161606 The rest of https://github.com/profanity-im/profanity/issues/1478 I can't reproduce. Seems to work fine.
* OMEMO LoggingDebXWoody2021-06-281-4/+5
|
* OMEMO: Separate handling of device listDebXWoody2021-06-051-1/+12
| | | | | | | | | | | | | | | | | | | | | | In profanity are two handlers for device list: * _handle_own_device_list * _handle_device_list_start_session I seems both handler will start a session via omemo_start_device_session_handle_bundle _handle_own_device_list will also make sure, that the own device is withing the omemo device list. If we add the _handle_device_list_start_session into the hashmap, we are not going the republish ourself, in case we clean-up the device list from another client. This will maybe fix #1552 99 Little Bugs in my Code. Take one down. Patch it around. 113 Bugs in my Code
* Merge pull request #1542 from DebXWoody/bugfix/fix1541Michael Vetter2021-06-031-0/+13
|\ | | | | OMEMO: Don't encrypt to yourself (MUC)
| * OMEMO: Don't encrypt to yourself (MUC)DebXWoody2021-05-291-4/+4
| | | | | | | | Use connection_get_barejid instead of connection_get_fulljid.
| * OMEMO: Don't encrypt to yourself (MUC)DebXWoody2021-05-281-0/+13
| | | | | | | | | | | | | | | | | | As defined in XEP-0384 the application should not encrypt the message to own devices. Within a groupchat, yourself are a recipients as well. We will check the recipients and filter out the own device of the own jid. This Pull Request will fix Issue: #1541
* | OMEMO - Unable to publish own device listDebXWoody2021-06-011-2/+3
|/ | | | | | | | | | If we are not able to publish our own device list, we just ignored it. This commit will show at least an error message and informs the user that this device is currently not in the list of devices. See Issue: #1538 Next task will be to handle the <precondition-not-met/> conflict properly.
* Improved OMEMO loggingDebXWoody2021-05-281-31/+45
| | | | | | | | | | | The most loggings has been set to debug. Just in case of error / problem the logging should be done with log-level ERROR or WARNING. We will see later, which loggings should be switched to log-level INFO. This improvement has been done to find OMEMO bugs. See also: #1070 #1530 #1538
* OMEMO - trust mode (#1506)Stefan2021-04-171-0/+36
| | | | | | | Add OMEMO trust mode capabilities. * ToFu / first usage * blind trust * manual
* OMEMO: Fail if message keys couldn't be encrypted for any recipient deviceMaximilian Wuttke2021-04-081-0/+20
| | | | | | | | | If the message (key) can't be encrypted for any device, sending the message is refused and an informative error message is presented to the user. Also, don't encrypt for the same device, since the OMEMO XEP disallows this.
* Include config.h in omemo filesMichael Vetter2021-03-261-0/+2
| | | | | | | | | So that off_t is defined in all files (so far http_upload.c and http_download.c too) the same way. Fix https://github.com/profanity-im/profanity/issues/1512 Thanks @pasis for finding the solution!
* Changes logging format to [OMEMO]Stefan2021-03-091-48/+49
|
* Update copyrightMichael Vetter2021-01-081-1/+1
|
* Refactor for threaded external executable for built-in download methodsWilliam Wennerström2020-12-031-1/+0
|
* Explicitly clear fragment from HTTP URLWilliam Wennerström2020-11-161-0/+6
|
* Add I/O error handling and use filenames instead of file descriptorsWilliam Wennerström2020-11-161-2/+3
|
* Refactor OMEMO download into AESGCMDownload toolWilliam Wennerström2020-11-161-7/+99
|
* Run make format on rebaseWilliam Wennerström2020-11-161-5/+8
|
* Move file encryption function to public headerWilliam Wennerström2020-11-161-0/+32
|
* Since the string from strerror should never be modified, use const.Philipp Klaus Krause2020-10-141-1/+1
|
* Free errors after they have been printedWilliam Wennerström2020-07-101-0/+4
|
* Apply coding styleMichael Vetter2020-07-071-269/+268
|
* Revert "Apply coding style"Michael Vetter2020-07-071-271/+272
| | | | | | This reverts commit 9b55f2dec0ea27a9ce4856e303425e12f866cea2. Sorting the includes creates some problems.
* Apply coding styleMichael Vetter2020-07-071-272/+271
| | | | Regards https://github.com/profanity-im/profanity/issues/1396
* Merge branch 'master' of github.com:profanity-im/profanityMichael Vetter2020-07-041-11/+13
|\
| * Merge pull request #1387 from DebXWoody/bugfix/1332-omemoMichael Vetter2020-07-041-11/+13
| |\ | | | | | | Request Device and Key, when OMEMO is in use
| | * Request Device and Key, when OMEMO is in useDebXWoody2020-06-041-11/+13
| | | | | | | | | | | | | | | | | | | | | | | | Profanity requests the device list and keys for contacts, also when the user hasn't generated the OMEMO key. If the user has no OMEMO key, there is no need to request OMEMO information. Issue: #1332
* | | Merge branch 'omemofix'Michael Vetter2020-07-041-1/+0
|\ \ \ | |/ / |/| |
| * | Messages are not shown in ChatSecureDebXWoody2020-07-041-1/+0
| | | | | | | | | | | | | | | | | | | | | | | | In 0.9.x we fixed an issue, because OMEMO devices should be defined in "item" with id "current". This should work, but it won't work if there is no "current". If there is no "current" we will just use the first item. Issue #1384
* | | Remove prefs_free_string()Michael Vetter2020-07-021-1/+1
|/ / | | | | | | | | It just does a free. Related to b580b9ef119045f142fa4baa9689a1c5ce8864ef
* / Use files_get_account_data_path instead of duplicate codeMichael Vetter2020-07-011-21/+14
|/ | | | | We often had a use case where we want the account specific data dir. Let's create a function for this instead of doing it by hand each time.
* Add and use connection_get_barejid()Michael Vetter2020-05-251-4/+4
| | | | Instead of connection_get_fulljid() and then creating a Jid from it.
* Expand omemo error messageMichael Vetter2020-02-211-2/+2
|
* xep-0308: enable corrections for outgoing encrypted messagesMichael Vetter2020-02-121-3/+3
|
* Add context to autocomplete_with_func and use it for omemo trust commandPaul Fariello2020-01-311-7/+25
| | | | Fix #1068