Skip to content

Add network MAC randomization #1057

Open
@networkfusion

Description

@networkfusion

Description

Currently all STM32 devices use the same default network MAC address for network connections, as their boards are only mean't for development purposes. This differs from ESP32 devices that use unique ones (although this feature request is still valid for those as well!).
In many situations it is possible that there are more devices connected to the same network that will cause conflicts if you (easily) forget to change the MAC when reflashing the board.

MAC Randomization is now commonplace on most operating systems (especially for WiFi) and should be utilized by nanoFramework.

How to solve the problem

See: https://www.mist.com/get-to-know-mac-address-randomization-in-2020/ for how randomized MAC's are generated.

Although it should be suggested (at least in documentation) that a block of addresses should be purchased for production devices, since some firewalls will likely block them!
On STM32 devices, it should use the "unique ID" of the device as the starting point to ensure best chance of it being "unique".

Options:

  • Add as an option to the VS extension
  • Add a property to the managed code
  • Add both?

Supplimentary suggestions:

  • nanoff should also offer a way to override this so that a "production MAC" can be flashed along with the firmware and program.
  • If a default STM32 "development" MAC is used, it should choose a randomized MAC by default.

Describe alternatives you've considered

No response

Aditional context

No response

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions