Codex 登录报错:token_exchange_failed 解决

Codex 登录报错:token_exchange_failed 现象 下载 Windows 版 Codex 后,进行账号登录,跳转浏览器授权回调后,页面卡住,返回客户端直接报错: 1 2 3 Sign-in could not be completed Token exchange failed: error sending request for url (https://auth.openai.com/oauth/token) Error code: token_exchange_failed 原因 全局代理环境变量: 1 2 3 HTTP_PROXY=socks5://127.0.0.1:1080 HTTPS_PROXY=socks5://127.0.0.1:1080 ALL_PROXY=socks5://127.0.0.1:1080 系统所有网络请求(包括本地 localhost:1455 登录回调)全部走代理; Codex 本地监听 1455 端口等待浏览器回调请求,但请求被代理拦截转发; 本地服务收不到回调请求,授权令牌无法交换,直接抛出 token_exchange_failed; 解决 1. 在 PowerShell 添加 NO_PROXY 环境变量 以普通 PowerShell 执行,适配代理端口 1080: 1 2 3 4 [Environment]::SetEnvironmentVariable("HTTP_PROXY", "socks5://127.0.0.1:1080", "User") [Environment]::SetEnvironmentVariable("HTTPS_PROXY", "socks5://127.0.0.1:1080", "User") [Environment]::SetEnvironmentVariable("ALL_PROXY", "socks5://127.0.0.1:1080", "User") [Environment]::SetEnvironmentVariable("NO_PROXY", "localhost,127.0.0.1,::1,192.168.0.0/16,10.0.0.0/8", "User") 或者直接添加环境变量也可以 ...

May 9, 2026 · 1 min · 84 words · flash122u

Vulnhub Nullbyte

信息收集 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 ┌──(root㉿kali)-[~] └─# arp-scan 192.168.56.0/24 Interface: eth0, type: EN10MB, MAC: 00:0c:29:ef:b6:d2, IPv4: 192.168.56.107 Starting arp-scan 1.10.0 with 256 hosts (https://github.com/royhills/arp-scan) 192.168.56.1 0a:00:27:00:00:0d (Unknown: locally administered) 192.168.56.100 08:00:27:d8:6c:85 PCS Systemtechnik GmbH 192.168.56.113 08:00:27:b5:82:c6 PCS Systemtechnik GmbH 3 packets received by filter, 0 packets dropped by kernel Ending arp-scan 1.10.0: 256 hosts scanned in 2.139 seconds (119.68 hosts/sec). 3 responded ┌──(root㉿kali)-[~] └─# nmap 192.168.56.113 -p- -sT -sV Starting Nmap 7.95 ( https://nmap.org ) at 2026-03-07 10:22 EST Nmap scan report for 192.168.56.113 Host is up (0.017s latency). Not shown: 65531 closed tcp ports (conn-refused) PORT STATE SERVICE VERSION 80/tcp open http Apache httpd 2.4.10 ((Debian)) 111/tcp open rpcbind 2-4 (RPC #100000) 777/tcp open ssh OpenSSH 6.7p1 Debian 5 (protocol 2.0) 45114/tcp open status 1 (RPC #100024) MAC Address: 08:00:27:B5:82:C6 (PCS Systemtechnik/Oracle VirtualBox virtual NIC) Service Info: OS: Linux; CPE: cpe:/o:linux:linux_kernel Service detection performed. Please report any incorrect results at https://nmap.org/submit/ . Nmap done: 1 IP address (1 host up) scanned in 26.07 seconds ┌──(root㉿kali)-[~] └─# gobuster dir -u http://192.168.56.113/ -w /usr/share/wordlists/dirbuster/directory-list-2.3-medium.txt =============================================================== Gobuster v3.6 by OJ Reeves (@TheColonial) & Christian Mehlmauer (@firefart) =============================================================== [+] Url: http://192.168.56.113/ [+] Method: GET [+] Threads: 10 [+] Wordlist: /usr/share/wordlists/dirbuster/directory-list-2.3-medium.txt [+] Negative Status codes: 404 [+] User Agent: gobuster/3.6 [+] Timeout: 10s =============================================================== Starting gobuster in directory enumeration mode =============================================================== /uploads (Status: 301) [Size: 318] [--> http://192.168.56.113/uploads/] /javascript (Status: 301) [Size: 321] [--> http://192.168.56.113/javascript/] /phpmyadmin (Status: 301) [Size: 321] [--> http://192.168.56.113/phpmyadmin/] /server-status (Status: 403) [Size: 302] Progress: 220560 / 220561 (100.00%) =============================================================== Finished =============================================================== 尝试 phpmyadmin 漏洞 参考 phpmyadmin漏洞汇总-CSDN博客 ...

March 7, 2026 · 6 min · 1137 words · flash122u

使用 VMware 和 VirtualBox 搭建靶机环境

环境为 Windows 系统。 准备 virtualbox 配置 下载 virtualbox 修改网络配置 Vmware 配置 下载 Vmware 并激活 1 2 3 4 5 6 VMware Workstation Pro 17 许可证密钥(任选其一即可): NZ4RR-FTK5H-H81C1-Q30QH-1V2LA MC60H-DWHD5-H80U9-6V85M-8280D JU090-6039P-08409-8J0QH-2YR7F 4A4RR-813DK-M81A9-4U35H-06KND ZF3R0-FHED2-M80TY-8QYGC-NPKYF 配置网卡: 编辑 –> 虚拟网络编辑器 修改 VMnet0 桥接至 VirtualBox Host-Only Ethernet Adapter VMnet8 设置: Kali 配置 下载并安装 Kali (或使用 清华源 下载) 配置如下 靶机 下面以 vulnhub-NullByte 靶机为例 在 virtualbox 导入 .ova 后缀的文件 导入后设置网络: 设置完成后启动靶机 在 kali 中查看网卡参数: 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 ┌──(root㉿kali)-[~] └─# ifconfig eth0: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500 inet 192.168.56.107 netmask 255.255.255.0 broadcast 192.168.56.255 inet6 fe80::9013:58b7:1178:dd00 prefixlen 64 scopeid 0x20<link> ether 00:0c:29:ef:b6:d2 txqueuelen 1000 (Ethernet) RX packets 225 bytes 127893 (124.8 KiB) RX errors 0 dropped 0 overruns 0 frame 0 TX packets 774 bytes 137194 (133.9 KiB) TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0 eth1: flags=4163<UP,BROADCAST,RUNNING,MULTICAST> mtu 1500 inet 192.168.58.132 netmask 255.255.255.0 broadcast 192.168.58.255 inet6 fe80::5271:3d12:3c26:10f8 prefixlen 64 scopeid 0x20<link> ether 00:0c:29:ef:b6:dc txqueuelen 1000 (Ethernet) RX packets 581 bytes 198134 (193.4 KiB) RX errors 0 dropped 0 overruns 0 frame 0 TX packets 414 bytes 59761 (58.3 KiB) TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0 lo: flags=73<UP,LOOPBACK,RUNNING> mtu 65536 inet 127.0.0.1 netmask 255.0.0.0 inet6 ::1 prefixlen 128 scopeid 0x10<host> loop txqueuelen 1000 (Local Loopback) RX packets 8 bytes 480 (480.0 B) RX errors 0 dropped 0 overruns 0 frame 0 TX packets 8 bytes 480 (480.0 B) TX errors 0 dropped 0 overruns 0 carrier 0 collisions 0 看到 eth0 成功连上了 56 网段 ...

March 7, 2026 · 3 min · 542 words · flash122u

使用 Hugo 和 GitHub Pages 搭建博客

记录这个博客的搭建过程,实现 Typora 本地写作、Hugo 进行静态网页生成、GitHub Pages 公网访问。 一、安装 Hugo 1. 安装 Scoop 包管理器 1.1 打开 PowerShell 按下 Win + R,输入 powershell,按回车打开 PowerShell 终端。 1.2 允许执行脚本 运行以下命令以设置执行策略,允许执行远程签名的脚本。 1 Set-ExecutionPolicy -ExecutionPolicy RemoteSigned -Scope CurrentUser 如果提示是否更改执行策略,输入 Y 或 A 确认。 1.3 下载并安装 Scoop 运行以下命令安装 Scoop。 1 Invoke-RestMethod -Uri https://get.scoop.sh | Invoke-Expression 安装完成后,可通过以下命令验证 Scoop 是否安装成功。 1 scoop --version 2. 安装 Hugo 2.1 安装 Hugo 扩展版本 运行以下命令安装 hugo-extended 版本。 1 scoop install hugo-extended 安装完成后,验证 Hugo 是否安装成功。 1 hugo version 2.2 更新 Scoop 与 Hugo ...

January 5, 2026 · 8 min · 1684 words · flash122u