You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 

30 lines
620 B

  1. package aws
  2. import (
  3. "net/http"
  4. "time"
  5. )
  6. // V4Signer:
  7. // Exporting methods for testing
  8. func (s *V4Signer) RequestTime(req *http.Request) time.Time {
  9. return s.requestTime(req)
  10. }
  11. func (s *V4Signer) CanonicalRequest(req *http.Request) string {
  12. return s.canonicalRequest(req)
  13. }
  14. func (s *V4Signer) StringToSign(t time.Time, creq string) string {
  15. return s.stringToSign(t, creq)
  16. }
  17. func (s *V4Signer) Signature(t time.Time, sts string) string {
  18. return s.signature(t, sts)
  19. }
  20. func (s *V4Signer) Authorization(header http.Header, t time.Time, signature string) string {
  21. return s.authorization(header, t, signature)
  22. }