Lines Matching full:scheme
40 static const char *cups_auth_find(const char *www_authenticate, const char *scheme);
41 static const char *cups_auth_param(const char *scheme, const char *name, char *value, size_t valsiz…
42 static const char *cups_auth_scheme(const char *www_authenticate, char *scheme, size_t schemesize);
114 *schemedata; /* Scheme-specific data */ in cupsDoAuthentication()
115 char scheme[256], /* Scheme name */ in cupsDoAuthentication() local
169 …_scheme(www_auth, scheme, sizeof(scheme)); schemedata; schemedata = cups_auth_scheme(schemedata + … in cupsDoAuthentication()
172 * Check the scheme name... in cupsDoAuthentication()
175 DEBUG_printf(("2cupsDoAuthentication: Trying scheme \"%s\"...", scheme)); in cupsDoAuthentication()
178 if (!_cups_strcasecmp(scheme, "Negotiate") && !cups_is_local_connection(http)) in cupsDoAuthentication()
205 if (_cups_strcasecmp(scheme, "Basic") && in cupsDoAuthentication()
206 _cups_strcasecmp(scheme, "Digest") && in cupsDoAuthentication()
207 _cups_strcasecmp(scheme, "Negotiate")) in cupsDoAuthentication()
213 DEBUG_printf(("2cupsDoAuthentication: Scheme \"%s\" not yet supported.", scheme)); in cupsDoAuthentication()
240 http->digest_tries = _cups_strncasecmp(scheme, "Digest", 6) != 0; in cupsDoAuthentication()
267 if (!_cups_strcasecmp(scheme, "Basic")) in cupsDoAuthentication()
280 else if (!_cups_strcasecmp(scheme, "Digest")) in cupsDoAuthentication()
510 * 'cups_auth_find()' - Find the named WWW-Authenticate scheme.
514 * Returns @code NULL@ if the auth scheme is not present.
517 static const char * /* O - Start of matching scheme or @code NULL@ if not found */
519 const char *scheme) /* I - Authentication scheme */ in cups_auth_find() argument
521 size_t schemelen = strlen(scheme); /* Length of scheme */ in cups_auth_find()
524 …BUG_printf(("8cups_auth_find(www_authenticate=\"%s\", scheme=\"%s\"(%d))", www_authenticate, schem… in cups_auth_find()
538 * See if this is "Scheme" followed by whitespace or the end of the string. in cups_auth_find()
541 …if (!strncmp(www_authenticate, scheme, schemelen) && (isspace(www_authenticate[schemelen] & 255) |… in cups_auth_find()
544 * Yes, this is the start of the scheme-specific information... in cups_auth_find()
553 * Skip the scheme name or param="value" string... in cups_auth_find()
589 cups_auth_param(const char *scheme, /* I - Pointer to auth data */ in cups_auth_param() argument
600 …DEBUG_printf(("8cups_auth_param(scheme=\"%s\", name=\"%s\", value=%p, valsize=%d)", scheme, name, … in cups_auth_param()
602 while (!isspace(*scheme & 255) && *scheme) in cups_auth_param()
603 scheme ++; in cups_auth_param()
605 while (*scheme) in cups_auth_param()
607 while (isspace(*scheme & 255) || *scheme == ',') in cups_auth_param()
608 scheme ++; in cups_auth_param()
610 if (!strncmp(scheme, name, namelen) && scheme[namelen] == '=') in cups_auth_param()
616 scheme += namelen + 1; in cups_auth_param()
617 if (*scheme == '\"') in cups_auth_param()
619 scheme ++; in cups_auth_param()
621 while (*scheme && *scheme != '\"') in cups_auth_param()
624 *valptr++ = *scheme; in cups_auth_param()
626 scheme ++; in cups_auth_param()
631 …while (*scheme && strchr("ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789-._~+/=", … in cups_auth_param()
634 *valptr++ = *scheme; in cups_auth_param()
636 scheme ++; in cups_auth_param()
653 while (!isspace(*scheme & 255) && *scheme) in cups_auth_param()
655 if (*scheme == '=') in cups_auth_param()
657 else if (*scheme == '\"') in cups_auth_param()
663 scheme ++; in cups_auth_param()
664 while (*scheme && *scheme != '\"') in cups_auth_param()
665 scheme ++; in cups_auth_param()
668 scheme ++; in cups_auth_param()
672 * If this wasn't a parameter, we are at the end of this scheme's in cups_auth_param()
689 * 'cups_auth_scheme()' - Get the (next) WWW-Authenticate scheme.
696 static const char * /* O - Start of scheme or @code NULL@ if not found */
698 char *scheme, /* I - Scheme name buffer */ in cups_auth_scheme() argument
701 const char *start; /* Start of scheme data */ in cups_auth_scheme()
702 char *sptr = scheme, /* Pointer into scheme buffer */ in cups_auth_scheme()
703 *send = scheme + schemesize - 1;/* End of scheme buffer */ in cups_auth_scheme()
707 …(("8cups_auth_scheme(www_authenticate=\"%s\", scheme=%p, schemesize=%d)", www_authenticate, (void … in cups_auth_scheme()
719 * Parse the scheme name or param="value" string... in cups_auth_scheme()
722 …for (sptr = scheme, start = www_authenticate, param = 0; *www_authenticate && *www_authenticate !=… in cups_auth_scheme()
740 if (sptr > scheme && !param) in cups_auth_scheme()
750 *scheme = '\0'; in cups_auth_scheme()
952 *schemedata; /* Data for the named auth scheme */ in cups_local_auth()