Description
Summary
Follow-up to #10. The fix/pypi-classifiers-0.1.1 branch now contains an eggpass eggpool producer, but its ticket and reverse-auth settings are not consumable by the current EggPool implementation. This is an interoperability blocker for the live-producer acceptance criteria, not just a packaging/classifier issue. See PR #9, reviewed at head 78fb98d22228b52f76c5695e0c3cd93f22fcc58a.
Please agree and test a versioned producer/consumer contract with EggPool before treating the live enrollment path as complete. The mismatches below are against EggPool's current strict ticket decoder and reverse-server configuration; some could be fixed on either side, but the two projects need one explicit contract.
Confirmed compatibility gaps
-
Ticket schema is rejected. At the reviewed head,
src/eggpool.rsemits fields includingv,ca_sha256,api_key, andeggpass. EggPool's currentRawTicketrequiresversionandca_pinand usesdeny_unknown_fields; it does not acceptapi_keyoreggpasseither. The ticket therefore fails decoding before enrollment. EggPass producer references: payload construction. -
Ticket lifetime exceeds EggPool's limit. EggPass issues a 600-second ticket, while the current EggPool decoder rejects lifetimes over 120 seconds (
MAX_TICKET_LIFETIME_SECONDS). For compatibility with the current consumer, issue a ticket with at most 120 seconds remaining, or coordinate and test a deliberate change to the consumer's limit. -
CA pin format and digest input differ. EggPass currently emits URL-safe Base64 of SHA-256 over the first certificate's DER (pin calculation). EggPool currently compares lowercase hexadecimal SHA-256 over the exact configured CA file bytes. Those values cannot match as implemented. Choose one canonical input and encoding; for the current EggPool implementation that means the configured CA file bytes and lowercase hex, unless EggPool is changed in lockstep.
-
Reverse-auth username differs. EggPass connects using the username
enroll(reverse-auth setup); EggPool currently configures the reverse server to expect the account name. Agree how the one-time enrollment username is accepted and what stable per-agent identity is used after enrollment. -
Enrollment and inference credentials have different roles. The enrollment token is one-time tunnel-enrollment authorization; EggPass's API key authenticates ordinary requests to its local OpenAI-compatible API. EggPass emits a separate
api_key, but EggPool currently rejects that field and wires the enrollment secret into the account's API-key setting. The consumer must receive and use the EggPass API key for inference while using the enrollment token only for enrollment/transport authentication. Do not collapse these roles, share credentials across users, or add cross-user fallback/pooling.
Contract to agree
- Specify the exact v1 ticket prefix, required/optional fields, version handling, expiry limit, and rejection behavior. Keep strict unknown-field handling; explicitly support any field EggPool needs rather than silently ignoring schema drift.
- Specify one CA pin algorithm, byte input, and textual encoding, and test it using the actual CA file used by the EggPool server.
- Specify the first-connection and reconnect authentication usernames/credentials, including how the one-time token becomes a durable per-agent tunnel credential.
- Specify how the EggPass API key is conveyed and installed as the per-user account key, separately from the enrollment secret. Neither provider OAuth tokens nor refresh tokens should leave the user's machine.
Acceptance criteria
- A ticket produced by
eggpass eggpoolat the supported version is accepted by the corresponding EggPool decoder. Add a shared/golden fixture or equivalent contract test for the exact JSON schema; test unsupported versions, unknown fields, malformed pins, expired tickets, and tickets exceeding the agreed maximum lifetime are rejected. - With Eggress
=1.0.12, an integration test enrolls using the agreed username and one-time token, validates TLS using the agreed CA pin and server name, and opens the reverse tunnel to the fixed loopback EggPass target. - Through that tunnel, a test client successfully calls
GET /v1/modelsand completes a deterministic chat-completion test using EggPass's API key. Verify that the enrollment token is not used as the inference API key and cannot be replayed for a second enrollment. - After enrollment, reconnect works with the agreed per-agent credential; revocation closes the connection and removes or invalidates that credential. Test that one user's credential cannot authenticate or route traffic as another user.
- Tests assert that tickets, enrollment tokens, API keys, certificates, provider tokens, and request bodies are absent from logs, diagnostics, and debug output. Provider OAuth access/refresh tokens remain local to EggPass.
- Relevant EggPass and EggPool CI checks pass with these interoperability tests; document the supported EggPool contract/version.
Activity