[OpenNMS/opennms] d8d21b: NMS-19723: Consolidate trapd CM config-name consta...
Scott Theleman via opennms-cvs <[email protected]>
| Newsgroups | gmane.network.opennms.cvs |
|---|---|
| Message-ID | <OpenNMS/opennms/push/refs/heads/jira/NMS-19723-trapd-mask-passwords/[email protected]> |
Branch: refs/heads/jira/NMS-19723-trapd-mask-passwords
Home: https://github.com/OpenNMS/opennms
Commit: d8d21b1fe42ff9ac8daeba008ec1111365f517f9
https://github.com/OpenNMS/opennms/commit/d8d21b1fe42ff9ac8daeba008ec1111365f517f9
Author: Scott Theleman <[email protected]>
Date: 2026-07-21 (Tue, 21 Jul 2026)
Changed paths:
M features/config/upgrade/src/main/java/org/opennms/config/upgrade/TrapdSnmpv3UserIdBackfill.java
M features/config/upgrade/src/test/java/org/opennms/config/upgrade/TrapdSnmpv3UserIdBackfillIT.java
M opennms-config-jaxb/src/main/java/org/opennms/netmgt/config/trapd/TrapdConfiguration.java
M opennms-dao/src/main/java/org/opennms/netmgt/dao/jaxb/DefaultTrapdConfigDao.java
Log Message:
-----------
NMS-19723: Consolidate trapd CM config-name constant into TrapdConfiguration
The "trapd-config" CM config name (used to locate the config in
kvstore_jsonb / the CM REST service) was duplicated across
DefaultTrapdConfigDao, TrapdSnmpv3UserIdBackfill, and its IT. Move it to
a single TrapdConfiguration.CM_CONFIG_NAME constant in opennms-config-jaxb,
which every consumer already depends on, so no new module dependency is
introduced.
Commit: 1367e2edcd6d216eba7d312f6d82ac289252c1d9
https://github.com/OpenNMS/opennms/commit/1367e2edcd6d216eba7d312f6d82ac289252c1d9
Author: Scott Theleman <[email protected]>
Date: 2026-07-21 (Tue, 21 Jul 2026)
Changed paths:
M features/scv/api/src/main/java/org/opennms/features/scv/utils/ScvUtils.java
M opennms-webapp-rest/pom.xml
M opennms-webapp-rest/src/main/java/org/opennms/web/rest/support/SecurityHelper.java
Log Message:
-----------
NMS-19723: Move SCV expression pattern into ScvUtils
Relocate the ${scv:...} matcher from SecurityHelper into the canonical SCV
utility class (features/scv/api ScvUtils) as SCV_EXPRESSION_PATTERN plus an
isScvExpression() predicate, so the SCV-reference syntax lives in the SCV
module alongside the other SCV constants and serves as the Java-side
counterpart to ui/src/lib/scvValidator.ts. SecurityHelper.isScvExpression()
now delegates. Adds a compile-scope dependency from opennms-webapp-rest on
org.opennms.features.scv.api (previously present at test scope only).
Commit: c71c5bd90895bad46b386332635442a347ae61f6
https://github.com/OpenNMS/opennms/commit/c71c5bd90895bad46b386332635442a347ae61f6
Author: Scott Theleman <[email protected]>
Date: 2026-07-21 (Tue, 21 Jul 2026)
Changed paths:
M opennms-webapp-rest/src/main/java/org/opennms/web/rest/v2/TrapdRestService.java
M opennms-webapp-rest/src/test/java/org/opennms/web/rest/v2/TrapdRestServiceIT.java
Log Message:
-----------
NMS-19723: Reject duplicate SNMPv3 user ids in Trapd config requests
Masked-credential resolution correlates incoming users to stored ones by id
via getSnmpv3UserById(), which assumes ids are unique. A payload with two
users sharing the same id would resolve both against the first match and
persist an unreachable duplicate, silently corrupting the second user's
credentials on the next masked round-trip. Reject such payloads with a
BAD_REQUEST validation error in the shared validateTrapdConfigRequest(), so
both the PUT and upload paths are covered. Blank ids (new users, assigned an
id at persist time) are exempt. Adds IT coverage for duplicate ids on both
paths and for multiple blank-id users being allowed.
Compare: https://github.com/OpenNMS/opennms/compare/692f038f8c93...c71c5bd90895
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