You should follow @Sandford_Police on X for satire on UK
Community App Maintainer
Users in this group maintain apps from the Cloudron Community Appstore https://ca.cloudron.io/
Posts
-
The regime in the UK is out of control -
VPN protection: allow other VPN apps (WireGuard, NetBird, ...) as the VPN app (small patch)Apologies for having AI write it, but probably writes better than me, now:
Thanks for VPN protection, and for the new allowlist. I'm maintaining the NetBird community package (self-hosted WireGuard mesh). Several of its users would like to protect Cloudron apps with NetBird instead of running OpenVPN alongside it.
I read through
platform/boxmaster(c36346e). The only OpenVPN-specific part is how the VPN app is selected. The rest is already provider-neutral:reverseproxy.jsallows the selected app's container IPv4/IPv6, thendeny allapp-bridge.js/vpn-access-configserves split-DNS data to whichever app is selectedapptask.jsclears the policy when that app is uninstalled
Selection is checked against
io.cloudron.openvpnin four places:network.js:setVpnAccessConfig,apps.js:setVpnAccess,VpnAccess.vueandAccess.vue.Proposal: accept any app with the
net_admincapability as the VPN app. Any app that routes VPN traffic needs that capability anyway, and the admin still has to pick it explicitly in Network > VPN access. That is the same trust decision as picking OpenVPN today. The patch also blocks only the selected VPN app (rather than every OpenVPN app) from requiring VPN access, and refuses to select an app that is itself protected.It needs no change to manifest-format. If you'd rather have an explicit opt-in, a new
vpncapability in@cloudron/manifest-formatwould work just as well with the same box changes. I'm happy to rework it either way.On the NetBird side, the plan is a separate small "routing peer" app (net_admin, masquerades mesh traffic to the Cloudron host). It would not be the management server, because that container also runs public services and must not be trusted as VPN ingress. NetBird policies would then decide which user groups can reach the protected apps. They act on the whole set, though, because every protected app shares the host's IP.
Testing: I added cases to
src/test/network-test.js. ESLint is clean on the changed files, apart from an existingno-use-before-defineatapps.js:520, and the dashboard builds. I couldn't run the mocha suite because its setup needs your Linux sudo scripts, so please treat the tests as unrun.diff --git a/dashboard/src/components/app/Access.vue b/dashboard/src/components/app/Access.vue index d04b9bf..506dc19 100644 --- a/dashboard/src/components/app/Access.vue +++ b/dashboard/src/components/app/Access.vue @@ -14,8 +14,6 @@ import UsersModel from '../../models/UsersModel.js'; import GroupsModel from '../../models/GroupsModel.js'; import { requestError, selectOptionsFromUsers } from '../../utils.js'; -const OPENVPN_APP_APPSTORE_ID = 'io.cloudron.openvpn'; - const props = defineProps([ 'app', 'refreshApp' ]); const features = inject('features'); @@ -35,8 +33,10 @@ const accessRestrictionAcl = ref({ users: [], groups: [] }); const operatorAcl = ref({ users: [], groups: [] }); const requiresVpn = ref(false); const vpnProtectionEnabled = ref(false); +const selectedVpnAppId = ref(null); -const showRequireVpn = computed(() => props.app.manifest?.id !== OPENVPN_APP_APPSTORE_ID && features.value.vpnProtection); +// the selected VPN app is the trusted ingress, so it cannot itself be VPN protected +const showRequireVpn = computed(() => features.value.vpnProtection && props.app.id !== selectedVpnAppId.value); function allowlistHasEntry(text) { return (text || '').split('\n').some((line) => line.length !== 0 && line[0] !== '#'); @@ -113,9 +113,10 @@ onMounted(async () => { requiresVpn.value = !!props.app.requiresVpn; - if (showRequireVpn.value) { + if (features.value.vpnProtection) { [error, result] = await networkModel.getVpnAccessConfig(); if (error) return console.error(error); + selectedVpnAppId.value = result.vpnAppId || null; vpnProtectionEnabled.value = !!result.vpnAppId || allowlistHasEntry(result.allowlist); } }); diff --git a/dashboard/src/components/network/VpnAccess.vue b/dashboard/src/components/network/VpnAccess.vue index f0079bf..b845ecd 100644 --- a/dashboard/src/components/network/VpnAccess.vue +++ b/dashboard/src/components/network/VpnAccess.vue @@ -13,6 +13,11 @@ const { t } = useI18n(); const OPENVPN_APP_APPSTORE_ID = 'io.cloudron.openvpn'; +// keep in sync with apps.isVpnProvider() in the box code +function isVpnProvider(manifest) { + return manifest?.id === OPENVPN_APP_APPSTORE_ID || (manifest?.capabilities || []).includes('net_admin'); +} + // UI presets map onto the two-mode wire model: full | custom(+cidrs) | custom(no cidrs) const ROUTING_FULL = 'full'; const ROUTING_APPS_ONLY = 'apps-only'; @@ -107,7 +112,7 @@ async function loadData() { installedApps.value = apps; vpnApps.value = apps - .filter((app) => app.manifest?.id === OPENVPN_APP_APPSTORE_ID) + .filter((app) => isVpnProvider(app.manifest) && !app.requiresVpn) .map((app) => ({ id: app.id, label: app.label || app.fqdn || app.id })); [error, apps] = await networkModel.getVpnAccessConfig(); diff --git a/src/apps.js b/src/apps.js index d2f0b4e..a042f55 100644 --- a/src/apps.js +++ b/src/apps.js @@ -1150,15 +1150,22 @@ async function setOperators(app, operators, auditSource) { await eventlog.add(eventlog.ACTION_APP_CONFIGURE, auditSource, { appId, app, operators }); } +// an app can be selected as the VPN app if it can route traffic (OpenVPN, WireGuard, NetBird, ...). +// the admin still has to select it explicitly, after which its container IPs are trusted as VPN ingress +function isVpnProvider(manifest) { + assert.strictEqual(typeof manifest, 'object'); + + return manifest.id === constants.OPENVPN_APP_APPSTORE_ID || (manifest.capabilities || []).includes('net_admin'); +} + async function setVpnAccess(app, enable, auditSource) { assert.strictEqual(typeof app, 'object'); assert.strictEqual(typeof enable, 'boolean'); assert.strictEqual(typeof auditSource, 'object'); - if (app.manifest.id === constants.OPENVPN_APP_APPSTORE_ID) throw new BoxError(BoxError.BAD_FIELD, 'VPN app cannot require VPN access'); - if (enable) { const config = await settings.getJson(settings.VPN_ACCESS_CONFIG_KEY); + if (config?.vpnAppId === app.id) throw new BoxError(BoxError.BAD_FIELD, 'VPN app cannot require VPN access'); const allowlist = network.parseVpnAccessAllowlist(await network.getVpnAccessAllowlist()); if (!config?.vpnAppId && allowlist.length === 0) throw new BoxError(BoxError.BAD_FIELD, 'VPN app is not configured'); } @@ -3126,6 +3133,7 @@ export default { setAccessRestriction, setOperators, + isVpnProvider, setVpnAccess, setCrontab, setUpstreamUri, diff --git a/src/network.js b/src/network.js index 2d1d1e9..0ebb6d7 100644 --- a/src/network.js +++ b/src/network.js @@ -185,7 +185,8 @@ async function setVpnAccessConfig(policy, auditSource, allowlist) { const vpnApp = await apps.get(vpnAppId); if (!vpnApp) throw new BoxError(BoxError.BAD_FIELD, 'vpnAppId not found'); - if (vpnApp.manifest.id !== constants.OPENVPN_APP_APPSTORE_ID) throw new BoxError(BoxError.BAD_FIELD, 'vpnAppId must be an OpenVPN app'); + if (!apps.isVpnProvider(vpnApp.manifest)) throw new BoxError(BoxError.BAD_FIELD, 'vpnAppId must be a VPN app (OpenVPN or an app with the net_admin capability)'); + if (vpnApp.requiresVpn) throw new BoxError(BoxError.BAD_FIELD, 'VPN app cannot itself require VPN access'); validateTunnelRouting(tunnelRouting); } diff --git a/src/test/network-test.js b/src/test/network-test.js index ea34bd2..d7e6d18 100644 --- a/src/test/network-test.js +++ b/src/test/network-test.js @@ -210,11 +210,53 @@ describe('Network', function () { assert.equal(error.reason, BoxError.BAD_FIELD); }); - it('rejects non-openvpn app', async function () { + it('rejects an app that cannot route traffic', async function () { const [error] = await safe(network.setVpnAccessConfig({ vpnAppId: common.app.id, tunnelRouting: { mode: 'full', customCidrs: [] } }, auditSource)); assert.equal(error.reason, BoxError.BAD_FIELD); }); + describe('with a net_admin VPN app', function () { + const meshAppId = 'network-mesh-vpn-app-id'; + + before(async function () { + const meshManifest = { ...common.manifest, id: 'io.example.meshvpn', capabilities: [ 'net_admin' ] }; + const meshData = { + ...common.app, + id: meshAppId, + appStoreId: '', + installationState: constants.APP_ISTATE_INSTALLED, + subdomain: 'network-mesh-vpn', + domain: common.domain.domain, + manifest: meshManifest, + portBindings: {}, + secondaryDomains: [], + redirectDomains: [], + aliasDomains: [], + containerId: 'network-mesh-vpn-container-id', + containerIp: '172.18.88.97' + }; + await apps.add(meshAppId, meshData.appStoreId, '', meshManifest, meshData.subdomain, meshData.domain, {}, meshData); + }); + + after(async function () { + await network.setVpnAccessConfig(null, auditSource); + await apps.del(meshAppId); + }); + + it('can select it as the VPN app', async function () { + await network.setVpnAccessConfig({ vpnAppId: meshAppId, tunnelRouting: { mode: 'custom', customCidrs: [] } }, auditSource); + assert.equal((await network.getVpnAccessConfig()).vpnAppId, meshAppId); + }); + + it('cannot select it while it requires VPN access itself', async function () { + await network.setVpnAccessConfig(null, auditSource); + await apps.update(meshAppId, { requiresVpn: true }); + const [error] = await safe(network.setVpnAccessConfig({ vpnAppId: meshAppId, tunnelRouting: { mode: 'full', customCidrs: [] } }, auditSource)); + assert.equal(error.reason, BoxError.BAD_FIELD); + await apps.update(meshAppId, { requiresVpn: false }); + }); + }); + it('rejects invalid tunnel routing', async function () { const [error] = await safe(network.setVpnAccessConfig({ vpnAppId, tunnelRouting: { mode: 'full' } }, auditSource)); assert.equal(error.reason, BoxError.BAD_FIELD);Would you consider this, or something like it? Thanks!
-
OpenTubeX Sync Server - Self-Hosted, End-to-End Encrypted Sync Backend for the OpenTubeX YouTube Client@Teiluj Thanks for posting this. I am definitely interested in packaging it but am vv busy. I shall try, if nobody else is interested. Will need a week or so.
-
The regime in the UK is out of control -
🚀 HarnessRouter: community package now available0.2.0 is out: please update, and rotate your keys if you ran 0.1.0.
Package 0.2.0 moves HarnessRouter Community Edition from 0.37.13 to 0.41.16. It is a security release.
0.1.0 was affected by upstream advisories fixed in that span:
- GHSA-2464-fhr4-w9xw and GHSA-2xp9-vwfh-vxw4: remote code execution through the console's image optimiser,
with no sign-in needed. The optimiser is now off. - The critical fix in upstream 0.37.17: anyone holding an API key could read any file as root, including the
internal key, the secret key, provider keys and the databases.
If you installed 0.1.0, upstream asks you to rotate:
- the secret key (
HR_SECRET_KEY; in this package/app/data/.secrets/secret-key), - the console password,
- every provider key and every API key,
- MCP server tokens, if untrusted agents ran.
If auto-update is on, your install has already moved or will at the next check. If it is off, update from the
app's Updates tab. Cloudron takes a backup first; keep it, because rolling back to 0.1.0 is not clean (some stored
tokens move to a form 0.37.13 cannot read). The first start reinstalls the agent tools once, so allow several
minutes before the console answers.Also in 0.2.0: downloads at first start and environment builds run as firewalled unprivileged users, root is
firewalled from Cloudron's internal network (an MCP server must be reachable at a public address or through this
Cloudron's HTTPS front door), and the listing now says plainly that this package is unofficial and not supported
by the HarnessRouter project.Full notes: https://github.com/OrcVole/harnessrouter-cloudron/blob/main/CHANGELOG.md
- GHSA-2464-fhr4-w9xw and GHSA-2xp9-vwfh-vxw4: remote code execution through the console's image optimiser,
-
uMap - create interactive maps with OpenStreetMapHello @thomasroy and welcome to the Cloudron community forum
-
Cloudron Dashboard: App Groupingbumping this issue.
-
Social Media Handles and Community Apps -
Define custom well-known entries via CloudronManifest.json@girish I tested this on production with Element X on Android and iOS.
When the Matrix well-known is served by the app, calls work. When it is served by Cloudron, calls fail with
Call is not supported ... MISSING_MATRIX_RTC_FOCUS. This also happens after I set matrix/client through the API so the content is identical to the app's, includingorg.matrix.msc4143.rtc_foci. Removing the dashboard entry makes calls work again.The remaining difference seems to be the header. The app sends
Access-Control-Allow-Origin: *, Cloudron'swell-knownhandler does not. Element Call runs inside a webview and reads/.well-known/matrix/clientwithfetch(), so without the header the browser blocks the response and Element Call can't see the focus. The Matrix spec also asks for this header on the clientwell-known.So the apex is still blocked for me. Two small changes should free it:
- Add
Access-Control-Allow-Origin: *to the matrix well-known responses. - Allow custom
JSONformatrix/client. The dashboard has a single "Matrix server location" field that generates a fixed template withoutrtc_foci, although the API already accepts and serves custom content.
- Add
-
Domain aliases for emailHello @matthiaskurz
Is that not what I have described, except the complete "Domain Alias"?
Instead of only allowing 1x domain to be selected, either allow anAll DomainsorSelect Domainsfor aliases.
Like that?

Member List
|
2,983
Posts
4,325
Reputation
|
|
3,385
Posts
4,968
Reputation
|
|
7
Posts
21
Reputation
|
|
965
Posts
1,237
Reputation
|
|
38
Posts
92
Reputation
|