Skip to content

Add a Java signing client - #128

Open
beetlebugorg wants to merge 2 commits into
feat/go-signing-clientfrom
feat/java-signing-client
Open

Add a Java signing client#128
beetlebugorg wants to merge 2 commits into
feat/go-signing-clientfrom
feat/java-signing-client

Conversation

@beetlebugorg

@beetlebugorg beetlebugorg commented Sep 9, 2026

Copy link
Copy Markdown
Owner

What

org.beetlebug:moddims at clients/java signs /dims4/ and /dims5/ URLs and encrypts an image URL into eurl. Java 17, no runtime dependency, and JUnit 5 in the test scope. Dims5Signer and Dims4Signer each have a sign method and a signEncrypted method. Eurl holds the key derivation and the two ciphers. IllegalArgumentException is the whole error surface, and its message starts with the rule that fired.

clients.yml gains a java job that runs mvn -B test on Temurin 17. release-java.yml publishes to GitHub Packages on a clients/java/v tag, with the built-in GITHUB_TOKEN. The release profile attaches the sources jar and the javadoc jar. release.yml keeps its v* trigger, and clients/java/v1.0.0 does not match it.

.gitignore gains /clients/java/target/, the directory a Maven build writes.

Why

Stacked on #127, and below that on #126.

Issue #124. Rules writes its own escape table, its own two decoders, and its own sort. URLEncoder escapes a tilde as %7E and leaves an asterisk alone, so it produces a canonical query the module refuses. URLDecoder reads a plus as a space, and url keeps the plus. String.compareTo orders by UTF-16 code unit and the module orders by UTF-8 byte, so the sort compares name.getBytes(UTF_8). Java 17 has no HKDF, so Eurl does the extract and the expand from RFC 5869.

maven.pkg.github.com answered 401 to an unauthenticated GET when I checked it. A consumer puts a GitHub token in settings.xml, and docs/docs/clients/java.md gives the server block and the repository block.

Verify

cd clients/java && mvn -B test

54 tests pass. FixtureTest runs all 42 records from test/fixtures/signing.tsv as its own tests, so a failure names the case.

release-java.yml has not run. The first clients/java/v1.0.0 tag is the test.

org.beetlebug:moddims at clients/java signs /dims4/ and /dims5/ URLs and
encrypts an image URL into eurl. Java 17, no runtime dependency, and
JUnit 5 in the test scope. The checked in version is 0.0.0-SNAPSHOT.

Rules holds the escape table, the two decoders, the sort, and the URL
splitting. URLEncoder escapes a tilde and leaves an asterisk alone, and
URLDecoder reads a plus as a space, so the class writes both.
String.compareTo orders by UTF-16 code unit and the module orders by
UTF-8 byte, so the sort compares name.getBytes(UTF_8). Java 17 has no
HKDF, so Eurl does the extract and the expand from RFC 5869.

IllegalArgumentException is the whole error surface, and its message
starts with the rule that fired. FixtureTest reads
test/fixtures/signing.tsv and runs every record as its own test.
SignerTest covers what a record cannot.
clients.yml gains a java job that runs mvn -B test from clients/java on
Temurin 17.

release-java.yml publishes org.beetlebug:moddims to GitHub Packages on a
clients/java/v tag. It reads the version from the tag and deploys with
the built-in GITHUB_TOKEN, so a release needs no secret of its own. The
release profile attaches the sources jar and the javadoc jar.
release.yml keeps its v* trigger, and clients/java/v1.0.0 does not match
it.

maven.pkg.github.com answers 401 to an unauthenticated read, including
from a public repository. docs/docs/clients/java.md gives the server
block a consumer puts in settings.xml and the repository block it names.
@beetlebugorg
beetlebugorg changed the base branch from main to feat/go-signing-client September 9, 2026 23:45
@beetlebugorg
beetlebugorg added this pull request to stack #129 September 9, 2026 23:45
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.

1 participant