[OpenNMS/opennms] 5e25bc: NMS-20049: harden smoke test login against CSRF/se...

Marshall Massengill via opennms-cvs <[email protected]>
Newsgroups gmane.network.opennms.cvs
Message-ID <OpenNMS/opennms/push/refs/heads/foundation-2024/[email protected]>
  Branch: refs/heads/foundation-2024
  Home:   https://github.com/OpenNMS/opennms
  Commit: 5e25bc2b22dbf3425f931a9f631df7cbde0180fe
      https://github.com/OpenNMS/opennms/commit/5e25bc2b22dbf3425f931a9f631df7cbde0180fe
  Author: Marshall Massengill <[email protected]>
  Date:   2026-07-21 (Tue, 21 Jul 2026)

  Changed paths:
    M smoke-test/src/main/java/org/opennms/smoketest/selenium/AbstractOpenNMSSeleniumHelper.java

  Log Message:
  -----------
  NMS-20049: harden smoke test login against CSRF/session race

Deleting cookies while the previous test's page is still loaded lets a
background request (e.g. a Vaadin heartbeat) race the login.jsp load
and swap the session cookie after the form is rendered. The form's
CSRF token then no longer matches, j_spring_security_check rejects the
POST and forwards to accessDenied.jsp, which passes login()'s
post-login checks. skipPasswordGate() then blocks for the full
timeout and the test runs unauthenticated, showing up as unrelated
flaky failures (GraphMLTopologyIT, TopologyIT, NodeDetailPageIT).

login() now parks on about:blank after cookie deletion so nothing can
race the form render, retries up to three times if the POST lands on
accessDenied.jsp, and skipPasswordGate() returns immediately when not
on the gate page instead of waiting for a button that never appears.


  Commit: b6f6dde420a94c47288cef7596a7fd5f8fe9672e
      https://github.com/OpenNMS/opennms/commit/b6f6dde420a94c47288cef7596a7fd5f8fe9672e
  Author: Marshall Massengill <[email protected]>
  Date:   2026-07-22 (Wed, 22 Jul 2026)

  Changed paths:
    M smoke-test/src/main/java/org/opennms/smoketest/selenium/AbstractOpenNMSSeleniumHelper.java

  Log Message:
  -----------
  Merge pull request #8649 from OpenNMS/mm/NMS-20049-smoke

NMS-20049: harden smoke test login against CSRF/session race


Compare: https://github.com/OpenNMS/opennms/compare/572db79e320b...b6f6dde420a9

To unsubscribe from these emails, change your notification settings at https://github.com/OpenNMS/opennms/settings/notifications


_______________________________________________
Please read the OpenNMS Mailing List FAQ:
http://www.opennms.org/wiki/index.php?page=MailingListFaq
opennms-cvs mailing list

To *unsubscribe* or change your subscription options, see the bottom of this page:
https://lists.sourceforge.net/lists/listinfo/opennms-cvs
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.