这是indexloc提供的服务,不要输入任何密码
Skip to content

Conversation

@timothycarambat
Copy link
Member

Block private octets of link-scraping & collection just in case a user self-hosts AnythingLLM on the same network as another service that has zero authentication or access controls on it. Attackers in this case would also need to explicitly be granted high-level permissions to accomplish this in addition to knowing valid internal IPs.

@timothycarambat timothycarambat merged commit 0db6c3b into master Jan 19, 2024
@timothycarambat timothycarambat deleted the security/block-private-octets branch January 19, 2024 18:49
@review-agent-prime
Copy link

collector/utils/url/index.js

The validURL function uses the URL object to validate the URL. However, it directly accesses the properties of the URL object, which can make the code less readable. By destructuring the URL object, we can improve the readability of the code.
Create Issue
See the diff
Checkout the fix

    function validURL(url) {
      try {
        const { protocol, hostname } = new URL(url);
        if (!VALID_PROTOCOLS.includes(protocol)) return false;
        if (isInvalidIp({ hostname })) return false;
        return true;
      } catch {}
      return false;
    }
git fetch origin && git checkout -b ReviewBot/Impro-jsa549v origin/ReviewBot/Impro-jsa549v

cabwds pushed a commit to cabwds/anything-llm that referenced this pull request Jul 3, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants