Skip to content

Commit d4f7591

Browse files
update maybe?
1 parent cccc66a commit d4f7591

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

59 files changed

+2287
-2929
lines changed

.github/ISSUE_TEMPLATE/general.md

+1-1
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ You can copy the debug info from the console and attach the console information
1313
Example: [https://beta.sodium-5h8.pages.dev](https://beta.sodium-5h8.pages.dev)
1414

1515
**UserAgent**
16-
Example: Mozilla/5.0 (X11; CrOS x86_64 14541.0.0) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/117.0.0.0 Safari/537.36
16+
Example: Mozilla/5.0 (X11; CrOS x86_64 14541.0.0) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/130.0.0.0 Safari/537.36
1717

1818
**Sodium Version**
1919
Example: 1.3.7 (LTS)

.gitignore

+2-1
Original file line numberDiff line numberDiff line change
@@ -1 +1,2 @@
1-
node_modules/
1+
node_modules/
2+
.npmrc

SECURITY.md

+2-2
Original file line numberDiff line numberDiff line change
@@ -6,9 +6,9 @@ Only current versions of the site are being updated, if you are using an older v
66

77
| Version | Supported |
88
| ------- | ------------------ |
9+
| 2.7.x | :green_check_mark: |
910
| 2.5.x | :green_check_mark: |
10-
| 2.4.x | :white_check_mark: |
11-
| 2.3.x | :blue_check_mark: |
11+
| 2.3.x | :x: |
1212
| < 2.2 | :x: |
1313

1414
## Reporting a Vulnerability

index.mjs

+3-3
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,7 @@ app.use((req, res, next) => {
2020
}
2121
});
2222

23-
async function checkForUpdates() {
23+
async function updateCheck() {
2424
try {
2525
const packageJson = JSON.parse(fs.readFileSync('package.json', 'utf8'));
2626
const localVersion = packageJson.version;
@@ -45,12 +45,12 @@ function logServerDetails(port) {
4545

4646
const port = parseInt(process.env.PORT, 10) || 8080;
4747
app.listen(port, () => {
48-
checkForUpdates();
48+
updateCheck();
4949
logServerDetails(port);
5050
});
5151

5252
const shutdown = () => {
53-
console.log('Server Shutdown. Goodbye!');
53+
console.log('Goodbye!');
5454
process.exit(0);
5555
};
5656

package-lock.json

+3-3
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

+1-2
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "sodium-instance",
3-
"version": "2.5.0",
3+
"version": "2.7.0",
44
"description": "Sodium is a site used for evading internet censorship",
55
"type": "module",
66
"engines": {
@@ -16,7 +16,6 @@
1616
"license": "MIT",
1717
"dependencies": {
1818
"@mercuryworkshop/wisp-js": "^0.1.1",
19-
"@tomphttp/bare-server-node": "2.0.3",
2019
"axios": "^1.7.5",
2120
"express": "^4.19.2",
2221
"ip": "^2.0.1",

pnpm-lock.yaml

-64
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

replit.nix

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
{ pkgs }: {
22
deps = [
3-
pkgs.nodejs-20_x
3+
pkgs.nodejs-22_x
44
];
55
}

sodium-static/package-lock.json

+2-2
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

sodium-static/package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"name": "sodium-static",
33
"main": "lib/index.js",
4-
"version": "2.5.0",
4+
"version": "2.7.0",
55
"type": "module",
66
"files": [
77
"public",

sodium-static/public/404.html

+2-4
Original file line numberDiff line numberDiff line change
@@ -77,8 +77,6 @@ <h3><a href="/">Sodium</a></h3>
7777
<script>
7878
async function regSW() {
7979
console.log('Waiting on SW Cache to Register...');
80-
const stockSW = "/sw.js";
81-
const dynSW = "/meteor-sw.js"
8280
const swAllowedHostnames = ["localhost", "127.0.0.1"];
8381

8482
if (
@@ -90,11 +88,11 @@ <h3><a href="/">Sodium</a></h3>
9088
if (!navigator.serviceWorker)
9189
throw new Error("Your browser doesn't support service workers.");
9290

93-
await navigator.serviceWorker.register(stockSW, {
91+
await navigator.serviceWorker.register("/sw.js", {
9492
scope: "/sw/",
9593
});
9694

97-
await navigator.serviceWorker.register(dynSW, {
95+
await navigator.serviceWorker.register("/sjw.js", {
9896
scope: "/service/",
9997
});
10098

sodium-static/public/about/index.html

+1-1
Original file line numberDiff line numberDiff line change
@@ -129,7 +129,7 @@ <h3><a href="/">Sodium</a></h3>
129129
};
130130

131131
const releaseDayWithSuffix = formattedDay + ordinalSuffix(formattedDay);
132-
versionInfoElement.textContent = `v2.5.0 Stable (Released: ${formattedMonth} ${releaseDayWithSuffix}, ${formattedYear} - Commit: `;
132+
versionInfoElement.textContent = `v2.7.0 Stable (Released: ${formattedMonth} ${releaseDayWithSuffix}, ${formattedYear} - Commit: `;
133133
const commitLink = document.createElement("a");
134134
commitLink.href = data[0].html_url;
135135
commitLink.textContent = commitId;

sodium-static/public/appframe.html

+1-1
Original file line numberDiff line numberDiff line change
@@ -105,7 +105,7 @@
105105
const script = document.createElement('script');
106106

107107
if (useProxy) {
108-
if (proxyOption && proxyOption.toLowerCase() === "Meteor") {
108+
if (proxyOption && proxyOption.toLowerCase() === "Scramjet") {
109109
script.src = `${window.location.origin}/service/route?url=${pluginUrl}`;
110110
} else {
111111
script.src = `${window.location.origin}/sw/${Ultraviolet.codec.xor.encode(pluginUrl)}`;

sodium-static/public/apps/index.html

+3-40
Original file line numberDiff line numberDiff line change
@@ -26,51 +26,14 @@
2626
<script src="assets/js/apps.js" defer></script>
2727
<script src="regcache.js" defer></script>
2828
<script>
29-
/*
30-
document.addEventListener("libcurl_load", async () => {
31-
const wispSrv = localStorage.getItem('wispServer') || "wss://tomp.app/wisp"
32-
libcurl.set_websocket(`${wispSrv}`)
33-
const appsContainer = document.getElementById("apps-container");
34-
try {
35-
const { data: apps } = await libcurl.fetch("https://api.z1g.top/api/apps").then((req) => req.json()).catch((err) => {
36-
console.error(err)
37-
return null;
38-
});
39-
if (!apps) {
40-
appsContainer.innerHTML = "<p>Failed to load apps</p>";
41-
return;
42-
}
43-
apps.forEach(async (app) => {
44-
const column = document.createElement("div");
45-
column.classList.add("column");
46-
const a = document.createElement("a");
47-
a.onclick = () => loadapp(app.url);
48-
const img = document.createElement("img");
49-
const image = await libcurl.fetch(app.icon).then((req) => req.blob()).then((blob) => URL.createObjectURL(blob));
50-
img.src = image;
51-
img.width = 150;
52-
img.height = 75;
53-
const p = document.createElement("p");
54-
p.textContent = app.name;
55-
a.appendChild(img);
56-
a.appendChild(p);
57-
column.appendChild(a);
58-
appsContainer.appendChild(column);
59-
});
60-
} catch (err) {
61-
console.error(err);
62-
appsContainer.innerHTML = "<p>Failed to load apps</p>";
63-
}
64-
});
65-
*/
6629
function loadapp(value) {
6730
let url = value.trim();
6831

6932
const proxyOption = localStorage.getItem("proxyOption");
7033

71-
if (proxyOption && proxyOption.toLowerCase() === "Meteor") {
72-
const MeteorURL = `${window.location.origin}/service/${Ultraviolet.codec.xor.encode(url)}`;
73-
sessionStorage.setItem("appUrl", MeteorURL);
34+
if (proxyOption && proxyOption.toLowerCase() === "Scramjet") {
35+
const ScramjetURL = `${window.location.origin}/service/${Ultraviolet.codec.xor.encode(url)}`;
36+
sessionStorage.setItem("appUrl", ScramjetURL);
7437
} else {
7538
if (!checkUrl(url)) {
7639
url = "https://www.google.com/search?q=" + url;

sodium-static/public/assets/css/generic.css

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
/*
22
Generic Moddable Theme
3-
(C) Copyright 2024 z1g Project
3+
(C) Copyright 2025 z1g Project
44
Licensed under the MIT LIcense
55
Want to show off your work? Submit your theme!
66
*/

0 commit comments

Comments
 (0)