Benutzer-Werkzeuge

Webseiten-Werkzeuge


setup_zero_buster

Dies ist eine alte Version des Dokuments!


Raspbian-Buster herunterladen und installieren: 2020-05-27-raspios-buster-armhf.zip

Flashen mit BalneaEtcher

Dateien installieren, leere „ssh“

cmdline.txt (anhängen)

 ip=192.168.178.32::192.168.178.1:255.255.255.0:zero:wlan0:off

wpa_supplicant.conf

country=DE
ctrl_interface=DIR=/var/run/wpa_supplicant GROUP=netdev
update_config=1
network={
    ssid="iMacToGo"
    psk="PASSWORD"
    key_mgmt=WPA-PSK
}
ssh pi@192.168.178.32
pwd:raspberry

sudo raspi-config

1: password
2: hostname:zero
4: de_DE.UTF-8 UTF-8 / de_DE.UTF-8 
4: Timezone: Europe->Monaco
5: PiCamera
7: Expand Filesystem

sudo reboot now

sudo apt-get update
sudo apt-get -y dist-upgrade (15 Minuten)

sudo reboot now

Netzwerk - wieder auf DHCP umstellen und mit meinem WLAN Verbinden

/etc/network/interfaces
allow-hotplug wlan0
iface wlan0 inet dhcp
    wpa-conf /etc/wpa_supplicant/wpa_supplicant.conf
wireless-power off
/etc/wpa_supplicant/wpa_supplicant.conf
country=DE
ctrl_interface=DIR=/var/run/wpa_supplicant GROUP=netdev
update_config=1
network={
    ssid="iMacToGo"
    psk="KENNWORT"
    key_mgmt=WPA-PSK
}

Das zweite WLAN als Hotspot einrichten mit einrichten

sudo apt-get install dnsmasq hostapd

sudo nano /etc/network/interfaces
allow-hotplug wlan1
iface wlan1 inet static
address 192.168.10.254
netmask 255.255.255.0
up iptables-restore < /etc/iptables.nat
wireless-power off

sudo nano /etc/hostapd.conf
# WLAN-Router-Betrieb
# Schnittstelle und Treiber
interface=wlan1
#driver=nl80211
# WLAN-Konfiguration
ssid=WLANrouter
channel=1
hw_mode=g
ieee80211n=1
ieee80211d=1
country_code=DE
wmm_enabled=1
# WLAN-Verschlüsselung
auth_algs=1
wpa=2
wpa_key_mgmt=WPA-PSK
rsn_pairwise=CCMP
wpa_passphrase=testtest

sudo nano /etc/default/hostapd
DAEMON_CONF="/etc/hostapd.conf"

sudo nano /etc/dnsmasq.conf
interface=wlan1
no-dhcp-interface=eth0
dhcp-range=interface:wlan1,192.168.10.1,192.168.10.10,infinite

sudo nano /etc/sysctl.conf
net.ipv4.ip_forward=1

(sollten die nächsten Befehle nicht gehen, erst den Rest machen, dann gehen sie)
sudo iptables -t nat -A POSTROUTING -o wlan0 -j MASQUERADE
sudo iptables -A FORWARD -i wlan0 -o wlan1 -m state --state RELATED,ESTABLISHED -j ACCEPT
sudo iptables -A FORWARD -i wlan1 -o wlan0 -j ACCEPT
sudo sh -c "iptables-save > /etc/iptables.nat"

sudo dnsmasq --test -C /etc/dnsmasq.conf (testen)
sudo hostapd -dd /etc/hostapd.conf (testen)

sudo service dnsmasq start
sudo systemctl enable dnsmasq (beim booten)

sudo systemctl unmask hostapd
sudo systemctl start hostapd
sudo systemctl enable hostapd (beim booten)

VNC-Server, der vom Mac aus geht

sudo apt-get install tightvncserver
vncserver (starten)

Suche

sudo apt-get install mlocate
sudo updatedb 

Tools

sudo apt-get install aircrack-ng
sudo airmon-ng start wlan1
sudo airodump-ng wlan1mon
sudo apt-get install gawk tcpdump # https://github.com/brannondorsey/sniff-probes
IFACE=wlan1mon 
OUTPUT=output.txt 
#CHANNEL_HOP=1

sudo apt-get installl dsniff

Statt den FORWARD Regeln kann man auch eine Bridge einrichten:
sudo apt-get install bridge-utils
sudo brctl addbr br0
(sudo brctl Addis br0 wlan0) geht nicht, stattdessen in "sudo nano /etc/default/hostapd"
bridge=br0

sudo nano /etc/network/interfaces
auto br0
face br0 net manual
bridge_ports wlan0 wlan1

urlsnarf -i wlan0 (alles andere geht nicht)

# der block geht noch nicht
git clone https://github.com/moxie0/sslstrip.git
sudo apt-get install python-twisted-web
sudo iptables -t nat -A PREROUTING -p tcp --destination-port 80 -j REDIRECT --to-port 8080
iptables -t nat -L
python sslstrip.py -p -l 8080
tail -f sslstrip.log

Zugriff per Bluetooth (mit zwei Apps kamen immer Steuerzeichen mit, also doch Hotspot)
Verbindung (erstellen von bnep0) geht nur, wenn am Handy Mehr→Bluetooth-Tethering AN ist
http://bluez.sourceforge.net/contrib/HOWTO-PAN

Bei Connect-Problemen:

sudo cat /var/log/syslog | grep -i protocol
Jul 29 11:02:50 zero bluetoothd[426]: a2dp-source profile connect failed for 00:EC:0A:72:14:61: Protocol not available
sudo apt-get install pulseaudio-module-bluetooth
pulseaudio --start
sudo apt-get install bluez bluez-tools
sudo bluetoothctl
agent on
default-agent
scan on
pair 00:EC:0A:72:14:61
trust 00:EC:0A:72:14:61
connect 00:EC:0A:72:14:61
exit
git clone https://github.com/WayneKeenan/RaspberryPi_BTPAN_AutoConnect.git

Zugriff per Webbrowser auf die Konsole

sudo apt install shellinabox minicom
sudo nano /etc/default/shellinabox
SHELLINABOX_ARGS="-t -s /:LOGIN -s /termi:pi:pi:/usr/home/pi:/usr/bin/minicom --no-beep" 
/etc/init.d/shellinabox restart (1)
http://192.168.178.32:4200

FritzBox Anrufe feststellen - callMonitor Externer Link

#96*5*
telnet fritz.box 1012
29.07.20 10:19:09;RING;0;#from#;#to#;SIP1;
29.07.20 10:19:16;DISCONNECT;0;0;

Mehr Infos:
https://administrator.de/wissen/netzwerk-management-server-raspberry-pi-191718.html#toc-18

setup_zero_buster.1596017510.txt.gz · Zuletzt geändert: 2020/07/29 10:11 von varnholt