Science Score: 44.0%

This score indicates how likely this project is to be science-related based on various indicators:

  • CITATION.cff file
    Found CITATION.cff file
  • codemeta.json file
    Found codemeta.json file
  • .zenodo.json file
    Found .zenodo.json file
  • DOI references
  • Academic publication links
  • Academic email domains
  • Institutional organization owner
  • JOSS paper metadata
  • Scientific vocabulary similarity
    Low similarity (5.0%) to scientific vocabulary
Last synced: 7 months ago · JSON representation ·

Repository

GLMFuzz

Basic Info
  • Host: GitHub
  • Owner: msxfXF
  • License: apache-2.0
  • Language: C
  • Default Branch: master
  • Size: 7.79 MB
Statistics
  • Stars: 1
  • Watchers: 1
  • Forks: 0
  • Open Issues: 1
  • Releases: 0
Created almost 2 years ago · Last pushed almost 2 years ago
Metadata Files
Readme Changelog Contributing License Citation

README.md

GLMFuzz 编译指南

项目

github: https://github.com/msxfXF/GLMFuzz docker hub: https://hub.docker.com/layers/msxf/glmfuzz

设置环境变量

bash export LLVM_VERSION=16

更新软件源

将Ubuntu的软件源更改为清华大学的镜像源,以加快下载速度:

bash sed -i 's@archive.ubuntu.com@mirrors.tuna.tsinghua.edu.cn@g' /etc/apt/sources.list sed -i 's@security.ubuntu.com@mirrors.tuna.tsinghua.edu.cn@g' /etc/apt/sources.list

更新系统并安装基本工具

更新系统并安装一些基本工具:

bash apt-get update apt-get full-upgrade -y apt-get install -y --no-install-recommends wget ca-certificates apt-utils rm -rf /var/lib/apt/lists/*

安装 NVIDIA 驱动

首先,确保您的系统上安装了最新的 NVIDIA 驱动。您可以通过以下命令来安装,版本号请自行查阅:

bash sudo apt-get update sudo apt-get install -y nvidia-driver-470

安装完成后,重启系统以使驱动生效:

bash sudo reboot

安装 CUDA

接下来,安装 CUDA 工具包。请根据您的操作系统和 CUDA 版本下载相应的安装包。以下是安装 CUDA 11.3 的示例:

bash wget https://developer.download.nvidia.com/compute/cuda/11.3.0/local_installers/cuda_11.3.0_465.19.01_linux.run sudo sh cuda_11.3.0_465.19.01_linux.run

在安装过程中,选择安装 CUDA 工具包和驱动(如果尚未安装驱动)。

安装完成后,添加 CUDA 路径到环境变量:

bash echo 'export PATH=/usr/local/cuda-11.3/bin:$PATH' >> ~/.bashrc echo 'export LD_LIBRARY_PATH=/usr/local/cuda-11.3/lib64:$LD_LIBRARY_PATH' >> ~/.bashrc source ~/.bashrc

安装 cuDNN

下载并安装 cuDNN 库。以下是安装 cuDNN 8.2 的示例:

bash wget https://developer.download.nvidia.com/compute/redist/cudnn/v8.2.0/cudnn-11.3-linux-x64-v8.2.0.53.tgz tar -xzvf cudnn-11.3-linux-x64-v8.2.0.53.tgz sudo cp cuda/include/cudnn*.h /usr/local/cuda/include sudo cp cuda/lib64/libcudnn* /usr/local/cuda/lib64 sudo chmod a+r /usr/local/cuda/include/cudnn*.h /usr/local/cuda/lib64/libcudnn*

安装依赖项

在编译 PyTorch 之前,您需要安装一些依赖项:

bash sudo apt-get update sudo apt-get install -y build-essential cmake git libopenblas-dev libblas-dev libeigen3-dev python3-dev python3-pip pip3 install numpy pyyaml mkl mkl-include setuptools cmake cffi typing_extensions future six requests dataclasses

编译和安装 PyTorch

克隆 PyTorch 仓库并编译安装:

bash git clone --recursive https://github.com/pytorch/pytorch cd pytorch git submodule sync git submodule update --init --recursive python3 setup.py install

验证安装

安装完成后,您可以通过以下命令验证 PyTorch 和 CUDA 的安装是否成功:

python import torch print(torch.__version__) print(torch.cuda.is_available()) print(torch.cuda.get_device_name(0))

如果输出显示 PyTorch 版本号和 CUDA 设备名称,则说明安装成功。

添加LLVM软件源

添加LLVM软件源并下载其GPG密钥:

bash echo "deb [signed-by=/etc/apt/keyrings/llvm-snapshot.gpg.key] http://apt.llvm.org/jammy/ llvm-toolchain-jammy-${LLVM_VERSION} main" > /etc/apt/sources.list.d/llvm.list wget -qO /etc/apt/keyrings/llvm-snapshot.gpg.key https://apt.llvm.org/llvm-snapshot.gpg.key

安装所需软件包

安装项目所需的各种软件包:

bash apt-get update apt-get -y install --no-install-recommends \ make cmake automake meson ninja-build bison flex \ git xz-utils bzip2 wget jupp nano bash-completion less vim joe ssh psmisc \ python3 python3-dev python3-pip python-is-python3 \ libtool libtool-bin libglib2.0-dev \ apt-transport-https gnupg dialog \ gnuplot-nox libpixman-1-dev bc \ gcc-${GCC_VERSION} g++-${GCC_VERSION} gcc-${GCC_VERSION}-plugin-dev gdb lcov \ clang-${LLVM_VERSION} clang-tools-${LLVM_VERSION} libc++1-${LLVM_VERSION} \ libc++-${LLVM_VERSION}-dev libc++abi1-${LLVM_VERSION} libc++abi-${LLVM_VERSION}-dev \ libclang1-${LLVM_VERSION} libclang-${LLVM_VERSION}-dev \ libclang-common-${LLVM_VERSION}-dev libclang-rt-${LLVM_VERSION}-dev libclang-cpp${LLVM_VERSION} \ libclang-cpp${LLVM_VERSION}-dev liblld-${LLVM_VERSION} \ liblld-${LLVM_VERSION}-dev liblldb-${LLVM_VERSION} liblldb-${LLVM_VERSION}-dev \ libllvm${LLVM_VERSION} libomp-${LLVM_VERSION}-dev libomp5-${LLVM_VERSION} \ lld-${LLVM_VERSION} lldb-${LLVM_VERSION} llvm-${LLVM_VERSION} \ llvm-${LLVM_VERSION}-dev llvm-${LLVM_VERSION}-runtime llvm-${LLVM_VERSION}-tools \ $([ "$(dpkg --print-architecture)" = "amd64" ] && echo gcc-${GCC_VERSION}-multilib gcc-multilib) \ $([ "$(dpkg --print-architecture)" = "arm64" ] && echo libcapstone-dev) rm -rf /var/lib/apt/lists/*

更新编译器替代项

设置GCC和Clang的默认版本:

bash update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-${GCC_VERSION} 0 update-alternatives --install /usr/bin/g++ g++ /usr/bin/g++-${GCC_VERSION} 0 update-alternatives --install /usr/bin/clang clang /usr/bin/clang-${LLVM_VERSION} 0 update-alternatives --install /usr/bin/clang++ clang++ /usr/bin/clang++-${LLVM_VERSION} 0

安装Rust工具链

使用Rustup安装Rust工具链:

bash wget -qO- https://sh.rustup.rs | CARGO_HOME=/etc/cargo sh -s -- -y -q --no-modify-path

设置环境变量

将Cargo的bin目录添加到PATH环境变量中:

bash export PATH=/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/etc/cargo/bin

清理APT缓存

清理APT缓存以释放空间:

bash apt clean -y

设置LLVM配置

设置LLVM配置的环境变量:

bash export LLVM_CONFIG=llvm-config-16

克隆并安装afl-cov

克隆afl-cov仓库并进行安装:

bash git clone --depth=1 https://github.com/vanhauser-thc/afl-cov (cd afl-cov && make install) rm -rf afl-cov

编译和安装项目

编译和安装GLMFuzz:

```bash git clone https://github.com/msxfXF/GLMFuzz.git cd GLMFuzz make distrib sudo make install

CC=gcc-11 CXX=g++-11 TESTBUILD= /bin/sh -c sed -i.bak 's/^ -/ /g' GNUmakefile make clean make distrib ([ "${TESTBUILD}" ] || (make install)) mv GNUmakefile.bak GNUmakefile ```

配置开发环境

配置开发环境的一些常用设置:

bash CC=gcc-11 CXX=g++-11 TEST_BUILD= /bin/sh -c echo "set encoding=utf-8" > /root/.vimrc echo ". /etc/bash_completion" >> ~/.bashrc echo 'alias joe="joe --wordwrap --joe_state -nobackup"' >> ~/.bashrc echo "export PS1='"'[AFL++ \h] \w \$ '"'" >> ~/.bashrc

Owner

  • Name: Haofei Sun
  • Login: msxfXF
  • Kind: user
  • Location: China, Beijing

Studying at Beijing University of Posts and Telecommunications, Loving open source

Citation (CITATION.cff)

cff-version: 1.2.0
message: "If you use this software, please cite it as below."
authors:
  - given-names: Marc
    family-names: Heuse
    email: mh@mh-sec.de
  - given-names: Heiko
    family-names: Eißfeldt
    email: heiko.eissfeldt@hexco.de
  - given-names: Andrea
    family-names: Fioraldi
    email: andreafioraldi@gmail.com
  - given-names: Dominik
    family-names: Maier
    email: mail@dmnk.co
title: "AFL++"
version: 4.00c
type: software
date-released: 2022-01-26
url: "https://github.com/AFLplusplus/AFLplusplus"
keywords:
  - fuzzing
  - fuzzer
  - fuzz-testing
  - instrumentation
  - afl-fuzz
  - qemu
  - llvm
  - unicorn-emulator
  - securiy
license: AGPL-3.0-or-later

GitHub Events

Total
  • Issues event: 1
Last Year
  • Issues event: 1

Dependencies

custom_mutators/libafl_base/Cargo.toml cargo
custom_mutators/rust/Cargo.toml cargo
custom_mutators/rust/custom_mutator/Cargo.toml cargo
custom_mutators/rust/custom_mutator-sys/Cargo.toml cargo
custom_mutators/rust/example/Cargo.toml cargo
custom_mutators/rust/example_lain/Cargo.toml cargo
unicorn_mode/samples/speedtest/rust/Cargo.toml cargo
Dockerfile docker
  • ubuntu 22.04 build
frida_mode/many-linux/Dockerfile docker
  • fridadotre/manylinux-x86_64 latest build
frida_mode/ub1804/Dockerfile docker
  • ubuntu xenial build
frida_mode/ts/package-lock.json npm
  • @babel/code-frame 7.18.6 development
  • @babel/helper-validator-identifier 7.19.1 development
  • @babel/highlight 7.18.6 development
  • @types/node 14.18.36 development
  • ansi-styles 3.2.1 development
  • argparse 1.0.10 development
  • balanced-match 1.0.2 development
  • brace-expansion 1.1.11 development
  • builtin-modules 1.1.1 development
  • chalk 2.4.2 development
  • color-convert 1.9.3 development
  • color-name 1.1.3 development
  • commander 2.20.3 development
  • concat-map 0.0.1 development
  • diff 4.0.2 development
  • escape-string-regexp 1.0.5 development
  • esprima 4.0.1 development
  • fs.realpath 1.0.0 development
  • function-bind 1.1.1 development
  • get-caller-file 1.0.3 development
  • glob 7.2.3 development
  • has 1.0.3 development
  • has-flag 3.0.0 development
  • inflight 1.0.6 development
  • inherits 2.0.4 development
  • is-core-module 2.11.0 development
  • js-tokens 4.0.0 development
  • js-yaml 3.14.1 development
  • minimatch 3.1.2 development
  • minimist 1.2.7 development
  • mkdirp 0.5.6 development
  • mock-require 3.0.3 development
  • normalize-path 2.1.1 development
  • once 1.4.0 development
  • path-is-absolute 1.0.1 development
  • path-parse 1.0.7 development
  • remove-trailing-separator 1.1.0 development
  • resolve 1.22.1 development
  • semver 5.7.1 development
  • sprintf-js 1.0.3 development
  • supports-color 5.5.0 development
  • supports-preserve-symlinks-flag 1.0.0 development
  • tslib 1.14.1 development
  • tslint 6.1.3 development
  • tsutils 2.29.0 development
  • typescript 4.9.5 development
  • typescript-tslint-plugin 0.5.5 development
  • vscode-jsonrpc 4.0.0 development
  • vscode-languageserver 5.2.1 development
  • vscode-languageserver-protocol 3.14.1 development
  • vscode-languageserver-types 3.14.0 development
  • vscode-uri 1.0.8 development
  • wrappy 1.0.2 development
  • @types/frida-gum 16.5.1
frida_mode/ts/package.json npm
  • @types/node ^14.14.2 development
  • tslint ^6.1.3 development
  • typescript ^4.0.3 development
  • typescript-tslint-plugin ^0.5.5 development
  • @types/frida-gum ^16.2.0
mutators/requirements.txt pypi
  • Requests ==2.31.0
  • chatglm_cpp ==0.3.1
  • modelscope ==1.13.3
  • pandas ==2.2.2
  • pyshark ==0.6
  • torch ==2.2.0