From fa2fcbcbecd993ab51b4bd2f3f4f395c85d5ef8c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C5=A0imon=20Brandner?= Date: Tue, 25 Jul 2023 11:07:20 +0200 Subject: [PATCH 1/2] Hide E2EE behind a flag MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Šimon Brandner --- src/room/LobbyView.tsx | 19 ++++++++++++------- src/settings/SettingsModal.tsx | 14 ++++++++++++++ src/settings/useSetting.ts | 3 +++ 3 files changed, 29 insertions(+), 7 deletions(-) diff --git a/src/room/LobbyView.tsx b/src/room/LobbyView.tsx index e52835ae..258b474f 100644 --- a/src/room/LobbyView.tsx +++ b/src/room/LobbyView.tsx @@ -27,6 +27,7 @@ import { useLocationNavigation } from "../useLocationNavigation"; import { MatrixInfo, VideoPreview } from "./VideoPreview"; import { E2EEConfig, UserChoices } from "../livekit/useLiveKit"; import { InputField } from "../input/Input"; +import { useEnableE2EE } from "../settings/useSetting"; interface Props { matrixInfo: MatrixInfo; @@ -40,6 +41,8 @@ export function LobbyView(props: Props) { const { t } = useTranslation(); useLocationNavigation(); + const [enableE2EE] = useEnableE2EE(); + const joinCallButtonRef = useRef(null); useEffect(() => { if (joinCallButtonRef.current) { @@ -80,13 +83,15 @@ export function LobbyView(props: Props) { matrixInfo={props.matrixInfo} onUserChoicesChanged={setUserChoices} /> - + {enableE2EE && ( + + )} diff --git a/src/settings/useSetting.ts b/src/settings/useSetting.ts index 63f1e23a..8d3f074f 100644 --- a/src/settings/useSetting.ts +++ b/src/settings/useSetting.ts @@ -104,6 +104,9 @@ export const useDeveloperSettingsTab = () => export const useShowConnectionStats = () => useSetting("show-connection-stats", false); +export const useEnableE2EE = () => + useSetting("enable-end-to-end-encryption", false); + export const useDefaultDevices = () => useSetting("defaultDevices", { audioinput: "", From 9abd409a9affc1ebc8983cdfa4140eeee6e7ff44 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=C5=A0imon=20Brandner?= Date: Tue, 25 Jul 2023 11:07:30 +0200 Subject: [PATCH 2/2] i18n MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Šimon Brandner --- public/locales/en-GB/app.json | 1 + 1 file changed, 1 insertion(+) diff --git a/public/locales/en-GB/app.json b/public/locales/en-GB/app.json index 5425fe69..4fcdc1b5 100644 --- a/public/locales/en-GB/app.json +++ b/public/locales/en-GB/app.json @@ -38,6 +38,7 @@ "Download debug logs": "Download debug logs", "Element Call Home": "Element Call Home", "Element Call is temporarily not end-to-end encrypted while we test scalability.": "Element Call is temporarily not end-to-end encrypted while we test scalability.", + "Enable end-to-end encryption (password protected calls)": "Enable end-to-end encryption (password protected calls)", "Exit full screen": "Exit full screen", "Expose developer settings in the settings window.": "Expose developer settings in the settings window.", "Feedback": "Feedback",