mud-cli

command module
v0.0.7 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Aug 13, 2021 License: Apache-2.0 Imports: 1 Imported by: 0

README

mud-cli

mud-cli provides multiple utilities for working with Manufacturer Usage Descriptions (RFC8520).

Description

Manufacturer Usage Descriptions (MUDs) allow manufacturers of IoT equipment to specify the intended network communication patterns of the devices they manufacture. The access control policies described in a MUD file allow network controllers to automatically enforce rules on the device, resulting in devices only being allowed to communicate within the boundaries of the access control policies.

Usage

mud-cli contains the following commands:

  • read - reads (and validates) a MUD file and prints the contents
  • validate - validates a MUD file
  • sign - sign a MUD file, creating a new signature file
  • verify - verifies a MUD file signature
  • view - shows a graphical representation of the MUD using MUD Visualizer
Examples
$ ./mud
mud provides several utilities for working with MUD files

Usage:
  mud [command]

Available Commands:
  completion  generate the autocompletion script for the specified shell
  help        Help about any command
  read        Reads and prints MUD file contents
  sign        Signs a MUD file
  validate    Validates a MUD file to be formatted correctly
  verify      Verifies the signature for a MUD file
  view        Provides a graphical view of a MUD file
Binary Verification

mud-cli is signed using Cosign. This means that binaries can be verified as follows:

$ cosign verify-blob -key cosign.pub -signature mud-darwin-amd64.sig mud-darwin-amd64
Verified OK

The public key (cosign.pub) is available in the repository. Signature files and binaries are available from the Releases page.

MUD Visualizer

This project embeds MUD Visualizer for visualization of MUD files.

Things that can be done

  • Improve README.md
  • Add 'Use' texts with examples to commands
  • Building a Docker image (including Cosign signing)
  • Optimizing the binary size (i.e. UPX)
  • Add tests
  • Fix (most, highest priority) TODOs ... :-)
  • Customize / improve the MUD Visualizer? It needs proper attribution, at least.
  • Add some more logging (with levels)
  • Replace calls to fmt with proper logging / output
  • Allow the tool to be chained (i.e. use STDIN/STDOUT, pipes, etc.)
  • A command for generating MUD files (from pcap or some different way)
  • A command for editing MUD files (i.e. metadata)
  • A command that initializes a .mud directory inside user HOME, that is used for intermediate storage? If necessary, of course.
  • Allow setting a different location than the user home directory ...

Documentation

Overview

Copyright © 2021 Herman Slatman <hslatman>

Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software distributed under the License is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.

Directories

Path Synopsis
web/build.go
web/build.go

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL