Пример #1
0
  public void maySetSAuthVersion(HttpRequest request) {
    if (request.hasNotHeader(Header.SAuth.Value.Authorization))
      request.setHeader(Header.SAuth.Value.Authorization);

    if (request.hasNotHeader(Header.SAuth.Value.Version))
      request.setHeader(Header.SAuth.Value.Version);
  }
Пример #2
0
 public void setSAuthSignature(HttpRequest request, long folded) {
   java.lang.String value = alto.io.u.Hex.encode(folded);
   request.setHeader(Header.SAuth.Signature, value);
 }
Пример #3
0
 public void setSAuthSignature(HttpRequest request, java.lang.String value) {
   request.setHeader(Header.SAuth.Signature, value);
 }
Пример #4
0
 public void setSAuthNonce(HttpRequest request, java.lang.String value) {
   request.setHeader(Header.SAuth.Nonce, value);
 }
Пример #5
0
 public void maySetSAuthNonce(HttpRequest request) {
   if (request.hasNotHeader(Header.SAuth.Nonce))
     request.setHeader(Header.SAuth.Nonce, alto.io.u.Prng.RandLongStringHex());
 }
Пример #6
0
 public void setSAuthNonce(HttpRequest request) {
   request.setHeader(Header.SAuth.Nonce, alto.io.u.Prng.RandLongStringHex());
 }
Пример #7
0
 public void setSAuthUID(HttpRequest request, Principal principal) {
   request.setHeader(Header.SAuth.UID, principal.getName());
 }
Пример #8
0
 public void maySetSAuthUID(HttpRequest request, java.lang.String uid) {
   java.lang.String value = this.getSAuthUID(request);
   if (null == value || (!value.equals(uid))) request.setHeader(Header.SAuth.UID, uid);
 }
Пример #9
0
 public void setSAuthUID(HttpRequest request, java.lang.String value) {
   request.setHeader(Header.SAuth.UID, value);
 }