Query Info Flags (Winhttp.h)
These attributes and modifiers are used by WinHttpQueryHeaders.
The attribute flags are used by WinHttpQueryHeaders to indicate what information to retrieve. Most of the attribute flags map directly to a specific HTTP header. There are also some special flags, such as WINHTTP_QUERY_RAW_HEADERS, that are not related to a specific header.
-
WINHTTP_QUERY_ACCEPT
-
-
Retrieves the acceptable media types for the response.
-
-
WINHTTP_QUERY_ACCEPT_CHARSET
-
-
Retrieves the acceptable character sets for the response.
-
-
WINHTTP_QUERY_ACCEPT_ENCODING
-
-
Retrieves the acceptable content-coding values for the response.
-
-
WINHTTP_QUERY_ACCEPT_LANGUAGE
-
-
Retrieves the acceptable natural languages for the response.
-
-
WINHTTP_QUERY_ACCEPT_RANGES
-
-
Retrieves the types of range requests that are accepted for a resource.
-
-
WINHTTP_QUERY_AGE
-
-
Retrieves the Age response-header field, which contains the sender's estimate of the amount of time since the response was generated at the originating server.
-
-
WINHTTP_QUERY_ALLOW
-
-
Receives the HTTP verbs supported by the server.
-
-
WINHTTP_QUERY_AUTHENTICATION_INFO
-
-
Retrieves the Authentication-Info header.
-
-
WINHTTP_QUERY_AUTHORIZATION
-
-
Retrieves the authorization credentials used for a request.
-
-
WINHTTP_QUERY_CACHE_CONTROL
-
-
Retrieves the cache control directives.
-
-
WINHTTP_QUERY_CONNECTION
-
-
Retrieves any options that are specified for a particular connection and must not be communicated by proxies over further connections.
-
-
WINHTTP_QUERY_CONTENT_BASE
-
-
Retrieves the base Uniform Resource Identifier (URI) to resolve relative URLs within the entity.
-
-
WINHTTP_QUERY_CONTENT_DESCRIPTION
-
-
Obsolete. Maintained for legacy application compatibility.
-
-
WINHTTP_QUERY_CONTENT_DISPOSITION
-
-
Obsolete. Maintained for legacy application compatibility.
-
-
WINHTTP_QUERY_CONTENT_ENCODING
-
-
Retrieves additional content coding that has been applied to the entire resource.
-
-
WINHTTP_QUERY_CONTENT_ID
-
-
Retrieves the content identification.
-
-
WINHTTP_QUERY_CONTENT_LANGUAGE
-
-
Retrieves the language that the content is written in.
-
-
WINHTTP_QUERY_CONTENT_LENGTH
-
-
Retrieves the size of the resource, in bytes.
-
-
WINHTTP_QUERY_CONTENT_LOCATION
-
-
Retrieves the resource location for the entity enclosed in the message.
-
-
WINHTTP_QUERY_CONTENT_MD5
-
-
Retrieves an MD5 digest of the entity body for the purpose of providing an end-to-end message integrity check for the entity body. For more information, see RFC 1864.
-
-
WINHTTP_QUERY_CONTENT_RANGE
-
-
Retrieves the location in the full entity body where the partial entity body should be inserted and the total size of the full entity body.
-
-
WINHTTP_QUERY_CONTENT_TRANSFER_ENCODING
-
-
Retrieves an encoding transformation applicable to an entity-body. It may already have been applied, may need to be applied, or may be optionally applicable.
-
-
WINHTTP_QUERY_CONTENT_TYPE
-
-
Receives the content type of the resource, such as text or html.
-
-
WINHTTP_QUERY_COOKIE
-
-
Retrieves any cookies associated with the request.
-
-
WINHTTP_QUERY_COST
-
-
Not supported.
-
-
WINHTTP_QUERY_CUSTOM
-
-
Causes WinHttpQueryHeaders to search for the header name specified in the pwszName parameter and store the header information in lpBuffer. An application can use WINHTTP_OPTION_RECEIVE_RESPONSE_TIMEOUT to limit the maximum time this query waits for all headers to be received.
-
-
WINHTTP_QUERY_DATE
-
-
Receives the date and time at which the message was originated.
-
-
WINHTTP_QUERY_DERIVED_FROM
-
-
Not supported.
-
-
WINHTTP_QUERY_ETAG
-
-
Retrieves the entity tag for the associated entity.
-
-
WINHTTP_QUERY_EXPECT
-
-
Retrieves the Expect header, which indicates whether the client application should expect 100 series responses.
-
-
WINHTTP_QUERY_EXPIRES
-
-
Receives the date and time after which the resource should be considered outdated.
-
-
WINHTTP_QUERY_FORWARDED
-
-
Obsolete. Maintained for legacy application compatibility.
-
-
WINHTTP_QUERY_FROM
-
-
Retrieves the e-mail address for the user who controls the requesting user agent if the From header is given.
-
-
WINHTTP_QUERY_HOST
-
-
Retrieves the Internet host and port number of the resource being requested.
-
-
WINHTTP_QUERY_IF_MATCH
-
-
Retrieves the contents of the If-Match request-header field.
-
-
WINHTTP_QUERY_IF_MODIFIED_SINCE
-
-
Retrieves the contents of the If-Modified-Since header.
-
-
WINHTTP_QUERY_IF_NONE_MATCH
-
-
Retrieves the contents of the If-None-Match request-header field.
-
-
WINHTTP_QUERY_IF_RANGE
-
-
Retrieves the contents of the If-Range request-header field. This header allows the client application to check if the entity related to a partial copy of the entity in the client application's cache has not been updated. If the entity has not been updated, send the parts that the client application is missing. If the entity has been updated, send the entire updated entity.
-
-
WINHTTP_QUERY_IF_UNMODIFIED_SINCE
-
-
Retrieves the contents of the If-Unmodified-Since request-header field.
-
-
WINHTTP_QUERY_LINK
-
-
Obsolete. Maintained for legacy application compatibility.
-
-
WINHTTP_QUERY_LAST_MODIFIED
-
-
Receives the date and time at which the resource was last modified. The date and time are determined by the server.
-
-
WINHTTP_QUERY_LOCATION
-
-
Retrieves the absolute URI used in a Location response-header.
-
-
WINHTTP_QUERY_MAX
-
-
Indicates the maximum value of a WINHTTP_QUERY_* value. Not a query flag.
-
-
WINHTTP_QUERY_MAX_FORWARDS
-
-
Retrieves the number of proxies or gateways that can forward the request to the next inbound server.
-
-
WINHTTP_QUERY_MESSAGE_ID
-
-
Not supported.
-
-
WINHTTP_QUERY_MIME_VERSION
-
-
Receives the version of the Multipurpose Internet Mail Extensions (MIME) protocol that was used to construct the message.
-
-
WINHTTP_QUERY_ORIG_URI
-
-
Obsolete. Maintained for legacy application compatibility.
-
-
WINHTTP_QUERY_PRAGMA
-
-
Receives the implementation-specific directives that might apply to any recipient along the request/response chain.
-
-
WINHTTP_QUERY_PROXY_AUTHENTICATE
-
-
Retrieves the authentication scheme and realm returned by the proxy.
-
-
WINHTTP_QUERY_PROXY_AUTHORIZATION
-
-
Retrieves the header that is used to identify the user to a proxy that requires authentication. This header can only be retrieved before the request is sent to the server.
-
-
WINHTTP_QUERY_PROXY_CONNECTION
-
-
Retrieves the Proxy-Connection header.
-
-
WINHTTP_QUERY_PROXY_SUPPORT
-
-
Retrieves the Proxy-Support header.
-
-
WINHTTP_QUERY_PUBLIC
-
-
Receives HTTP verbs available at this server.
-
-
WINHTTP_QUERY_RANGE
-
-
Retrieves the byte range of an entity.
-
-
WINHTTP_QUERY_RAW_HEADERS
-
-
Receives all the headers returned by the server. Each header is terminated by "\0". An additional "\0" terminates the list of headers.
-
-
WINHTTP_QUERY_RAW_HEADERS_CRLF
-
-
Receives all the headers returned by the server. Each header is separated by a carriage return/line feed (CR/LF) sequence.
-
-
WINHTTP_QUERY_REFERER
-
-
Receives the URI of the resource where the requested URI was obtained.
-
-
WINHTTP_QUERY_REFRESH
-
-
Obsolete. Maintained for legacy application compatibility.
-
-
WINHTTP_QUERY_REQUEST_METHOD
-
-
Receives the HTTP verb that is being used in the request, typically GET or POST.
-
-
WINHTTP_QUERY_RETRY_AFTER
-
-
Retrieves the amount of time the service is expected to be unavailable.
-
-
WINHTTP_QUERY_SERVER
-
-
Retrieves information about the software used by the originating server to handle the request.
-
-
WINHTTP_QUERY_SET_COOKIE
-
-
Receives the value of the cookie set for the request.
-
-
WINHTTP_QUERY_STATUS_CODE
-
-
Receives the status code returned by the server. For a list of possible values, see HTTP Status Codes.
-
-
WINHTTP_QUERY_STATUS_TEXT
-
-
Receives additional text returned by the server on the response line.
-
-
WINHTTP_QUERY_TITLE
-
-
Obsolete. Maintained for legacy application compatibility.
-
-
WINHTTP_QUERY_TRANSFER_ENCODING
-
-
Retrieves the type of transformation that has been applied to the message body so it can be safely transferred between the sender and recipient.
-
-
WINHTTP_QUERY_UNLESS_MODIFIED_SINCE
-
-
Retrieves the Unless-Modified-Since header.
-
-
WINHTTP_QUERY_UPGRADE
-
-
Retrieves the additional communication protocols that are supported by the server.
-
-
WINHTTP_QUERY_URI
-
-
Receives some or all of the URI by which the Request-URI resource can be identified.
-
-
WINHTTP_QUERY_USER_AGENT
-
-
Retrieves information about the user agent that made the request.
-
-
WINHTTP_QUERY_VARY
-
-
Retrieves the header that indicates that the entity was selected from a number of available representations of the response using server-driven negotiation.
-
-
WINHTTP_QUERY_VERSION
-
-
Retrieves the HTTP version that is present in the status line.
-
-
WINHTTP_QUERY_VIA
-
-
Retrieves the intermediate protocols and recipients between the user agent and the server on requests, and between the origin server and the client on responses.
-
-
WINHTTP_QUERY_WARNING
-
-
Retrieves additional information about the status of a response that might not be reflected by the response status code.
-
-
WINHTTP_QUERY_WWW_AUTHENTICATE
-
-
Retrieves the authentication scheme and realm returned by the server.
-
The modifier flags are used in conjunction with an attribute flag to modify the request. Modifier flags either modify the format of the data returned or indicate where the WinHttpQueryHeaders function should search for the information.
-
WINHTTP_QUERY_FLAG_NUMBER
-
-
Returns the data as a 32-bit number for headers whose value is a number, such as the status code.
-
-
WINHTTP_QUERY_FLAG_REQUEST_HEADERS
-
-
Queries request headers only.
-
-
WINHTTP_QUERY_FLAG_SYSTEMTIME
-
-
Returns the header value as a SYSTEMTIME structure, which does not require the application to parse the data. Use for headers whose value is a date/time string, such as "Last-Modified-Time".
-
WINHTTP_QUERY_FLAG_TRAILERS
-
Introduced in Windows 11, version 21H2 (10.0; Build 22000). Queries response trailers. Prior to querying response trailers, you must call WinHttpReadData until it returns 0 bytes read.
WINHTTP_QUERY_FLAG_WIRE_ENCODING
-
Introduced in Windows 11, version 21H2 (10.0; Build 22000). By default, WinHttpQueryHeaders performs a Unicode conversion before returning the header that was queried. If this flag is set, WinHttp returns the header to the caller without performing this conversion.
Requirements
Requirement | Value |
---|---|
Minimum supported client | Windows XP, Windows 2000 Professional with SP3 [desktop apps only] |
Minimum supported server | Windows Server 2003, Windows 2000 Server with SP3 [desktop apps only] |
Header |
|