Coder Social home page Coder Social logo

as-base64's People

Contributors

chefsale avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar

Forkers

frederikbolding

as-base64's Issues

Index out of range for seemingly valid Base64

Hey!

Thanks for creating a great library.

I have been playing around with it lately and noticed a weird issue.

The following input fails to decode but decodes fine using atob for example: eyJuYW1lIjogIlR3aW4gRmxhbWVzICM0OS4gQWx5c29uICYgQ291cnRuZXkgQWxpYW5vIiwiaW1hZ2UiOiAiaHR0cHM6Ly9hcndlYXZlLm5ldC9vMDhSUVBTTnNoSzYybmNFc0NsRjRpWjNiMVpKYnRCSFdMTU54NVhfVFI0IiwiYWx0X2ltYWdlIjogImh0dHBzOi8vaXBmcy5pby9pcGZzL1FtTm1rdGNuMmRuQU5KaTI1Z0ZpYndtRVZ2ZVNZU3NBaGdLN01Ld1dBSnoyZXYiLCJkZXNjcmlwdGlvbiI6ICJUaXRsZTogQWx5c29uICYgQ291cnRuZXkgQWxpYW5vXG5cbkFydGlzdDogSnVzdGluIEF2ZXJzYW5vXG5cbk1lZGl1bTogQy00MSBQaG90b2dyYXBoaWMgUHJpbnRcblxuRGltZW5zaW9uczogMTbigJ0geCAyMOKAnVxuXG5QcmljZTogJDEsMDAwXG5cbkVkaXRpb246IDFcLzFcblxuWWVhcjogMjAxOFxuXG5BZGRpdGlvbmFsIEluZm9ybWF0aW9uOiBUd2lucyBhcmUgdGhvdWdodCB0byBicmluZyBsdWNrIHRvIHRob3NlIHdobyBzZWUgdGhlbSBhbmQgdG91Y2ggdGhlbSwgYW5kIHRoZXkgYXJlIHNob3dlcmVkIHdpdGggZ2lmdHMgYW5kIG1vbmV5IGZyb20gc3RyYW5nZXJzLiBUaGV5IGFyZSByZWdhcmRlZCBhcyBiZWFyZXJzIG9mIGhhcHBpbmVzcywgZ29vZCBsdWNrIGFuZCByaWNoZXMgZm9yIHRoZWlyIHBhcmVudHMsIGJ1dCBhbHNvIGFzIGZhbWlsaWFycyBvZiB0aGUgZ29kcywgd2l0aCBleHRyYW9yZGluYXJ5IHBvd2Vycy4iLCJwb3dlcmVkQnkiOiJodHRwczovL3d3dy5uYW1lbGVzcy5pby8ifQ. It throws an error with index out of range.

Any ideas?

Also, it would be great to have some sort of try_decode function that doesn't just hard crash in case of errors like this ๐Ÿค”

Security Policy violation SECURITY.md

This issue was automatically created by Allstar.

Security Policy Violation
Security policy not enabled.
A SECURITY.md file can give users information about what constitutes a vulnerability and how to report one securely so that information about a bug is not publicly visible. Examples of secure reporting methods include using an issue tracker with private issue support, or encrypted email with a published key.

To fix this, add a SECURITY.md file that explains how to handle vulnerabilities found in your repository. Go to https://github.com/near/as-base64/security/policy to enable.

For more information, see https://docs.github.com/en/code-security/getting-started/adding-a-security-policy-to-your-repository.


This issue will auto resolve when the policy is in compliance.

Issue created by Allstar. See https://github.com/ossf/allstar/ for more information. For questions specific to the repository, please contact the owner or maintainer.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.