A desktop browser with x402 built in: when a page asks for payment, it pays in stablecoins and shows the content.

9 downloads

dbbasic-browser/apps/browser/scripts/linux-sandbox.sh
Download zip
Clone
Clone with git
git clone https://gitstable.com/git/askrobots/dbbasic-browser.git
HTTPS
https://gitstable.com/git/askrobots/dbbasic-browser.git
SSH
ssh://git@gitstable.com:2222/askrobots/dbbasic-browser.git

Cloning needs no sign-in. Pushing over HTTPS asks for your username and an access token. SSH needs your key under SSH keys.

danq9 toolbar: Back and Forward are greyed out when there's nowhere to go cc08c7a 1 week, 2 days ago History
linux-sandbox.sh · 1.4 KB · 37 lines
1#!/bin/sh
2# SPDX-License-Identifier: Apache-2.0
3#
4# Let Chromium's page sandbox start on Linux systems that restrict unprivileged user namespaces (Ubuntu 24.04 and later).
5#
6# sudo apps/browser/scripts/linux-sandbox.sh /path/to/electron
7#
8# On those systems the browser stops at start-up with "The SUID sandbox helper binary was found, but is not configured
9# correctly". This loads an AppArmor profile that allows user namespaces for that one binary, and nothing else. The
10# sandbox itself stays on, so --no-sandbox is never needed. Run it again when the binary moves.
11#
12# Elsewhere it does nothing: no AppArmor, or no restriction.
13set -eu
14
15bin=${1:?usage: linux-sandbox.sh /path/to/electron}
16[ -x "$bin" ] || { echo "not an executable: $bin" >&2; exit 2; }
17case "$bin" in *'"'*) echo "path must not contain a double quote" >&2; exit 2 ;; esac
18
19restrict=/proc/sys/kernel/apparmor_restrict_unprivileged_userns
20if [ ! -r "$restrict" ] || [ "$(cat "$restrict")" != 1 ]; then
21 echo "user namespaces are not restricted here; nothing to do"
22 exit 0
23fi
24command -v apparmor_parser >/dev/null || { echo "apparmor_parser not found" >&2; exit 1; }
25
26profile=/etc/apparmor.d/dbbasic-electron
27cat > "$profile" <<EOF
28abi <abi/4.0>,
29include <tunables/global>
30
31profile dbbasic-electron "$bin" flags=(unconfined) {
32 userns,
33 include if exists <local/dbbasic-electron>
34}
35EOF
36apparmor_parser -r "$profile"
37echo "loaded $profile for $bin"