当前位置:网站首页>IDA pro逆向工具寻找socket server的IP和port
IDA pro逆向工具寻找socket server的IP和port
2022-07-07 12:48:00 【晓翔仔】
在逆向分析代码的时候,我们有时需要找到某软件做服务端时提供的ip:port。
使用IDA pro反编译代码,找到套接字设置的代码处,发现我们期待的IP和port的地方是数字
这时我们该怎么办呢?
第一步:将地址信息转为16进制的正数
选中数字,右击选择invert sign和Hexadecimal。


第二步:ip地址转为整数
使用在线地址转换工具将ip地址转为整数

如果你想自己编写C语言代码实现,可以使用atoi函数,参考这篇文章:
C语言实现字符串IP与整数型IP的相互转换 - 丁培飞 - 博客园
第三步:字节序转换
字节序转换函数主要有四种
htons :将16位无 符号整数从本地字节序转换成网络字节序
htonl :将32位无 符号整数从本地字节序转换成网络字节序
ntohs :将16位无 符号整数从网络字节序转换成本地字节序
ntohl :将32位无 符号整数从网络字节序转换成本地字节序
你也可以直接手算。
这里的IP是 1.0.0.127 -> 127.0.0.1
这里的port是0xA822 -> 0x228A = 8872
边栏推荐
- PLC:自动纠正数据集噪声,来洗洗数据集吧 | ICLR 2021 Spotlight
- 半小时『直播连麦搭建』动手实战,大学生技术岗位简历加分项get!
- 6、Electron无边框窗口和透明窗口 锁定模式 设置窗口图标
- JS image to Base64
- AWS learning notes (III)
- JSON解析实例(Qt含源码)
- Nllb-200: meta open source new model, which can translate 200 languages
- 关于后台动态模板添加内容的总结 Builder使用
- NLLB-200:Meta开源新模型,可互译200种语言
- 2022 cloud consulting technology series high availability special sharing meeting
猜你喜欢

Navigation - are you sure you want to take a look at such an easy-to-use navigation framework?

⼀个对象从加载到JVM,再到被GC清除,都经历了什么过程?

How bad can a programmer be? Nima, they are all talents

Spatiotemporal deformable convolution for compressed video quality enhancement (STDF)

拼多多败诉,砍价始终差0.9%一案宣判;微信内测同一手机号可注册两个账号功能;2022年度菲尔兹奖公布|极客头条...

Stm32cubemx, 68 sets of components, following 10 open source protocols

Substance Painter笔记:多显示器且多分辨率显示器时的设置

Huawei cloud database DDS products are deeply enabled

Webrtc audio anti weak network technology (Part 1)

Simple use of websocket
随机推荐
Mmkv use and principle
Cocos creator direction and angle conversion
electron remote 报错
Es log error appreciation -- allow delete
Simple steps for modifying IP of sigang electronic scale
15、文本编辑工具VIM使用
Ascend 910 realizes tensorflow1.15 to realize the Minist handwritten digit recognition of lenet network
Deformable convolutional dense network for enhancing compressed video quality
⼀个对象从加载到JVM,再到被GC清除,都经历了什么过程?
属性关键字OnDelete,Private,ReadOnly,Required
Apache多个组件漏洞公开(CVE-2022-32533/CVE-2022-33980/CVE-2021-37839)
KITTI数据集简介与使用
Summary on adding content of background dynamic template builder usage
Instructions d'utilisation de la trousse de développement du module d'acquisition d'accord du testeur mictr01
Demis Hassabis谈AlphaFold未来目标
Decrypt the three dimensional design of the game
内部排序——插入排序
【服务器数据恢复】某品牌StorageWorks服务器raid数据恢复案例
Data connection mode in low code platform (Part 2)
Démontage de la fonction du système multi - Merchant Mall 01 - architecture du produit