RustCrypto / RustCrypto/utils

zeroize: `tests::zeroize_c_string` fails on i386

Open
#774 14 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Dominant language
Rust
Stars
674
Forks
170
Avg merge
1d 12h
Merged PRs (30d)
10

Description

Hi,

while testing zeroize on Debian infrastructure one test fails (it does not fail on other architectures).

---- tests::zeroize_c_string stdout ----
thread 'tests::zeroize_c_string' panicked at 'assertion failed: `(left == right)`
  left: `21`,
 right: `0`', src/lib.rs:936:17
stack backtrace:
   0: rust_begin_unwind
             at /usr/src/rustc-1.58.1/library/std/src/panicking.rs:498:5
   1: core::panicking::panic_fmt
             at /usr/src/rustc-1.58.1/library/core/src/panicking.rs:107:14
   2: core::panicking::assert_failed_inner
   3: core::panicking::assert_failed
             at /usr/src/rustc-1.58.1/library/core/src/panicking.rs:145:5
   4: zeroize::tests::zeroize_c_string
             at ./src/lib.rs:936:17
   5: zeroize::tests::zeroize_c_string::{{closure}}
             at ./src/lib.rs:922:5
   6: core::ops::function::FnOnce::call_once
             at /usr/src/rustc-1.58.1/library/core/src/ops/function.rs:227:5
   7: core::ops::function::FnOnce::call_once
             at /usr/src/rustc-1.58.1/library/core/src/ops/function.rs:227:5

Please find the full log at https://ci.debian.net/data/autopkgtest/testing/i386/r/rust-zeroize/22485575/log.gz

Any hints how to debug this?

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start at tests::zeroize_c_string in src/lib.rs around lines 922-936 and compare the Debian i386 failure with runs on other architectures. Use the linked Debian log to identify why the assertion sees 21 instead of 0; done means the test passes on i386 without regressing other architectures.

Written by the indexing model from the issue text.

Assessment

Tech stack
rust
Domain
operating-systems, testing-qa
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
25/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.