Class AmbryUrlSigningService

  • All Implemented Interfaces:
    com.github.ambry.frontend.UrlSigningService

    public class AmbryUrlSigningService
    extends java.lang.Object
    implements com.github.ambry.frontend.UrlSigningService
    Default implementation of UrlSigningService that currently only converts all headers that start with "x-ambry-" into query parameters and does not actually sign the URL.

    A real implementation needs to encode enough information for manipulations to be discovered. See https://github.com/linkedin/ambry/issues/788

    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      java.lang.String getDownloadEndpoint()  
      java.lang.String getSignedUrl​(com.github.ambry.rest.RestRequest restRequest)  
      java.lang.String getUploadEndpoint()  
      boolean isRequestSigned​(com.github.ambry.rest.RestRequest restRequest)  
      void verifySignedRequest​(com.github.ambry.rest.RestRequest restRequest)  
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
      • Methods inherited from interface com.github.ambry.frontend.UrlSigningService

        verifySignedRequest
    • Method Detail

      • getSignedUrl

        public java.lang.String getSignedUrl​(com.github.ambry.rest.RestRequest restRequest)
                                      throws com.github.ambry.rest.RestServiceException
        Specified by:
        getSignedUrl in interface com.github.ambry.frontend.UrlSigningService
        Throws:
        com.github.ambry.rest.RestServiceException
      • isRequestSigned

        public boolean isRequestSigned​(com.github.ambry.rest.RestRequest restRequest)
        Specified by:
        isRequestSigned in interface com.github.ambry.frontend.UrlSigningService
      • verifySignedRequest

        public void verifySignedRequest​(com.github.ambry.rest.RestRequest restRequest)
                                 throws com.github.ambry.rest.RestServiceException
        Specified by:
        verifySignedRequest in interface com.github.ambry.frontend.UrlSigningService
        Throws:
        com.github.ambry.rest.RestServiceException
      • getUploadEndpoint

        public java.lang.String getUploadEndpoint()
      • getDownloadEndpoint

        public java.lang.String getDownloadEndpoint()