Basic form:
tcpdump -i interface OPTIONS -w - | tee outputFile | tcpdump -r -
-w - : write data to stdout
tee : write data to file and its own stdout
-r - : read data from stdin
Example:
tcpdump -i enp3s0 udp and port 53 -w - | tee packet.pcap | tcpdump -nn -r -
Thursday, May 21, 2015
Tuesday, May 5, 2015
Use iptables for CentOS 7 instead of firewalld
CentOS 7 is now using firewalld instead of iptables. To use iptables, here are the steps:
1. Disable firewalld
systemctrl disable firewalld
2. Stop firewalld
systemctrl stop firewalld
3. Install iptables-services
yum install iptables-services
4. Enable iptables
systemctl enable iptables
5. Start iptables
systemctl start iptables
6. Configure iptables as usual (/etc/sysconfig/iptables)
1. Disable firewalld
systemctrl disable firewalld
2. Stop firewalld
systemctrl stop firewalld
3. Install iptables-services
yum install iptables-services
4. Enable iptables
systemctl enable iptables
5. Start iptables
systemctl start iptables
6. Configure iptables as usual (/etc/sysconfig/iptables)
Monday, May 4, 2015
Add a private key to Mac OS X KeyChain
ssh-add -K ~/.ssh/id_rsa
ps. make sure the permission of id_rsa is 600
Subscribe to:
Posts (Atom)
Check clients which connect to Mac OS X Wi-Fi Internet Sharing
arp -i bridge100 -a bridge100 may be different on your Mac OSX
-
For Mac OS: Use lipo. Ex. lipo -info staticLibrary.a For Linux OS: Use file Ex. file staticLibrary.c
-
[轉貼]用GCC自製Library 引用 : PTT 看板 : LinuxDev ( 作者 : cole945) Library 可分成三種, static 、 shared 與 dynamically loaded 。 1. Static libr...
-
1. Create an account on TestFlight ( http://testflightapp.com ) and with "Developer" option checked. 2. Log in to the TestFlight ...