-
Notifications
You must be signed in to change notification settings - Fork 114
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
Rust oak_loader
binary is not reproducibly buildable (ahash::SEED)
#862
Comments
Partly addresses project-oak#862 (it looks like there are some other non-deterministic diffs unrelated to this)
Partly addresses #862 (it looks like there are some other non-deterministic diffs unrelated to this)
Update: #863 fixed the There is still another diff left (following the first few steps from above, then):
I have no idea what this is about, but it does not seem to be an ELF header: the output of |
Maybe getting to the bottom of this: Disassembling around that section with
which to me looks like a random seed of some sort that gets generated by the compiler and baked into the resulting binary? |
Relevant section with demangled name:
|
oak_loader
binary is not reproducibly buildable (NT_GNU_BUILD_ID)oak_loader
binary is not reproducibly buildable (ahash::SEED)
BTW, % echo _ZN5ahash4SEED17h75898f69630b4c3aE | c++filt
ahash::SEED
% dpkg -S `which c++filt`
binutils: /usr/bin/c++filt |
Probably this, which looks to be under the |
This makes the build non-deterministic: project-oak#862 (comment) It was introduced in an attempt to make `oak_abi` `no_std` compatible, but that's not necessary any more. Ref project-oak#862
This makes the build non-deterministic: project-oak#862 (comment) It was introduced in an attempt to make `oak_abi` `no_std` compatible, but that's not necessary any more. Ref project-oak#862
This makes the build non-deterministic: project-oak#862 (comment) It was introduced in an attempt to make `oak_abi` `no_std` compatible, but that's not necessary any more. Ref project-oak#862
This makes the build non-deterministic: project-oak#862 (comment) It was introduced in an attempt to make `oak_abi` `no_std` compatible, but that's not necessary any more. Ref project-oak#862
This makes the build non-deterministic: project-oak#862 (comment) It was introduced in an attempt to make `oak_abi` `no_std` compatible, but that's not necessary any more. Ref project-oak#862
The |
This was making the build non-deterministic: #862 (comment) It was introduced in an attempt to make `oak_abi` `no_std` compatible, but that's not necessary any more. Ref #862
The C++/Rust combined build seems to at least have "naïve reproducibility" (two consecutive clean builds give the same binary output, implying that there's no explicit randomness or timestamping in the build). |
This was done in project-oak#863 for the gnu (libc) target Ref project-oak#862
To reproduce (no pun intended):
output of the final diff:
It seems that the
NT_GNU_BUILD_ID
field is populated with a random string at each build invocation.I guess we could strip that out in a post-build step, but it would be nice to figure out if there is a
cargo
orrustc
flag to avoid this in the first place.cc @ipetr0v
Blocks #861
The text was updated successfully, but these errors were encountered: