### CI Link

https://gradle-enterprise.elastic.co/s/awqa2s2dkorzs

### Repro line

./gradlew :libs:elasticsearch-core:test --tests "org.elasticsearch.jdk.JarHellTests.testNonJDKModuleURLs" -Dtests.seed=97CC4411A902D87D -Dtests.iters=2

### Does it reproduce?

Yes

### Applicable branches

main

### Failure history

_No response_

### Failure excerpt

> Task :libs:elasticsearch-core:test FAILED

REPRODUCE WITH: ./gradlew ':libs:elasticsearch-core:test' --tests "org.elasticsearch.jdk.JarHellTests.testNonJDKModuleURLs {seed=[97CC4411A902D87D:DC845B02DBE2253]}" -Dtests.seed=97CC4411A902D87D -Dtests.locale=nl -Dtests.timezone=Pacific/Majuro -Druntime.java=20

org.elasticsearch.jdk.JarHellTests > testNonJDKModuleURLs {seed=[97CC4411A902D87D:DC845B02DBE2253]} FAILED
    java.nio.file.InvalidPathException: File name: testNonJDKModuleURLs {seed=[97CC4411A902D87D:DC845B02DBE2253]}-001 contains a reserved character: :: testNonJDKModuleURLs {seed=[97CC4411A902D87D:DC845B02DBE2253]}-001
        at __randomizedtesting.SeedInfo.seed([97CC4411A902D87D:DC845B02DBE2253]:0)
        at org.apache.lucene.tests.mockfile.WindowsPath.checkInvalidPath(WindowsPath.java:58)
        at org.apache.lucene.tests.mockfile.WindowsPath.resolve(WindowsPath.java:42)
        at org.apache.lucene.tests.mockfile.FilterPath.resolve(FilterPath.java:151)
        at java.base/java.nio.file.Path.resolve(Path.java:516)
        at org.apache.lucene.tests.mockfile.FilterPath.resolve(FilterPath.java:156)
        at org.apache.lucene.tests.util.TestRuleTemporaryFilesCleanup.createTempDir(TestRuleTemporaryFilesCleanup.java:286)
        at org.apache.lucene.tests.util.LuceneTestCase.createTempDir(LuceneTestCase.java:3065)
        at org.elasticsearch.jdk.JarHellTests.testNonJDKModuleURLs(JarHellTests.java:124)

libs/core/src/test/java/org/elasticsearch/jdk/JarHellTests.java
/*
 * Copyright Elasticsearch B.V. and/or licensed to Elasticsearch B.V. under one
 * or more contributor license agreements. Licensed under the Elastic License
 * 2.0 and the Server Side Public License, v 1; you may not use this file except
 * in compliance with, at your election, the Elastic License 2.0 or the Server