{"id":18408276,"url":"https://github.com/protectwise/net-parser-rs","last_synced_at":"2025-04-07T08:33:01.581Z","repository":{"id":57666954,"uuid":"138343882","full_name":"protectwise/net-parser-rs","owner":"protectwise","description":"Rust network packet parser","archived":false,"fork":false,"pushed_at":"2020-06-23T01:55:20.000Z","size":3875,"stargazers_count":10,"open_issues_count":7,"forks_count":5,"subscribers_count":15,"default_branch":"master","last_synced_at":"2025-03-22T16:02:13.711Z","etag":null,"topics":[],"latest_commit_sha":null,"homepage":"","language":"Rust","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/protectwise.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null}},"created_at":"2018-06-22T20:07:29.000Z","updated_at":"2023-05-12T14:45:03.000Z","dependencies_parsed_at":"2022-09-02T14:10:39.486Z","dependency_job_id":null,"html_url":"https://github.com/protectwise/net-parser-rs","commit_stats":null,"previous_names":[],"tags_count":1,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/protectwise%2Fnet-parser-rs","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/protectwise%2Fnet-parser-rs/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/protectwise%2Fnet-parser-rs/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/protectwise%2Fnet-parser-rs/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/protectwise","download_url":"https://codeload.github.com/protectwise/net-parser-rs/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247620833,"owners_count":20968295,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":[],"created_at":"2024-11-06T03:18:06.574Z","updated_at":"2025-04-07T08:32:56.571Z","avatar_url":"https://github.com/protectwise.png","language":"Rust","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Network Packet Parser (net-parser-rs)\nBasic network parser leveraging Rust and [nom](https://github.com/Geal/nom) for safe and efficient packet parsing. Design\ninfluenced by [pktparse-rs](https://github.com/moosingin3space/pktparse-rs/tree/master/src).\n\n## Getting Started\nAdd net-parser-rs to your dependencies\n\n```toml\n[dependencies]\nnet-parser-rs=\"0.3\"\n```\n\n```rust\n    #![feature(try_from)]\n    extern crate net_parser_rs;\n\n    use net_parser_rs::CaptureParser;\n    use std::*;\n\n    //Parse a file with global header and packet records\n    let file_bytes = include_bytes!(\"capture.pcap\");\n    let records = CaptureParser::parse_file(file_bytes).expect(\"Could not parse\");\n\n    //Parse a sequence of one or more packet records\n    let records = CaptureParser::parse_records(record_bytes).expect(\"Could not parse\");\n\n    //Parse a single packet\n    let packet = CaptureParser::parse_record(packet_bytes).expect(\"Could not parse\");\n\n    //Convert a packet into flow information\n    use net_parser_rs::flow::*;\n\n    let flow = packet.extract_flow().expect(\"Could not extract flow\");\n```\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fprotectwise%2Fnet-parser-rs","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fprotectwise%2Fnet-parser-rs","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fprotectwise%2Fnet-parser-rs/lists"}