【报错】kali安装ngrok报错解决办法(zsh: exec format error: ./ngrok)

问题描述

kali安装ngrok令牌授权失败

在这里插入图片描述

在安装配置文件的时候报错:zsh: exec format error: ./ngrok

在这里插入图片描述

原因分析:

在Kali Linux上执行./ngrok时出现zsh exec格式错误的问题可能是由于未安装正确版本的ngrok或操作系统不兼容ngrok导致的。以下是一些可能的解决方法:

1、确保你已经从ngrok官网下载了适用于你的操作系统和架构的正确版本,并将其保存在正确的目录中。

2、检查ngrok文件的权限是否正确,可以运行 chmod +x ./ngrok 命令更改文件权限。

3、检查ngrok文件头是否正确,可以运行 file ./ngrok 命令查看文件类型和架构。

4、尝试更新你的操作系统,并重新安装ngrok。

如果上述方法都没有解决问题,可以尝试安装其他版本的ngrok或使用其他工具替代ngrok。

解决方案:

先查看自己的vps处理器架构

dpkg --print-architecture

在这里插入图片描述

之前ngrok下载的是Linux(ARM64)

但是我的处理器架构是AMD64

所以下载这个

在这里插入图片描述

授权令牌设置成功

在这里插入图片描述

bash: /: Is a directory api.ngrok.com: command not found bash: curl/8.12.1: No such file or directory bash: downloads/kali-nethunter-2024.4-generic-armhf-rootfs-minimal.zip: Permission denied ~ $ curl -X GET "https://api.ngrok.com/" \ -H "Ngrok-Version: 2" \ -H "User-Agent: YourApp/1.0" \ -H "Authorization: Bearer YOUR_NGROK_TOKEN" {"uri":"https://api.ngrok.com/","subresource_uris":{"abuse_reports":"https://api.ngrok.com/abuse_reports","agent_ingresses":"https://api.ngrok.com/agent_ingresses","api_keys":"https://api.ngrok.com/api_keys","certificate_authorities":"https://api.ngrok.com/certificate_authorities","credentials":"https://api.ngrok.com/credentials","edges_https":"https://api.ngrok.com/edges/https","edges_tcp":"https://api.ngrok.com/edges/tcp","edges_tls":"https://api.ngrok.com/edges/tls","endpoint_configurations":"https://api.ngrok.com/endpoint_configurations","endpoints":"https://api.ngrok.com/endpoints","event_destinations":"https://api.ngrok.com/event_destinations","event_subscriptions":"https://api.ngrok.com/event_subscriptions","failover_backends":"https://api.ngrok.com/backends/failover","http_response_backends":"https://api.ngrok.com/backends/http_response","ip_policies":"https://api.ngrok.com/ip_policies","ip_policy_rules":"https://api.ngrok.com/ip_policy_rules","ip_restrictions":"https://api.ngrok.com/ip_restrictions","reserved_addrs":"https://api.ngrok.com/reserved_addrs","reserved_domains":"https://api.ngrok.com/reserved_domains","ssh_certificate_authorities":"https://api.ngrok.com/ssh_certificate_authorities","ssh_credentials":"https://api.ngrok.com/ssh_credentials","ssh_host_certificates":"https://api.ngrok.com/ssh_host_certificates","ssh_user_certificates":"https://api.ngrok.com/ssh_user_certificates","static_backends":"https://api.ngrok.com/backends/static","tls_certificates":"https://api.ngrok.com/tls_certificates","tunnel_group_backends":"https://api.ngrok.com/backends/tunnel_group","tunnel_sessions":"https://api.ngrok.com/tunnel_sessions","tunnels":"https://api.ngrok.com/tunnels","weighted_backends":~ $ # 获取支持的API版本列表 curl -I https://api.ngrok.com/ -H "Ngrok-Version: 2" HTTP/2 200 content-type: application/json; charset=utf-8 date: Sat, 15 Mar 2025 09:37:05 GMT ngrok-operation-id: op_2uLciwto7lQaHgWmBNRCL3PEOde content-length: 1771 ~ $ # 使用HTTPie显示详细交互 http GET https://api.ngrok.com/ Ngrok-Version:2 # 使用openssl检查证书链 openssl s_client -connect api.ngrok.com:443 -showcerts No command http found, did you mean: Command httpd in package apache2 Command htop in package htop The program openssl is not installed. Install it by executing: pkg install openssl-tool
最新发布
03-16
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包

打赏作者

九芒星#

你的鼓励是我创作最大的动力

¥1 ¥2 ¥4 ¥6 ¥10 ¥20
扫码支付:¥1
获取中
扫码支付

您的余额不足,请更换扫码支付或充值

打赏作者

实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值