knightpp / knightpp/serde_bencoded

Leading zeros in integer

Open
#6 1 comment 0 reactions 0 assignees View on GitHub
good first issue
Dominant language
Rust
Stars
4
Forks
2
PR merge metrics
No merged PRs in 30d

Description

It seems that serde_bencode is accepting integers with leading zeros as a valid bencode encoded integer but the specs clearly say that leading zeros are not allowed. For example i01e should be invalidly bencode encoded integer, not 1.

Contributor guide

No contributing guide indexed for this repository

Research direction

The issue names no files or tests. Start by locating the bencode integer decoder and its handling of i01e; add a regression test showing that this input is rejected while valid integer encodings remain accepted.

Written by the indexing model from the issue text.

Assessment

Tech stack
rust
Domain
backend
Issue type
Bug
Difficulty
2/5
Estimated time
1-3 hours
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
42/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.