时时勤拂拭,勿使惹尘埃

TOC

Categories

SDR(五)hackrf_gsm


0x0 环境
kali2.0 or mac

0x1 安装库

sudo apt-get install hackrf libhackrf-dev libhackrf0
sudo apt-get install gnuradio gnuradio-dev gr-osmosdr gqrx-sdr wireshark

0x2 编译安装

0x21 安装gr-gsm

git clone https://github.com/ptrkrysik/gr-gsm.git
cd gr-gsm 
mkdir build
cd build
cmake ..
make
sudo make install
sudo ldconfig
遇到的坑:
1、CMake Error at CMakeLists.txt:76 (message): SWIG required to compile gr-gsm
2、No package ‘libosmocore’ found
git clone git://git.osmocom.org/libosmocore.git
cd libosmocore/
autoreconf -i
./configure
make
sudo make install
sudo ldconfig -i
3、mac版缺少libpcsc
./configure --disable-pcsc #libpcsclite isn't available on OS X
4、/usr/bin: python2: No such file or directory
sudo ln -s /usr/bin/python2.7 /usr/local/bin/python2
5、完成后编译其他程序无法读取到libosmocore
~/.zshrcPKG_CONFIG_PATH=$PKG_CONFIG_PATH:/Users/***/Desktop/source/rf/libosmocore
export PKG_CONFIG_PATH

0x22 安装kalibrate-hackrf

能够识别GSM信号运营商的工具
git clone https://github.com/scateu/kalibrate-hackrf.git
cd kalibrate-hackrf
./bootstrap
./configure
make
sudo make install

0x3 采集

识别GSM信号运营商

0x4 信号

每个小波峰都是一个信道

很明显的离散信号


信号都是分段的

0x5 采集

gr-gsm工具编译完成后,gr-gsm/apps生成文件:
使用gnuradio加载监听程序文件,实时信号采集如下:
gnuradio-companion ./grgsm_livemon.grc

wireshark查看数据包(实际没采集到,这些是示例数据包)
sudo wireshark -k -Y 'gsmtap && !icmp' -i lo

0 评论:

发表评论