Skip to content

Channel Management#57

Merged
MrAlders0n merged 7 commits intomainfrom
dev
Dec 19, 2025
Merged

Channel Management#57
MrAlders0n merged 7 commits intomainfrom
dev

Conversation

@MrAlders0n
Copy link
Collaborator

✨ New Features

Dynamic Channel Key Derivation

  • Added deriveChannelKey() function that generates a 16-byte channel key from any hashtag channel name using SHA-256 hashing
    • Supports any hashtag channel (e.g., #wardriving, #wardrive, #test)
    • Validates channel name format (must start with # and contain only letters, numbers, and dashes)
    • Normalizes channel names to lowercase following MeshCore convention
    • Uses Web Crypto API with proper error handling for environments lacking crypto support

Automatic Channel Creation

  • Added createWardriveChannel() function that automatically creates the wardriving channel if it doesn't exist
    • Finds the first available empty channel slot
    • Throws descriptive error if no channel slots are available
    • Uses derived channel key for secure channel creation

Enhanced Channel Management

  • Updated ensureChannel() function to automatically create channels when not found
    • Attempts to create the channel if lookup fails
    • Provides better error messages for troubleshooting
    • Eliminates the need for manual channel creation on companion devices

Automatic Channel Cleanup

  • Added channel deletion on disconnect
    • Automatically removes the wardriving channel when disconnecting
    • Prevents channel slot pollution on companion devices
    • Includes graceful error handling (disconnect continues even if deletion fails)

🔧 Improvements

Security Enhancements

  • Removed hardcoded encryption key (WARDROVE_KEY)
    • Replaced with dynamic key derivation for better security practices
    • Each channel now derives its own unique key from the channel name

User Experience

  • Better error messages throughout the channel management flow
  • More informative debug logging for troubleshooting
  • Reduced manual setup requirements (no need to pre-create channels)

🐛 Bug Fixes

  • None in this release

📝 Documentation

  • Updated README. md badge to reflect version 1.2.1

Breaking Changes: None - This is a backwards-compatible enhancement release.

Migration Notes: Users no longer need to manually create the #wardriving channel on their companion devices before connecting. The app will create it automatically.

MrAlders0n and others added 7 commits December 18, 2025 20:36
Co-authored-by: MrAlders0n <55921894+MrAlders0n@users.noreply.github.com>
Co-authored-by: MrAlders0n <55921894+MrAlders0n@users.noreply.github.com>
Co-authored-by: MrAlders0n <55921894+MrAlders0n@users.noreply.github.com>
Co-authored-by: MrAlders0n <55921894+MrAlders0n@users.noreply.github.com>
…-channel

Auto-create #wardriving channel with SHA-256 derived keys
@MrAlders0n MrAlders0n merged commit 2575859 into main Dec 19, 2025
1 check passed
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.

2 participants