GIVE YOUR AGENT THE EVIDENCE

Set up in your agent.

One prompt to get started. Paste it into your coding agent to connect cve.new through MCP and bring vulnerability context into your workflow.

Your agent needs remote MCP support and access to https://cve.new/mcp.

Read the setup guide

GIVE YOUR AGENT THE EVIDENCE

Investigate in your agent.

Turn this advisory into a focused investigation. Ask your agent to check your project’s versions, explain the evidence, and suggest a compatible fix.

Your agent needs remote MCP support and access to https://cve.new/mcp.

Read the setup guide

GHSA-875x-g8p7-5w27medium5.3

The FIDO2/Webauthn Support for PHP library allows enumeration of valid usernames

Check your stack

The advisory, in context

Summary

The ProfileBasedRequestOptionsBuilder method returns allowedCredentials without any credentials if no username was found.

Details

When WebAuthn is used as the first or only authentication method, an attacker can enumerate usernames based on the absence of the allowedCredentials property in the assertion options response. This allows enumeration of valid or invalid usernames.

Proposal how to resolve it:

return $this->publicKeyCredentialRequestOptionsFactory->create(
            $this->profile,
            count($allowedCredentials) <= 0 ? self::getRandomCredentials(): $allowedCredentials,
            $optionsRequest->userVerification,
            $extensions
);

private static function getRandomCredentials(): array
{
        $credentialSources = [];
        for ($i = 0; $i <= rand(0,1); $i++) {
            $credentialSources[] = new PublicKeyCredentialSource(
                random_bytes(32),
                "public-key",
                [],
                "basic",
                new EmptyTrustPath(),
                Uuid::v7(),
                random_bytes(77),
                Uuid::v7()->__toString(),
                rand(0, 6000),
                null
            );
        }
        return array_map(
            static fn (PublicKeyCredentialSource $credential): PublicKeyCredentialDescriptor => $credential->getPublicKeyCredentialDescriptor(),
            $credentialSources
        );
}

PoC

curl https://example.com/assertion/options
-H 'content-type: application/json'
--data-raw '{"username":"NotMeRandomUsername123"}'

Impact

By knowing which usernames are valid, attackers can focus their efforts on a smaller set of potential targets, increasing the efficiency and likelihood of successful attacks.

Affected packages

Start with the recorded fix for your release branch. Check your installed version and test compatibility before upgrading. Fixing this advisory does not rule out other vulnerabilities in the release.

Ecosystem versions

From 4.5.0 before 4.9.0

Fixed in 4.9.0

26 explicitly affected versions

4.5.0, 4.5.1, 4.5.2, 4.6.0, 4.6.1, 4.6.2, 4.6.3, 4.6.4, 4.7.0, 4.7.1, 4.7.2, 4.7.3, 4.7.4, 4.7.5, 4.7.6, 4.7.7, 4.7.8, 4.7.9, 4.8.0, 4.8.1, 4.8.2, 4.8.3, 4.8.4, 4.8.5, 4.8.6, 4.8.7

View affected-version evidence
{
  "ranges": [
    {
      "events": [
        {
          "introduced": "4.5.0"
        },
        {
          "fixed": "4.9.0"
        }
      ],
      "type": "ECOSYSTEM"
    }
  ],
  "versions": [
    "4.5.0",
    "4.5.1",
    "4.5.2",
    "4.6.0",
    "4.6.1",
    "4.6.2",
    "4.6.3",
    "4.6.4",
    "4.7.0",
    "4.7.1",
    "4.7.2",
    "4.7.3",
    "4.7.4",
    "4.7.5",
    "4.7.6",
    "4.7.7",
    "4.7.8",
    "4.7.9",
    "4.8.0",
    "4.8.1",
    "4.8.2",
    "4.8.3",
    "4.8.4",
    "4.8.5",
    "4.8.6",
    "4.8.7"
  ]
}
Ecosystem versions

From 4.5.0 before 4.9.0

Fixed in 4.9.0

26 explicitly affected versions

4.5.0, 4.5.1, 4.5.2, 4.6.0, 4.6.1, 4.6.2, 4.6.3, 4.6.4, 4.7.0, 4.7.1, 4.7.2, 4.7.3, 4.7.4, 4.7.5, 4.7.6, 4.7.7, 4.7.8, 4.7.9, 4.8.0, 4.8.1, 4.8.2, 4.8.3, 4.8.4, 4.8.5, 4.8.6, 4.8.7

View affected-version evidence
{
  "ranges": [
    {
      "events": [
        {
          "introduced": "4.5.0"
        },
        {
          "fixed": "4.9.0"
        }
      ],
      "type": "ECOSYSTEM"
    }
  ],
  "versions": [
    "4.5.0",
    "4.5.1",
    "4.5.2",
    "4.6.0",
    "4.6.1",
    "4.6.2",
    "4.6.3",
    "4.6.4",
    "4.7.0",
    "4.7.1",
    "4.7.2",
    "4.7.3",
    "4.7.4",
    "4.7.5",
    "4.7.6",
    "4.7.7",
    "4.7.8",
    "4.7.9",
    "4.8.0",
    "4.8.1",
    "4.8.2",
    "4.8.3",
    "4.8.4",
    "4.8.5",
    "4.8.6",
    "4.8.7"
  ]
}

References