diff --git a/native/profile/secondary-device-qr-code-scanner.react.js b/native/profile/secondary-device-qr-code-scanner.react.js --- a/native/profile/secondary-device-qr-code-scanner.react.js +++ b/native/profile/secondary-device-qr-code-scanner.react.js @@ -40,6 +40,7 @@ type PeerToPeerMessage, } from 'lib/types/tunnelbroker/peer-to-peer-message-types.js'; import { qrCodeAuthMessageTypes } from 'lib/types/tunnelbroker/qr-code-auth-message-types.js'; +import { isDev } from 'lib/utils/dev-utils.js'; import { rawDeviceListFromSignedList } from 'lib/utils/device-list-utils.js'; import { assertWithValidator } from 'lib/utils/validation-utils.js'; @@ -57,6 +58,7 @@ import { useSelector } from '../redux/redux-utils.js'; import { useStyles, useColors } from '../themes/colors.js'; import Alert from '../utils/alert.js'; +import { useShowVersionUnsupportedAlert } from '../utils/hooks.js'; import { deviceIsEmulator } from '../utils/url-utils.js'; const barCodeTypes = [BarCodeScanner.Constants.BarCodeType.qr]; @@ -94,6 +96,14 @@ const { panelForegroundTertiaryLabel } = useColors(); + const showVersionUnsupportedAlert = useShowVersionUnsupportedAlert(true); + React.useEffect(() => { + // Secondary device auth is unsupported publicly in this version + if (!isDev) { + showVersionUnsupportedAlert(); + } + }, [showVersionUnsupportedAlert]); + const tunnelbrokerMessageListener = React.useCallback( async (message: TunnelbrokerToDeviceMessage) => { const encryptionKey = aes256Key.current;