From 85f7a5e1d793628b675312b6c9134458453e3f1e Mon Sep 17 00:00:00 2001 From: Arjun <36335769+0x34d@users.noreply.github.com> Date: Thu, 27 Apr 2023 07:22:00 +0530 Subject: [PATCH] [gluon] initial integration (#10170) [Gluon](https://github.com/ProtonMail/gluon) is used by [ProtonMail](https://proton.me/mail). PR for fuzzing harness: https://github.com/ProtonMail/gluon/pull/341 --------- Signed-off-by: Arjun Singh --- projects/gluon/Dockerfile | 21 +++++++++++++++++++++ projects/gluon/build.sh | 23 +++++++++++++++++++++++ projects/gluon/project.yaml | 10 ++++++++++ 3 files changed, 54 insertions(+) create mode 100644 projects/gluon/Dockerfile create mode 100644 projects/gluon/build.sh create mode 100644 projects/gluon/project.yaml diff --git a/projects/gluon/Dockerfile b/projects/gluon/Dockerfile new file mode 100644 index 000000000..178aadae3 --- /dev/null +++ b/projects/gluon/Dockerfile @@ -0,0 +1,21 @@ +# Copyright 2023 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +################################################################################ + +FROM gcr.io/oss-fuzz-base/base-builder-go +RUN git clone --depth 1 https://github.com/ProtonMail/gluon.git +RUN go install github.com/AdamKorcz/go-118-fuzz-build@latest +COPY build.sh $SRC/ +WORKDIR $SRC/gluon diff --git a/projects/gluon/build.sh b/projects/gluon/build.sh new file mode 100644 index 000000000..0fa6ba25f --- /dev/null +++ b/projects/gluon/build.sh @@ -0,0 +1,23 @@ +#!/bin/bash -eu +# Copyright 2023 Google LLC +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +################################################################################ + +go get github.com/AdamKorcz/go-118-fuzz-build/testing + +compile_native_go_fuzzer github.com/ProtonMail/gluon/imap FuzzNewParsedMessage fuzz_new_parsed_message +compile_native_go_fuzzer github.com/ProtonMail/gluon/rfc5322 FuzzParseAddress fuzz_parse_address +compile_native_go_fuzzer github.com/ProtonMail/gluon/rfc5322 FuzzRFC5322 fuzz_rfc5322 +compile_native_go_fuzzer github.com/ProtonMail/gluon/rfc822 FuzzParseDec fuzz_parse_dec diff --git a/projects/gluon/project.yaml b/projects/gluon/project.yaml new file mode 100644 index 000000000..2a7f95a1a --- /dev/null +++ b/projects/gluon/project.yaml @@ -0,0 +1,10 @@ +homepage: "https://proton.me" +language: go +primary_contact: "security@proton.me" +auto_ccs: + - "ajsinghyadav00@gmail.com" +fuzzing_engines: + - libfuzzer +sanitizers: + - address +main_repo: "https://github.com/ProtonMail/gluon"