Internet-Draft | Callsign-Derived IPv6 IIDs | February 2023 |
Pratten | Expires 20 August 2023 | [Page] |
This document defines a method for generating stable IPv6 Interface Identifiers for amateur packet radio nodes. This method is meant to be an alternative to hardware address based Interface Identifier generation such that the benefits of stable addressing may be achieved even on nodes that have unstable, changing, or experimental networking hardware. Instead of a physically-derived address, this method utilizes an amateur radio node's government-assigned callsign as the basis for its Interface Identifier.¶
This Internet-Draft is submitted in full conformance with the provisions of BCP 78 and BCP 79.¶
Internet-Drafts are working documents of the Internet Engineering Task Force (IETF). Note that other groups may also distribute working documents as Internet-Drafts. The list of current Internet-Drafts is at https://datatracker.ietf.org/drafts/current/.¶
Internet-Drafts are draft documents valid for a maximum of six months and may be updated, replaced, or obsoleted by other documents at any time. It is inappropriate to use Internet-Drafts as reference material or to cite them other than as "work in progress."¶
This Internet-Draft will expire on 20 August 2023.¶
Copyright (c) 2023 IETF Trust and the persons identified as the document authors. All rights reserved.¶
This document is subject to BCP 78 and the IETF Trust's Legal Provisions Relating to IETF Documents (https://trustee.ietf.org/license-info) in effect on the date of publication of this document. Please review these documents carefully, as they describe your rights and restrictions with respect to this document. Code Components extracted from this document must include Revised BSD License text as described in Section 4.e of the Trust Legal Provisions and are provided without warranty as described in the Revised BSD License.¶
This document specifies the steps an amateur packet radio node takes in order to generate a stable and unique IPv6 Interface Identifier (IID) [RFC2460]. The resulting Interface Identifier SHALL be used in conjunction with processes such as (but not limited to) Stateless Address Autoconfiguration (SLAAC) [RFC4862], DHCPv6 [RFC3315], or manual configuration to configure IPv6 connectivity on the node.¶
Callsign-derived Interface Identifier generation requires minimal manual configuration, and when paired with SLAAC may allow a mobile amateur packet radio node to automatically connect to, and communicate with any compliant amateur radio network provided that the node has been configured with a callsign, and is communicating on the correct radio frequency.¶
The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this document are to be interpreted as described in [RFC2119].¶
Amateur packet radio nodes generally identify themselves with a string of ASCII characters comprised of:¶
For example, a node operated under the callsign "VA3ZZA" with the node ID of "5" would identify itself on-air as "VA3ZZA-5".¶
To determine a 64 bit long [RFC4291] Interface Identifier for an amateur packet radio node in conformance with this specification, the following steps MUST be be taken:¶
If the callsign is less than or equal to 9 characters in length:¶
If the callsign is greater than 9 characters in length:¶
Addresses generated using this method will look like the following:¶
AAAA:AAAA:AAAA:AAAA:BCCC:CCCC:CCCC:CCCD | | || || | | || |+- Node ID | | |+---------------+-- Callsign or Hash | | +------------------- Hash Bit + Callsign or Hash +-----------------+--------------------- Prefix¶
When directly packing a shorter callsign into the Interface Identifier, the following charset MUST be used:¶
<space> - 000000 S - 010011 A - 000001 T - 010100 B - 000010 U - 010101 C - 000011 V - 010110 D - 000100 W - 010111 E - 000101 X - 011000 F - 000110 Y - 011001 G - 000111 Z - 011010 H - 001000 0 - 011011 I - 001001 1 - 011100 J - 001010 2 - 011101 K - 001011 3 - 011110 L - 001100 4 - 011111 M - 001101 5 - 100000 N - 001110 6 - 100001 O - 001111 7 - 100010 P - 010000 8 - 100011 Q - 010001 9 - 100100 R - 010010 / - 100101¶
Each character translates to 6 bits. This allows for more efficient packing of longer callsigns.¶
import hashlib CHARSET = " ABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789/" def encode(callsign: str, node_id: int = 0) -> int: # The output is a 64-bit integer output = 0x0000000000000000 # The right-most 4 bits are the node ID output |= node_id & 0x0F # If the callsign is longer than 9 characters, # perform a hash operation if len(callsign) > 9: # Set the hash bit output |= 0x8000000000000000 # Hash the callsign hashed = hashlib.sha256(callsign.encode("ascii")).digest() # Truncate the hash to 59 bits output |= int.from_bytes(hashed, "big") & 0x7FFFFFFFFFFFFFF0 else: # Text-transform and right-pad the callsign # with spaces as needed callsign = callsign.upper().ljust(9, " ") # Fill in the remaining bits via the charset. # The leftmost callsign character will be the # leftmost 6 bits of the output for i in range(9): six_bits = CHARSET.index(callsign[i]) & 0x3F output |= six_bits << (58 - (i * 6)) return output¶
It is recommended to use the generated Interface Identifier with Stateless Address Autoconfiguration to automatically determine the node's IPv6 prefix and establish routes to other hosts in a radio network.¶
While SLAAC is the recommended method of configuration, it is not required. Amateur packet radio networks may also use alternate address configuration mechanisms such as DHCPv6 or manual configuration as the participants see fit.¶
As a side effect of basing the Interface Identifier on an existing globally unique identifier, DAD [RFC4862] conflicts should be non-existent for permanent callsigns.¶
If a conflict is encountered when using a permanent callsign, the node operator SHOULD contact the operator of the offending station, and/or the appropriate regulatory authority about possible unauthorized use of a callsign.¶
Due to the need for hashing of longer temporary callsigns, a hash collision may occur. If this happens, the node operator SHOULD append a suffix to the node's callsign. Callsign suffixes are arbitrary strings that start with "/" and contain characters A-Z and 0-9. For example, adding a suffix of "IETF" to "VA3ZZA" could result in a callsign like "VA3ZZA/IETF".¶
This method of Interface Identifier generation has the following benefits:¶
The International Telecommunication Union requires all stations operating in the amateur service to self-identify when transmitting. Various countries also impose further requirements such as the interval and method by which stations must identify themselves.¶
The legal requirement to identify all transmissions nullifies any privacy benefits gained from other privacy-aware addressing methods.¶
This memo includes no request to IANA.¶
This document should not affect the security of the Internet.¶