【问题标题】:express-api gets /inform post from localhostexpress-api 从 localhost 获取 /inform 帖子
【发布时间】:2021-06-14 05:51:20
【问题描述】:

在我的 express rest-api 上,我每分钟都会记录一个 /inform 帖子。

::ffff:127.0.0.1 POST /inform 404 146 - 69.963 ms
::ffff:127.0.0.1 POST /inform 404 146 - 62.149 ms
::ffff:127.0.0.1 POST /inform 404 146 - 20.479 ms

我已将 apache2 代理从 api.domain.com:80 配置到 localhost:8080(这是我的 express-api),其他一切正常。

系统是Debian10,有node、apache2、php等:

node -v
v10.24.0

npm -v
7.6.0

php -v
PHP 7.3.27-1~deb10u1 (cli)

/usr/sbin/apache2 -v
Server version: Apache/2.4.38 (Debian)
Server built:   2020-08-25T20:08:29

这显然与代理有关,但我不知道是什么。 Apache2-Config:

<IfModule mod_ssl.c>
<VirtualHost *:443>
        ServerName api.domain.com
        ServerAdmin webmaster@api.domain.com

        ProxyPreserveHost On
        ProxyRequests Off
        ProxyPass / http://localhost:8080/
        ProxyPassReverse / http://localhost:8080/
        KeepAlive Off

        <Proxy *>
                Order deny,allow
                Allow from all
        </Proxy>

        # certs here
</VirtualHost>
</IfModule>

谁能告诉我这是从哪里来的?

【问题讨论】:

  • 我看到了同样的事情。您的网络中有任何 Ubiquiti 设备吗?我在想它可能是一个试图联系其控制器的 AP:jrjparks.github.io/unofficial-unifi-guide/protocols/inform.html
  • 其实我在家使用的是统一安全网关。一定是这样,谢谢!
  • 然后我将其发布为答案。如果您可以将其标记为正确,那就太好了:-)

标签: api rest express proxy apache2


【解决方案1】:

如果您的网络中有任何 Ubiquiti 设备,他们可能会尝试“打电话回家”到在同一端口上运行的 Unify 控制器应用程序。见 jrjparks.github.io/unofficial-unifi-guide/protocols/inform.html

我遇到了同样的问题,并通过在一个未被恶意网络成员 ping 的不同端口上运行我的应用程序来解决它。

【讨论】:

    猜你喜欢
    • 1970-01-01
    • 2015-11-30
    • 2019-11-30
    • 2023-03-29
    • 1970-01-01
    • 2020-02-07
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多