Fix segfault when aesgcm url isn't the expected size
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.
This commit is contained in:
@@ -1862,6 +1862,7 @@ omemo_parse_aesgcm_url(const char* aesgcm_url,
|
||||
}
|
||||
|
||||
if (strlen(*fragment) != AESGCM_URL_NONCE_LEN + AESGCM_URL_KEY_LEN) {
|
||||
ret = 1;
|
||||
goto out;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user