dongmei8511 2014-03-07 14:57
浏览 125
已采纳

Traceroute通过php(或其他东西)到不同的IP

I need to figure out a way that users in my internal network can trigger a traceroute from their PC to a particular server that is not the webhost server. My thought is to somehow open a telnet session on their PC using admin rights, run the traceroute, and somehow retrieve that data and put it back on the webpage. I would like to do this with as little user interaction as possible.

Is there even a remote possibility that this can be done? I am able to open a telnet session with fsock, but that is as far as I have gotten.

  • 写回答

1条回答 默认 最新

  • duanjiong1952 2014-03-07 15:00
    关注

    No you can't. PHP runs on the server, not on the client. So the traceroute will be started from the server which is running the PHP script. It will never trigger a traceroute from the PC of the user requesting the website.

    I am able to open a telnet session with fsock, but that is as far as I have gotten.

    You can do that with PHP, but this connection is from your server on which the PHP script is running. It will never be from the client requesting the website. So in the form you stated your question now, the answer is: NO that is not possible.

    However please see this SO question Here a java applet is suggested. A Java applet runs in the client browser and IS capable of doing a traceroute from the clientside. So that will be the way to go for you. But this has nothing to do with PHP at all.

    本回答被题主选为最佳回答 , 对您是否有帮助呢?
    评论

报告相同问题?

悬赏问题

  • ¥100 set_link_state
  • ¥15 虚幻5 UE美术毛发渲染
  • ¥15 CVRP 图论 物流运输优化
  • ¥15 Tableau online 嵌入ppt失败
  • ¥100 支付宝网页转账系统不识别账号
  • ¥15 基于单片机的靶位控制系统
  • ¥15 真我手机蓝牙传输进度消息被关闭了,怎么打开?(关键词-消息通知)
  • ¥15 装 pytorch 的时候出了好多问题,遇到这种情况怎么处理?
  • ¥20 IOS游览器某宝手机网页版自动立即购买JavaScript脚本
  • ¥15 手机接入宽带网线,如何释放宽带全部速度