Skip to content

Commit 70bc924

Browse files
committed
Merge Maven Central publish setup + docs modernization for 0.4.0 release
2 parents 85bd787 + 7dcccf4 commit 70bc924

5 files changed

Lines changed: 108 additions & 23 deletions

File tree

‎CANONICAL.md‎

Lines changed: 10 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -17,22 +17,22 @@ with whole-number floats collapsed to integers.
1717

1818
## Exact behaviours this port implements
1919

20-
1. **NFC normalization** — every string **value** and every object **key** is
20+
1. **NFC normalization**: every string **value** and every object **key** is
2121
`Normalizer.normalize(s, Form.NFC)` before serialization. (`"cafe"+U+0301` →
2222
`café`.) This is the main divergence from RFC 8785, which does *not* normalize.
23-
2. **Key sorting** — object keys sorted by Unicode **code point** ascending,
23+
2. **Key sorting**: object keys sorted by Unicode **code point** ascending,
2424
recursively. NFC is applied to keys *before* sorting.
25-
3. **Separators** — `,` between items, `:` between key and value. No whitespace.
26-
4. **Raw UTF-8, no `\uXXXX`** — non-ASCII characters are emitted as raw UTF-8
25+
3. **Separators**: `,` between items, `:` between key and value. No whitespace.
26+
4. **Raw UTF-8, no `\uXXXX`**: non-ASCII characters are emitted as raw UTF-8
2727
bytes (`ensure_ascii=False`). `é` = `c3 a9`, `☃` = `e2 98 83`, `😀` =
2828
`f0 9f 98 80`.
29-
5. **Whole-number floats → integers** — `1.0` → `1`, `2.00` → `2`. A non-whole
29+
5. **Whole-number floats → integers**: `1.0` → `1`, `2.00` → `2`. A non-whole
3030
float keeps its value: `1.5` → `1.5`. (Implemented via `BigDecimal`:
3131
`stripTrailingZeros().scale() <= 0` means whole.)
32-
6. **Integers stay integers, arbitrary precision** — `9007199254740993` is
32+
6. **Integers stay integers, arbitrary precision**: `9007199254740993` is
3333
serialized exactly. This port parses integral JSON numbers into
3434
`java.math.BigInteger`, so there is no `2^53` precision loss.
35-
7. **Control-char escaping** — only `"`, `\`, and U+0000–U+001F are escaped,
35+
7. **Control-char escaping**: only `"`, `\`, and U+0000 to U+001F are escaped,
3636
using `\b \t \n \f \r` where applicable and `\uXXXX` otherwise. `/` is **not**
3737
escaped. This matches Python's `json.dumps`.
3838

@@ -44,10 +44,10 @@ agree. **Signed payloads should avoid non-trivial floats** (e.g. `0.1 + 0.2`).
4444

4545
## Signing & encoding
4646

47-
- **VC** — signed payload is the credential minus `proof` and `credentialStatus`,
47+
- **VC**: signed payload is the credential minus `proof` and `credentialStatus`,
4848
canonicalized as above, Ed25519-signed; `proof.proofValue` is base64url **with
4949
padding**.
50-
- **UCAN** — EdDSA JWTs (compact form). The signed message is
50+
- **UCAN**: EdDSA JWTs (compact form). The signed message is
5151
`base64url(header) + "." + base64url(payload)` (base64url **without** padding,
5252
per the JWT spec). Only `alg=EdDSA` is accepted.
53-
- **did:key** — `did:key:z` + base58btc(`0xed 0x01` ‖ raw-32-byte key).
53+
- **did:key**: `did:key:z` + base58btc(`0xed 0x01` ‖ raw-32-byte key).

‎CODE_OF_CONDUCT.md‎

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
# Code of Conduct
2+
3+
This project adopts the Contributor Covenant, version 2.1, as its code of conduct:
4+
https://www.contributor-covenant.org/version/2/1/code_of_conduct/
5+
6+
All contributors, maintainers, and participants are expected to follow it. By
7+
participating, you agree to help keep this a welcoming, respectful community.
8+
9+
## Reporting
10+
11+
To report a concern, contact the maintainers privately at info@vibetensor.com.
12+
All reports are reviewed and handled confidentially.
13+
14+
Translations of the full text are available at
15+
https://www.contributor-covenant.org/translations/.

‎CONTRIBUTING.md‎

Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,38 @@
1+
# Contributing to the Attestix Java verifier
2+
3+
Thanks for your interest. This is the Java port of the Attestix offline
4+
verifier, part of the [Attestix](https://github.com/VibeTensor/attestix) project.
5+
6+
## Getting started
7+
8+
1. Fork and clone the repository.
9+
2. Build and run the tests:
10+
11+
```
12+
./gradlew test
13+
```
14+
15+
## Conformance (required)
16+
17+
Every verifier port MUST reproduce the shared cross-language conformance vectors
18+
from the core repo at
19+
[`spec/verify/v1`](https://github.com/VibeTensor/attestix/tree/main/spec/verify/v1).
20+
Run the conformance suite before opening a pull request: a change that diverges
21+
from the shared `vectors.json` will not be accepted.
22+
23+
## Pull requests
24+
25+
- Branch from `main` and keep each PR focused.
26+
- Use conventional commit messages (`fix:`, `feat:`, `docs:`, `test:`, `chore:`).
27+
- Make sure the full test suite passes and add tests for new behaviour.
28+
- Avoid unrelated formatting churn.
29+
30+
## Reporting issues
31+
32+
Open an issue with a minimal reproduction. For security issues, follow
33+
[SECURITY.md](SECURITY.md) instead of filing a public issue.
34+
35+
## License
36+
37+
By contributing you agree that your contributions are licensed under the
38+
Apache License 2.0, the same license as this repository.

‎README.md‎

Lines changed: 19 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,8 @@
33
Offline verifier for **Attestix**-issued credentials, in pure Java. Verify
44
Ed25519 [W3C Verifiable Credentials](https://www.w3.org/TR/vc-data-model/) and
55
[UCAN](https://github.com/ucan-wg/spec) delegation chains that were issued by the
6-
[Attestix](https://github.com/VibeTensor/attestix) Python core — **with no Python
7-
runtime needed**.
6+
[Attestix](https://github.com/VibeTensor/attestix) Python core (**with no Python
7+
runtime needed**).
88

99
This is a language port of the Attestix verifier. It reproduces the Attestix
1010
canonical form **byte-for-byte** and is validated against the shared
@@ -31,7 +31,7 @@ Maven (once published to Maven Central):
3131

3232
```xml
3333
<dependency>
34-
<groupId>io.vibetensor</groupId>
34+
<groupId>com.vibetensor</groupId>
3535
<artifactId>attestix</artifactId>
3636
<version>0.4.0</version>
3737
</dependency>
@@ -40,7 +40,7 @@ Maven (once published to Maven Central):
4040
Gradle (Kotlin DSL):
4141

4242
```kotlin
43-
implementation("io.vibetensor:attestix:0.4.0")
43+
implementation("com.vibetensor:attestix:0.4.0")
4444
```
4545

4646
Requires Java 11+ at runtime. (CI builds and tests on Temurin 17.)
@@ -129,15 +129,21 @@ Every vector in `testdata/vectors.json` is asserted by
129129
## Releasing to Maven Central
130130

131131
This build is **publish-ready** (POM metadata, sources + javadoc jars, GPG
132-
signing wired) but is **not** auto-published. To cut a release:
133-
134-
1. Configure Sonatype OSSRH / Central Portal credentials
135-
(`OSSRH_USERNAME`, `OSSRH_PASSWORD`) and a GPG key (`SIGNING_KEY`,
136-
`SIGNING_PASSWORD`) as environment variables or Gradle properties.
137-
2. `./gradlew publish` to stage to OSSRH.
138-
3. Close & release the staging repository (or use the Central Portal UI).
139-
140-
No tokens are committed; publishing is a manual, credentialed step.
132+
signing wired) via the Sonatype **Central Portal** (`central.sonatype.com`). To
133+
cut a release:
134+
135+
1. Configure Central Portal token credentials
136+
(`mavenCentralUsername`, `mavenCentralPassword`) and an in-memory GPG key
137+
(`signingInMemoryKey`, `signingInMemoryKeyPassword`) as `ORG_GRADLE_PROJECT_*`
138+
environment variables or Gradle properties.
139+
2. Bump `version` in `build.gradle.kts`, commit, then push a matching `vX.Y.Z`
140+
tag. The `publish` GitHub Actions workflow runs the conformance vectors and
141+
then `./gradlew publishToMavenCentral`.
142+
3. With `automaticRelease = true`, Central validates and releases the artifact
143+
automatically (no manual staging step). Flip that flag to stage first.
144+
145+
No tokens are committed; release runs only on a version tag with the credentials
146+
supplied as encrypted GitHub Actions secrets.
141147

142148
## License
143149

‎SECURITY.md‎

Lines changed: 26 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,26 @@
1+
# Security Policy
2+
3+
## Supported versions
4+
5+
This is a verifier for [Attestix](https://github.com/VibeTensor/attestix) and
6+
tracks the Attestix core 0.4.x release line. Security fixes land on the latest
7+
released version.
8+
9+
| Version | Supported |
10+
|---|---|
11+
| 0.4.x | yes |
12+
| < 0.4 | no |
13+
14+
## Reporting a vulnerability
15+
16+
Please do NOT open a public issue for security vulnerabilities.
17+
18+
Report privately by either:
19+
20+
- opening a GitHub Security Advisory on this repository
21+
(https://github.com/VibeTensor/attestix-java/security/advisories/new), or
22+
- emailing info@vibetensor.com.
23+
24+
Include a description, affected versions, and a reproduction if possible. We
25+
follow coordinated disclosure: we acknowledge the report, work on a fix, and
26+
credit you (unless you prefer otherwise) when the fix ships.

0 commit comments

Comments
 (0)