Distributions
› Ubuntu
› Fedora
› CentOS
中文资源站
› 网易开源镜像站
tyonly
V2EX  ›  Linux

在 Linux 上如何监控 PHP curl 对外请求的 HTTP 或者 HTTPS 域

  •  
  •   tyonly · Apr 26, 2020 · 5605 views
    This topic created in 2398 days ago, the information mentioned may be changed or developed.

    目前没有找到合适的工具,因此看看大家有没有合适的方案? 场景:某个 PHP 文件里 CURL 请求特定网址偷偷下载东西 目的:监控请求的是什么网址

    11 replies  •  2020-05-07 14:54:15 +08:00
    lhx2008
    lhx2008
    Apr 26, 2020 via Android
    1
    用 phptrace 来抓
    tyonly
    tyonly
    OP
    Apr 27, 2020
    2
    @lhx2008 我想监控所有的 PHP 文件对外请求状态 ,PHPTRACE 是个脚本?
    tyonly
    tyonly
    OP
    Apr 27, 2020
    3
    找到一个 tcpdump,研究中
    laojiaqing
    laojiaqing
    Apr 27, 2020
    4
    curl 前写日志,用 guzzle
    iminto
    iminto
    Apr 27, 2020
    5
    strace php 的进程就可以了。
    ···
    strace -p 24507
    ···
    tyonly
    tyonly
    OP
    Apr 27, 2020
    6
    我的目标是监控所有的 CMS 文件对外请求的。不是单个文件,所以想找到基于服务器的解决方案。
    yushuda
    yushuda
    Apr 28, 2020
    7
    定时下马?
    tyonly
    tyonly
    OP
    Apr 28, 2020
    8
    不是下马,是监控 CMS 有没有被人下马,链接到不该链接的网站上去下载东西了
    tanghongkai
    tanghongkai
    Apr 30, 2020
    9
    基于服务器的话可以走自己的 dns 服务器然后看日志吧
    tyonly
    tyonly
    OP
    May 7, 2020
    10
    @tanghongkai 服务器用的是阿里云,目前考虑方案是自己装包存储起来,然后在筛选
    About   ·   Help   ·   Advertise   ·   Blog   ·   API   ·   FAQ   ·   Privacy   ·   Solana   ·   956 Online   Highest 6679   ·     Select Language
    创意工作者们的社区
    World is powered by solitude
    VERSION: 3.9.8.5 · 32ms · UTC 20:15 · PVG 04:15 · LAX 12:15 · JFK 15:15
    ♥ Do have faith in what you're doing.