IT干货网

极验验证码破解与研究

sanshao 2022年03月04日 DevOps 201 0

1、极验官网完整流程

极验完整流程

一、实例研究

我们以春秋航空注册场景的验证码为研究对象

1、实例研究地址

IT虾米网

2、实例研究场景

春秋注册验证码

二、请求分析

1、网络请求抓包

极验请求抓包

从网络抓包结果可以看到,整个极验验证码与极验服务器一共交互了8次。要想破解极验验证码,首先我们就需要搞清楚每次请求都携带了哪些参数,其次就是参数如何生成的?只有搞明白每个参数的意义,后续我们才能够通过伪造参数以达到破解的目的。

2、数据说明

在分析极验请求前,需要先解释说明两个参数。

(1)gt:极验为每个使用方提供一个唯一身份标识用于进行服务区分

(2)challenge:用于请求串联,我们都知道http是无状态的,有了challenge就能把各个请求串联起来。(注意:challenge是会发生改变的,记得及时更换)

3、请求分析

请求1:gt.js

(1)请求介绍

关于第一个请求,在极验的官方文档已经给我们介绍了(IT虾米网gt.js文件用于加载对应的验证JS库。

(2)关键代码

Config.prototype = { 
    api_server: 'api.geetest.com', 
    protocol: 'http://', 
    typePath: '/gettype.php', 
    fallback_config: { 
        slide: { 
            static_servers: ["static.geetest.com", "dn-staticdown.qbox.me"], 
            type: 'slide', 
            slide: '/static/js/geetest.0.0.0.js' 
        }, 
        fullpage: { 
            static_servers: ["static.geetest.com", "dn-staticdown.qbox.me"], 
            type: 'fullpage', 
            fullpage: '/static/js/fullpage.0.0.0.js' 
        } 
    }, 
    _get_fallback_config: function () { 
        var self = this; 
        if (isString(self.type)) { 
            return self.fallback_config[self.type]; 
        } else if (self.new_captcha) { 
            return self.fallback_config.fullpage; 
        } else { 
            return self.fallback_config.slide; 
        } 
    }, 
    _extend: function (obj) { 
        var self = this; 
        new _Object(obj)._each(function (key, value) { 
            self[key] = value; 
        }) 
    } 
}; 

解释说明

(1)正常请求会发送gettype.php请求

# Request URL 
https://api.geetest.com/gettype.php?gt=25ba81caec944f8d74c98befd841a667&callback=geetest_1605974702024 
 
# Query String Parammeters 
gt: 25ba81caec944f8d74c98befd841a667 
callback: geetest_1605974702024 

(2)兜底策略

如果发生异常情况,极验服务器无法响应。这时就会发送http://static.geetest.com/static/js/geetest.0.0.0.js获取能够在本地验证的js文件,确保应用服务正常运行。具体可以参考我的另一篇博客《极验无感验证破解》https://www.cnblogs.com/boycelee/p/13951819.html

请求2:gettype.js

(1)请求介绍

该请求的目的是获取极验安全的核心js文件/static/js/fullpage.9.0.2.js和极验提供的各类型验证码对应的js文件。

(2)请求详情

# Request URL 
https://api.geetest.com/gettype.php?gt=25ba81caec944f8d74c98befd841a667&callback=geetest_1605974702024 
 
# Query String Parammeters 
gt: 25ba81caec944f8d74c98befd841a667 
callback: geetest_1605974702024 
 
# Response 
geetest_1605974702024({status: "success",…}) 
data: {type: "fullpage", voice: "/static/js/voice.1.2.0.js", maze: "/static/js/maze.1.0.1.js",…} 
aspect_radio: {slide: 103, voice: 128, click: 128, pencil: 128, beeline: 50} 
beeline: "/static/js/beeline.1.0.1.js" 
click: "/static/js/click.2.9.4.js" 
fullpage: "/static/js/fullpage.9.0.2.js" 
geetest: "/static/js/geetest.6.0.9.js" 
maze: "/static/js/maze.1.0.1.js" 
pencil: "/static/js/pencil.1.0.3.js" 
slide: "/static/js/slide.7.7.5.js" 
static_servers: ["static.geetest.com/", "dn-staticdown.qbox.me/"] 
type: "fullpage" 
voice: "/static/js/voice.1.2.0.js" 
status: "success" 

请求3:fullpage.js

请求介绍

该js文件就是极验验证码的核心文件,其主要功能是指纹数据、环境检测数据收集。获取js文件可以通过https://static.geetest.com/static/js/fullpage.9.0.2.js得到。

请求4:get.php

(1)请求介绍

该请求主要发送的内容是通过执行fullpage.js文件收集的浏览器数据,用于后续设备指纹计算以及初步风险检测。如果该请求伪造得足够好,就会触发无感验证

(2)关键步骤

​ 流程图

极验get_php1请求

​ a、数据收集

​ 浏览器数据:js文件元素、浏览器大小、浏览器插件、canvas、字体、时区等数据

{        
        textLength, 
        HTMLLength, 
        documentMode, 
        A, 
        IMG, 
        INPUT, 
        LINK,SPAN, 
        STYLE, 
        screenLeft, 
        screenTop, 
        screenAvailLeft, 
        screenAvailTop, 
        innerWidth, 
        innerHeight, 
        outerWidth, 
        outerHeight, 
        browserLanguage, 
        browserLanguages, 
        devicePixelRatio, 
        colorDepth, 
        userAgent, 
        screenWidth, 
        screenHeight, 
        screenAvailWidth, 
        screenAvailHeight, 
        localStorageEnabled, 
        sessionStorageEnabled, 
        indexedDBEnabled, 
        platform, 
        doNotTrack, 
        timezone, 
        canvas2DFP, 
        canvas3DFP, 
        plugins, 
        maxTouchPoints, 
        flashEnabled, 
        javaEnabled, 
        hardwareConcurrency, 
        jsFonts, 
        timestamp, 
        performanceTiming 
  ...等等(不完全暴露,以免被有心人利用) 
}; 

​ b、格式处理

​ 在每个收集的数据中间,通过“!”感叹号来对数据进行切割。

​ c、请求参数构造

{ 
	      gt: gt, 
        challenge: challenge, 
        new_captcha: true, 
        protocol: https == true ? "https://" : "http://", 
        beeline: scriptInfo.beeline, 
        fullpage: scriptInfo.fullpage, 
        static_servers: scriptInfo.static_servers, 
        pencil: scriptInfo.pencil, 
        click: scriptInfo.click, 
        voice: scriptInfo.voice, 
        slide: "/static/js/slide.7.7.5.js", 
        geetest: "/static/js/geetest.6.0.9.js", 
        https: https, 
        i: # 收集的浏览器数据  
} 

​ d、明文请求参数加密

​ 使用对称加密算法对上述明文参数进行加密(可能是AES)。

​ e、构造密文请求参数

gt: 25ba81caec944f8d74c98befd841a667 
challenge: 61f4492c9e8ea1e136e98b38107d561e 
lang: zh-cn 
pt: 0 
client_type: web 
w: Wt(lNJWNy9DeW5Z6nJck3NZCQaoyQdi3TTcxtdnFpU65OTMLZvjnrK9bgDx94DdhAlV0bvg61eh)qX0m(bWYmvFzG84QiCW7S5tLICB4QMC(zoR0YLHui9VVj6iJwWEK9lFIqklAGbsFUYHM3GEGr6mrnflcVvbIyyo8SJGIF4j70VqCLwmmcChYl4TX9GZQb0pN0)dJHSIJucHlyrrxhSpqk4b(ox65Ur4IX)De0of3r6WB78QI7)XNqxKheWL(L7peMT)f(bIl6ut5S1gO7d9dRSSZac9SjtQGUfXPNHtbm1tOts(zRdjihk8z)Zfsh)JFqM4QQgrhnd6wBOQ8pyv60bjgpONQeJdKnNBIb(SXgo)flKztgLn1cehGDcCTTQcNlnWi5E7R)(5X01pqSyc16(8YSj)CXk2T6JHUXCXXFAXrSFWs7noM4IR7KUawc1KLmu4lDLA913wOOGoCv5C06D4D48IkVeDIalagtcLwMVd(S7TAVVwWtxXXzsnxLipWbB9HjYSiYPeg3YzjvnJpbV)oDukpEkYkl2kjs53ucZ8jo33(QE09ubUvMLgQuHwIWOoqaO5VJ4ESffY)87yPJrLJprSRUTYHmuTAo6yyI0OeQGk5CHxx67iHrgzHnNxAAPZY5yrv)CJ3xcBhZgu0tk8lCYgiH1wbigIChhPgd5QTP0nJiOJPgQs76yVkvX7bLEMWJfWjLqIzZ1hd9XQmt)2yGvVLC0iiApcqGuKSvRhxvVrW01WPp6pzFOywFXULhI7vsqUOTvqoNnwJtnSv1b40F)F2y6lC8LRsj1AKBcxREtAtqKvpXOcCFPxT2qMdLKgISgYJ33RVknFDS4JfOhTk9AgXBFtSJ2zM7tpPROoRoBsPVMOrbO)mdip4Z62PxxSDS8cA0PW980wi6ZhaDamumAlxx8RQKLPW587)9Xehn5s6cIMdMFRIAubg0VXlnW5Us2IvKeI6cjEfHNMyCJz4Fmv3)IYsXh3iigq87dCjtkGlGiVTrjjo2q44e(qr0GAo5CrxuKO)EgbdLDAyqf)5WFlSx)VXn5UoZF(AunphgVIn4(vMeFVWN(fWYj(MKztePyzCi2Cdd3pLrrL2IrD7NvNo87wvdX6ro5Q6GVVHP14IvrQsArUDdnIZjz5kMJ0IG0rsd2oQL2XFndtTcuJNlRewL5KYai(K2uPNjCQmXLfEfH2LMIjerHM126aAv5EhwLuFhvxKhIjoEGoQqMGg3FZorOHWIJEt6jSDtKNwLeeUXomknlRtaVwVCJJkrR9MfM8vldLCZ..e581bf73fb48171a223c9fac8fc74f151438380e515f1775cb26d78086253beef82f250f02349285fd86ed2d52d0acb6f45fa1733340ea282c3524c432d93df20d22b28c2c382e1ad52d72b20fcc2104188b7e99d11ca440325cb4391e34d78f2122162d3e3fb3efa810139c6d1f933b1dacfdc1e044686369271275d2ac258a 

​ w参数:步骤4中对称加密后的数据(gt、chanllenge、浏览器数据、验证码js路径)+ 使用非对称加密对“对称加密密钥”进行加密后的加密串

​ f、返回数据

geetest_1605981310309({ 
    "status": "success", 
    "data": { 
        "logo": false, 
        "s": "73304840", 
        "i18n_labels": { 
            "read_reversed": false, 
            "copyright": "u7531u6781u9a8cu63d0u4f9bu6280u672fu652fu6301", 
            "goto_confirm": "u524du5f80", 
            "ready": "u70b9u51fbu6309u94aeu8fdbu884cu9a8cu8bc1", 
            "goto_homepage": "u662fu5426u524du5f80u9a8cu8bc1u670du52a1Geetestu5b98u7f51", 
            "next": "u6b63u5728u52a0u8f7du9a8cu8bc1", 
            "next_ready": "u8bf7u5b8cu6210u9a8cu8bc1", 
            "loading_content": "u667au80fdu9a8cu8bc1u68c0u6d4bu4e2d", 
            "success": "u9a8cu8bc1u6210u529f", 
            "fullpage": "u667au80fdu68c0u6d4bu4e2d", 
            "reset": "u8bf7u70b9u51fbu91cdu8bd5", 
            "goto_cancel": "u53d6u6d88", 
            "refresh_page": "u9875u9762u51fau73b0u9519u8befu5566uff01u8981u7ee7u7eedu64cdu4f5cuff0cu8bf7u5237u65b0u6b64u9875u9762", 
            "success_title": "u901au8fc7u9a8cu8bc1", 
            "error_content": "u8bf7u70b9u51fbu6b64u5904u91cdu8bd5", 
            "error": "u7f51u7edcu4e0du7ed9u529b", 
            "error_title": "u7f51u7edcu8d85u65f6" 
        }, 
        "static_servers": ["static.geetest.com", "dn-staticdown.qbox.me"], 
        "theme": "wind", 
        "feedback": "", 
        "c": [12, 58, 98, 36, 43, 95, 62, 15, 12], 
        "api_server": "api.geetest.com", 
        "theme_version": "1.5.8" 
    } 
}) 

​ g、无感验证

如果该请求伪造的浏览器信息足够好,就会触发无感验证,不需要进行加强验证。

# Response 
geetest_1606035710872({status: "success", data: {s: "6b402d61", theme: "wind", api_server: "api.geetest.com",…}}) 
data: {s: "6b402d61", theme: "wind", api_server: "api.geetest.com",…} 
api_server: "api.geetest.com" 
c: [12, 58, 98, 36, 43, 95, 62, 15, 12] 
feedback: "" 
i18n_labels: {success_title: "通过验证", refresh_page: "页面出现错误啦!要继续操作,请刷新此页面", ready: "点击按钮进行验证", next: "正在加载验证",…} 
logo: false 
s: "6b402d61" 
static_servers: ["static.geetest.com", "dn-staticdown.qbox.me"] 
theme: "wind" 
theme_version: "1.5.8" 
status: "success" 

请求5:ajax.php

(1)请求介绍

​ a、请求详情

# Request URL 
https://api.geetest.com/ajax.php? 
 
# Query String Parameters 
gt: 25ba81caec944f8d74c98befd841a667 
challenge: f91e9b5f7cb34fc2fef98a1281c4f9a5 
lang: zh-cn 
pt: 0 
client_type: web 
w: PN3AyfkANbA5SEGeV3zj3wrdYwzvdZZw0hxaGHTXJUKFj7oeqLehkFa0c2Wma0D)DkvqU4xfIcbZGjnFyBK0NQ7VFAKCE(BnrKk5RDHCLXGrU3jkPh1pPGCXxywO2y2gg332yjxU7Wk7ZZzYroMNgrNZdc4ebUioVkgivWUbGFSEOBLPBPtU3Mg56FixAAO8jr1VsKXQsJFbmmMeGZ)QgmtJ9xUOhmFXjBNIbfVlsxvFljpNYaGrYxb7jV8(PhtHROTS37gGcpBoLuCXJo1iSHXEPixniDFZoQYt8r9gxFiK)CTPgwmiqXHeg0mkCQTxUTDr1)fVw9(1DCVTOXgXwCQ3LDIfdmi7bTNOqOf2F)8kXGv8g8cvMcSxkoAK(FWIblKoHjk4BT(thhJG4oyphzxQkRFLjXKE8aEmBI1Wn3legt66SGj3zZJk94OyWrkEWLyK2YnT7SYS1KVjj1Gd81mZlVA5P5sfnhZl72IRuaLGWn4jIFJhcd0dAZs5sTrIXzMpmoInN6TvMHTlux3oHs3c6l8TUPExxMoQ6oMLVAi6IZM0hrUDozyrWRJ8UT6KaeKBIgruAM)YXdQCGM4zDzL0fPwzTJC3cmlBLFmuGE(hAxbBzCuuyD8)7g2no7n0okLw9tpovsBaISZLH8pP4ujt05oz0ekEYnYZloSgQFTs40s(31TB8Pg5IO7Mg83WqgvDhKH1t1nsgqtwEmOuP6ra1yV6UHqqcg1MoPb2Rk5IbXws)utkSbrfLBlEYKVNuCqIuTqr9pvvhnHSeD5Y7pJYLBqS6sWCNQo8H()S8bQ)R2n0j8kAGUnJ27tIHzVKJE3BiO5ZO4WudFKpcqQVffhPpjtzl(f65)nLI5Hd0X7MLpXbUR36DC7FkTHwlVR4jMh3s2MboNIhpxuzzDgNzxwH9gmlgPpL3eU0s2UYGUY5L94DWTNktRlTaVEGNdpDAIoaoVKC6uf2wBJvwZh0TWrhGr2PdHiBpcmJYXlDpH0csf5PTGyBHxcNv0(AiOoKsYc0xcaLUJq)OlFBzErRIbxTnG1bfB4u1KG9vBs)qxGqux7n8DfIQ8tQCswqKk(5Yr7fnGTlO6zGlPmMQdcSfuCasd9T573MrZsIc(sX)VC5wc4Rd2BI31RVbu6P7DhQBnt)1IPPLKOmNo)liGCgG9PaFyAX(TJvyD5DDKDE)0fAbl7DD2i9NBW)Eoq9lVDalE(F8xxnlVxfQCJP)CyJEG8F0SxJo4AG6kQF(JFOEn8zH)UDbeYz1tgOWEcO0hDTdlmOIEVP1Ipmrpa95bQm4lSlbtE(vFjy2NrWt1AN)fyAgIvWaQH9bypqoUinzSxK4DJlaipaMee3Z9odzZw9aB5z9KaEixqDrCsf7H7Nfus. 
callback: geetest_1605981541804 
 
# Response 
geetest_1605981541804({"status": "success", "data": {"result": "slide"}}) 

问题:w参数如何生成?

(2)关键步骤

​ a、数据收集

浏览器数据:再一次收集“请求4”中的浏览器数据。 

​ b、格式处理

​ (1)在每个收集的数据中间,通过“!”感叹号来对数据进行切割。

​ (2)在每个收集的数据中间,通过“magic”来对数据进行切割。例子:11078magic data34095magic dataCSS1Compatmagic data168magic data-1magic data-1magic data-1magic

​ 此处相对于“请求4”有点不一样,为什么一份数据要用两种方式进行切割,请求4与请求5都发送一遍,我也没想明白。

​ c、鼠标数据收集

​ 数据格式:行为 + x坐标 + y坐标 + 时间戳 + 行为

var pointArray = [["move",900,400,1552388419164,"pointermove"],["move",904,397,1552388419180,"pointermove"],["move",911,381,1552388419195,"pointermove"],["move",916,379,1552388419210,"pointermove"],["move",923,377,1552388419225,"pointermove"],["move",930,373,1552388419240,"pointermove"],["move",937,369,1552388419256,"pointermove"],["move",942,366,1552388419271,"pointermove"],["move",949,364,1552388419287,"pointermove"],["move",953,362,1552388419302,"pointermove"],["move",957,360,1552388419318,"pointermove"],["move",961,356,1552388419333,"pointermove"],["move",966,352,1552388419349,"pointermove"],["move",973,350,1552388419364,"pointermove"],["move",978,348,1552388419380,"pointermove"],["move",983,345,1552388419396,"pointermove"],["move",990,343,1552388419411,"pointermove"],["move",994,340,1552388419427,"pointermove"],["move",999,336,1552388419442,"pointermove"],["down",1059,411,1552388422125,"pointerdown"],["focus",1552388422126],["up",1059,411,1552388422375,"pointerup"]];

​ d、s与c参数加密

​ s参数与c参数是“请求4返回的”,我的理解是与s参数是“请求4”进行绑定而c参数是图片顺序(从极验服务器返回的图片是被无规则切割后的,我们需要c参数配合算法还原)

极验打乱图片

​ e、上述参数各种加密后进行再一次加密

​ f、生成最终w参数

​ 与“请求4”中的w参数加密方法相同。

​ w参数:(gt, challenge, ip, version, c, s, 浏览器信息, 鼠标轨迹)对称加密 + 使用非对称加密对“对称加密密钥”进行加密后的加密串

​ g、数据结构图

​ 此处加密结构实在是太过于冗余,所以用图的方式更清晰。

极验w参数加密1

请求6:slide.js

请求介绍

“请求5”中Response返回数据geetest_1605981541804({"status": "success", "data": {"result": "slide"}})表明,使用滑块进行加强验证。后续进行滑块验证码验证时,会使用该js进行数据收集与加密处理。

请求详情

# Request URL 
https://static.geetest.com/static/js/slide.7.7.5.js 
 
# Response 
返回滑块验证相关js代码 

请求7:get.php

(1)请求介绍

​ 获取验证码相关信息,例如图片路径、图片还原数组,请求串联参数challenge、y坐标等数据。

(2)请求详情

geetest_1605982735902({ 
    "hide_delay": 800, 
    "static_servers": ["static.geetest.com/", "dn-staticdown.qbox.me/"], 
    "logo": false, 
    "https": true, 
    "width": "100%", 
    "feedback": "", 
    "product": "embed", 
    "so": 0, 
    "ypos": 37, 
    "link": "", 
    "version": "6.0.9", 
    "fullbg": "pictures/gt/7d068eca5/7d068eca5.jpg", 
    "clean": false, 
    "height": 160, 
    "xpos": 0, 
    "theme_version": "1.2.4", 
    "id": "aa812df54ff9aee0ddb35400abe906992", 
    "gt": "25ba81caec944f8d74c98befd841a667", 
    "s": "476e6b52", 
    "api_server": "https://api.geetest.com/", 
    "slice": "pictures/gt/7d068eca5/slice/b5afeb19a.png", 
    "i18n_labels": { 
        "logo": "u7531u6781u9a8cu63d0u4f9bu6280u672fu652fu6301", 
        "cancel": "u53d6u6d88", 
        "close": "u5173u95edu9a8cu8bc1", 
        "error": "u8bf7u91cdu8bd5", 
        "feedback": "u5e2eu52a9u53cdu9988", 
        "voice": "u89c6u89c9u969cu788d", 
        "success": "sec u79d2u7684u901fu5ea6u8d85u8fc7 score% u7684u7528u6237", 
        "tip": "u8bf7u5b8cu6210u4e0bu65b9u9a8cu8bc1", 
        "read_reversed": false, 
        "refresh": "u5237u65b0u9a8cu8bc1", 
        "fail": "u8bf7u6b63u786eu62fcu5408u56feu50cf", 
        "forbidden": "u602au7269u5403u4e86u62fcu56feuff0cu8bf7u91cdu8bd5", 
        "loading": "u52a0u8f7du4e2d...", 
        "slide": "u62d6u52a8u6ed1u5757u5b8cu6210u62fcu56fe" 
    }, 
    "theme": "ant", 
    "bg": "pictures/gt/7d068eca5/bg/b5afeb19a.jpg", 
    "mobile": true, 
    "challenge": "a812df54ff9aee0ddb35400abe906992lw", 
    "show_delay": 250, 
    "benchmark": false, 
    "type": "multilink", 
    "fullpage": false, 
    "template": "", 
    "c": [12, 58, 98, 36, 43, 95, 62, 15, 12] 
}) 
 

请求8:ajax.php

(1)请求介绍

该请求就是最重要的一步,验证码验证数据收集,主要收集数据包括滑块相对偏移位置(x坐标)、鼠标滑动轨迹、c参数、s参数、版本信息等。

(2)请求详情

# Request URL 
https://api.geetest.com/ajax.php? 
 
# Query String Param 
gt: 25ba81caec944f8d74c98befd841a667 
challenge: a812df54ff9aee0ddb35400abe906992g1 
lang: zh-cn 
pt: 0 
client_type: web 
w: 01xw)7RkAQTxgt5(KAirHJNk(GQHPSqovqV(huofhVj6LOrChUNg6NV)sMQYfBVZFGoug6B7VB0X)0rw3kI3rEXkMGOk1ewLqxZTVSDud7N6ryucakpAMXzhXRimQa4vPmjYz1nus80DQKvG7iq6XPSbdFxARitg0b4TIcRgX(3AOGK)V2cujs6ExkH7puvD9M8887mK6lCSee6FfBXrO2PdgmlamfM8omcLDwkDECw4g9fODBjYzKnSb1qq27JIyEfyBT77A1xmfhBtgJ8vKEIsm5MyR7LZGMIrXYMwd5IL0317NtnpvpeMGXey8DbABEt43y0UQDpIxkkfwbzJs6BGUKI)FGKlmO5ZA4gX5V(t951E76rZVmSAJBuNuv(doL5nYt(LdhoEq2ElpMts02jxmGT9Zkf0(H3McshaIWT5pcyM6ReRXVbOo2WFzxXZz9ITykQjFtoTr(ld4ydqpvejZSxyUZk5FIhKe4PYExT1Lms2sMXZu)gHYGFRmJf8KlYfsArButqV4zkhSajAnvE0cN1dhkB5J36rlwDqT6tG4XqJ9GbY1BcCisT1GKCEy402TCeCHeE)PfDKBeMzJ0ZeWpnVEEYmciKtc9eCfdklIrEUefWMYDdX0IUIDyjQ7rvPghprHhdw(uFp1UPAmTraHyxqVAOcJBd1YFkOLI9xoBdmFP9n0UJVXtuzcCvVNIPPBznXmw6RaEoGg(i1((OkQeu9lp4BqFRQmS76NFd5oJ1LVT5o)((CzOsB03X2L6FIeLVw(v6Y09QAmFRfqw..7bce8d8ab16eaf8c1342a4a7b3e7b0100f58082dd49d8cc5d8ee528f161bb0ba579580015dce1747d454b545158b47f0bf4660f293adf3fc8392a86f498eec6ebb5fb6bc891e696987aef7d9d5282d9dce43729ac87a3515283b833b028bca48a5d5004842cd88bee068f495fbcb02ae4c493bc51dbb67811bb49852f498be64 
callback: geetest_1605984542722 
 
# Response 
geetest_1605984542722({"message": "success", "success": 0}) 

关键步骤

​ a、图片还原

​ 配合前序请求返回的c数组和图片还原算法对被切割打乱的图片进行还原。

​ b、缺口识别

​ 计算x坐标可以参考我的另一篇文章《第三代验证码研究》IT虾米网

​ c、w参数

​ (gt, challenge, x坐标, 滑动轨迹, c参数, s参数, 版本)对称加密 + 使用非对称加密对“对称加密密钥”进行加密后的加密串

​ 使用对称加密对参数进行加密,再使用非对称加密对密钥进行加密

​ d、数据图

​ 此处加密结构实在是太过于冗余,所以用图的方式更清晰

极验w参数加密2

4、整体流程

极验整体流程

三、成果展示

极验成果

一旦验证码验证通过就会返回validate。validate可以理解为通行令牌,该令牌会将环境检测数据、行为数据以及风险结果等数据进行串联,一般情况下如果成功获取到validate参数,就预示着我们破解极验验证码工作取得成功。

四、总结

总体来说,极验验证码的整体设计不算复杂,但数据加密实在是太过于冗余复杂了。从设计角度上看中规中矩,环境数据收集 -> 环境检测 -> 加强验证/无感验证 -> 再次数据收集(环境 + 行为)-> 完成验证。相对而言我个人觉得顶象和瑞数的设计可能更有特点一些,在破解和对抗的难度上来讲,它们也相对更难一些。

五、最后

本文配合其他文章一起服用效果更好,能更全面体会安全产品的设计。
(1)《第三代验证码研究》IT虾米网

(2)《顶象验证码破解与研究》IT虾米网

(3)《极验验证码破解与研究》IT虾米网

(4)《极验无感验证破解》IT虾米网

(5)《同盾小程序指纹破解》IT虾米网

本文不提供完整解决方案和完整数据,仅用于理论研究,维护网络安全,人人有责。

本文内容仅限于安全研究,不公开具体源码。维护网络安全,人人有责。

本文配合其他文章一起服用效果更好,能更全面体会安全产品的设计。
(1)《第三代验证码研究》IT虾米网

(2)《顶象验证码破解与研究》IT虾米网

(3)《极验验证码破解与研究》IT虾米网

(4)《极验无感验证破解》IT虾米网

(5)《同盾小程序指纹破解》IT虾米网

本文主要通过破解协议的方式绕过极验安全验证,思路与网上自动化的方式有很大的不同

原文地址:https://www.cnblogs.com/boycelee/p/14021048.html


评论关闭
IT干货网

微信公众号号:IT虾米 (左侧二维码扫一扫)欢迎添加!

金融业务全链路探秘