[PR #4283] [CLOSED] [client] Shorten peer public key in connection logs #19957

Open
opened 2026-08-05 05:06:40 -04:00 by saavagebueno · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/netbirdio/netbird/pull/4283
Author: @pappz
Created: 8/4/2025
Status: Closed

Base: mainHead: log-short-id


📝 Commits (2)

  • f396277 Shorten peer public key in connection logs
  • ffeacd5 Fix key shortening function to handle short public keys

📊 Changes

2 files changed (+9 additions, -1 deletions)

View changed files

📝 client/internal/peer/conn.go (+1 -1)
client/internal/peer/key.go (+8 -0)

📄 Description

Describe your changes

Shorter pub keys in logs:

2025-08-04T22:26:06Z INFO 285 [peer: 5ylZjz6] client/internal/peer/conn.go:478: created new wgProxy for relay connection: 127.0.0.1:1
2025-08-04T22:26:06Z INFO 64 [peer: 5ylZjz6] client/internal/peer/wg_watcher.go:88: WireGuard watcher started
2025-08-04T22:26:07Z INFO 285 [peer: 5ylZjz6] client/internal/peer/conn.go:509: start to communicate with peer via relay
2025-08-04T22:26:07Z INFO 453 [peer: 5ylZjz6] client/internal/peer/conn.go:349: set ICE to active connection
2025-08-04T22:26:07Z INFO 64 [peer: 5ylZjz6] client/internal/peer/wg_watcher.go:112: WireGuard watcher stopped
2025-08-04T22:26:09Z INFO 294 [peer: 5ylZjz6] client/internal/peer/guard/guard.go:74: start reconnect loop...

Stack

Checklist

  • Is it a bug fix
  • Is a typo/documentation fix
  • Is a feature enhancement
  • It is a refactor
  • Created tests that fail without the change (if possible)
  • Extended the README / documentation, if necessary

By submitting this pull request, you confirm that you have read and agree to the terms of the Contributor License Agreement.


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/netbirdio/netbird/pull/4283 **Author:** [@pappz](https://github.com/pappz) **Created:** 8/4/2025 **Status:** ❌ Closed **Base:** `main` ← **Head:** `log-short-id` --- ### 📝 Commits (2) - [`f396277`](https://github.com/netbirdio/netbird/commit/f396277f918033cf97d701caf41f07292c03fe75) Shorten peer public key in connection logs - [`ffeacd5`](https://github.com/netbirdio/netbird/commit/ffeacd5e18586d8d4be5d3ae3c4377f999519d9b) Fix key shortening function to handle short public keys ### 📊 Changes **2 files changed** (+9 additions, -1 deletions) <details> <summary>View changed files</summary> 📝 `client/internal/peer/conn.go` (+1 -1) ➕ `client/internal/peer/key.go` (+8 -0) </details> ### 📄 Description ## Describe your changes Shorter pub keys in logs: ``` 2025-08-04T22:26:06Z INFO 285 [peer: 5ylZjz6] client/internal/peer/conn.go:478: created new wgProxy for relay connection: 127.0.0.1:1 2025-08-04T22:26:06Z INFO 64 [peer: 5ylZjz6] client/internal/peer/wg_watcher.go:88: WireGuard watcher started 2025-08-04T22:26:07Z INFO 285 [peer: 5ylZjz6] client/internal/peer/conn.go:509: start to communicate with peer via relay 2025-08-04T22:26:07Z INFO 453 [peer: 5ylZjz6] client/internal/peer/conn.go:349: set ICE to active connection 2025-08-04T22:26:07Z INFO 64 [peer: 5ylZjz6] client/internal/peer/wg_watcher.go:112: WireGuard watcher stopped 2025-08-04T22:26:09Z INFO 294 [peer: 5ylZjz6] client/internal/peer/guard/guard.go:74: start reconnect loop... ``` ## Issue ticket number and link ## Stack <!-- branch-stack --> ### Checklist - [ ] Is it a bug fix - [ ] Is a typo/documentation fix - [ ] Is a feature enhancement - [x] It is a refactor - [ ] Created tests that fail without the change (if possible) - [ ] Extended the README / documentation, if necessary > By submitting this pull request, you confirm that you have read and agree to the terms of the [Contributor License Agreement](https://github.com/netbirdio/netbird/blob/main/CONTRIBUTOR_LICENSE_AGREEMENT.md). --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
saavagebueno added the pull-request label 2026-08-05 05:06:40 -04:00
Sign in to join this conversation.
No Label pull-request
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: DYNR/netbird#19957