Sha512.php 607 B

123456789101112131415161718192021222324252627282930313233343536
  1. <?php
  2. /**
  3. * This file is part of Lcobucci\JWT, a simple library to handle JWT and JWS
  4. *
  5. * @license http://opensource.org/licenses/BSD-3-Clause BSD-3-Clause
  6. */
  7. namespace Lcobucci\JWT\Signer\Rsa;
  8. use Lcobucci\JWT\Signer\Rsa;
  9. /**
  10. * Signer for RSA SHA-512
  11. *
  12. * @author Luís Otávio Cobucci Oblonczyk <lcobucci@gmail.com>
  13. * @since 2.1.0
  14. */
  15. class Sha512 extends Rsa
  16. {
  17. /**
  18. * {@inheritdoc}
  19. */
  20. public function getAlgorithmId()
  21. {
  22. return 'RS512';
  23. }
  24. /**
  25. * {@inheritdoc}
  26. */
  27. public function getAlgorithm()
  28. {
  29. return OPENSSL_ALGO_SHA512;
  30. }
  31. }