-
Notifications
You must be signed in to change notification settings - Fork 85
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Sandbox BGS does not accept events with missing prev
field
#327
Comments
prev
fieldprev
field
Thanks for the report, will take a look! |
hrm... the prev field on the generated struct probably wants to be omitempty, but i dont think thats actually going to cause an issue. |
I see some signature validation failures on retroid repos |
Do you have timestamps for those validation failures? I might be able to figure out what I was doing at the time. At one point I'd forgotten to update my _atproto DNS record, although I don't think that would manifest itself as signature validation errors |
yeah i saw the bad dns record one. I'm 90% sure whats going on here is that you're signing over the 'commit' with the 'prev' field entirely missing, where when i check the signature i'm computing the bytes to have 'prev=null'. |
👀 yeah, some languages should be able to validate whatever is in the commit. golang will have a bit of trouble... I guess trying both variations shouldn't be too bad performance-wise as long as it is really clear which is expected and 99.99% of signature validations are happy path? this could be a major problem for, eg, label signing and validation though (several fields, with no-value-provided common for several), will want to ensure there is no ambiguity in that case. cc: @dholms |
IIUC, as of repo v3, the
prev
field is optional. I got rid of it while updating picopds to repo v3. However, I couldn't get the sandbox BGS to accept my commit events until I added dummyprev
fields (set to null) to my commit objects and firehose events (I'm not sure if both were strictly needed, but I changed both at once and it started working after that).The text was updated successfully, but these errors were encountered: