Skip to content

Commit 65dd0f7

Browse files
committed
Add CockroachDB error-based fingerprints (PostgreSQL fork)
CockroachDB is already recognized as a PostgreSQL fork by the active fingerprint, but data/xml/errors.xml had no passive (error-message) signatures for it, so error-based detection couldn't flag a CockroachDB backend the way it does for the existing MySQL forks (MariaDB/TiDB/MemSQL). Add two CockroachDB-specific error signatures under the PostgreSQL block: - the location-first syntax error ('at or near "...": syntax error', distinct from PostgreSQL's 'syntax error at or near ...') - the go.crdb.dev / github.com/cockroachdb reference link emitted in CockroachDB error hints Validated against CockroachDB v26.2 (Docker): htmlParser() resolves these to PostgreSQL with forkNote='CockroachDB', while genuine PostgreSQL/MySQL errors and unrelated pages are unaffected (no false attribution). Each signature carries a CockroachDB-specific token to avoid false positives. sha256sums.txt regenerated; smoke test passes.
1 parent b30c169 commit 65dd0f7

2 files changed

Lines changed: 3 additions & 1 deletion

File tree

data/txt/sha256sums.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@ a7eb4d1bcbdfd155383dcd35396e2d9dd40c2e89ce9d5a02e63a95a94f0ab4ea data/xml/banne
7777
e2febc92f9686eacf17a0054f175917b783cc6638ca570435a5203b03245fc18 data/xml/banner/x-aspnet-version.xml
7878
3a440fbbf8adffbe6f570978e96657da2750c76043f8e88a2c269fe9a190778c data/xml/banner/x-powered-by.xml
7979
0223157364ea212de98190e7c6f46f9d2ee20cf3d17916d1af16e857bb5dc575 data/xml/boundaries.xml
80-
bc23e6213d55390661da57ca7424b3d9876062015cf8f5b66717157bdd3895ea data/xml/errors.xml
80+
0678220c8659b8bedfdb5753f0d527a3258643bd74b3484c3f7e323c3bbb08ed data/xml/errors.xml
8181
d0b094a110bccec97d50037cc51445191561c0722ec53bf2cebe1521786e2451 data/xml/payloads/boolean_blind.xml
8282
53d0f29459f37248c320d5cb9960d432f46889696d27ae30cc3a3309fd6e026c data/xml/payloads/error_based.xml
8383
b0f434f64105bd61ab0f6867b3f681b97fa02b4fb809ac538db382d031f0e609 data/xml/payloads/inline_query.xml

data/xml/errors.xml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -34,6 +34,8 @@
3434
<error regexp="org\.postgresql\.jdbc"/>
3535
<error regexp="Pdo[./_\\]Pgsql"/>
3636
<error regexp="PSQLException"/>
37+
<error regexp="at or near &quot;[^&quot;]*&quot;: syntax error" fork="CockroachDB"/>
38+
<error regexp="See: https?://(go\.crdb\.dev|github\.com/cockroachdb)" fork="CockroachDB"/>
3739
</dbms>
3840

3941
<dbms value="Microsoft SQL Server">

0 commit comments

Comments
 (0)