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

Crockford's Base32 decode doesn't ignore hyphen (-) in encoded input #123

Open
rmandvikar opened this issue Sep 9, 2021 · 0 comments
Open
Labels

Comments

@rmandvikar
Copy link

rmandvikar commented Sep 9, 2021

Steps to reproduce the bug

  1. Navigate to cryptii.com.
  2. Switch to Crockford's base32 decode.
  3. Input EHJQ6X-0 as text to decode.

Describe what you expected to happen

Should decode as test but displays an error.

Unexpected code point at index 6`).

Crockford's base32 spec says to ignore - chars while decoding.

Hyphens (-) can be inserted into symbol strings. This can partition a string into manageable pieces, improving readability by helping to prevent confusion. Hyphens are ignored during decoding. An application may look for hyphens to assure symbol string correctness.
See https://www.crockford.com/base32.html

Version, environment and state

{
  "version": "4.0.8+master.b029d8c",
  "env": {
    "name": "chrome",
    "version": "93.0.4577",
    "os": "Windows 10",
    "type": "browser"
  },
  "pipe": {
    "id": 3167649728,
    "url": "https://cryptii.com/pipes/base32",
    "title": "Base32 converter – Encode and decode online",
    "description": "Base32 is a transfer encoding using a 32-character set, which can be beneficial when dealing with case-insensitive filesystems, spoken language or human memory.",
    "items": [
      {
        "name": "text",
        "title": "Encoded"
      },
      {
        "name": "base32",
        "settings": {
          "variant": "crockford-base32"
        },
        "reverse": true
      },
      {
        "name": "text"
      }
    ],
    "content": {
      "data": "EHJQ6X-0"
    }
  }
}
@rmandvikar rmandvikar added the bug label Sep 9, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

1 participant