-
Notifications
You must be signed in to change notification settings - Fork 71
Modify tests directory structure #83
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
Merged
Changes from all commits
Commits
File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,49 @@ | ||
FROM tpm2software/tpm2-tss | ||
|
||
ENV PKG_CONFIG_PATH /usr/local/lib/pkgconfig | ||
|
||
RUN apt-get update && \ | ||
apt-get install -y git make gcc python3 python curl wget && \ | ||
apt-get install -y automake autoconf libtool pkg-config libssl-dev && \ | ||
# These libraries are needed for bindgen as it uses libclang.so | ||
apt-get install -y clang libclang-dev libc6-dev-i386 | ||
|
||
WORKDIR /tmp | ||
RUN wget https://github.com/ARMmbed/mbed-crypto/archive/mbedcrypto-2.0.0.tar.gz | ||
RUN tar xf mbedcrypto-2.0.0.tar.gz | ||
RUN cd mbed-crypto-mbedcrypto-2.0.0 \ | ||
&& make SHARED=0 | ||
|
||
WORKDIR /tmp | ||
# Download and install TSS 2.0 | ||
RUN git clone https://github.com/tpm2-software/tpm2-tss.git --branch 2.3.1 | ||
RUN cd tpm2-tss \ | ||
&& ./bootstrap \ | ||
&& ./configure \ | ||
&& make -j$(nproc) \ | ||
&& make install \ | ||
&& ldconfig | ||
|
||
# Download and install TPM2 tools | ||
RUN git clone https://github.com/tpm2-software/tpm2-tools.git --branch 4.1 | ||
RUN cd tpm2-tools \ | ||
&& ./bootstrap \ | ||
&& ./configure --enable-unit \ | ||
&& make install | ||
|
||
WORKDIR /tmp | ||
RUN wget https://github.com/opendnssec/SoftHSMv2/archive/2.5.0.tar.gz | ||
RUN tar xf 2.5.0.tar.gz | ||
RUN cd SoftHSMv2-2.5.0 \ | ||
&& sh autogen.sh \ | ||
&& ./configure --disable-gost \ | ||
&& make \ | ||
&& make install | ||
|
||
# Create a new token in a new slot. The slot number assigned will be random | ||
# and is found with the find_slot_number script. | ||
RUN softhsm2-util --init-token --slot 0 --label "Parsec Tests" --pin 123456 --so-pin 123456 | ||
|
||
# Install Rust toolchain | ||
RUN curl https://sh.rustup.rs -sSf | bash -s -- -y | ||
ENV PATH="/root/.cargo/bin:${PATH}" |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
[core_settings] | ||
log_level = "debug" | ||
# The CI already timestamps the logs | ||
log_timestamp = false | ||
|
||
[listener] | ||
listener_type = "DomainSocket" | ||
timeout = 200 # in milliseconds | ||
|
||
[[key_manager]] | ||
name = "on-disk-manager" | ||
manager_type = "OnDisk" | ||
|
||
[[provider]] | ||
provider_type = "MbedProvider" | ||
key_id_manager = "on-disk-manager" | ||
|
||
[[provider]] | ||
provider_type = "TpmProvider" | ||
key_id_manager = "on-disk-manager" | ||
tcti = "mssim" | ||
|
||
[[provider]] | ||
provider_type = "Pkcs11Provider" | ||
key_id_manager = "on-disk-manager" | ||
library_path = "/usr/local/lib/softhsm/libsofthsm2.so" | ||
user_pin = "123456" | ||
# The slot_number mandatory field is going to be added by the find_slot_number.sh script | ||
# to the last line of this file in the form: | ||
# slot_number = 123456 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,16 @@ | ||
// Copyright (c) 2019, Arm Limited, All Rights Reserved | ||
// SPDX-License-Identifier: Apache-2.0 | ||
// | ||
// 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. | ||
mod all_providers; | ||
mod per_provider; |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Is there no need to
sleep
after this?There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No, because we do a
cargo build
before so that is alsmost instantaneous 😸