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

T3202: Enable wireguard debug messages #3679

Merged
merged 2 commits into from
Jun 22, 2024
Merged

Conversation

natali-rs1985
Copy link
Contributor

@natali-rs1985 natali-rs1985 commented Jun 19, 2024

Change Summary

Added ability to enable or disable dynamic debugging for Wireguard on demand

set system option kernel debug wireguard

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Code style update (formatting, renaming)
  • Refactoring (no functional changes)
  • Migration from an old Vyatta component to vyos-1x, please link to related PR inside obsoleted component
  • Other (please describe):

Related Task(s)

Related PR(s)

Component(s) name

system option

Proposed changes

How to test

set system option kernel debug wireguard
commit

# configure wireguard interface
set interfaces wireguard wg01 address '10.1.0.1/30'
set interfaces wireguard wg01 description 'VPN-to-wg02'
set interfaces wireguard wg01 peer to-wg02 address '192.0.2.1'
set interfaces wireguard wg01 peer to-wg02 allowed-ips '192.168.2.0/24'
set interfaces wireguard wg01 peer to-wg02 port '51820'
set interfaces wireguard wg01 peer to-wg02 public-key 'XMrlPykaxhdAAiSjhtPlvi30NVkvLQliQuKP7AI7CyI='
set interfaces wireguard wg01 per-client-thread
set interfaces wireguard wg01 port '51820'
set interfaces wireguard wg01 private-key 'cNcQKm4KTmtOFyUp+THWKWs50rAh/3il9YAUvSHzInE='
set protocols static route 192.168.2.0/24 interface wg01
commit

now dynamic debugging messages can be viewed by running journalctl

Smoketest result

Checklist:

  • I have read the CONTRIBUTING document
  • I have linked this PR to one or more Phabricator Task(s)
  • I have run the components SMOKETESTS if applicable
  • My commit headlines contain a valid Task id
  • My change requires a change to the documentation
  • I have updated the documentation accordingly

Copy link

github-actions bot commented Jun 19, 2024

👍
No issues in PR Title / Commit Title

Copy link
Member

@c-po c-po left a comment

Choose a reason for hiding this comment

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

I like the idea of adding dynamic debug support for Kernel modules to the CLI.

The implementation focusses only on Wireguard so far. I'd rather move the implementation to set system option kernel debug-wireguard or something similar, as it's a change to the Kernel that occurs and not syslog, syslog is only the "messenger".

@natali-rs1985 natali-rs1985 requested a review from c-po June 19, 2024 15:10
@natali-rs1985 natali-rs1985 changed the title syslog: T3202: Enable wireguard debug messages T3202: Enable wireguard debug messages Jun 19, 2024
src/conf_mode/system_option.py Outdated Show resolved Hide resolved
src/conf_mode/system_option.py Outdated Show resolved Hide resolved
Copy link

This pull request has conflicts, please resolve those before we can evaluate the pull request.

Copy link

Conflicts have been resolved. A maintainer will review the pull request shortly.

Copy link

This pull request has conflicts, please resolve those before we can evaluate the pull request.

Copy link

Conflicts have been resolved. A maintainer will review the pull request shortly.

@c-po c-po merged commit 757dae2 into vyos:current Jun 22, 2024
9 checks passed
@c-po
Copy link
Member

c-po commented Jun 22, 2024

@Mergifyio backport sagitta circinus

Copy link
Contributor

mergify bot commented Jun 22, 2024

backport sagitta circinus

✅ Backports have been created

c-po added a commit that referenced this pull request Jun 25, 2024
T3202: Enable wireguard debug messages (backport #3679)
c-po added a commit that referenced this pull request Jun 25, 2024
T3202: Enable wireguard debug messages (backport #3679)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Development

Successfully merging this pull request may close these issues.

4 participants