Hacktoberfest 2026: the issues maintainers tagged for October, open and beginner-friendly. Browse Hacktoberfest issues

zeroize_derive: attribute for obtaining a mutable slice

Open
#901 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Assessment

Difficulty
3/5
Estimated time
1-2 days
Newbie friendliness
48/100
Issue type
Feature
Clarity
Mostly clear
Activity status
Stale
Tech stack
rust
Domain
tooling

Research direction

Start by locating the zeroize custom-derive entry point and the existing slice Zeroize implementation described in the issue. Trace how derive attributes are parsed, then add coverage for #[zeroize(as_mut)] on a Vec field; done means the attribute derives a working implementation that uses the field's mutable slice.

Written by the indexing model from the issue text.

Description

An optimized Zeroize<Z> impl exists for slices where Z: DefaultIsZeros.

It would be nice if custom derive could leverage it by obtaining a mutable slice of a field, e.g. via the AsMut trait:

#[zeroize(as_mut)]
field: Vec<u8>,
Dominant language
Rust
Stars
674
Forks
170
Avg merge
1d 12h
Merged PRs (30d)
10

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.

More from RustCrypto/utils

All issues in RustCrypto/utils

Similar issues

More Rust issues

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.