Initial Tails Support / Center align profile attributes / biotext

This commit is contained in:
Sarah Jamie Lewis 2023-04-04 19:57:35 -07:00 committed by Gitea
parent 267b1b09b1
commit db421f2691
4 changed files with 88 additions and 3 deletions

View File

@ -113,15 +113,15 @@ class _PeerSettingsViewState extends State<PeerSettingsView> {
child: Column(children: [
Padding(
padding: EdgeInsets.all(1),
child: SelectableText(Provider.of<ContactInfoState>(context, listen: false).attributes[0] ?? ""),
child: SelectableText(Provider.of<ContactInfoState>(context, listen: false).attributes[0] ?? "", textAlign: TextAlign.center,),
),
Padding(
padding: EdgeInsets.all(1),
child: SelectableText(Provider.of<ContactInfoState>(context, listen: false).attributes[1] ?? ""),
child: SelectableText(Provider.of<ContactInfoState>(context, listen: false).attributes[1] ?? "", textAlign: TextAlign.center,),
),
Padding(
padding: EdgeInsets.all(1),
child: SelectableText(Provider.of<ContactInfoState>(context, listen: false).attributes[2] ?? ""),
child: SelectableText(Provider.of<ContactInfoState>(context, listen: false).attributes[2] ?? "", textAlign: TextAlign.center,),
)
]))
]),

55
linux/cwtch-tails.yml Normal file
View File

@ -0,0 +1,55 @@
---
# TODO: This can likely be restricted even further, especially in regards to the ADD_ONION pattern
- apparmor-profiles:
- '/home/amnesia/.local/lib/cwtch/cwtch'
users:
- 'amnesia'
commands:
AUTHCHALLENGE:
- 'SAFECOOKIE .*'
SETEVENTS:
- 'CIRC WARN ERR'
- 'CIRC ORCONN INFO NOTICE WARN ERR HS_DESC HS_DESC_CONTENT'
GETINFO:
- 'net/listeners/socks'
GETCONF:
- 'DisableNetwork'
SETCONF:
- 'DisableNetwork.*'
ADD_ONION:
- '.*'
DEL_ONION:
- '.+'
HSFETCH:
- '.+'
events:
CIRC:
suppress: true
ORCONN:
suppress: true
INFO:
suppress: true
NOTICE:
suppress: true
WARN:
suppress: true
ERR:
suppress: true
HS_DESC:
response:
- pattern: '650 HS_DESC CREATED (\S+) (\S+) (\S+) \S+ (.+)'
replacement: '650 HS_DESC CREATED {} {} {} redacted {}'
- pattern: '650 HS_DESC UPLOAD (\S+) (\S+) .*'
replacement: '650 HS_DESC UPLOAD {} {} redacted redacted'
- pattern: '650 HS_DESC UPLOADED (\S+) (\S+) .+'
replacement: '650 HS_DESC UPLOADED {} {} redacted'
- pattern: '650 HS_DESC REQUESTED (\S+) NO_AUTH'
replacement: '650 HS_DESC REQUESTED {} NO_AUTH'
- pattern: '650 HS_DESC REQUESTED (\S+) NO_AUTH \S+ \S+'
replacement: '650 HS_DESC REQUESTED {} NO_AUTH redacted redacted'
- pattern: '650 HS_DESC RECEIVED (\S+) NO_AUTH \S+ \S+'
replacement: '650 HS_DESC RECEIVED {} NO_AUTH redacted redacted'
- pattern: '.*'
replacement: ''
HS_DESC_CONTENT:
suppress: true

3
linux/cwtch.tails.sh Executable file
View File

@ -0,0 +1,3 @@
#!/bin/sh
# Start Cwtch with Tails
exec env CWTCH_TAILS=true LD_LIBRARY_PATH=~/.local/lib/cwtch/:~/.local/lib/cwtch/Tor ~/.local/lib/cwtch/cwtch

27
linux/install-tails.sh Executable file
View File

@ -0,0 +1,27 @@
#!/bin/sh
mkdir -p ~/.local/bin
sed "s|~|$HOME|g" cwtch.home.sh > ~/.local/bin/cwtch
chmod a+x ~/.local/bin/cwtch
mkdir -p ~/.local/share/icons
cp cwtch.png ~/.local/share/icons
mkdir -p ~/.local/share/cwtch
cp -r data ~/.local/share/cwtch
mkdir -p ~/.local/lib/cwtch
cp -r lib/* ~/.local/lib/cwtch
mkdir -p ~/.local/share/applications
sed "s|~|$HOME|g" cwtch.home.desktop > $HOME/.local/share/applications/cwtch.desktop
chmod a+x $HOME/.local/share/applications/cwtch.desktop
# Tails needs to be have been setup up with an Administration account
# https://tails.boum.org/doc/first_steps/welcome_screen/administration_password/
# Make Auth Cookie Readable
sudo chmod o+r /var/run/tor/control.authcookie
# Copy Onion Grater Config
sudo cp cwtch-tails.yml /etc/onion-grater.d/cwtch.yml
# Restart Onion Grater so the Config Takes effect
sudo systemctl restart onion-grater.service