ios7crypt

package module
v0.0.5 Latest Latest
Warning

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

Go to latest
Published: Apr 2, 2018 License: BSD-2-Clause-Views Imports: 8 Imported by: 0

README

go-ios7crypt - a Go port of IOS7Crypt

EXAMPLE

$ ios7crypt -encrypt monkey
020b0b55000316

$ ios7crypt -decrypt 020b0b55000316
monkey

$ ios7crypt -help
  -decrypt string
        Decrypt a hash
  -encrypt string
        Encrypt a password
  -help
        Show usage information
  -version
        Show version information

ABOUT

IOS7Crypt is an educational resource illustrating some fundamentals of introductory practical cryptography:

  • An example of building a larger crypto algorithm out of XOR
  • Constant vs Variable keys
  • Instructions for compiling and running an example encryption program

DOWNLOAD

https://github.com/mcandre/go-ios7crypt/releases

DOCUMENTATION

https://godoc.org/github.com/mcandre/go-ios7crypt

RUNTIME REQUIREMENTS

(None)

BUILDTIME REQUIREMENTS

  • Go 1.9+
  • Mage (e.g., go get github.com/magefile/mage)
  • goimports (e.g. go get golang.org/x/tools/cmd/goimports)
  • golint (e.g. go get github.com/golang/lint/golint)
  • errcheck (e.g. go get github.com/kisielk/errcheck)
  • nakedret (e.g. go get github.com/alexkohler/nakedret)
  • Docker
  • goxcart (e.g., github.com/mcandre/goxcart/...)
  • zipc (e.g. go get github.com/mcandre/zipc/...)

INSTALL FROM REMOTE GIT REPOSITORY

$ go get github.com/mcandre/go-ios7crypt/...

(Yes, include the ellipsis as well, it's the magic Go syntax for downloading, building, and installing all components of a package, including any libraries and command line tools.)

INSTALL FROM LOCAL GIT REPOSITORY

$ mkdir -p $GOPATH/src/github.com/mcandre
$ git clone https://github.com/mcandre/go-ios7crypt.git $GOPATH/src/github.com/mcandre/go-ios7crypt
$ cd $GOPATH/src/github.com/mcandre/go-ios7crypt
$ git submodule update --init --recursive
$ go install ./...

TEST REMOTELY

$ go test github.com/mcandre/go-ios7crypt/...

TEST LOCALLY

$ go test

COVERAGE

$ mage coverageHTML
$ karp cover.html

PORT

$ mage port

LINT

Keep the code tidy:

$ mage lint

Documentation

Overview

Package ios7crypt provides primitives for encrypting and decrypting text according to the old Cisco type 5 algorithm.

Index

Constants

View Source
const Version = "0.0.5"

Version is a semver constant for this package.

Variables

This section is empty.

Functions

func Decrypt

func Decrypt(hash string) (string, error)

Decrypt attempts to invert a type 7 hash into the original password, returning an error in the event of failure.

func Encrypt

func Encrypt(password string) string

Encrypt returns an unbounded, type 7 encrypted form of the given password text.

func Xlat

func Xlat(index uint) byte

Xlat simulates a static, repeating key sequence.

Types

This section is empty.

Directories

Path Synopsis
cmd
ios7crypt command
Package main provides an ios7crypt executable.
Package main provides an ios7crypt executable.

Jump to

Keyboard shortcuts

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