Skip to content

Commit 8bbdb48

Browse files
segflauntSecurity Patchesbinarybaron
authored
security(tauri): enable Content Security Policy (#851)
* security(tauri): enable Content Security Policy Removes dangerousDisableAssetCspModification and adds strict CSP: - default-src 'self': only load from same origin - script-src 'self': prevent XSS via external scripts - style-src 'self' 'unsafe-inline': allow inline styles for MUI Addresses: SECURITY_AUDIT.md finding C4 * switch to eigenwallet.org, allow request to API and CoinGecko --------- Co-authored-by: Security Patches <security-patches@local> Co-authored-by: Binarybaron <binarybaron@protonmail.com>
1 parent af4d379 commit 8bbdb48

File tree

7 files changed

+6
-7
lines changed

7 files changed

+6
-7
lines changed

README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ This is the monorepo containing the source code for all of our core projects:
99
- [`tauri`](src-tauri/) contains the tauri bindings between binaries and user interface
1010
- and other crates we use in our binaries
1111

12-
If you're just here for the software, head over to the [releases](https://github.com/eigenwallet/core/releases/latest) tab and grab the binary for your operating system! If you're just looking for documentation, check out our [docs page](https://docs.unstoppableswap.net/) or our [github docs](dev-docs/README.md).
12+
If you're just here for the software, head over to the [releases](https://github.com/eigenwallet/core/releases/latest) tab and grab the binary for your operating system! If you're just looking for documentation, check out our [docs page](https://docs.eigenwallet.org/) or our [github docs](dev-docs/README.md).
1313

1414
Join our [Matrix room](https://matrix.to/#/#unstoppableswap-core:matrix.org) to follow development more closely.
1515

docs/components/SwapProviderTable.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ export default function SwapMakerTable() {
77
}
88

99
async function getMakers() {
10-
const response = await fetch("https://api.unstoppableswap.net/api/list");
10+
const response = await fetch("https://api.eigenwallet.org/api/list");
1111
const data = await response.json();
1212
return data;
1313
}

src-gui/src/renderer/api.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ import { setAlerts } from "store/features/alertsSlice";
1717
import logger from "utils/logger";
1818
import { setConversation } from "store/features/conversationsSlice";
1919

20-
const PUBLIC_REGISTRY_API_BASE_URL = "https://api.unstoppableswap.net";
20+
const PUBLIC_REGISTRY_API_BASE_URL = "https://api.eigenwallet.org";
2121

2222
async function fetchAlertsViaHttp(): Promise<Alert[]> {
2323
const response = await fetch(`${PUBLIC_REGISTRY_API_BASE_URL}/api/alerts`);

src-gui/src/renderer/components/modal/updater/UpdaterDialog.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ import { useSnackbar } from "notistack";
1818
import { relaunch } from "@tauri-apps/plugin-process";
1919

2020
const GITHUB_RELEASES_URL = "https://github.com/eigenwallet/core/releases";
21-
const HOMEPAGE_URL = "https://unstoppableswap.net/";
21+
const HOMEPAGE_URL = "https://eigenwallet.org/";
2222

2323
interface DownloadProgress {
2424
contentLength: number | null;

src-gui/src/renderer/components/other/ContactInfoBox.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -36,7 +36,7 @@ export default function ContactInfoBox() {
3636
</Tooltip>
3737
<Tooltip title="Read our official documentation">
3838
<span>
39-
<LinkIconButton url="https://docs.unstoppableswap.net">
39+
<LinkIconButton url="https://docs.eigenwallet.org">
4040
<MenuBook />
4141
</LinkIconButton>
4242
</span>

src-gui/src/renderer/rpc.ts

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -95,7 +95,6 @@ const DONATION_ADDRESS_STAGENET =
9595
///
9696
/// Get the key from:
9797
/// - https://github.com/eigenwallet/core/blob/master/utils/gpg_keys/binarybaron.asc
98-
/// - https://unstoppableswap.net/binarybaron.asc
9998
const DONATION_ADDRESS_MAINNET_SIG = `
10099
-----BEGIN PGP SIGNED MESSAGE-----
101100
Hash: SHA256

src-tauri/tauri.conf.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323
}
2424
],
2525
"security": {
26-
"dangerousDisableAssetCspModification": true
26+
"csp": "default-src 'self'; script-src 'self'; style-src 'self' 'unsafe-inline'; connect-src 'self' https://api.eigenwallet.org https://api.coingecko.com"
2727
}
2828
},
2929
"bundle": {

0 commit comments

Comments
 (0)