Skip to content

nginx: test bad-host cert CN#1426

Merged
alxndrsn merged 3 commits intogetodk:nextfrom
alxndrsn:nginx-check-badcert-has-cn
Oct 22, 2025
Merged

nginx: test bad-host cert CN#1426
alxndrsn merged 3 commits intogetodk:nextfrom
alxndrsn:nginx-check-badcert-has-cn

Conversation

@alxndrsn
Copy link
Contributor

@alxndrsn alxndrsn commented Oct 21, 2025

The test for SSLLabs implodes if a Common Name is not set for the cert served for incorrect domains.

See: https://www.ssllabs.com/ssltest/analyze.html?d=production.getodk.cloud

This is a test for the change made in #1366

What has been done to verify that this works as intended?

A new test! And ssllabs test compliance has been confirmed manually.

Why is this the best possible solution? Were any other approaches considered?

There isn't any obvious way to integrate with ssllabs, as its closed-source, and integrating with their API would (1) add a dependency on their live service, and (2) require deploying central publicly before tests can be run.

How does this change affect users? Describe intentional changes to behavior and behavior that could have accidentally been affected by code changes. In other words, what are the regression risks?

No change.

Does this change require updates to documentation? If so, please file an issue here and include the link below.

No.

Before submitting this PR, please make sure you have:

  • branched off and targeted the next branch OR only changed documentation/infrastructure (master is stable and used in production)
  • verified that any code or assets from external sources are properly credited in comments or that everything is internally sourced

The test for SSLLabs implodes if a Common Name is not set for the cert served for incorrect domains.

See: https://www.ssllabs.com/ssltest/analyze.html?d=production.getodk.cloud

This is a test for the change made in getodk#1366
@alxndrsn alxndrsn marked this pull request as ready for review October 21, 2025 19:13
@alxndrsn alxndrsn requested a review from yanokwa October 21, 2025 19:13
Copy link
Member

@yanokwa yanokwa left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@alxndrsn alxndrsn merged commit 6bb0012 into getodk:next Oct 22, 2025
5 checks passed
@alxndrsn alxndrsn deleted the nginx-check-badcert-has-cn branch October 22, 2025 10:37
brontolosone added a commit to brontolosone/central-backend that referenced this pull request Oct 24, 2025
…sequent POSTs (continuations of attachment uploads). Fixes getodk/central#1426
brontolosone added a commit to brontolosone/central-backend that referenced this pull request Oct 24, 2025
…sequent POSTs (continuations of attachment uploads). Fixes getodk/central#1426
ktuite added a commit to getodk/central-backend that referenced this pull request Dec 6, 2025
* add failing test: OpenRosa attachment addition submission is not auditlogged

* blobs: refactor ensure()

- Make inserting a blob which already exists a true no-op
  (saves DB churn; the sha update of the replaced approach caused a row copy)
- Remove comment related to force-a-write-so-we-can-return-the-id
  (as we do it differently now)
- Remove comment about avoiding a TOCTOU issue by sending the file over
  (potentially unnecessarily).
  1. There was almost a TOCTOU issue anyway, but it was elided by
     touching every used row, which makes concurrent deleters/updaters
     of that row block until our transaction commit.
  2. Avoiding sending the file over *and* avoiding a TOCTOU should be
     doable with a row lock or advisory lock.

* OpenRosa submissions: auditlog updates to attachment set, also on subsequent POSTs (continuations of attachment uploads). Fixes getodk/central#1426

* Handle resubmitting or altering attachment when resending submission with missing attachment

---------

Co-authored-by: Kathleen Tuite <ktuite@getodk.org>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants