{"record":{"id":"df74960aa29bf446","repo":"apereo/cas","slug":"ticket-is-not-registered-in-the-catalog-and-i-df7496","errorCode":null,"errorMessage":"Ticket [{}] is not registered in the catalog and is unrecognized","messagePattern":"Ticket \\[(.+?)\\] is not registered in the catalog and is unrecognized","errorType":"console","errorClass":null,"httpStatus":null,"severity":"warning","filePath":"support/cas-server-support-ignite-ticket-registry/src/main/java/org/apereo/cas/ticket/registry/IgniteTicketRegistry.java","lineNumber":122,"sourceCode":"        if (metadata != null) {\n            val sql = \"DELETE FROM %s where id=?\".formatted(metadata.getProperties().getStorageName());\n            try (val rs = ignite.sql().execute(null, sql, encTicketId)) {\n                return rs.affectedRows();\n            }\n        }\n        return 0;\n    }\n\n    @Override\n    public @Nullable Ticket getTicket(final String ticketIdToGet, final Predicate<Ticket> predicate) {\n        val ticketId = digestIdentifier(ticketIdToGet);\n        if (StringUtils.isBlank(ticketId)) {\n            return null;\n        }\n        LOGGER.debug(\"Encoded ticket id is [{}]\", ticketId);\n        val metadata = ticketCatalog.find(ticketIdToGet);\n        if (metadata == null) {\n            LOGGER.warn(\"Ticket [{}] is not registered in the catalog and is unrecognized\", ticketIdToGet);\n            return null;\n        }\n        val table = ignite.tables().table(metadata.getProperties().getStorageName());\n        val kvView = table.keyValueView();\n        val keyTuple = Tuple.create().set(\"id\", ticketId);\n        val valueTuple = kvView.get(null, keyTuple);\n        if (valueTuple == null) {\n            LOGGER.debug(\"No ticket by id [{}] is found in the ignite ticket registry\", ticketIdToGet);\n            return null;\n        }\n        val ticketBytes = valueTuple.bytesValue(\"ticket\");\n        val result = decodeAndDeserialize(ticketBytes);\n        return predicate.test(result) ? result : null;\n    }\n\n    @Override\n    public Collection<? extends Ticket> getTickets() {\n        try (val stream = stream()) {","sourceCodeStart":104,"sourceCodeEnd":140,"githubUrl":"https://github.com/apereo/cas/blob/e7288fc434b4f4505b8452e1a57e8fb3111bb863/support/cas-server-support-ignite-ticket-registry/src/main/java/org/apereo/cas/ticket/registry/IgniteTicketRegistry.java#L104-L140","documentation":"This is a WARN log emitted by IgniteTicketRegistry.getTicket when the requested ticket id has no entry in the CAS ticket catalog. The registry resolves tickets by looking up the ticket's metadata (including the Ignite storage/table name) from the TicketCatalog; if the catalog does not know the id prefix, it cannot determine which Ignite table to query and returns null instead of throwing. It indicates the ticket id is malformed or belongs to a ticket type that was never registered with the catalog.","triggerScenarios":"Calling ticketRegistry.getTicket(ticketId) with an id whose prefix (e.g. TGT-, ST-, PGT-) does not match any TicketCatalog registration; passing an arbitrary/garbage string (e.g. from a forged or legacy callback parameter) to getTicket; a custom ticket type added to Ignite but not registered in the ticket catalog; ticket-id prefix renaming after a version upgrade or config change so old ids no longer resolve to metadata.","commonSituations":"Validation of a ticket id taken from an untrusted request parameter; cleanup jobs iterating over stale external references to deleted ticket types; clusters upgraded where the catalog configuration lost a ticket definition so previously valid ids now return null; tests passing literal placeholder ids.","solutions":["Verify the ticket id string is a genuine CAS ticket id with a known prefix and is not truncated or corrupted before calling getTicket","Ensure every custom ticket definition is registered with the TicketCatalog (cas.ticket.catalog entries) so its prefix maps to metadata and the correct Ignite storage name","Check for CAS version/config changes that renamed ticket prefixes; migrate or invalidate old ids","Handle the null return gracefully - treat it as TicketException/invalid-ticket flow rather than expecting an exception"],"exampleFix":"// before\nval ticket = ticketRegistry.getTicket(requestedId, TicketGrantingTicket.class);\nticket.getAuthentication();\n// after\nval ticket = ticketRegistry.getTicket(requestedId, TicketGrantingTicket.class);\nif (ticket == null) {\n    throw new InvalidTicketException(new BadRequ...\n","handlingStrategy":"validation","validationCode":"if (ticketId == null || ticketId.isBlank() || !ticketId.matches(\"(TGT|ST|PT|PGT|RT|OC|IMP)-.*\")) { throw new IllegalArgumentException(\"Unknown ticket id format: \" + ticketId); }","typeGuard":"function isValidTicketId(id) { return typeof id === 'string' && /^(TGT|ST|PT|PGT|RT)-/.test(id); }","tryCatchPattern":"try { val ticket = registry.getTicket(id, TicketGrantingTicket.class); if (ticket == null) { /* treat as invalid ticket */ } } catch (TicketException e) { /* handle invalid/expired */ }","preventionTips":["Validate ticket id shape/prefix before calling getTicket","Register all custom ticket definitions in the ticket catalog","Never pass raw user input directly to getTicket without prior flow validation","Treat null return as invalid-ticket, not a bug"],"tags":["ticket-registry","ignite","ticket-catalog","null-return"],"backgroundTag":"resource-not-found","analyzedSha":"e7288fc434b4f4505b8452e1a57e8fb3111bb863","analyzedAt":"2026-09-08T15:39:16.015Z","contentChangedAt":"2026-09-08T15:39:16.015Z","schemaVersion":2},"datasetVersion":"2026-09-15T23:17:13.987Z"}