Google Authenticator Implementation with PHP

Поділитися
Вставка
  • Опубліковано 2 жов 2024
  • A basic implementation of the RFC 6238 standards for TOTP: Time-Based One-Time Password Algorithm using PHP for original Key and QR Code generation and the Google Authenticator application for TOTP generation.
    More about me:
    interactiveuto...
    GitHub:
    github.com/gil...
    Documentation:
    www.rfc-editor...
    packagist.org/...
    packagist.org/...

КОМЕНТАРІ • 15

  • @JoshRosario310
    @JoshRosario310 5 місяців тому

    Great tutorial, thank you very much.

  • @helloholahi
    @helloholahi Рік тому +2

    super great tutorial!! 🙂 very clear, you explain things well with enough details to understand everything, thanks for sharing this!

  • @virgilesahaguian2133
    @virgilesahaguian2133 6 місяців тому +1

    Question, how can we link that with the google auth application ?

  • @donesposito
    @donesposito 2 місяці тому

    Thank you! Your implementation and explanation in this video worked like a charm.

  • @yeslouise9317
    @yeslouise9317 Рік тому +1

    thanks. is it advisable to store the secret keys in the database? I'm only limited to this option right now.

    • @InteractiveUtopia
      @InteractiveUtopia  Рік тому

      Not advisable, but many times as states it is the only feasible way

  • @CarloOmbri
    @CarloOmbri Рік тому +1

    Hello, my web host does not use imagemagick extension but GD2. How can I change the code? thanks

    • @InteractiveUtopia
      @InteractiveUtopia  Рік тому

      I am guessing this is for the QR code generator. Have you tried a different one? If you got the url to be created that is the important part. Then use that url in your QR generation app of your choice. You can even use a system online (not super safe nor recommended in this case) but you can use it to test your code.

    • @helloholahi
      @helloholahi Рік тому +3

      you can modify your code this way:
      - comment or remove this line: use BaconQrCode\Renderer\Image\ImagickImageBackEnd;
      - add this line instead (or below the previous one): use BaconQrCode\Renderer\Image\SvgImageBackEnd;
      this will load the Svg library instead of the Imagick one, which doesn't require Imagick or GD, and will generate a .svg image, which is lighter and more high-density pixels screens friendly.
      - this portion of code:
      $renderer = new ImageRenderer(
      new RendererStyle(250),
      new ImagickImageBackEnd()
      );
      becomes:
      $renderer = new ImageRenderer(
      new RendererStyle(250),
      new SvgImageBackEnd()
      );
      - then change the file name from .png to .svg
      - the tag becomes:

    • @InteractiveUtopia
      @InteractiveUtopia  Рік тому +1

      Thanks for the help!

  • @xXNJEEBXx
    @xXNJEEBXx Рік тому +1

    thanks i love you