tryte-crypt-go

command module
v0.0.0-...-cb976ff Latest Latest
Warning

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

Go to latest
Published: Apr 11, 2021 License: GPL-3.0 Imports: 6 Imported by: 0

README

GitHub Workflow Status (branch) FOSSA Status

tryte-crypt-go

Disclaimer: DO NOT Send Your Crypto to seeds generated with this program. Only use IOTA Foundation apps or generate your seed offline.

This GoLang package encrypts tryte strings, including for IOTA private seeds. This is based on vbakke's tryte-encrypt library that was written in JavaScript.

This package is not fully standardised to vbakke's library, notably CTR mode is not used due to some issues decoding keys, xChaCha20-Poly1305 is used.

CMD Line Usage

go build cmd.go
go run cmd.go

Follow the instructions in command line to encrypt and existing seed or generate a new seed. Recommended use is offline on an air gapped machine.

Raw IOTA Seed (using the passphrase "test" at 4 difficulty) A999TEST999SEED99999999999999999999999999999999999999999999999999999999999999999Z

Encrypted Seed TCYABB9BQCABWACBVAVAWARCBBVAXAVAYAABZAWAXA9BUACBRCYAUACBZAWAPCSCTCPCUCVAWAABABVASCSCYAUAUC9BWAUASC9BCBSC9BUAYAVACBPC9BXA9BBBQCXAYAZAYABBABYACB9B9BZAUABBVAABUAPCYAZAZARCUCQCWARCUAUCABZATCRCPCSCYAABWAABXAWAYAQCPCRCYAUC9BUA9BAB9BZAPCWACBRCXAVAXAWAVAAB9BPCRCTCRCABSCQCYAWATCWAUCSCVAVAUCZATCSCQCABZAYATCBBUAPCBB9BWAZA9BCBRCRCPCPCRCSCUASCWAYAABRCXAWACBXAZAZAQCVA:T4

Server Installation

go build main.go
go run main.go

To make this simple to use, I made 3 endpoints. I do not recommend using this on a website to generate seeds, only if you build offline and generate yourself.

Endpoint Form Data
/encrypt seed: string, passphrase: string, difficulty: integer
/decrypt seed: string, passphrease: string
/generate passphrease: string, difficulty: string

After running main.go, the server should start up at port 3000, allowing navigation to the server using http://127.0.0.1:3000 or localhost:3000.

The following enpdoints for this application, /encrypt and /decrypt each expect form-data.

image

FOSSA Status

Documentation

The Go Gopher

There is no documentation for this package.

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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