Package com.github.ambry.frontend
Class AmbryUrlSigningService
- java.lang.Object
-
- com.github.ambry.frontend.AmbryUrlSigningService
-
- All Implemented Interfaces:
com.github.ambry.frontend.UrlSigningService
public class AmbryUrlSigningService extends java.lang.Object implements com.github.ambry.frontend.UrlSigningService
Default implementation ofUrlSigningService
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)
-
-
-
Method Detail
-
getSignedUrl
public java.lang.String getSignedUrl(com.github.ambry.rest.RestRequest restRequest) throws com.github.ambry.rest.RestServiceException
- Specified by:
getSignedUrl
in interfacecom.github.ambry.frontend.UrlSigningService
- Throws:
com.github.ambry.rest.RestServiceException
-
isRequestSigned
public boolean isRequestSigned(com.github.ambry.rest.RestRequest restRequest)
- Specified by:
isRequestSigned
in interfacecom.github.ambry.frontend.UrlSigningService
-
verifySignedRequest
public void verifySignedRequest(com.github.ambry.rest.RestRequest restRequest) throws com.github.ambry.rest.RestServiceException
- Specified by:
verifySignedRequest
in interfacecom.github.ambry.frontend.UrlSigningService
- Throws:
com.github.ambry.rest.RestServiceException
-
getUploadEndpoint
public java.lang.String getUploadEndpoint()
-
getDownloadEndpoint
public java.lang.String getDownloadEndpoint()
-
-