Skip to content

map34/simple_tftp

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

19 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Simple TFTP

Build Status

A simple in-memory TFTP server written in Golang. Just open up your favorite tftp client interface, and start saving your data on the TFTP server.

Get

go get github.com/map34/simple_tftp
cd $GOPATH/src/github.com/map34/simple_tftp
glide install

or

mkdir -p $GOPATH/src/github.com/map34/simple_tftp
cd $GOPATH/src/github.com/map34/simple_tftp
cp -r <location_of_project>/* .
glide install

If you want to install the server as a binary, just do:

cd  $GOPATH/src/github.com/map34/simple_tftp
go install .

Go

To start the TFTP server.

cd  $GOPATH/src/github.com/map34/simple_tftp
go run main.go

Or after installation, from the CLI, just run

simple_tftp

you will see an interface such as this:

INFO[0000] Listening UDP at [::]:52767

which means that the server is listening for incoming requests. To start storing to / reading from the server from the CLI:

$ tftp
tftp> binary
tftp> connect localhost 52767
tftp> put some_file.txt
Sent 3230 bytes in 0.0 seconds
tftp> get some_file.txt
Received 3230 bytes in 0.0 seconds

Test

Unit test uses testify for assertion tests.

cd  $GOPATH/src/github.com/map34/simple_tftp
go test tftputils/*

About

A simple in-memory TFTP server written in Golang.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published