trying to figure out if I'm hitting a bug or if I'...
# exposed
w
trying to figure out if I'm hitting a bug or if I'm doing something wrong. When I use a binary() column or a blob() column, it does not insert anything into the postgres database. I'm trying to implement webauthn for a webapp and when I try to store any of the bytea values like credential id which is a byte[64], it doesn't fail it just inserts 1 byte representing \xa0. I'm inserting like the following:
Copy code
attestedCredentialDataCredentialId = ExposedBlob(authData.attestedCredentialData!!.credentialId)
attestedCredentialDataCoseKey  = ExposedBlob(objectConverter.cborConverter.writeValueAsBytes(authData.attestedCredentialData!!.coseKey))

attestationStatement = ExposedBlob(objectConverter.cborConverter.writeValueAsBytes(registrationData.attestationObject!!.attestationStatement))
authenticatorExtensions = ExposedBlob(objectConverter.cborConverter.writeValueAsBytes(authData.extensions))
clientExtensions = ExposedBlob(objectConverter.cborConverter.writeValueAsBytes(registrationData.clientExtensions))
but the result looks like so:
Copy code
026-03-19 17:19:22.066 [eventLoopGroupProxy-4-1 @call-handler#24] DEBUG Exposed - INSERT INTO authenticators (id, "user", counter, uv_initialized, backup_eligible, backed_up, transports, attested_credential_data_aaguid, attested_credential_data_credential_id, attested_credential_data_cose_key, attestation_statement, authenticator_extensions, client_extensions) VALUES ('9962bc64-e705-4ec4-9a1f-71f26414f6f1', '34ad7d26-d645-4d45-941d-e05e66129eea', 0, FALSE, FALSE, FALSE, ARRAY['usb','nfc'], '00000000-0000-0000-0000-000000000000', E'\\x', E'\\x', E'\\x', E'\\x', E'\\x')
it looks like it's just inserting null for all blobs for some reason
✅ 1
don't know what I did, but testing today, I'm now getting the data stored in the db looks as expected. It still prints like that in the debugging, but the attested credential data is now correct. Chalking it up to build environment.