Skip to content

Instantly share code, notes, and snippets.

@KibaFox
KibaFox / main.rs
Created November 20, 2016 20:20
Simple Rust TCP Server
// Simple TCP server
// This is a simple tcp server written in rust that will print any line sent to
// it. It listens on port 5000 and you can use telnet to send lines of text.
use std::net::{TcpListener, TcpStream};
use std::io::{BufRead, BufReader};
fn main() {
let listener = TcpListener::bind("127.0.0.1:5000").unwrap();

Keybase proof

I hereby claim:

  • I am KibaFox on github.
  • I am kibafox (https://keybase.io/kibafox) on keybase.
  • I have a public key whose fingerprint is 8A25 6DAC 853E 966D 6D50 FAB5 9739 5F79 558B DC4F

To claim this, I am signing this object: