Coder Social home page Coder Social logo

komorogrov / netlifter Goto Github PK

View Code? Open in Web Editor NEW

This project forked from qingkaishi/netlifter

0.0 0.0 0.0 10.19 MB

Lifting network implementation to precise format specification

License: GNU Affero General Public License v3.0

Shell 0.45% C++ 98.10% C 0.39% CMake 1.06%

netlifter's Introduction

Popeye

Popeye is a prototype implementation of the technique known as NetLifter, which is published in CCS 2023 and aims to lift the source code of a protocol implementation to BNF-style protocol formats.

Lifting Network Protocol Implementation to Precise Format Specification with Security Applications
Qingkai Shi, Junyang Shao, Yapeng Ye, Mingwei Zheng, Xiangyu Zhang
The ACM Conference on Computer and Communications Security (CCS '23)

Disclaimer

There are a lot of rough edges and bugs in this early prototype. Pull requests are welcome if you like to contribute to this project.

Build

Dependency:

  • llvm-12.0.1, you can install it by sudo apt install llvm-12.
  • z3-4.8.12, better to use my copy, need to compile and install using cmake.
$ mkdir build
$ cd build
$ cmake ..
$ make

Run the following command for regression testing. You can refer to benchmarks/popeye/regession.sh for how we run each benchmark protocol.

$ cd build
$ make regression

Run

Details of how we run Popeye can be found here. Please refer to benchmarks/readme.txt for more examples. Basically, the input is LLVM bitcode with some simple annotations that annotate the byte buffer containing the network message. The output is the message format in BNF.

Note that when compiling source code to LLVM bitcode, please add -fno-vectorize -fno-slp-vectorize to CFLAGS and CXXFLAGS to avoid generating vectorized instructions, which currently we do not support.

Also, it's better to remove all -Ox options and add the -g option to CFLAGS and CXXFLAGS, which will let the bitcode include debug information. The debug information will help infer the name of fields in a network message.

netlifter's People

Contributors

qingkaishi avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.