Skip to content
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

fix: Fix the regular expression for the daemon's notification subscription #1557

Merged
merged 1 commit into from
Nov 19, 2024

Conversation

gkc
Copy link
Contributor

@gkc gkc commented Nov 19, 2024

- What I did
fix: Fix the regular expression for the daemon's notification subscription so if device name is 'xyz' then it will handle notifications to 'ping.xyz.sshnp' or 'xyz.sshnp' but not to 'ping.wxyz' or 'wxyz.sshnp'

Fixes #1485

- How I did it
See commits

- How to verify it

  • Run two daemons, one with device name xyz and another with device name wxyz
  • Run npt or sshnp client with device name wxyz
  • If using sshnpd from releases up to now, both daemons will receive the request; and if they are using policy then both will send a request to the policy server. (Note that, ultimately, the daemon for xyz will not actually try to handle the request, which is why this bug has slipped through the net until now)
  • If using sshnpd built from this branch, the request will only be received by the intended recipient daemon.

…ption so if device name is 'xyz' then it will handle notifications to 'ping.xyz.sshnp' or 'xyz.sshnp' but not to 'ping.wxyz' or 'wxyz.sshnp'
@gkc gkc merged commit e4c2443 into trunk Nov 19, 2024
9 checks passed
@gkc gkc deleted the fix-1485 branch November 19, 2024 17:08
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.

Policy server being asked for policy when the name of device is similar
2 participants