summaryrefslogtreecommitdiffhomepage
path: root/gui/src/renderer/components/ConnectionPanel.tsx
diff options
context:
space:
mode:
authorOskar Nyberg <oskar@mullvad.net>2022-04-28 10:56:25 +0200
committerOskar Nyberg <oskar@mullvad.net>2022-04-28 10:57:42 +0200
commit05ed04ec3ddc6d7f5d74397d7956bee36df70524 (patch)
treec3b8aee14c79ef60428293b5e2fd75b9d180b5cf /gui/src/renderer/components/ConnectionPanel.tsx
parentfa4876768cd889b4a7b951d3be607f87b65323d1 (diff)
downloadmullvadvpn-05ed04ec3ddc6d7f5d74397d7956bee36df70524.tar.xz
mullvadvpn-05ed04ec3ddc6d7f5d74397d7956bee36df70524.zip
Show obfuscation endpoint as in-data
Diffstat (limited to 'gui/src/renderer/components/ConnectionPanel.tsx')
-rw-r--r--gui/src/renderer/components/ConnectionPanel.tsx14
1 files changed, 11 insertions, 3 deletions
diff --git a/gui/src/renderer/components/ConnectionPanel.tsx b/gui/src/renderer/components/ConnectionPanel.tsx
index 060802a1d9..7f4c28286b 100644
--- a/gui/src/renderer/components/ConnectionPanel.tsx
+++ b/gui/src/renderer/components/ConnectionPanel.tsx
@@ -4,6 +4,7 @@ import styled from 'styled-components';
import { colors } from '../../config.json';
import {
+ ObfuscationType,
ProxyType,
proxyTypeToString,
RelayProtocol,
@@ -29,6 +30,10 @@ export interface IBridgeData extends IEndpoint {
bridgeType: ProxyType;
}
+export interface IObfuscationData extends IEndpoint {
+ obfuscationType: ObfuscationType;
+}
+
export interface IOutAddress {
ipv4?: string;
ipv6?: string;
@@ -43,6 +48,7 @@ interface IProps {
entryLocationInAddress?: IInAddress;
bridgeInfo?: IBridgeData;
outAddress?: IOutAddress;
+ obfuscationEndpoint?: IObfuscationData;
onToggle: () => void;
className?: string;
}
@@ -126,10 +132,12 @@ export default class ConnectionPanel extends React.Component<IProps> {
);
}
- private getEntryPoint() {
- const { inAddress, entryLocationInAddress, bridgeInfo } = this.props;
+ private getEntryPoint(): IEndpoint | undefined {
+ const { obfuscationEndpoint, inAddress, entryLocationInAddress, bridgeInfo } = this.props;
- if (entryLocationInAddress && inAddress) {
+ if (obfuscationEndpoint) {
+ return obfuscationEndpoint;
+ } else if (entryLocationInAddress && inAddress) {
return entryLocationInAddress;
} else if (bridgeInfo && inAddress) {
return bridgeInfo;