Skip to content

Instantly share code, notes, and snippets.

@sontqq
Created October 30, 2019 23:15
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save sontqq/c452dbfdf727a0273f549469b2e5f703 to your computer and use it in GitHub Desktop.
Save sontqq/c452dbfdf727a0273f549469b2e5f703 to your computer and use it in GitHub Desktop.
UsefulLinuxCommands.txt
tshark -T fields -e wlan.sa_resolved -e wlan.da._resolved -e wlan.sa -l -i wlan0 -o gui.column.format:'"MAC", "%uhs","RSSI", "%e"' | while read line; do echo "$line" >> mac.log; done
# SZAR sudo tshark -S -l -i wlan0 -Y 'wlan.fc.type_subtype eq 4' -T fields -e wlan.sa -e wlan_mgt.ssid
tshark -i wlan0 -Y http.request -T fields -e http.host -e http.request.full_uri
tshark -i wlan0 -f "src port 53" -n -T fields -e frame.time -e ip.src -e ip.dst -e dns.qry.name
tshark -i wlan0 -Y 'http.request.method == POST and tcp contains "password"' | grep password
SELECT * FROM gps WHERE whattime > CURDATE();
ALTER TABLE fruit ADD UNIQUE (name)
INSERT IGNORE INTO fruit (name) VALUES ('mango')
+-------------+
| id | name |
+ ----------- +
| 1 | apple |
| 2 | orange |
| 3 | banana |
| 4 | grape |
+-------------+
#!/bin/bash
echo "Setting up traffic forwarding.\n"
iptables -t nat -A POSTROUTING -o enp3s0 -j MASQUERADE
iptables -A FORWARD -i enp1s0 -j ACCEPT
echo 1 > /proc/sys/net/ipv4/ip_forward
ifconfig enp1s0 192.168.0.10 netmask 255.255.255.0
service networking restart
ifconfig enp1s0 192.168.0.10 netmask 255.255.255.0
echo "Done.\n"
admin/qnsztkft
RECORD LIVE MJPEG
ffmpeg -f v4l2 -framerate 90 -video_size 1280x720 -input_format mjpeg -i /dev/video1 out.mkv
RECORD WITHOUT CONVERSION
ffmpeg -f v4l2 -framerate 90 -video_size 1280x720 -input_format mjpeg -i /dev/video1 -c copy mjpeg.mkv
CONVERSION AFTER RECORD
ffmpeg -i mjpeg.mkv -c:v libx264 -crf 23 -preset medium -pix_fmt yuv420p out.mkv
<iframe src="http://ipcamlive.com/player/player.php?alias=szekesfehervar" width="800px" height="600px"/>
https://www.ipcamlive.com/camerastatus?id=92939
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment