Skip to content

Commit

Permalink
Adding RF Swift bindings for Mirage and uploading run file for Open5GS
Browse files Browse the repository at this point in the history
  • Loading branch information
FlUxIuS committed Aug 2, 2024
1 parent 94ebc23 commit c99be9e
Show file tree
Hide file tree
Showing 4 changed files with 18 additions and 3 deletions.
2 changes: 1 addition & 1 deletion go/rfswift/dock/rfdock.go
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ var dockerObj = DockerInst{net: "host",
entrypoint: "/bin/bash",
x11forward: "/tmp/.X11-unix:/tmp/.X11-unix",
usbforward: "/dev/bus/usb:/dev/bus/usb",
extrabinding: "/dev/ttyACM0:/dev/ttyACM0", // Some more if needed /run/dbus/system_bus_socket:/run/dbus/system_bus_socket,/dev/snd:/dev/snd,/dev/dri:/dev/dri
extrabinding: "/dev/ttyACM0:/dev/ttyACM0,/run/dbus/system_bus_socket:/run/dbus/system_bus_socket,/dev/snd:/dev/snd,/dev/dri:/dev/dri,/dev/input:/dev/input", // Some more if needed /run/dbus/system_bus_socket:/run/dbus/system_bus_socket,/dev/snd:/dev/snd,/dev/dri:/dev/dri
imagename: "myrfswift:latest",
extrahosts: "",
extraenv: "",
Expand Down
2 changes: 1 addition & 1 deletion go/rfswift/rfutils/configs.go
Original file line number Diff line number Diff line change
Expand Up @@ -156,7 +156,7 @@ imagename = myrfswift:latest
[container]
shell = /bin/zsh
bindings = /dev/bus/usb:/dev/bus/usb,/run/dbus/system_bus_socket:/run/dbus/system_bus_socket,/dev/snd:/dev/snd,/dev/dri:/dev/dri
bindings = /dev/bus/usb:/dev/bus/usb,/run/dbus/system_bus_socket:/run/dbus/system_bus_socket,/dev/snd:/dev/snd,/dev/dri:/dev/dri,/dev/input:/dev/input
network = host
x11forward = /tmp/.X11-unix:/tmp/.X11-unix
xdisplay = "DISPLAY=:0"
Expand Down
14 changes: 14 additions & 0 deletions run/Open5GS.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
#!/bin/bash

sudo ip tuntap add name ogstun mode tun
sudo ip addr add 10.45.0.1/16 dev ogstun
sudo ip addr add 2001:db8:cafe::1/48 dev ogstun
sudo ip link set ogstun up

### Enable IPv4/IPv6 Forwarding
sudo sysctl -w net.ipv4.ip_forward=1
sudo sysctl -w net.ipv6.conf.all.forwarding=1

### Add NAT Rule
sudo iptables -t nat -A POSTROUTING -s 10.45.0.0/16 ! -o ogstun -j MASQUERADE
sudo ip6tables -t nat -A POSTROUTING -s 2001:db8:cafe::/48 ! -o ogstun -j MASQUERADE
3 changes: 2 additions & 1 deletion scripts/rf_tools.sh
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ function mirage_soft_install() {
echo apt-fast console-setup/codeset47 string "Guess optimal character set" | debconf-set-selections
echo apt-fast console-setup/charmap47 string "UTF-8" | debconf-set-selections
installfromnet "apt-fast install -y libpcsclite-dev pcsc-tools kmod kbd"
installfromnet "pip3 install keyboard"
goodecho "[+] Installing Mirage"
[ -d /root/thirdparty ] || mkdir -p /root/thirdparty
cd /root/thirdparty
Expand Down Expand Up @@ -184,4 +185,4 @@ function wifite2_soft_install () {
cd /rftools/wifi
installfromnet "git clone https://github.com/derv82/wifite2.git"
cd wifite2/
}
}

0 comments on commit c99be9e

Please sign in to comment.