Skip to content
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

registry paths hard coded in binary #9311

Closed
chemsaf3 opened this issue Mar 28, 2021 · 3 comments
Closed

registry paths hard coded in binary #9311

chemsaf3 opened this issue Mar 28, 2021 · 3 comments
Labels
C-bug Category: bug

Comments

@chemsaf3
Copy link

chemsaf3 commented Mar 28, 2021

Problem

hardcoded paths in binary with username and fs paths. bloats binary, prevent reproducibility, and violates privacy. even in release mode

strip command does not properly remove everything too

redacted EXAMPLES

internal error: entered unreachable codeD:\REDACTED\.cargo\registry\src\github.com-1ecc6299db9ec823\aho-corasick-0.7.15\src\ahocorasick.rs
D:\REDACTED\.cargo\registry\src\github.com-1ecc6299db9ec823\aho-corasick-0.7.15\src\prefilter.rssetRareByteOffsets
called `Option::unwrap()` on a `None` valueD:\REDACTED\.cargo\registry\src\github.com-1ecc6299db9ec823\aho-corasick-0.7.15\src\classes.rs
D:\REDACTED\.cargo\registry\src\github.com-1ecc6299db9ec823\aho-corasick-0.7.15\src\packed\pattern.rs
internal error: entered unreachable codeD:\REDACTED\.cargo\registry\src\github.com-1ecc6299db9ec823\aho-corasick-0.7.15\src\packed\teddy\compile.rs
D:\REDACTED\.cargo\registry\src\github.com-1ecc6299db9ec823\rand-0.8.3\src\rngs\thread.rs
D:\REDACTED\.cargo\registry\src\github.com-1ecc6299db9ec823\rand_chacha-0.3.0\src\guts.rs
D:\REDACTED\git\PROJECT\target\release\deps\PROJECT.pdb

Steps

  1. install rust
  2. write an app using a dep
  3. compile app
  4. check strings for user id

Possible Solution(s)

auto strip this info (preferred) or provide wildcard way to mangle paths

Notes

Output of cargo version:

> cargo version
cargo 1.50.0 (f04e7fab7 2021-02-04)

Related

#5505
rust-lang/rust#40374
rust-lang/rust#40552
rust-lang/rust#75263

@ehuss
Copy link
Contributor

ehuss commented Mar 29, 2021

Thanks for the report! It looks like you found several other issues related to this, so I'm unclear if this issue is covering anything new. It seems like #5505 covers dealing with remapping, can you clarify what is different here?

@rust-lang rust-lang deleted a comment from pthreat Apr 4, 2021
@geraldo-netto
Copy link

+1

@ehuss
Copy link
Contributor

ehuss commented May 29, 2021

I'm going to close this issue as a duplicate of #5505. I realize this is an important issue for some, and hopefully there will be some progress in the future. You may want to also check out rust-lang/rfcs#3127 which is a recent proposal to work towards resolving this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
C-bug Category: bug
Projects
None yet
Development

No branches or pull requests

3 participants