Giter VIP home page Giter VIP logo

xray-crack's Introduction

XRAY CRACKER

生成证书

使用 -g username 生成永久证书

# ./xray-cracker -g kali

证书已写入文件:xray-license.lic

破解 xray

目前 PubKey 是加密过的,加密算法很简单,但是那个函数是硬编码了几百个局部变量,替换一波后,两个一对进行加、减、异或等操作进行还原,看样子是用代码生成的加密函数代码然后编译的,如果花时间在这上面可能是个死局,因为可以在每一次编译前都重新生成一下代码

所以我选择从其他地方入手,很明显公钥是用来验证签名的,如此看来直接修改签名验证函数的返回值就行,golang 中 VerifyPSS 返回一个 err,如果err==nil就代表签名没问题,放在汇编里就是 test 某寄存器 然后 setzsetnz,改一下就行

使用 -c path-to-xray 自动patch二进制xray

# ./xray-crack.exe -c xray_linux_amd64
linux amd64
[.text] offset: 0x1000, addr: 0x401000-0x11787e3
Signature last index: 0xae2f2e
Patch success: xray_linux_amd64

破解效果

使用修改版 xray 和永久证书后,效果如下

# ./xray_linux_amd64 version

____  ___.________.    ____.   _____.___.
\   \/  /\_   __   \  /  _  \  \__  |   |
 \     /  |    _  _/ /  /_\  \  /   |   |
 /     \  |    |   \/    |    \ \____   |
\___/\  \ |____|   /\____|_   / / _____/
      \_/       \_/        \_/  \/

Version: 1.3.3/1d166d72/COMMUNITY-ADVANCED
Licensed to kali, license is valid until 2099-09-08 19:00:00

[INFO] 2020-09-29 00:20:20 [default:entry.go:122] set file descriptor limit to 10000
[INFO] 2020-09-29 00:20:20 [default:entry.go:157] loading config file from /home/kali/tools/scan/xray/config.yaml
[xray 1.3.3/1d166d72]
Build: [2020-09-17] [linux/amd64] [RELEASE/COMMUNITY-ADVANCED]
Compiler Version: go version go1.14.4 linux/amd64
License ID: 00000000000000000000000000000000
User Name: kali/00000000000000000000000000000000
Not Valid Before: 2020-06-11 12:00:00
Not Valid After: 2099-09-08 19:00:00

To show open source licenses, please use `osslicense` sub-command.

xray-crack's People

Contributors

zu1k avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.