Skip to content

telumo/network-examples

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

33 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

network-examples

Rust

Rustでネットワークのパケットキャプチャ・解析・制御等を実装するための勉強用レポジトリです。

目標

  • パケットキャプチャ
  • フロー解析 / 特徴抽出(保存)
  • 特定のアクセス制御

知識

ネットワーク

Rust

その他

実行方法

ビルド

cargo build --release

実行

./target/release/network-examples --address 127.0.0.1:3333 --protocol tcp --role server

実行方法(初回)

ソースコードのクローン

# クローン
git clone https://github.com/telumo/network-examples.git

# 移動
cd network-examples

# ブランチの作成
git branch <name>
# ex) git branch hasegawa

# チェックアウト

git checkout <name>
# ex)  git chechout hasegawa

ビルド | 実行

# ビルド
cargo build

# 実行
cargo run

コミット & プッシュ

# コミット
git add .
git commit -m "<メッセージ>"

# 最新版の取得
git checkout master
git pull
git checkout <name>

# マージ
git merge master

# プッシュ
git push  
# 初回時のみ
git push --set-upstream origin <name>

プルリクエスト & マージ

  1. githubのプルリクエスト機能で master <= ブランチ にプルリクエストを送る。
  2. マージする

環境構築(Cargo)

インストール

# インストール
curl --proto '=https' --tlsv1.2 -sSf https://sh.rustup.rs | sh

# アクティベート
source ~/.cargo/env

# update
rustup update

Rustのインストール-Rustプログラミング言語

実行

# ビルド
cargo build

# 実行
cargo run

問題

数字をて足す

  • numbers.txtファイルから数字を取得する numbers.txt
1
2
  • 全ての数字の和を求める

  • numbers.txtに追記する

1
2
3

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages