Repository navigation
Conversation
…signatures Move the reactor to org.owasp coordinates (issue #531): the library is org.owasp:java-html-sanitizer, its parent java-html-sanitizer-parent, and the unpublished modules get the same prefix. A new legacy-relocation module publishes, with each release, a POM-only relocation at com.googlecode.owasp-java-html-sanitizer: owasp-java-html-sanitizer that points to the same version under the new coordinates. Java packages, the JPMS module name and, now pinned, the OSGi bundle symbolic name are unchanged. The shade exclude names the shim metadata directories in full, since java*/** under org.owasp would also strip the library's own pom.properties. JReleaser's built-in signer hashes with SHA-1, so sign with gpg in command mode with SHA-512 instead. scripts/with-release-key.sh puts the pinned release key alone in a temporary keyring for it. The release and the no-publish check now verify the staging repository holds exactly the expected components before anything is tagged or uploaded, and the signature check rejects digests weaker than SHA-256. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Implements #531: future releases publish as
org.owasp:java-html-sanitizer, signed only with the project release keyF6109A4F3F5616E1A7A62099E02DB03BAF6C438C.Draft until Sonatype adds
com.googlecode.owasp-java-html-sanitizerto the OWASP Central organization. Every release now stages a relocation POM there, so until that access exists the Central Portal would reject the whole deployment. Nothing would be partially published.Coordinates
org.owasp:java-html-sanitizer. Parent:org.owasp:java-html-sanitizer-parent. The shims, examples and empiricism modules get the samejava-html-sanitizer-prefix; they stay unpublished.legacy-relocation/module publishes, with each release, a POM-onlycom.googlecode.owasp-java-html-sanitizer:owasp-java-html-sanitizer:<version>. It relocates toorg.owasp:java-html-sanitizer, with no dependencies and no pinned target version. Existing releases at the old coordinates are untouched.org.owasp.htmlpackage, the JPMS moduleowasp.java.html.sanitizer, Java 8 bytecode, and the version scheme.Bundle-SymbolicNameis now pinned tocom.googlecode.owasp-java-html-sanitizer, because bnd would otherwise derive a new name from the coordinates. The packaging verification checks this.java*/**underorg.owaspwould also have stripped the library's ownpom.properties, which scanners use to identify the JAR.Signing
--digest-algo SHA512.scripts/with-release-key.shputs only the pinned release key in a temporary keyring for JReleaser.scripts/verify-artifact-signatures.shrejects digests weaker than SHA-256 and prints gpg's status on failure.Release safety
scripts/check-staged-release.shruns after the build and before tagging. It requires that staging holds exactly the library jar, sources, javadoc and POM, the parent POM, and the relocation POM. It also checks the relocation target, the JAR's own Maven metadata, the absence of shim metadata, and the OSGi name.Validation (local, Homebrew JDKs)
./mvnw clean verifyon JDK 11, 17, 21 and 25: 761 + 7 tests pass on each, including the JPMS and Java 8 consumer checks.Publication build at placeholder version
20000101.0produces exactly the six expected components, andcheck-staged-release.shpasses.JReleaser
deployin dry-run mode with a throwaway key:Negative cases fail as intended:
Maven 3.9 resolution against the staged repository:
ShellCheck, actionlint, YAML parse and
git diff --checkpass.Not in this PR
docs/maven.mdmigration guide, README badge, javadoc.io links,SECURITY.md,docs/vulnerabilities.md). Changing them before the firstorg.owasprelease would point readers at coordinates that don't exist yet, so that will be a follow-up merged just before the release. The relocation message points todocs/maven.md.🤖 Generated with Claude Code