mirror of
https://github.com/jayofelony/pwnagotchi.git
synced 2025-07-01 18:37:27 -04:00
Merge https://github.com/evilsocket/pwnagotchi into win_connection_share.ps1
This commit is contained in:
@ -3,60 +3,62 @@
|
|||||||
- 127.0.0.1
|
- 127.0.0.1
|
||||||
become: yes
|
become: yes
|
||||||
vars:
|
vars:
|
||||||
pwn_hostname: "pwnagotchi"
|
pwnagotchi:
|
||||||
pwn_version: "master"
|
hostname: "{{ lookup('env', 'PWN_HOSTNAME') | default('pwnagotchi', true) }}"
|
||||||
|
version: "{{ lookup('env', 'PWN_VERSION') | default('master', true) }} "
|
||||||
tasks:
|
system:
|
||||||
|
boot_options:
|
||||||
- name: selected hostname
|
- "dtoverlay=dwc2"
|
||||||
debug:
|
- "dtparam=spi=on"
|
||||||
msg: "{{ pwn_hostname }}"
|
- "dtoverlay=spi1-3cs"
|
||||||
|
- "dtoverlay=pi3-disable-bt"
|
||||||
- name: build version
|
- "dtparam=audio=off"
|
||||||
debug:
|
services:
|
||||||
msg: "{{ pwn_version }}"
|
enable:
|
||||||
|
- dphys-swapfile.service
|
||||||
- name: change hostname
|
- getty@ttyGS0.service
|
||||||
hostname:
|
disable:
|
||||||
name: "{{pwn_hostname}}"
|
- apt-daily.timer
|
||||||
|
- apt-daily.service
|
||||||
- name: add hostname to /etc/hosts
|
- apt-daily-upgrade.timer
|
||||||
lineinfile:
|
- apt-daily-upgrade.service
|
||||||
dest: /etc/hosts
|
- wpa_supplicant.service
|
||||||
regexp: '^127\.0\.0\.1[ \t]+localhost'
|
- bluetooth.service
|
||||||
line: '127.0.0.1 localhost {{pwn_hostname}} {{pwn_hostname}}.local'
|
- triggerhappy.service
|
||||||
state: present
|
- ifup@wlan0.service
|
||||||
|
|
||||||
- name: Add re4son-kernel repo key
|
|
||||||
apt_key:
|
|
||||||
url: https://re4son-kernel.com/keys/http/archive-key.asc
|
|
||||||
state: present
|
|
||||||
|
|
||||||
- name: Add re4son-kernel repository
|
|
||||||
apt_repository:
|
|
||||||
repo: deb http://http.re4son-kernel.com/re4son/ kali-pi main
|
|
||||||
state: present
|
|
||||||
|
|
||||||
- name: update apt package cache
|
|
||||||
apt:
|
|
||||||
update_cache: yes
|
|
||||||
|
|
||||||
- name: upgrade apt distro
|
|
||||||
apt:
|
|
||||||
upgrade: dist
|
|
||||||
|
|
||||||
- name: install packages
|
|
||||||
apt:
|
|
||||||
name: "{{ packages }}"
|
|
||||||
state: present
|
|
||||||
vars:
|
|
||||||
packages:
|
packages:
|
||||||
|
pip:
|
||||||
|
install:
|
||||||
|
- inky
|
||||||
|
- smbus2
|
||||||
|
- absl-py>=0.1.6
|
||||||
|
- enum34
|
||||||
|
- gast==0.2.2
|
||||||
|
- google_pasta
|
||||||
|
- opt_einsum
|
||||||
|
- scapy
|
||||||
|
- gym
|
||||||
|
- keras_applications>=1.0.6
|
||||||
|
- keras_preprocessing>=1.0.5
|
||||||
|
- stable-baselines
|
||||||
|
- file_read_backwards
|
||||||
|
- tensorflow_estimator>=1.14.0,<1.15.0
|
||||||
|
- tensorboard>=1.13.0,<1.14.0
|
||||||
|
apt:
|
||||||
|
remove:
|
||||||
|
- rasberrypi-net-mods
|
||||||
|
- dhcpcd5
|
||||||
|
- triggerhappy
|
||||||
|
- wpa_supplicant
|
||||||
|
- nfs-common
|
||||||
|
install:
|
||||||
- vim
|
- vim
|
||||||
- screen
|
- screen
|
||||||
- golang
|
- golang
|
||||||
- git
|
- git
|
||||||
- build-essential
|
- build-essential
|
||||||
- python3-pip
|
- python3-pip
|
||||||
|
- unzip
|
||||||
- gawk
|
- gawk
|
||||||
- libopenmpi-dev
|
- libopenmpi-dev
|
||||||
- libatlas-base-dev
|
- libatlas-base-dev
|
||||||
@ -87,42 +89,114 @@
|
|||||||
- fonts-dejavu
|
- fonts-dejavu
|
||||||
- fonts-dejavu-core
|
- fonts-dejavu-core
|
||||||
- fonts-dejavu-extra
|
- fonts-dejavu-extra
|
||||||
|
- python3-crypto
|
||||||
|
- python3-requests
|
||||||
|
- python3-yaml
|
||||||
|
- python3-smbus
|
||||||
|
- python3-inkyphat
|
||||||
|
- python3-numpy
|
||||||
|
- python3-pil
|
||||||
|
- python3-tweepy
|
||||||
|
- python3-opencv
|
||||||
|
- python3-termcolor
|
||||||
|
- python3-astor
|
||||||
|
- python3-backports.weakref
|
||||||
|
- python3-h5py
|
||||||
|
- python3-six
|
||||||
|
- python3-protobuf
|
||||||
|
- python3-wrapt
|
||||||
|
- python3-wheel
|
||||||
|
- python3-mock
|
||||||
|
- python3-scipy
|
||||||
|
- python3-cloudpickle
|
||||||
|
|
||||||
|
bettercap:
|
||||||
|
query: "assets[?contains(name, 'armv6l')].browser_download_url"
|
||||||
|
|
||||||
|
tasks:
|
||||||
|
|
||||||
|
- name: selected hostname
|
||||||
|
debug:
|
||||||
|
msg: "{{ pwnagotchi.hostname }}"
|
||||||
|
|
||||||
|
- name: build version
|
||||||
|
debug:
|
||||||
|
msg: "{{ pwnagotchi.version }}"
|
||||||
|
|
||||||
|
- name: change hostname
|
||||||
|
hostname:
|
||||||
|
name: "{{pwnagotchi.hostname}}"
|
||||||
|
|
||||||
|
- name: add hostname to /etc/hosts
|
||||||
|
lineinfile:
|
||||||
|
dest: /etc/hosts
|
||||||
|
regexp: '^127\.0\.0\.1[ \t]+localhost'
|
||||||
|
line: '127.0.0.1 localhost {{pwnagotchi.hostname}} {{pwnagotchi.hostname}}.local'
|
||||||
|
state: present
|
||||||
|
|
||||||
|
- name: Add re4son-kernel repo key
|
||||||
|
apt_key:
|
||||||
|
url: https://re4son-kernel.com/keys/http/archive-key.asc
|
||||||
|
state: present
|
||||||
|
|
||||||
|
- name: Add re4son-kernel repository
|
||||||
|
apt_repository:
|
||||||
|
repo: deb http://http.re4son-kernel.com/re4son/ kali-pi main
|
||||||
|
state: present
|
||||||
|
|
||||||
|
- name: update apt package cache
|
||||||
|
apt:
|
||||||
|
update_cache: yes
|
||||||
|
|
||||||
|
- name: remove unecessary apt packages
|
||||||
|
apt:
|
||||||
|
name: "{{ packages.apt.remove }}"
|
||||||
|
state: absent
|
||||||
|
purge: yes
|
||||||
|
|
||||||
|
- name: upgrade apt distro
|
||||||
|
apt:
|
||||||
|
upgrade: dist
|
||||||
|
|
||||||
|
- name: install packages
|
||||||
|
apt:
|
||||||
|
name: "{{ packages.apt.install }}"
|
||||||
|
state: present
|
||||||
|
|
||||||
- name: configure dphys-swapfile
|
- name: configure dphys-swapfile
|
||||||
file:
|
file:
|
||||||
path: /etc/dphys-swapfile
|
path: /etc/dphys-swapfile
|
||||||
content: "CONF_SWAPSIZE=1024"
|
content: "CONF_SWAPSIZE=1024"
|
||||||
|
|
||||||
- name: disable unecessary services
|
- name: acquire python3 pip target
|
||||||
systemd:
|
command: "python3 -c 'import sys;print(sys.path.pop())'"
|
||||||
name: "{{services}}"
|
register: pip_target
|
||||||
state: stopped
|
|
||||||
enabled: no
|
|
||||||
vars:
|
|
||||||
services:
|
|
||||||
- apt-daily.timer
|
|
||||||
- apt-daily.service
|
|
||||||
- apt-daily-upgrade.timer
|
|
||||||
- apt-daily-upgrade.service
|
|
||||||
- bluetooth.service
|
|
||||||
- triggerhappy.service
|
|
||||||
|
|
||||||
- name: enable dphys-swapfile service
|
- name: install pip packages
|
||||||
systemd:
|
pip:
|
||||||
name: dphys-swapfile.service
|
name: "{{packages.pip.install}}"
|
||||||
state: started
|
extra_args: "--no-deps --extra-index-url=https://www.piwheels.hostedpi.com/simple/ --prefer-binary --no-cache-dir --platform=armv6l --target={{ pip_target.stdout }}"
|
||||||
enabled: yes
|
|
||||||
|
|
||||||
- name: build bettercap
|
- name: install grpcio
|
||||||
command: go get -u github.com/bettercap/bettercap
|
command: "pip3 install --no-deps --extra-index-url=https://www.piwheels.hostedpi.com/simple/ --no-cache-dir --prefer-binary --platform=armv6l --only-binary=:all: --target={{ pip_target.stdout }} https://www.piwheels.hostedpi.com/simple/grpcio/grpcio-1.24.1-cp37-cp37m-linux_armv6l.whl"
|
||||||
environment:
|
|
||||||
GOPATH: /root/go
|
|
||||||
GOROOT: /usr/lib/go
|
|
||||||
|
|
||||||
- name: install bettercap
|
- name: install tensorflow
|
||||||
copy:
|
command: "pip3 install --no-deps --extra-index-url=https://www.piwheels.hostedpi.com/simple/ --no-cache-dir --prefer-binary --platform=armv6l --only-binary=:all: --target={{ pip_target.stdout }} https://www.piwheels.org/simple/tensorflow/tensorflow-1.13.1-cp37-none-linux_armv6l.whl"
|
||||||
src: /root/go/bin/bettercap
|
|
||||||
dest: /usr/bin/bettercap
|
- name: fetch bettercap release information
|
||||||
|
uri:
|
||||||
|
url: https://api.github.com/repos/bettercap/bettercap/releases/latest
|
||||||
|
return_content: yes
|
||||||
|
register: bettercap_release
|
||||||
|
|
||||||
|
- name: download and install bettercap
|
||||||
|
unarchive:
|
||||||
|
src: "{{ bettercap_release.content | from_json | json_query(bettercap.query) | first }}"
|
||||||
|
dest: /usr/bin
|
||||||
|
remote_src: yes
|
||||||
|
exclude:
|
||||||
|
- README.md
|
||||||
|
- LICENSE.md
|
||||||
mode: 0755
|
mode: 0755
|
||||||
|
|
||||||
- name: clone bettercap caplets
|
- name: clone bettercap caplets
|
||||||
@ -151,10 +225,6 @@
|
|||||||
path: /tmp/pwnagotchi
|
path: /tmp/pwnagotchi
|
||||||
state: absent
|
state: absent
|
||||||
|
|
||||||
- name: install python modules
|
|
||||||
pip:
|
|
||||||
requirements: /root/pwnagotchi/scripts/requirements.txt
|
|
||||||
|
|
||||||
- name: create cpuusage script
|
- name: create cpuusage script
|
||||||
copy:
|
copy:
|
||||||
dest: /usr/bin/cpuusage
|
dest: /usr/bin/cpuusage
|
||||||
@ -249,11 +319,7 @@
|
|||||||
insertafter: EOF
|
insertafter: EOF
|
||||||
line: '{{ item }}'
|
line: '{{ item }}'
|
||||||
with_items:
|
with_items:
|
||||||
- "dtoverlay=dwc2"
|
- "{{system.boot_options}}"
|
||||||
- "dtparam=spi=on"
|
|
||||||
- "dtoverlay=spi1-3cs"
|
|
||||||
- "dtoverlay=pi3-disable-bt"
|
|
||||||
- "dtparam=audio=off"
|
|
||||||
|
|
||||||
- name: change root partition
|
- name: change root partition
|
||||||
replace:
|
replace:
|
||||||
@ -269,7 +335,7 @@
|
|||||||
state: present
|
state: present
|
||||||
backup: no
|
backup: no
|
||||||
regexp: '(.*)$'
|
regexp: '(.*)$'
|
||||||
line: '\1 modules-load=dwc2,g_ether'
|
line: '\1 modules-load=dwc2,g_cdc'
|
||||||
|
|
||||||
- name: configure ssh
|
- name: configure ssh
|
||||||
lineinfile:
|
lineinfile:
|
||||||
@ -281,7 +347,7 @@
|
|||||||
- name: configure motd
|
- name: configure motd
|
||||||
copy:
|
copy:
|
||||||
dest: /etc/motd
|
dest: /etc/motd
|
||||||
content: "(◕‿‿◕) {{pwn_hostname}} (pwnagotchi-{{pwn_version}})"
|
content: "(◕‿‿◕) {{pwnagotchi.hostname}} (pwnagotchi-{{pwnagotchi.version}})"
|
||||||
|
|
||||||
- name: clean apt cache
|
- name: clean apt cache
|
||||||
apt:
|
apt:
|
||||||
@ -291,16 +357,21 @@
|
|||||||
apt:
|
apt:
|
||||||
autoremove: yes
|
autoremove: yes
|
||||||
|
|
||||||
|
- name: enable services
|
||||||
|
systemd:
|
||||||
|
name: "{{services.enable}}"
|
||||||
|
state: started
|
||||||
|
enabled: yes
|
||||||
|
|
||||||
|
- name: disable unecessary services
|
||||||
|
systemd:
|
||||||
|
name: "{{services.disable}}"
|
||||||
|
state: stopped
|
||||||
|
enabled: no
|
||||||
|
|
||||||
- name: remove ssh keys
|
- name: remove ssh keys
|
||||||
file:
|
file:
|
||||||
state: absent
|
state: absent
|
||||||
path: "{{item}}"
|
path: "{{item}}"
|
||||||
with_items:
|
with_fileglob:
|
||||||
- /etc/ssh/ssh_host_rsa_key
|
- "/etc/ssh/ssh_host*_key*"
|
||||||
- /etc/ssh/ssh_host_rsa_key.pub
|
|
||||||
- /etc/ssh/ssh_host_dsa_key
|
|
||||||
- /etc/ssh/ssh_host_dsa_key.pub
|
|
||||||
- /etc/ssh/ssh_host/ecdsa_key
|
|
||||||
- /etc/ssh/ssh_host/ecdsa_key.pub
|
|
||||||
- /etc/ssh/ssh_host_ed25519_key
|
|
||||||
- /etc/ssh/ssh_host_ed25519_key.pub
|
|
||||||
|
@ -40,6 +40,8 @@ For instance, you can change `main.lang` to one of the supported languages:
|
|||||||
- macedonian
|
- macedonian
|
||||||
- italian
|
- italian
|
||||||
- french
|
- french
|
||||||
|
- russian
|
||||||
|
- swedish
|
||||||
|
|
||||||
## Display Selection
|
## Display Selection
|
||||||
|
|
||||||
|
@ -2,6 +2,9 @@
|
|||||||
|
|
||||||
The project has been developed to run on a Raspberry Pi 0 W configured as an [USB Ethernet gadget](https://learn.adafruit.com/turning-your-raspberry-pi-zero-into-a-usb-gadget/ethernet-gadget) device in order to connect to it via USB. However, given the proper configuration tweaks, any GNU/Linux computer with a WiFi interface that supports monitor mode could be used.
|
The project has been developed to run on a Raspberry Pi 0 W configured as an [USB Ethernet gadget](https://learn.adafruit.com/turning-your-raspberry-pi-zero-into-a-usb-gadget/ethernet-gadget) device in order to connect to it via USB. However, given the proper configuration tweaks, any GNU/Linux computer with a WiFi interface that supports monitor mode could be used.
|
||||||
|
|
||||||
|
*An important note about the AI:* a network trained with a specific WiFi interface will only work with another interface if it supports
|
||||||
|
the same exact WiFi channels of the first one. For instance, you can not use a neural network trained on a Raspberry Pi Zero W (that only supports 2.4Ghz channels) with a 5Ghz antenna, but you'll need to train one from scratch for those channels.
|
||||||
|
|
||||||
## Required Hardware
|
## Required Hardware
|
||||||
|
|
||||||
- [Raspberry Pi Zero W](https://www.raspberrypi.org/products/raspberry-pi-zero-w/).
|
- [Raspberry Pi Zero W](https://www.raspberrypi.org/products/raspberry-pi-zero-w/).
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
# main algorithm configuration
|
# main algorithm configuration
|
||||||
main:
|
main:
|
||||||
# currently implemented: en (default), de, el, fr, it, mk, nl, se
|
# currently implemented: en (default), de, el, fr, it, mk, nl, ru, se
|
||||||
lang: en
|
lang: en
|
||||||
# custom plugins path, if null only default plugins with be loaded
|
# custom plugins path, if null only default plugins with be loaded
|
||||||
custom_plugins:
|
custom_plugins:
|
||||||
@ -15,7 +15,7 @@ main:
|
|||||||
files:
|
files:
|
||||||
- /root/brain.nn
|
- /root/brain.nn
|
||||||
- /root/brain.json
|
- /root/brain.json
|
||||||
- /root/custom.yaml
|
- /root/custom.yml
|
||||||
- /root/handshakes
|
- /root/handshakes
|
||||||
- /etc/ssh
|
- /etc/ssh
|
||||||
- /etc/hostname
|
- /etc/hostname
|
||||||
@ -24,7 +24,7 @@ main:
|
|||||||
- /var/log/pwnagotchi.log
|
- /var/log/pwnagotchi.log
|
||||||
commands:
|
commands:
|
||||||
- 'tar czf /tmp/backup.tar.gz {files}'
|
- 'tar czf /tmp/backup.tar.gz {files}'
|
||||||
- 'scp /tmp/backup.tar.gz pwnagotchi@10.0.0.1:/home/pwnagotchi/backups/backup-$(date).tar.gz'
|
- 'scp /tmp/backup.tar.gz pwnagotchi@10.0.0.1:/home/pwnagotchi/backups/backup-$(date +%s).tar.gz'
|
||||||
gps:
|
gps:
|
||||||
enabled: false
|
enabled: false
|
||||||
twitter:
|
twitter:
|
||||||
|
@ -1,6 +1,6 @@
|
|||||||
import subprocess
|
import subprocess
|
||||||
|
|
||||||
version = '1.0.0plz2'
|
version = '1.0.0plz3'
|
||||||
|
|
||||||
_name = None
|
_name = None
|
||||||
|
|
||||||
|
Binary file not shown.
@ -0,0 +1,205 @@
|
|||||||
|
# SOME DESCRIPTIVE TITLE.
|
||||||
|
# Copyright (C) YEAR THE PACKAGE'S COPYRIGHT HOLDER
|
||||||
|
# This file is distributed under the same license as the PACKAGE package.
|
||||||
|
# FIRST AUTHOR <25989971+adolfaka@users.noreply.github.com>, 2019.
|
||||||
|
#
|
||||||
|
msgid ""
|
||||||
|
msgstr ""
|
||||||
|
"Project-Id-Version: \n"
|
||||||
|
"Report-Msgid-Bugs-To: \n"
|
||||||
|
"POT-Creation-Date: 2019-10-03 16:47+0200\n"
|
||||||
|
"PO-Revision-Date: 2019-10-05 18:50+0300\n"
|
||||||
|
"Language-Team: \n"
|
||||||
|
"MIME-Version: 1.0\n"
|
||||||
|
"Content-Type: text/plain; charset=UTF-8\n"
|
||||||
|
"Content-Transfer-Encoding: 8bit\n"
|
||||||
|
"X-Generator: Poedit 2.2.4\n"
|
||||||
|
"Last-Translator: Elliot Manson\n"
|
||||||
|
"Plural-Forms: nplurals=3; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && n"
|
||||||
|
"%10<=4 && (n%100<12 || n%100>14) ? 1 : 2);\n"
|
||||||
|
"Language: ru_RU\n"
|
||||||
|
|
||||||
|
msgid "ZzzzZZzzzzZzzz"
|
||||||
|
msgstr "ZzzzZZzzzzZzzz"
|
||||||
|
|
||||||
|
msgid "Hi, I'm Pwnagotchi! Starting ..."
|
||||||
|
msgstr "Привет, я Pwnagotchi! Поехали …"
|
||||||
|
|
||||||
|
msgid "New day, new hunt, new pwns!"
|
||||||
|
msgstr "Новый день, новая охота, новые взломы!"
|
||||||
|
|
||||||
|
msgid "Hack the Planet!"
|
||||||
|
msgstr "Взломаем всю планету!"
|
||||||
|
|
||||||
|
msgid "AI ready."
|
||||||
|
msgstr "Искусственный интеллект готов."
|
||||||
|
|
||||||
|
msgid "The neural network is ready."
|
||||||
|
msgstr "Нейронная сеть готова."
|
||||||
|
|
||||||
|
#, python-brace-format
|
||||||
|
msgid "Hey, channel {channel} is free! Your AP will say thanks."
|
||||||
|
msgstr "Эй, канал {channel} свободен! Ваша точка доступа скажет спасибо."
|
||||||
|
|
||||||
|
msgid "I'm bored ..."
|
||||||
|
msgstr "Мне скучно …"
|
||||||
|
|
||||||
|
msgid "Let's go for a walk!"
|
||||||
|
msgstr "Пойдем прогуляемся!"
|
||||||
|
|
||||||
|
msgid "This is the best day of my life!"
|
||||||
|
msgstr "Это лучший день в моей жизни!"
|
||||||
|
|
||||||
|
msgid "Shitty day :/"
|
||||||
|
msgstr "Дерьмовый день :/"
|
||||||
|
|
||||||
|
msgid "I'm extremely bored ..."
|
||||||
|
msgstr "Мне очень скучно …"
|
||||||
|
|
||||||
|
msgid "I'm very sad ..."
|
||||||
|
msgstr "Мне очень грустно …"
|
||||||
|
|
||||||
|
msgid "I'm sad"
|
||||||
|
msgstr "Мне грустно"
|
||||||
|
|
||||||
|
msgid "I'm living the life!"
|
||||||
|
msgstr "Я живу своей жизнью!"
|
||||||
|
|
||||||
|
msgid "I pwn therefore I am."
|
||||||
|
msgstr "Я взламываю, поэтому я существую."
|
||||||
|
|
||||||
|
msgid "So many networks!!!"
|
||||||
|
msgstr "Так, много сетей!!!"
|
||||||
|
|
||||||
|
msgid "I'm having so much fun!"
|
||||||
|
msgstr "Мне так весело!"
|
||||||
|
|
||||||
|
msgid "My crime is that of curiosity ..."
|
||||||
|
msgstr "Моё преступление - это любопытство …"
|
||||||
|
|
||||||
|
#, python-brace-format
|
||||||
|
msgid "Hello {name}! Nice to meet you. {name}"
|
||||||
|
msgstr "Привет, {name}! Приятно познакомиться. {name}"
|
||||||
|
|
||||||
|
#, python-brace-format
|
||||||
|
msgid "Unit {name} is nearby! {name}"
|
||||||
|
msgstr "Цель {name} близко! {name}"
|
||||||
|
|
||||||
|
#, python-brace-format
|
||||||
|
msgid "Uhm ... goodbye {name}"
|
||||||
|
msgstr "Хм … до свидания {name}"
|
||||||
|
|
||||||
|
#, python-brace-format
|
||||||
|
msgid "{name} is gone ..."
|
||||||
|
msgstr "{name} исчезла …"
|
||||||
|
|
||||||
|
#, python-brace-format
|
||||||
|
msgid "Whoops ... {name} is gone."
|
||||||
|
msgstr "Упс … {name} исчезла."
|
||||||
|
|
||||||
|
#, python-brace-format
|
||||||
|
msgid "{name} missed!"
|
||||||
|
msgstr "{name} упустил!"
|
||||||
|
|
||||||
|
msgid "Missed!"
|
||||||
|
msgstr "Промахнулся!"
|
||||||
|
|
||||||
|
msgid "Nobody wants to play with me ..."
|
||||||
|
msgstr "Никто не хочет играть со мной …"
|
||||||
|
|
||||||
|
msgid "I feel so alone ..."
|
||||||
|
msgstr "Мне так одиноко …"
|
||||||
|
|
||||||
|
msgid "Where's everybody?!"
|
||||||
|
msgstr "Где все?!"
|
||||||
|
|
||||||
|
#, python-brace-format
|
||||||
|
msgid "Napping for {secs}s ..."
|
||||||
|
msgstr "Дремлет {secs}с …"
|
||||||
|
|
||||||
|
msgid "Zzzzz"
|
||||||
|
msgstr "Zzzzz"
|
||||||
|
|
||||||
|
#, python-brace-format
|
||||||
|
msgid "ZzzZzzz ({secs}s)"
|
||||||
|
msgstr "ZzzZzzz ({secs}c)"
|
||||||
|
|
||||||
|
#, python-brace-format
|
||||||
|
msgid "Waiting for {secs}s ..."
|
||||||
|
msgstr "Ждем {secs}c …"
|
||||||
|
|
||||||
|
#, python-brace-format
|
||||||
|
msgid "Looking around ({secs}s)"
|
||||||
|
msgstr "Оглядываюсь вокруг ({secs}с)"
|
||||||
|
|
||||||
|
#, python-brace-format
|
||||||
|
msgid "Hey {what} let's be friends!"
|
||||||
|
msgstr "Эй, {what} давай дружить!"
|
||||||
|
|
||||||
|
#, python-brace-format
|
||||||
|
msgid "Associating to {what}"
|
||||||
|
msgstr "Связываюсь с {what}"
|
||||||
|
|
||||||
|
#, python-brace-format
|
||||||
|
msgid "Yo {what}!"
|
||||||
|
msgstr "Йоy {what}!"
|
||||||
|
|
||||||
|
#, python-brace-format
|
||||||
|
msgid "Just decided that {mac} needs no WiFi!"
|
||||||
|
msgstr "Просто решил, что {mac} не нужен WiFi! Кхе-кхе)"
|
||||||
|
|
||||||
|
#, python-brace-format
|
||||||
|
msgid "Deauthenticating {mac}"
|
||||||
|
msgstr "Деаутентификация {mac}"
|
||||||
|
|
||||||
|
#, python-brace-format
|
||||||
|
msgid "Kickbanning {mac}!"
|
||||||
|
msgstr "Кикаю {mac}!"
|
||||||
|
|
||||||
|
#, python-brace-format
|
||||||
|
msgid "Cool, we got {num} new handshake{plural}!"
|
||||||
|
msgstr "Круто, мы получили {num} новое рукопожатие!"
|
||||||
|
|
||||||
|
msgid "Ops, something went wrong ... Rebooting ..."
|
||||||
|
msgstr "Ой, что-то пошло не так … Перезагружаюсь …"
|
||||||
|
|
||||||
|
#, python-brace-format
|
||||||
|
msgid "Kicked {num} stations\n"
|
||||||
|
msgstr "Кикнул {num} станцию\n"
|
||||||
|
|
||||||
|
#, python-brace-format
|
||||||
|
msgid "Made {num} new friends\n"
|
||||||
|
msgstr "Заимел {num} новых друзей\n"
|
||||||
|
|
||||||
|
#, python-brace-format
|
||||||
|
msgid "Got {num} handshakes\n"
|
||||||
|
msgstr "Получил {num} рукопожатие\n"
|
||||||
|
|
||||||
|
msgid "Met 1 peer"
|
||||||
|
msgstr "Встретился один знакомый"
|
||||||
|
|
||||||
|
#, python-brace-format
|
||||||
|
msgid "Met {num} peers"
|
||||||
|
msgstr "Встретились {num} приятелей"
|
||||||
|
|
||||||
|
#, python-brace-format
|
||||||
|
msgid ""
|
||||||
|
"I've been pwning for {duration} and kicked {deauthed} clients! I've also met "
|
||||||
|
"{associated} new friends and ate {handshakes} handshakes! #pwnagotchi "
|
||||||
|
"#pwnlog #pwnlife #hacktheplanet #skynet"
|
||||||
|
msgstr ""
|
||||||
|
"Я взламывал {duration} и кикнул {deauthed} клиентов! Я также встретил "
|
||||||
|
"{associated} новых друзей и съел {handshakes} рукопожатий! #pwnagotchi "
|
||||||
|
"#pwnlog #pwnlife #hacktheplanet #skynet"
|
||||||
|
|
||||||
|
msgid "hours"
|
||||||
|
msgstr "часов"
|
||||||
|
|
||||||
|
msgid "hour"
|
||||||
|
msgstr "час"
|
||||||
|
|
||||||
|
msgid "minutes"
|
||||||
|
msgstr "минут"
|
||||||
|
|
||||||
|
msgid "minute"
|
||||||
|
msgstr "минуту"
|
@ -30,6 +30,7 @@ def on_loaded():
|
|||||||
return
|
return
|
||||||
|
|
||||||
READY = True
|
READY = True
|
||||||
|
logging.info("AUTO-BACKUP: Successfuly loaded.")
|
||||||
|
|
||||||
|
|
||||||
def on_internet_available(display, config, log):
|
def on_internet_available(display, config, log):
|
||||||
@ -41,11 +42,17 @@ def on_internet_available(display, config, log):
|
|||||||
|
|
||||||
files_to_backup = " ".join(OPTIONS['files'])
|
files_to_backup = " ".join(OPTIONS['files'])
|
||||||
try:
|
try:
|
||||||
|
logging.info("AUTO-BACKUP: Backing up ...")
|
||||||
display.set('status', 'Backing up ...')
|
display.set('status', 'Backing up ...')
|
||||||
display.update()
|
display.update()
|
||||||
|
|
||||||
for cmd in OPTIONS['commands']:
|
for cmd in OPTIONS['commands']:
|
||||||
subprocess.call(cmd.format(files=files_to_backup).split(), stdout=open(os.devnull, 'wb'))
|
logging.info(f"AUTO-BACKUP: Running {cmd.format(files=files_to_backup)}")
|
||||||
|
process = subprocess.Popen(cmd.format(files=files_to_backup), shell=True, stdin=None,
|
||||||
|
stdout=open("/dev/null", "w"), stderr=None, executable="/bin/bash")
|
||||||
|
process.wait()
|
||||||
|
if process.returncode > 0:
|
||||||
|
raise OSError(f"Command failed (rc: {process.returncode})")
|
||||||
|
|
||||||
logging.info("AUTO-BACKUP: backup done")
|
logging.info("AUTO-BACKUP: backup done")
|
||||||
STATUS.update()
|
STATUS.update()
|
||||||
|
Reference in New Issue
Block a user