allow unpadded messages (#1625)

* allow unpadded messages

* bump to v1.6.1

* lint

* Fix app image start for non-debian based distribs

Fixes #1620
pull/1626/head v1.6.1
Audric Ackermann 5 years ago committed by GitHub
parent 6821b789a4
commit 2f14030194
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

@ -9,7 +9,13 @@ let tray = null;
function createTrayIcon(getMainWindow, messages) {
// A smaller icon is needed on macOS
const iconSize = process.platform === 'darwin' ? '16' : '256';
const iconNoNewMessages = path.join(__dirname, '..', 'images', 'session', `session_icon_${iconSize}.png`);
const iconNoNewMessages = path.join(
__dirname,
'..',
'images',
'session',
`session_icon_${iconSize}.png`
);
tray = new Tray(iconNoNewMessages);

@ -1,5 +1,7 @@
#!/usr/bin/env bash
set -e
# do not set -x here because it will fail on non-debian based distrib
# set -e
# Some distributions do not have unprivileged_userns_clone disabled.
# If that's the case, and we run an AppImage (deb is not impacted by this),

@ -2,7 +2,7 @@
"name": "session-desktop",
"productName": "Session",
"description": "Private messaging from your desktop",
"version": "1.6.0",
"version": "1.6.1",
"license": "GPL-3.0",
"author": {
"name": "Loki Project",

@ -208,9 +208,7 @@ class SessionPasswordModalInner extends React.Component<Props, State> {
return;
}
const isValidWithStoredInDB = Boolean(
await this.validatePasswordHash(oldPassword)
);
const isValidWithStoredInDB = Boolean(await this.validatePasswordHash(oldPassword));
if (!isValidWithStoredInDB) {
this.setState({
error: window.i18n('changePasswordInvalid'),

@ -200,7 +200,8 @@ export function unpad(paddedData: ArrayBuffer): ArrayBuffer {
plaintext.set(paddedPlaintext.subarray(0, i));
return plaintext.buffer;
} else if (paddedPlaintext[i] !== 0x00) {
throw new Error('Invalid padding');
window.log.warn('got a message without padding... Letting it through for now');
return paddedPlaintext;
}
}

Loading…
Cancel
Save