Thursday, July 23, 2015
Tuesday, July 7, 2015
Keyboard shortcuts for symbols on Mac OS X
Degree (˚): option + k
Micro (µ): option + m
Copyright (©): option + g
Ohm (Ω): option + z
Registered (®): option + r
Trade mark (™): option + 2
Math:
Approximate (≈): option + x
PI (π): option + p
Delta (∆): option + j
Infinity (∞): option + 5
Division (÷): option + /
Not equal (≠) : option + '+'
Division (÷): option + /
Not equal (≠) : option + '+'
Plus/Minus (±): option + shift + =
Square root (√): option + v
Alpha (∂): option + d
Beta (ß): option + s
Function(ƒ): option + f
Calculus (∫): option + b
Yen (¥): option + y
Pound: (£): option + 3
Euro (€): option + shift + 2
No interface available in Wireshark on Mac OS
Change the permission to 644 on the BFF (Berkeley Packet Filter) in /dev/
sudo chmod 644 /dev/bpf*
or
whoami to find out your name
sudo chown yourname:admin /dev/bp*
And restart wireshark!
sudo chmod 644 /dev/bpf*
or
whoami to find out your name
sudo chown yourname:admin /dev/bp*
And restart wireshark!
Monday, July 6, 2015
USB to Serial (Console) on Mac OS X
Use the built-in "screen"
1. Install the USB to Serial driver (PL2303 Mac OS X)
2. In terminal, launch Screen and connect to device by following command (115200: baud rate)
screen /dev/cu.usbserial 115200
or screen /dev/tty.usbserial 115200
or screen /dev/tty.usbserial 115200
To list the screen sessions: screen -ls (output in format pid.tty.host)
To resume a detached session: screen -r or screen -x pid
Commands in 'screen':
'Control+a' and then '?' : Help
'Control+a' and then 'H' : toggle logging
'Control+a' and then 'Control+\' : Quit screen
Thursday, May 21, 2015
tcpdump wirte to screen and file
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 -
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 -
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
-
Date to Epoch time: (A1: Date cell) =(A1-25569)*86400 Epoch time to Date: (A1: Epoch time cell) =(A1/86400)+25569 PS. Need to format th...
-
1. Create an account on TestFlight ( http://testflightapp.com ) and with "Developer" option checked. 2. Log in to the TestFlight ...
-
[轉載] [Javascript] Encrypt your private blog post from the article of Kaie's Blog 今日在PPT上的Blog版逛到版友weijr所提到的一篇好文章,可以用來針對Blog中某一段文字給予加密,變成...