UAT 367 Cybersecurity, Command and Control Links and Unmanned Aircraft Systems Traffic Management

Worksheet 3 Enabling signing and testing in SITL

Lab 12 hAssesses CLO2

Objective

Prove MAVLink 2 signing rejects keyless and replayed commands, test AES-GCM encryption, plan key management and compute C2 availability

Equipment and materials

  • Computer with Python, pymavlink, cryptography and ArduPilot or PX4 SITL
  • GCS software supporting signing
  • Module 3 example code
  • Lab notebook

Safety

  • Test in SITL and loopback only; never send commands to anyone else's aircraft
  • Keep test keys separate from operational keys and never put keys in reports

Steps

  1. Run Example 1 and compare with pymavlink's frame for the same key and time
  2. Enable signing in SITL and the GCS per the guide (ArduPilot SITL with MAVProxy: signing setup over the local connection only)
  3. Send commands from a keyless script; check rejection and keep the log
  4. Replay a recorded frame on loopback; check replay protection
  5. Write a key management plan for the delivery network (create, distribute, store, rotate, revoke)
  6. Compute dual-path C2 availability with Example 2
  7. Run Example 4; flip a bit, change the header and reuse a nonce, record the results, and list the data still unencrypted with signing alone (such as the telemetry downlink) with the protocol that will protect it

Record of results

Table 1 Signing and replay-protection tests
TestWhat was sent or changedExpected resultObserved resultLog file or line
Table 2 AES-GCM test results
TestWhat was changedResult (accepted / InvalidTag / leak)Reason
Table 3 C2 availability
ConfigurationA₁A₂p_cAvailability AExpected outage per 30-min flight (s)

Questions

  1. The keyless command was rejected, yet anyone with a receiver can still read the telemetry. Use Tables 1 and 2 to explain the difference between authentication and encryption.

  2. Why was the replayed frame rejected even though every byte was valid, and what would happen if the receiver did not keep the latest timestamp per stream?

  3. In the nonce-reuse test, what exactly leaked, and how does the TLS 1.3 nonce construction (sequence number XOR static IV) prevent it?

  4. From Table 3, how much does a 0.2% common-mode failure change the outage, and which two measures in your key management plan or C2 design reduce common-mode failure or key compromise?

Check before you hand in

What to hand in

  • Signature comparison
  • Logs of rejected and replayed commands
  • Key management plan
  • Availability calculation
  • AES-GCM test results and the list of data needing encryption

CLO2 Design secure C2 links. (CLOs are a web-team draft; the course owner sets the final ones.)

Instructors: answers and teaching notes for this worksheet are in the teaching pack