# crypto: correctly disallow non-digits in time · gitcafe/zig

[View on GitCafe](https://git.cafe/gitcafe/zig/commit/8b71ec6db700dc7af22ce0729991bce846ae6d76)

Repository: [gitcafe/zig](https://git.cafe/gitcafe/zig)

Visibility: public

Requested revision: 8b71ec6db700dc7af22ce0729991bce846ae6d76

Requested commit: 8b71ec6db700dc7af22ce0729991bce846ae6d76

Commit: 8b71ec6db700dc7af22ce0729991bce846ae6d76

Tree: a5755b1aadcca066ef2823a5af9ebf8763a21750

Author: David Rubin

Committer: Andrew Kelley

## Message

```
crypto: correctly disallow non-digits in time

Previously these functions made the assumption that
when performing a  on the input digits,
there could be no collisions between the less
significant digits being larger than '9', and the
upper digits being small enough to get past the
 checks.

Now we perform a correct check across all of the
digits to ensure they're in between '0'-'9', at
a minimal cost, since all digits are checked in
parallel.

```

## Parents

- [9c55776d259a4c29bd292a690f37678cecd62fda](https://git.cafe/gitcafe/zig/commit/9c55776d259a4c29bd292a690f37678cecd62fda?format=markdown)

[Source at this commit](https://git.cafe/gitcafe/zig/tree/8b71ec6db700dc7af22ce0729991bce846ae6d76?format=markdown)
