mirror of
https://github.com/sunknudsen/privacy-guides.git
synced 2025-02-23 01:03:59 +00:00
Fixed missing .electrum directory bug
This commit is contained in:
parent
1a0cb0836f
commit
3892b1c10b
@ -585,7 +585,7 @@ $ sudo dphys-swapfile uninstall
|
|||||||
$ sudo systemctl disable dphys-swapfile.service
|
$ sudo systemctl disable dphys-swapfile.service
|
||||||
```
|
```
|
||||||
|
|
||||||
#### Remove `dphys-swapfile` `fake-hwclock` and `logrotate`
|
#### Remove `dphys-swapfile`, `fake-hwclock` and `logrotate`
|
||||||
|
|
||||||
```shell
|
```shell
|
||||||
sudo apt remove -y --purge dphys-swapfile fake-hwclock logrotate
|
sudo apt remove -y --purge dphys-swapfile fake-hwclock logrotate
|
||||||
@ -594,25 +594,21 @@ sudo apt remove -y --purge dphys-swapfile fake-hwclock logrotate
|
|||||||
#### Link `/etc/console-setup` to `/tmp/console-setup`
|
#### Link `/etc/console-setup` to `/tmp/console-setup`
|
||||||
|
|
||||||
```console
|
```console
|
||||||
$ sudo mv /etc/console-setup /tmp/console-setup
|
$ sudo rm -fr /etc/console-setup
|
||||||
|
|
||||||
$ sudo ln -s /tmp/console-setup /etc/console-setup
|
$ sudo ln -s /tmp/console-setup /etc/console-setup
|
||||||
```
|
```
|
||||||
|
|
||||||
#### Link `/etc/resolv.conf` to `/tmp/resolv.conf`
|
#### Link `/home/pi/.electrum` to `/tmp/pi/.electrum`
|
||||||
|
|
||||||
```console
|
```console
|
||||||
$ sudo mv /etc/resolv.conf /tmp/resolv.conf
|
$ ln -s /tmp/pi/.electrum /home/pi/.electrum
|
||||||
|
|
||||||
$ sudo ln -s /tmp/resolv.conf /etc/resolv.conf
|
|
||||||
```
|
```
|
||||||
|
|
||||||
#### Link `/home/pi/.gnupg` to `/tmp/pi/.gnupg`
|
#### Link `/home/pi/.gnupg` to `/tmp/pi/.gnupg`
|
||||||
|
|
||||||
```console
|
```console
|
||||||
$ mkdir -m 700 /tmp/pi
|
$ rm -fr /home/pi/.gnupg
|
||||||
|
|
||||||
$ mv /home/pi/.gnupg /tmp/pi/.gnupg
|
|
||||||
|
|
||||||
$ ln -s /tmp/pi/.gnupg /home/pi/.gnupg
|
$ ln -s /tmp/pi/.gnupg /home/pi/.gnupg
|
||||||
```
|
```
|
||||||
@ -620,7 +616,7 @@ $ ln -s /tmp/pi/.gnupg /home/pi/.gnupg
|
|||||||
#### Enable `tmp.mount` service
|
#### Enable `tmp.mount` service
|
||||||
|
|
||||||
```console
|
```console
|
||||||
$ echo -e "D /tmp 1777 root root -\nD /tmp/console-setup 1700 root root -\nD /tmp/pi 1700 pi pi -\nD /tmp/pi/.gnupg 1700 pi pi -\nD /var/tmp 1777 root root -" | sudo tee /etc/tmpfiles.d/tmp.conf
|
$ echo -e "D /tmp 1777 root root -\nD /tmp/console-setup 1700 root root -\nD /tmp/pi 1700 pi pi -\nD /tmp/pi/.electrum 1700 pi pi -\nD /tmp/pi/.gnupg 1700 pi pi -\nD /var/tmp 1777 root root -" | sudo tee /etc/tmpfiles.d/tmp.conf
|
||||||
|
|
||||||
$ sudo cp /usr/share/systemd/tmp.mount /etc/systemd/system/
|
$ sudo cp /usr/share/systemd/tmp.mount /etc/systemd/system/
|
||||||
|
|
||||||
|
@ -13,15 +13,19 @@ read -rs password
|
|||||||
|
|
||||||
export password=$password
|
export password=$password
|
||||||
|
|
||||||
printf "%s\n" "Running unit tests…"
|
if [ -n "$1" ]; then
|
||||||
|
printf "%s\n" "Running unit test…"
|
||||||
expect ./tests/bip39.exp
|
expect ./tests/$1
|
||||||
expect ./tests/electrum.exp
|
else
|
||||||
expect ./tests/default.exp
|
printf "%s\n" "Running unit tests…"
|
||||||
expect ./tests/shamir.exp
|
expect ./tests/bip39.exp
|
||||||
expect ./tests/shamir-2-of-3.exp
|
expect ./tests/electrum.exp
|
||||||
expect ./tests/clone.exp
|
expect ./tests/default.exp
|
||||||
expect ./tests/convert-default-to-shamir-2-of-3.exp
|
expect ./tests/shamir.exp
|
||||||
expect ./tests/convert-shamir-2-of-3-to-default.exp
|
expect ./tests/shamir-2-of-3.exp
|
||||||
expect ./tests/duplicate.exp
|
expect ./tests/clone.exp
|
||||||
expect ./tests/secure-erase.exp
|
expect ./tests/convert-default-to-shamir-2-of-3.exp
|
||||||
|
expect ./tests/convert-shamir-2-of-3-to-default.exp
|
||||||
|
expect ./tests/duplicate.exp
|
||||||
|
expect ./tests/secure-erase.exp
|
||||||
|
fi
|
||||||
|
@ -33,6 +33,9 @@ expect {
|
|||||||
-re {([a-z]+ ?){24}} {
|
-re {([a-z]+ ?){24}} {
|
||||||
test_ok true
|
test_ok true
|
||||||
}
|
}
|
||||||
|
eof {
|
||||||
|
test_failed
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
test_label "Should validate valid BIP39 mnemonic"
|
test_label "Should validate valid BIP39 mnemonic"
|
||||||
@ -69,6 +72,9 @@ expect {
|
|||||||
-re {Please type passphrase and press enter} {
|
-re {Please type passphrase and press enter} {
|
||||||
test_ok true
|
test_ok true
|
||||||
}
|
}
|
||||||
|
eof {
|
||||||
|
test_failed
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
test_label "Should fail to validate invalid BIP39 mnemonic"
|
test_label "Should fail to validate invalid BIP39 mnemonic"
|
||||||
@ -105,4 +111,7 @@ expect {
|
|||||||
-re {Invalid BIP39 mnemonic} {
|
-re {Invalid BIP39 mnemonic} {
|
||||||
test_ok true
|
test_ok true
|
||||||
}
|
}
|
||||||
|
eof {
|
||||||
|
test_failed
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -39,6 +39,9 @@ expect {
|
|||||||
-re {Secrets do not match} {
|
-re {Secrets do not match} {
|
||||||
test_ok
|
test_ok
|
||||||
}
|
}
|
||||||
|
eof {
|
||||||
|
test_failed
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
test_label "Should fails to backup secret using passphrases that do not match"
|
test_label "Should fails to backup secret using passphrases that do not match"
|
||||||
@ -87,6 +90,9 @@ expect {
|
|||||||
-re {Passphrases do not match} {
|
-re {Passphrases do not match} {
|
||||||
test_ok
|
test_ok
|
||||||
}
|
}
|
||||||
|
eof {
|
||||||
|
test_failed
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
test_label "Should backup secret showing passphrase"
|
test_label "Should backup secret showing passphrase"
|
||||||
@ -157,6 +163,9 @@ expect {
|
|||||||
-re {Done} {
|
-re {Done} {
|
||||||
test_ok
|
test_ok
|
||||||
}
|
}
|
||||||
|
eof {
|
||||||
|
test_failed
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
test_label "Should restore secret"
|
test_label "Should restore secret"
|
||||||
|
@ -26,4 +26,7 @@ expect {
|
|||||||
-re {([a-z]+ ?){24}} {
|
-re {([a-z]+ ?){24}} {
|
||||||
test_ok true
|
test_ok true
|
||||||
}
|
}
|
||||||
|
eof {
|
||||||
|
test_failed
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -50,6 +50,9 @@ expect {
|
|||||||
-re {Done} {
|
-re {Done} {
|
||||||
test_ok
|
test_ok
|
||||||
}
|
}
|
||||||
|
eof {
|
||||||
|
test_failed
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
test_label "Should secure erase flash drive using single round random overwrite and zero overwrite"
|
test_label "Should secure erase flash drive using single round random overwrite and zero overwrite"
|
||||||
@ -88,4 +91,7 @@ expect {
|
|||||||
-re {Done} {
|
-re {Done} {
|
||||||
test_ok
|
test_ok
|
||||||
}
|
}
|
||||||
|
eof {
|
||||||
|
test_failed
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
@ -137,6 +137,9 @@ expect {
|
|||||||
-re {Done} {
|
-re {Done} {
|
||||||
test_ok
|
test_ok
|
||||||
}
|
}
|
||||||
|
eof {
|
||||||
|
test_failed
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
test_label "Should restore secret using Shamir Secret Sharing"
|
test_label "Should restore secret using Shamir Secret Sharing"
|
||||||
|
Loading…
x
Reference in New Issue
Block a user