Fix up bc-java-wycheproof and enable build (#8983)

This commit is contained in:
jonathanmetzman 2022-11-17 15:11:59 -05:00 committed by GitHub
parent 31f6eba0c2
commit 0f3a505e5c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
5 changed files with 9 additions and 5 deletions

View File

@ -112,6 +112,8 @@ def should_build_coverage(project_yaml):
'"fuzzing_engines" if "none" is specified.')
assert len(engines) == 1, assert_message
return False
if 'wycheproof' in engines:
return False
language = project_yaml.get('language')
if language not in constants.LANGUAGES_WITH_COVERAGE_SUPPORT:

View File

@ -22,13 +22,12 @@ import subprocess
def main():
"""Runs whycheproof."""
"""Runs wycheproof."""
if len(sys.argv) < 3:
logging.error('Usage: %s <test_app> <testcase>.', sys.argv[0])
return 1
test_app = sys.argv[1]
return subprocess.run([test_app], check=False).returncode
return subprocess.run(sys.argv[1:], check=False).returncode
if __name__ == '__main__':

View File

@ -40,7 +40,7 @@ def main():
args = get_args()
if not os.path.exists(args.output_dir):
os.mkdir(args.output_dir)
testcase = os.path.join(args.output_dir, 'testcase')
testcase = os.path.join(args.output_dir, 'fuzz-0')
with open(testcase, 'w') as file_handle:
file_handle.write(' ')
return 0

View File

@ -17,3 +17,6 @@
bazel build BouncyCastleAllTests
rsync -aLkR bazel-bin/* $OUT
# Add dummy fuzzer to fool bad build check.
printf "#!/bin/bash\n./bazel-bin/BouncyCastleAllTests" > $OUT/WycheproofTarget.bash
chmod +x $OUT/WycheproofTarget.bash

View File

@ -7,4 +7,4 @@ fuzzing_engines:
sanitizers:
- "none"
file_github_issue: false
disabled: true
blackbox: true