Skip to content

A little improvement you might be interested to pull #2

Description

@pnowosie

Hello James,

First things first - kudos for great work to bringing TOTP codes to Elixir!

As a part of side project I need a totp library in elixir and found your repo. To convince myself it works as specified in RFC-6238 I've added test code to run tests agains rfc's test vectors. Besides small fix regarding leading zeros it generates the same, correct tokens for specified timestamps.

Small enhancements I did (besides test code) now one can specify

  • length of the generated token
  • more hash/hmac algorithms to use (RFC provides tests vectors for SHA-1, SHA-256, SHA-512)

One thing still needs to be done is to add a few words to readme to let other people know code is indeed solid, well tested and follows RFC specs, which is result of yours hard work 🥇 in the first place.

Please let me know if my changes fits to your vision and if you're interested in accepting my PR. I will be glad to join as a contributor.

/Pawel

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions