Repository navigation
Conversation
|
The two new PostgreSQL tests passed in CI. Both requests reached The overall Maven job is still red because it reaches the existing 41 integration-suite failures: 40 SQL-template route failures and the SQLite PATCH route mismatch. Those failures are already tracked in #961 and none came from CodeQL and both analysis jobs passed. This PR is ready for an independent review. |
|
@grabdoc We should also have a unicode character or two in a table name as well, for the tests. Please add that, say like: which is German for "everywhere". This will ensure unicode chars can be used in table names and objects without a problem. |
|
Thanks, Thad — I added |
|
Hmm but I think it might fail if escaped unicode characters are used? And is UESCAPE usage allowed? See docs https://www.postgresql.org/docs/current/sql-syntax-lexical.html |
|
Maybe UESCAPE clause itself needs to be a parameter?
|
This fixes the failing integration build and keeps the PostgreSQL regression coverage for #916 in the same branch.
The SQL template controller now has an explicit GET route for templates that do not use extra path variables. Previously those requests fell through to the generic primary-key route, so 40 template tests returned 400 instead of reaching the template executor. Templates with custom path variables still use the existing wildcard route.
Because the repaired route makes the requested template name reach the file loader, template names are now validated before any filesystem access. They are limited to safe filename characters, path separators and parent-directory references are rejected, and the normalized file must remain inside the configured template directory. Symlinks are not followed. The validation has 12 regression cases covering null, blank, traversal, absolute, nested, whitespace, and encoded-separator input.
The SQLite invalid-update test now uses the supported filter-based PATCH endpoint and sends an unknown column. It verifies the 400 response, the data-access error category, and the exact missing-column detail. The old test called an unsupported PATCH-by-primary-key URL and therefore received 405 before validating the payload.
The PostgreSQL fixture creates
stg."FilmData"andstg."überall"in a real container. Its endpoint tests cover exact-case lookup both without a profile header and withAccept-Profile: stg. The Unicode test also proves that the table name survives URL encoding, Spring path decoding, metadata lookup, and quoted SQL execution. Together they confirm the identifier fix from #948 through the full request path.Validation completed locally:
Related to #916 and #961.