code:     protected void setAuthenticateHeader(HttpServletRequest request,
                                           HttpServletResponse response,
                                           LoginConfig config,
                                           String nOnce) {
  
          // Get the realm name
          String realmName = config.getRealmName();
          if (realmName == null)
              realmName = REALM_NAME;
  
          byte[] buffer = null;
          synchronized (md5Helper) {
              buffer = md5Helper.digest(nOnce.getBytes());
          }
  
          String authenticateHeader = "Digest realm=\"" + realmName + "\", "
              +  "qop=\"auth\", nonce=\"" + nOnce + "\", " + "opaque=\""
              + md5Encoder.encode(buffer) + "\"";
          response.setHeader(AUTH_HEADER_NAME, authenticateHeader);
  
      }
  
  
  