win32inetcon.py 47 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667686970717273747576777879808182838485868788899091929394959697989910010110210310410510610710810911011111211311411511611711811912012112212312412512612712812913013113213313413513613713813914014114214314414514614714814915015115215315415515615715815916016116216316416516616716816917017117217317417517617717817918018118218318418518618718818919019119219319419519619719819920020120220320420520620720820921021121221321421521621721821922022122222322422522622722822923023123223323423523623723823924024124224324424524624724824925025125225325425525625725825926026126226326426526626726826927027127227327427527627727827928028128228328428528628728828929029129229329429529629729829930030130230330430530630730830931031131231331431531631731831932032132232332432532632732832933033133233333433533633733833934034134234334434534634734834935035135235335435535635735835936036136236336436536636736836937037137237337437537637737837938038138238338438538638738838939039139239339439539639739839940040140240340440540640740840941041141241341441541641741841942042142242342442542642742842943043143243343443543643743843944044144244344444544644744844945045145245345445545645745845946046146246346446546646746846947047147247347447547647747847948048148248348448548648748848949049149249349449549649749849950050150250350450550650750850951051151251351451551651751851952052152252352452552652752852953053153253353453553653753853954054154254354454554654754854955055155255355455555655755855956056156256356456556656756856957057157257357457557657757857958058158258358458558658758858959059159259359459559659759859960060160260360460560660760860961061161261361461561661761861962062162262362462562662762862963063163263363463563663763863964064164264364464564664764864965065165265365465565665765865966066166266366466566666766866967067167267367467567667767867968068168268368468568668768868969069169269369469569669769869970070170270370470570670770870971071171271371471571671771871972072172272372472572672772872973073173273373473573673773873974074174274374474574674774874975075175275375475575675775875976076176276376476576676776876977077177277377477577677777877978078178278378478578678778878979079179279379479579679779879980080180280380480580680780880981081181281381481581681781881982082182282382482582682782882983083183283383483583683783883984084184284384484584684784884985085185285385485585685785885986086186286386486586686786886987087187287387487587687787887988088188288388488588688788888989089189289389489589689789889990090190290390490590690790890991091191291391491591691791891992092192292392492592692792892993093193293393493593693793893994094194294394494594694794894995095195295395495595695795895996096196296396496596696796896997097197297397497597697797897998098198298398498598698798898999099199299399499599699799899910001001100210031004100510061007100810091010101110121013101410151016101710181019102010211022102310241025102610271028102910301031103210331034103510361037103810391040104110421043104410451046104710481049105010511052105310541055105610571058105910601061106210631064106510661067106810691070107110721073107410751076107710781079108010811082108310841085108610871088108910901091109210931094109510961097109810991100110111021103
  1. # Generated by h2py from \mssdk\include\WinInet.h
  2. INTERNET_INVALID_PORT_NUMBER = 0
  3. INTERNET_DEFAULT_FTP_PORT = 21
  4. INTERNET_DEFAULT_GOPHER_PORT = 70
  5. INTERNET_DEFAULT_HTTP_PORT = 80
  6. INTERNET_DEFAULT_HTTPS_PORT = 443
  7. INTERNET_DEFAULT_SOCKS_PORT = 1080
  8. INTERNET_MAX_HOST_NAME_LENGTH = 256
  9. INTERNET_MAX_USER_NAME_LENGTH = 128
  10. INTERNET_MAX_PASSWORD_LENGTH = 128
  11. INTERNET_MAX_PORT_NUMBER_LENGTH = 5
  12. INTERNET_MAX_PORT_NUMBER_VALUE = 65535
  13. INTERNET_MAX_PATH_LENGTH = 2048
  14. INTERNET_MAX_SCHEME_LENGTH = 32
  15. INTERNET_KEEP_ALIVE_ENABLED = 1
  16. INTERNET_KEEP_ALIVE_DISABLED = 0
  17. INTERNET_REQFLAG_FROM_CACHE = 0x00000001
  18. INTERNET_REQFLAG_ASYNC = 0x00000002
  19. INTERNET_REQFLAG_VIA_PROXY = 0x00000004
  20. INTERNET_REQFLAG_NO_HEADERS = 0x00000008
  21. INTERNET_REQFLAG_PASSIVE = 0x00000010
  22. INTERNET_REQFLAG_CACHE_WRITE_DISABLED = 0x00000040
  23. INTERNET_REQFLAG_NET_TIMEOUT = 0x00000080
  24. INTERNET_FLAG_RELOAD = (-2147483648)
  25. INTERNET_FLAG_RAW_DATA = 0x40000000
  26. INTERNET_FLAG_EXISTING_CONNECT = 0x20000000
  27. INTERNET_FLAG_ASYNC = 0x10000000
  28. INTERNET_FLAG_PASSIVE = 0x08000000
  29. INTERNET_FLAG_NO_CACHE_WRITE = 0x04000000
  30. INTERNET_FLAG_DONT_CACHE = INTERNET_FLAG_NO_CACHE_WRITE
  31. INTERNET_FLAG_MAKE_PERSISTENT = 0x02000000
  32. INTERNET_FLAG_FROM_CACHE = 0x01000000
  33. INTERNET_FLAG_OFFLINE = INTERNET_FLAG_FROM_CACHE
  34. INTERNET_FLAG_SECURE = 0x00800000
  35. INTERNET_FLAG_KEEP_CONNECTION = 0x00400000
  36. INTERNET_FLAG_NO_AUTO_REDIRECT = 0x00200000
  37. INTERNET_FLAG_READ_PREFETCH = 0x00100000
  38. INTERNET_FLAG_NO_COOKIES = 0x00080000
  39. INTERNET_FLAG_NO_AUTH = 0x00040000
  40. INTERNET_FLAG_RESTRICTED_ZONE = 0x00020000
  41. INTERNET_FLAG_CACHE_IF_NET_FAIL = 0x00010000
  42. INTERNET_FLAG_IGNORE_REDIRECT_TO_HTTP = 0x00008000
  43. INTERNET_FLAG_IGNORE_REDIRECT_TO_HTTPS = 0x00004000
  44. INTERNET_FLAG_IGNORE_CERT_DATE_INVALID = 0x00002000
  45. INTERNET_FLAG_IGNORE_CERT_CN_INVALID = 0x00001000
  46. INTERNET_FLAG_RESYNCHRONIZE = 0x00000800
  47. INTERNET_FLAG_HYPERLINK = 0x00000400
  48. INTERNET_FLAG_NO_UI = 0x00000200
  49. INTERNET_FLAG_PRAGMA_NOCACHE = 0x00000100
  50. INTERNET_FLAG_CACHE_ASYNC = 0x00000080
  51. INTERNET_FLAG_FORMS_SUBMIT = 0x00000040
  52. INTERNET_FLAG_FWD_BACK = 0x00000020
  53. INTERNET_FLAG_NEED_FILE = 0x00000010
  54. INTERNET_FLAG_MUST_CACHE_REQUEST = INTERNET_FLAG_NEED_FILE
  55. SECURITY_INTERNET_MASK = (INTERNET_FLAG_IGNORE_CERT_CN_INVALID | \
  56. INTERNET_FLAG_IGNORE_CERT_DATE_INVALID | \
  57. INTERNET_FLAG_IGNORE_REDIRECT_TO_HTTPS | \
  58. INTERNET_FLAG_IGNORE_REDIRECT_TO_HTTP )
  59. INTERNET_ERROR_MASK_INSERT_CDROM = 0x1
  60. INTERNET_ERROR_MASK_COMBINED_SEC_CERT = 0x2
  61. INTERNET_ERROR_MASK_NEED_MSN_SSPI_PKG = 0X4
  62. INTERNET_ERROR_MASK_LOGIN_FAILURE_DISPLAY_ENTITY_BODY = 0x8
  63. WININET_API_FLAG_ASYNC = 0x00000001
  64. WININET_API_FLAG_SYNC = 0x00000004
  65. WININET_API_FLAG_USE_CONTEXT = 0x00000008
  66. INTERNET_NO_CALLBACK = 0
  67. IDSI_FLAG_KEEP_ALIVE = 0x00000001
  68. IDSI_FLAG_SECURE = 0x00000002
  69. IDSI_FLAG_PROXY = 0x00000004
  70. IDSI_FLAG_TUNNEL = 0x00000008
  71. INTERNET_PER_CONN_FLAGS = 1
  72. INTERNET_PER_CONN_PROXY_SERVER = 2
  73. INTERNET_PER_CONN_PROXY_BYPASS = 3
  74. INTERNET_PER_CONN_AUTOCONFIG_URL = 4
  75. INTERNET_PER_CONN_AUTODISCOVERY_FLAGS = 5
  76. INTERNET_PER_CONN_AUTOCONFIG_SECONDARY_URL = 6
  77. INTERNET_PER_CONN_AUTOCONFIG_RELOAD_DELAY_MINS = 7
  78. INTERNET_PER_CONN_AUTOCONFIG_LAST_DETECT_TIME = 8
  79. INTERNET_PER_CONN_AUTOCONFIG_LAST_DETECT_URL = 9
  80. PROXY_TYPE_DIRECT = 0x00000001
  81. PROXY_TYPE_PROXY = 0x00000002
  82. PROXY_TYPE_AUTO_PROXY_URL = 0x00000004
  83. PROXY_TYPE_AUTO_DETECT = 0x00000008
  84. AUTO_PROXY_FLAG_USER_SET = 0x00000001
  85. AUTO_PROXY_FLAG_ALWAYS_DETECT = 0x00000002
  86. AUTO_PROXY_FLAG_DETECTION_RUN = 0x00000004
  87. AUTO_PROXY_FLAG_MIGRATED = 0x00000008
  88. AUTO_PROXY_FLAG_DONT_CACHE_PROXY_RESULT = 0x00000010
  89. AUTO_PROXY_FLAG_CACHE_INIT_RUN = 0x00000020
  90. AUTO_PROXY_FLAG_DETECTION_SUSPECT = 0x00000040
  91. ISO_FORCE_DISCONNECTED = 0x00000001
  92. INTERNET_RFC1123_FORMAT = 0
  93. INTERNET_RFC1123_BUFSIZE = 30
  94. ICU_ESCAPE = (-2147483648)
  95. ICU_USERNAME = 0x40000000
  96. ICU_NO_ENCODE = 0x20000000
  97. ICU_DECODE = 0x10000000
  98. ICU_NO_META = 0x08000000
  99. ICU_ENCODE_SPACES_ONLY = 0x04000000
  100. ICU_BROWSER_MODE = 0x02000000
  101. ICU_ENCODE_PERCENT = 0x00001000
  102. INTERNET_OPEN_TYPE_PRECONFIG = 0
  103. INTERNET_OPEN_TYPE_DIRECT = 1
  104. INTERNET_OPEN_TYPE_PROXY = 3
  105. INTERNET_OPEN_TYPE_PRECONFIG_WITH_NO_AUTOPROXY = 4
  106. PRE_CONFIG_INTERNET_ACCESS = INTERNET_OPEN_TYPE_PRECONFIG
  107. LOCAL_INTERNET_ACCESS = INTERNET_OPEN_TYPE_DIRECT
  108. CERN_PROXY_INTERNET_ACCESS = INTERNET_OPEN_TYPE_PROXY
  109. INTERNET_SERVICE_FTP = 1
  110. INTERNET_SERVICE_GOPHER = 2
  111. INTERNET_SERVICE_HTTP = 3
  112. IRF_ASYNC = WININET_API_FLAG_ASYNC
  113. IRF_SYNC = WININET_API_FLAG_SYNC
  114. IRF_USE_CONTEXT = WININET_API_FLAG_USE_CONTEXT
  115. IRF_NO_WAIT = 0x00000008
  116. ISO_GLOBAL = 0x00000001
  117. ISO_REGISTRY = 0x00000002
  118. ISO_VALID_FLAGS = (ISO_GLOBAL | ISO_REGISTRY)
  119. INTERNET_OPTION_CALLBACK = 1
  120. INTERNET_OPTION_CONNECT_TIMEOUT = 2
  121. INTERNET_OPTION_CONNECT_RETRIES = 3
  122. INTERNET_OPTION_CONNECT_BACKOFF = 4
  123. INTERNET_OPTION_SEND_TIMEOUT = 5
  124. INTERNET_OPTION_CONTROL_SEND_TIMEOUT = INTERNET_OPTION_SEND_TIMEOUT
  125. INTERNET_OPTION_RECEIVE_TIMEOUT = 6
  126. INTERNET_OPTION_CONTROL_RECEIVE_TIMEOUT = INTERNET_OPTION_RECEIVE_TIMEOUT
  127. INTERNET_OPTION_DATA_SEND_TIMEOUT = 7
  128. INTERNET_OPTION_DATA_RECEIVE_TIMEOUT = 8
  129. INTERNET_OPTION_HANDLE_TYPE = 9
  130. INTERNET_OPTION_LISTEN_TIMEOUT = 11
  131. INTERNET_OPTION_READ_BUFFER_SIZE = 12
  132. INTERNET_OPTION_WRITE_BUFFER_SIZE = 13
  133. INTERNET_OPTION_ASYNC_ID = 15
  134. INTERNET_OPTION_ASYNC_PRIORITY = 16
  135. INTERNET_OPTION_PARENT_HANDLE = 21
  136. INTERNET_OPTION_KEEP_CONNECTION = 22
  137. INTERNET_OPTION_REQUEST_FLAGS = 23
  138. INTERNET_OPTION_EXTENDED_ERROR = 24
  139. INTERNET_OPTION_OFFLINE_MODE = 26
  140. INTERNET_OPTION_CACHE_STREAM_HANDLE = 27
  141. INTERNET_OPTION_USERNAME = 28
  142. INTERNET_OPTION_PASSWORD = 29
  143. INTERNET_OPTION_ASYNC = 30
  144. INTERNET_OPTION_SECURITY_FLAGS = 31
  145. INTERNET_OPTION_SECURITY_CERTIFICATE_STRUCT = 32
  146. INTERNET_OPTION_DATAFILE_NAME = 33
  147. INTERNET_OPTION_URL = 34
  148. INTERNET_OPTION_SECURITY_CERTIFICATE = 35
  149. INTERNET_OPTION_SECURITY_KEY_BITNESS = 36
  150. INTERNET_OPTION_REFRESH = 37
  151. INTERNET_OPTION_PROXY = 38
  152. INTERNET_OPTION_SETTINGS_CHANGED = 39
  153. INTERNET_OPTION_VERSION = 40
  154. INTERNET_OPTION_USER_AGENT = 41
  155. INTERNET_OPTION_END_BROWSER_SESSION = 42
  156. INTERNET_OPTION_PROXY_USERNAME = 43
  157. INTERNET_OPTION_PROXY_PASSWORD = 44
  158. INTERNET_OPTION_CONTEXT_VALUE = 45
  159. INTERNET_OPTION_CONNECT_LIMIT = 46
  160. INTERNET_OPTION_SECURITY_SELECT_CLIENT_CERT = 47
  161. INTERNET_OPTION_POLICY = 48
  162. INTERNET_OPTION_DISCONNECTED_TIMEOUT = 49
  163. INTERNET_OPTION_CONNECTED_STATE = 50
  164. INTERNET_OPTION_IDLE_STATE = 51
  165. INTERNET_OPTION_OFFLINE_SEMANTICS = 52
  166. INTERNET_OPTION_SECONDARY_CACHE_KEY = 53
  167. INTERNET_OPTION_CALLBACK_FILTER = 54
  168. INTERNET_OPTION_CONNECT_TIME = 55
  169. INTERNET_OPTION_SEND_THROUGHPUT = 56
  170. INTERNET_OPTION_RECEIVE_THROUGHPUT = 57
  171. INTERNET_OPTION_REQUEST_PRIORITY = 58
  172. INTERNET_OPTION_HTTP_VERSION = 59
  173. INTERNET_OPTION_RESET_URLCACHE_SESSION = 60
  174. INTERNET_OPTION_ERROR_MASK = 62
  175. INTERNET_OPTION_FROM_CACHE_TIMEOUT = 63
  176. INTERNET_OPTION_BYPASS_EDITED_ENTRY = 64
  177. INTERNET_OPTION_DIAGNOSTIC_SOCKET_INFO = 67
  178. INTERNET_OPTION_CODEPAGE = 68
  179. INTERNET_OPTION_CACHE_TIMESTAMPS = 69
  180. INTERNET_OPTION_DISABLE_AUTODIAL = 70
  181. INTERNET_OPTION_MAX_CONNS_PER_SERVER = 73
  182. INTERNET_OPTION_MAX_CONNS_PER_1_0_SERVER = 74
  183. INTERNET_OPTION_PER_CONNECTION_OPTION = 75
  184. INTERNET_OPTION_DIGEST_AUTH_UNLOAD = 76
  185. INTERNET_OPTION_IGNORE_OFFLINE = 77
  186. INTERNET_OPTION_IDENTITY = 78
  187. INTERNET_OPTION_REMOVE_IDENTITY = 79
  188. INTERNET_OPTION_ALTER_IDENTITY = 80
  189. INTERNET_OPTION_SUPPRESS_BEHAVIOR = 81
  190. INTERNET_OPTION_AUTODIAL_MODE = 82
  191. INTERNET_OPTION_AUTODIAL_CONNECTION = 83
  192. INTERNET_OPTION_CLIENT_CERT_CONTEXT = 84
  193. INTERNET_OPTION_AUTH_FLAGS = 85
  194. INTERNET_OPTION_COOKIES_3RD_PARTY = 86
  195. INTERNET_OPTION_DISABLE_PASSPORT_AUTH = 87
  196. INTERNET_OPTION_SEND_UTF8_SERVERNAME_TO_PROXY = 88
  197. INTERNET_OPTION_EXEMPT_CONNECTION_LIMIT = 89
  198. INTERNET_OPTION_ENABLE_PASSPORT_AUTH = 90
  199. INTERNET_OPTION_HIBERNATE_INACTIVE_WORKER_THREADS = 91
  200. INTERNET_OPTION_ACTIVATE_WORKER_THREADS = 92
  201. INTERNET_OPTION_RESTORE_WORKER_THREAD_DEFAULTS = 93
  202. INTERNET_OPTION_SOCKET_SEND_BUFFER_LENGTH = 94
  203. INTERNET_OPTION_PROXY_SETTINGS_CHANGED = 95
  204. INTERNET_FIRST_OPTION = INTERNET_OPTION_CALLBACK
  205. INTERNET_LAST_OPTION = INTERNET_OPTION_PROXY_SETTINGS_CHANGED
  206. INTERNET_PRIORITY_FOREGROUND = 1000
  207. INTERNET_HANDLE_TYPE_INTERNET = 1
  208. INTERNET_HANDLE_TYPE_CONNECT_FTP = 2
  209. INTERNET_HANDLE_TYPE_CONNECT_GOPHER = 3
  210. INTERNET_HANDLE_TYPE_CONNECT_HTTP = 4
  211. INTERNET_HANDLE_TYPE_FTP_FIND = 5
  212. INTERNET_HANDLE_TYPE_FTP_FIND_HTML = 6
  213. INTERNET_HANDLE_TYPE_FTP_FILE = 7
  214. INTERNET_HANDLE_TYPE_FTP_FILE_HTML = 8
  215. INTERNET_HANDLE_TYPE_GOPHER_FIND = 9
  216. INTERNET_HANDLE_TYPE_GOPHER_FIND_HTML = 10
  217. INTERNET_HANDLE_TYPE_GOPHER_FILE = 11
  218. INTERNET_HANDLE_TYPE_GOPHER_FILE_HTML = 12
  219. INTERNET_HANDLE_TYPE_HTTP_REQUEST = 13
  220. INTERNET_HANDLE_TYPE_FILE_REQUEST = 14
  221. AUTH_FLAG_DISABLE_NEGOTIATE = 0x00000001
  222. AUTH_FLAG_ENABLE_NEGOTIATE = 0x00000002
  223. SECURITY_FLAG_SECURE = 0x00000001
  224. SECURITY_FLAG_STRENGTH_WEAK = 0x10000000
  225. SECURITY_FLAG_STRENGTH_MEDIUM = 0x40000000
  226. SECURITY_FLAG_STRENGTH_STRONG = 0x20000000
  227. SECURITY_FLAG_UNKNOWNBIT = (-2147483648)
  228. SECURITY_FLAG_FORTEZZA = 0x08000000
  229. SECURITY_FLAG_NORMALBITNESS = SECURITY_FLAG_STRENGTH_WEAK
  230. SECURITY_FLAG_SSL = 0x00000002
  231. SECURITY_FLAG_SSL3 = 0x00000004
  232. SECURITY_FLAG_PCT = 0x00000008
  233. SECURITY_FLAG_PCT4 = 0x00000010
  234. SECURITY_FLAG_IETFSSL4 = 0x00000020
  235. SECURITY_FLAG_40BIT = SECURITY_FLAG_STRENGTH_WEAK
  236. SECURITY_FLAG_128BIT = SECURITY_FLAG_STRENGTH_STRONG
  237. SECURITY_FLAG_56BIT = SECURITY_FLAG_STRENGTH_MEDIUM
  238. SECURITY_FLAG_IGNORE_REVOCATION = 0x00000080
  239. SECURITY_FLAG_IGNORE_UNKNOWN_CA = 0x00000100
  240. SECURITY_FLAG_IGNORE_WRONG_USAGE = 0x00000200
  241. SECURITY_FLAG_IGNORE_CERT_CN_INVALID = INTERNET_FLAG_IGNORE_CERT_CN_INVALID
  242. SECURITY_FLAG_IGNORE_CERT_DATE_INVALID = INTERNET_FLAG_IGNORE_CERT_DATE_INVALID
  243. SECURITY_FLAG_IGNORE_REDIRECT_TO_HTTPS = INTERNET_FLAG_IGNORE_REDIRECT_TO_HTTPS
  244. SECURITY_FLAG_IGNORE_REDIRECT_TO_HTTP = INTERNET_FLAG_IGNORE_REDIRECT_TO_HTTP
  245. SECURITY_SET_MASK = (SECURITY_FLAG_IGNORE_REVOCATION |\
  246. SECURITY_FLAG_IGNORE_UNKNOWN_CA |\
  247. SECURITY_FLAG_IGNORE_CERT_CN_INVALID |\
  248. SECURITY_FLAG_IGNORE_CERT_DATE_INVALID |\
  249. SECURITY_FLAG_IGNORE_WRONG_USAGE)
  250. AUTODIAL_MODE_NEVER = 1
  251. AUTODIAL_MODE_ALWAYS = 2
  252. AUTODIAL_MODE_NO_NETWORK_PRESENT = 4
  253. INTERNET_STATUS_RESOLVING_NAME = 10
  254. INTERNET_STATUS_NAME_RESOLVED = 11
  255. INTERNET_STATUS_CONNECTING_TO_SERVER = 20
  256. INTERNET_STATUS_CONNECTED_TO_SERVER = 21
  257. INTERNET_STATUS_SENDING_REQUEST = 30
  258. INTERNET_STATUS_REQUEST_SENT = 31
  259. INTERNET_STATUS_RECEIVING_RESPONSE = 40
  260. INTERNET_STATUS_RESPONSE_RECEIVED = 41
  261. INTERNET_STATUS_CTL_RESPONSE_RECEIVED = 42
  262. INTERNET_STATUS_PREFETCH = 43
  263. INTERNET_STATUS_CLOSING_CONNECTION = 50
  264. INTERNET_STATUS_CONNECTION_CLOSED = 51
  265. INTERNET_STATUS_HANDLE_CREATED = 60
  266. INTERNET_STATUS_HANDLE_CLOSING = 70
  267. INTERNET_STATUS_DETECTING_PROXY = 80
  268. INTERNET_STATUS_REQUEST_COMPLETE = 100
  269. INTERNET_STATUS_REDIRECT = 110
  270. INTERNET_STATUS_INTERMEDIATE_RESPONSE = 120
  271. INTERNET_STATUS_USER_INPUT_REQUIRED = 140
  272. INTERNET_STATUS_STATE_CHANGE = 200
  273. INTERNET_STATUS_COOKIE_SENT = 320
  274. INTERNET_STATUS_COOKIE_RECEIVED = 321
  275. INTERNET_STATUS_PRIVACY_IMPACTED = 324
  276. INTERNET_STATUS_P3P_HEADER = 325
  277. INTERNET_STATUS_P3P_POLICYREF = 326
  278. INTERNET_STATUS_COOKIE_HISTORY = 327
  279. INTERNET_STATE_CONNECTED = 0x00000001
  280. INTERNET_STATE_DISCONNECTED = 0x00000002
  281. INTERNET_STATE_DISCONNECTED_BY_USER = 0x00000010
  282. INTERNET_STATE_IDLE = 0x00000100
  283. INTERNET_STATE_BUSY = 0x00000200
  284. FTP_TRANSFER_TYPE_UNKNOWN = 0x00000000
  285. FTP_TRANSFER_TYPE_ASCII = 0x00000001
  286. FTP_TRANSFER_TYPE_BINARY = 0x00000002
  287. FTP_TRANSFER_TYPE_MASK = (FTP_TRANSFER_TYPE_ASCII | FTP_TRANSFER_TYPE_BINARY)
  288. MAX_GOPHER_DISPLAY_TEXT = 128
  289. MAX_GOPHER_SELECTOR_TEXT = 256
  290. MAX_GOPHER_HOST_NAME = INTERNET_MAX_HOST_NAME_LENGTH
  291. MAX_GOPHER_LOCATOR_LENGTH = (1 \
  292. + MAX_GOPHER_DISPLAY_TEXT \
  293. + 1 \
  294. + MAX_GOPHER_SELECTOR_TEXT \
  295. + 1 \
  296. + MAX_GOPHER_HOST_NAME \
  297. + 1 \
  298. + INTERNET_MAX_PORT_NUMBER_LENGTH \
  299. + 1 \
  300. + 1 \
  301. + 2 \
  302. )
  303. GOPHER_TYPE_TEXT_FILE = 0x00000001
  304. GOPHER_TYPE_DIRECTORY = 0x00000002
  305. GOPHER_TYPE_CSO = 0x00000004
  306. GOPHER_TYPE_ERROR = 0x00000008
  307. GOPHER_TYPE_MAC_BINHEX = 0x00000010
  308. GOPHER_TYPE_DOS_ARCHIVE = 0x00000020
  309. GOPHER_TYPE_UNIX_UUENCODED = 0x00000040
  310. GOPHER_TYPE_INDEX_SERVER = 0x00000080
  311. GOPHER_TYPE_TELNET = 0x00000100
  312. GOPHER_TYPE_BINARY = 0x00000200
  313. GOPHER_TYPE_REDUNDANT = 0x00000400
  314. GOPHER_TYPE_TN3270 = 0x00000800
  315. GOPHER_TYPE_GIF = 0x00001000
  316. GOPHER_TYPE_IMAGE = 0x00002000
  317. GOPHER_TYPE_BITMAP = 0x00004000
  318. GOPHER_TYPE_MOVIE = 0x00008000
  319. GOPHER_TYPE_SOUND = 0x00010000
  320. GOPHER_TYPE_HTML = 0x00020000
  321. GOPHER_TYPE_PDF = 0x00040000
  322. GOPHER_TYPE_CALENDAR = 0x00080000
  323. GOPHER_TYPE_INLINE = 0x00100000
  324. GOPHER_TYPE_UNKNOWN = 0x20000000
  325. GOPHER_TYPE_ASK = 0x40000000
  326. GOPHER_TYPE_GOPHER_PLUS = (-2147483648)
  327. GOPHER_TYPE_FILE_MASK = (GOPHER_TYPE_TEXT_FILE \
  328. | GOPHER_TYPE_MAC_BINHEX \
  329. | GOPHER_TYPE_DOS_ARCHIVE \
  330. | GOPHER_TYPE_UNIX_UUENCODED \
  331. | GOPHER_TYPE_BINARY \
  332. | GOPHER_TYPE_GIF \
  333. | GOPHER_TYPE_IMAGE \
  334. | GOPHER_TYPE_BITMAP \
  335. | GOPHER_TYPE_MOVIE \
  336. | GOPHER_TYPE_SOUND \
  337. | GOPHER_TYPE_HTML \
  338. | GOPHER_TYPE_PDF \
  339. | GOPHER_TYPE_CALENDAR \
  340. | GOPHER_TYPE_INLINE \
  341. )
  342. MAX_GOPHER_CATEGORY_NAME = 128
  343. MAX_GOPHER_ATTRIBUTE_NAME = 128
  344. MIN_GOPHER_ATTRIBUTE_LENGTH = 256
  345. GOPHER_ATTRIBUTE_ID_BASE = (-1412641792)
  346. GOPHER_CATEGORY_ID_ALL = (GOPHER_ATTRIBUTE_ID_BASE + 1)
  347. GOPHER_CATEGORY_ID_INFO = (GOPHER_ATTRIBUTE_ID_BASE + 2)
  348. GOPHER_CATEGORY_ID_ADMIN = (GOPHER_ATTRIBUTE_ID_BASE + 3)
  349. GOPHER_CATEGORY_ID_VIEWS = (GOPHER_ATTRIBUTE_ID_BASE + 4)
  350. GOPHER_CATEGORY_ID_ABSTRACT = (GOPHER_ATTRIBUTE_ID_BASE + 5)
  351. GOPHER_CATEGORY_ID_VERONICA = (GOPHER_ATTRIBUTE_ID_BASE + 6)
  352. GOPHER_CATEGORY_ID_ASK = (GOPHER_ATTRIBUTE_ID_BASE + 7)
  353. GOPHER_CATEGORY_ID_UNKNOWN = (GOPHER_ATTRIBUTE_ID_BASE + 8)
  354. GOPHER_ATTRIBUTE_ID_ALL = (GOPHER_ATTRIBUTE_ID_BASE + 9)
  355. GOPHER_ATTRIBUTE_ID_ADMIN = (GOPHER_ATTRIBUTE_ID_BASE + 10)
  356. GOPHER_ATTRIBUTE_ID_MOD_DATE = (GOPHER_ATTRIBUTE_ID_BASE + 11)
  357. GOPHER_ATTRIBUTE_ID_TTL = (GOPHER_ATTRIBUTE_ID_BASE + 12)
  358. GOPHER_ATTRIBUTE_ID_SCORE = (GOPHER_ATTRIBUTE_ID_BASE + 13)
  359. GOPHER_ATTRIBUTE_ID_RANGE = (GOPHER_ATTRIBUTE_ID_BASE + 14)
  360. GOPHER_ATTRIBUTE_ID_SITE = (GOPHER_ATTRIBUTE_ID_BASE + 15)
  361. GOPHER_ATTRIBUTE_ID_ORG = (GOPHER_ATTRIBUTE_ID_BASE + 16)
  362. GOPHER_ATTRIBUTE_ID_LOCATION = (GOPHER_ATTRIBUTE_ID_BASE + 17)
  363. GOPHER_ATTRIBUTE_ID_GEOG = (GOPHER_ATTRIBUTE_ID_BASE + 18)
  364. GOPHER_ATTRIBUTE_ID_TIMEZONE = (GOPHER_ATTRIBUTE_ID_BASE + 19)
  365. GOPHER_ATTRIBUTE_ID_PROVIDER = (GOPHER_ATTRIBUTE_ID_BASE + 20)
  366. GOPHER_ATTRIBUTE_ID_VERSION = (GOPHER_ATTRIBUTE_ID_BASE + 21)
  367. GOPHER_ATTRIBUTE_ID_ABSTRACT = (GOPHER_ATTRIBUTE_ID_BASE + 22)
  368. GOPHER_ATTRIBUTE_ID_VIEW = (GOPHER_ATTRIBUTE_ID_BASE + 23)
  369. GOPHER_ATTRIBUTE_ID_TREEWALK = (GOPHER_ATTRIBUTE_ID_BASE + 24)
  370. GOPHER_ATTRIBUTE_ID_UNKNOWN = (GOPHER_ATTRIBUTE_ID_BASE + 25)
  371. HTTP_MAJOR_VERSION = 1
  372. HTTP_MINOR_VERSION = 0
  373. HTTP_VERSIONA = "HTTP/1.0"
  374. HTTP_VERSION = HTTP_VERSIONA
  375. HTTP_QUERY_MIME_VERSION = 0
  376. HTTP_QUERY_CONTENT_TYPE = 1
  377. HTTP_QUERY_CONTENT_TRANSFER_ENCODING = 2
  378. HTTP_QUERY_CONTENT_ID = 3
  379. HTTP_QUERY_CONTENT_DESCRIPTION = 4
  380. HTTP_QUERY_CONTENT_LENGTH = 5
  381. HTTP_QUERY_CONTENT_LANGUAGE = 6
  382. HTTP_QUERY_ALLOW = 7
  383. HTTP_QUERY_PUBLIC = 8
  384. HTTP_QUERY_DATE = 9
  385. HTTP_QUERY_EXPIRES = 10
  386. HTTP_QUERY_LAST_MODIFIED = 11
  387. HTTP_QUERY_MESSAGE_ID = 12
  388. HTTP_QUERY_URI = 13
  389. HTTP_QUERY_DERIVED_FROM = 14
  390. HTTP_QUERY_COST = 15
  391. HTTP_QUERY_LINK = 16
  392. HTTP_QUERY_PRAGMA = 17
  393. HTTP_QUERY_VERSION = 18
  394. HTTP_QUERY_STATUS_CODE = 19
  395. HTTP_QUERY_STATUS_TEXT = 20
  396. HTTP_QUERY_RAW_HEADERS = 21
  397. HTTP_QUERY_RAW_HEADERS_CRLF = 22
  398. HTTP_QUERY_CONNECTION = 23
  399. HTTP_QUERY_ACCEPT = 24
  400. HTTP_QUERY_ACCEPT_CHARSET = 25
  401. HTTP_QUERY_ACCEPT_ENCODING = 26
  402. HTTP_QUERY_ACCEPT_LANGUAGE = 27
  403. HTTP_QUERY_AUTHORIZATION = 28
  404. HTTP_QUERY_CONTENT_ENCODING = 29
  405. HTTP_QUERY_FORWARDED = 30
  406. HTTP_QUERY_FROM = 31
  407. HTTP_QUERY_IF_MODIFIED_SINCE = 32
  408. HTTP_QUERY_LOCATION = 33
  409. HTTP_QUERY_ORIG_URI = 34
  410. HTTP_QUERY_REFERER = 35
  411. HTTP_QUERY_RETRY_AFTER = 36
  412. HTTP_QUERY_SERVER = 37
  413. HTTP_QUERY_TITLE = 38
  414. HTTP_QUERY_USER_AGENT = 39
  415. HTTP_QUERY_WWW_AUTHENTICATE = 40
  416. HTTP_QUERY_PROXY_AUTHENTICATE = 41
  417. HTTP_QUERY_ACCEPT_RANGES = 42
  418. HTTP_QUERY_SET_COOKIE = 43
  419. HTTP_QUERY_COOKIE = 44
  420. HTTP_QUERY_REQUEST_METHOD = 45
  421. HTTP_QUERY_REFRESH = 46
  422. HTTP_QUERY_CONTENT_DISPOSITION = 47
  423. HTTP_QUERY_AGE = 48
  424. HTTP_QUERY_CACHE_CONTROL = 49
  425. HTTP_QUERY_CONTENT_BASE = 50
  426. HTTP_QUERY_CONTENT_LOCATION = 51
  427. HTTP_QUERY_CONTENT_MD5 = 52
  428. HTTP_QUERY_CONTENT_RANGE = 53
  429. HTTP_QUERY_ETAG = 54
  430. HTTP_QUERY_HOST = 55
  431. HTTP_QUERY_IF_MATCH = 56
  432. HTTP_QUERY_IF_NONE_MATCH = 57
  433. HTTP_QUERY_IF_RANGE = 58
  434. HTTP_QUERY_IF_UNMODIFIED_SINCE = 59
  435. HTTP_QUERY_MAX_FORWARDS = 60
  436. HTTP_QUERY_PROXY_AUTHORIZATION = 61
  437. HTTP_QUERY_RANGE = 62
  438. HTTP_QUERY_TRANSFER_ENCODING = 63
  439. HTTP_QUERY_UPGRADE = 64
  440. HTTP_QUERY_VARY = 65
  441. HTTP_QUERY_VIA = 66
  442. HTTP_QUERY_WARNING = 67
  443. HTTP_QUERY_EXPECT = 68
  444. HTTP_QUERY_PROXY_CONNECTION = 69
  445. HTTP_QUERY_UNLESS_MODIFIED_SINCE = 70
  446. HTTP_QUERY_ECHO_REQUEST = 71
  447. HTTP_QUERY_ECHO_REPLY = 72
  448. HTTP_QUERY_ECHO_HEADERS = 73
  449. HTTP_QUERY_ECHO_HEADERS_CRLF = 74
  450. HTTP_QUERY_PROXY_SUPPORT = 75
  451. HTTP_QUERY_AUTHENTICATION_INFO = 76
  452. HTTP_QUERY_PASSPORT_URLS = 77
  453. HTTP_QUERY_PASSPORT_CONFIG = 78
  454. HTTP_QUERY_MAX = 78
  455. HTTP_QUERY_CUSTOM = 65535
  456. HTTP_QUERY_FLAG_REQUEST_HEADERS = (-2147483648)
  457. HTTP_QUERY_FLAG_SYSTEMTIME = 0x40000000
  458. HTTP_QUERY_FLAG_NUMBER = 0x20000000
  459. HTTP_QUERY_FLAG_COALESCE = 0x10000000
  460. HTTP_QUERY_MODIFIER_FLAGS_MASK = (HTTP_QUERY_FLAG_REQUEST_HEADERS \
  461. | HTTP_QUERY_FLAG_SYSTEMTIME \
  462. | HTTP_QUERY_FLAG_NUMBER \
  463. | HTTP_QUERY_FLAG_COALESCE \
  464. )
  465. HTTP_QUERY_HEADER_MASK = (~HTTP_QUERY_MODIFIER_FLAGS_MASK)
  466. HTTP_STATUS_CONTINUE = 100
  467. HTTP_STATUS_SWITCH_PROTOCOLS = 101
  468. HTTP_STATUS_OK = 200
  469. HTTP_STATUS_CREATED = 201
  470. HTTP_STATUS_ACCEPTED = 202
  471. HTTP_STATUS_PARTIAL = 203
  472. HTTP_STATUS_NO_CONTENT = 204
  473. HTTP_STATUS_RESET_CONTENT = 205
  474. HTTP_STATUS_PARTIAL_CONTENT = 206
  475. HTTP_STATUS_AMBIGUOUS = 300
  476. HTTP_STATUS_MOVED = 301
  477. HTTP_STATUS_REDIRECT = 302
  478. HTTP_STATUS_REDIRECT_METHOD = 303
  479. HTTP_STATUS_NOT_MODIFIED = 304
  480. HTTP_STATUS_USE_PROXY = 305
  481. HTTP_STATUS_REDIRECT_KEEP_VERB = 307
  482. HTTP_STATUS_BAD_REQUEST = 400
  483. HTTP_STATUS_DENIED = 401
  484. HTTP_STATUS_PAYMENT_REQ = 402
  485. HTTP_STATUS_FORBIDDEN = 403
  486. HTTP_STATUS_NOT_FOUND = 404
  487. HTTP_STATUS_BAD_METHOD = 405
  488. HTTP_STATUS_NONE_ACCEPTABLE = 406
  489. HTTP_STATUS_PROXY_AUTH_REQ = 407
  490. HTTP_STATUS_REQUEST_TIMEOUT = 408
  491. HTTP_STATUS_CONFLICT = 409
  492. HTTP_STATUS_GONE = 410
  493. HTTP_STATUS_LENGTH_REQUIRED = 411
  494. HTTP_STATUS_PRECOND_FAILED = 412
  495. HTTP_STATUS_REQUEST_TOO_LARGE = 413
  496. HTTP_STATUS_URI_TOO_LONG = 414
  497. HTTP_STATUS_UNSUPPORTED_MEDIA = 415
  498. HTTP_STATUS_RETRY_WITH = 449
  499. HTTP_STATUS_SERVER_ERROR = 500
  500. HTTP_STATUS_NOT_SUPPORTED = 501
  501. HTTP_STATUS_BAD_GATEWAY = 502
  502. HTTP_STATUS_SERVICE_UNAVAIL = 503
  503. HTTP_STATUS_GATEWAY_TIMEOUT = 504
  504. HTTP_STATUS_VERSION_NOT_SUP = 505
  505. HTTP_STATUS_FIRST = HTTP_STATUS_CONTINUE
  506. HTTP_STATUS_LAST = HTTP_STATUS_VERSION_NOT_SUP
  507. HTTP_ADDREQ_INDEX_MASK = 0x0000FFFF
  508. HTTP_ADDREQ_FLAGS_MASK = (-65536)
  509. HTTP_ADDREQ_FLAG_ADD_IF_NEW = 0x10000000
  510. HTTP_ADDREQ_FLAG_ADD = 0x20000000
  511. HTTP_ADDREQ_FLAG_COALESCE_WITH_COMMA = 0x40000000
  512. HTTP_ADDREQ_FLAG_COALESCE_WITH_SEMICOLON = 0x01000000
  513. HTTP_ADDREQ_FLAG_COALESCE = HTTP_ADDREQ_FLAG_COALESCE_WITH_COMMA
  514. HTTP_ADDREQ_FLAG_REPLACE = (-2147483648)
  515. HSR_ASYNC = WININET_API_FLAG_ASYNC
  516. HSR_SYNC = WININET_API_FLAG_SYNC
  517. HSR_USE_CONTEXT = WININET_API_FLAG_USE_CONTEXT
  518. HSR_INITIATE = 0x00000008
  519. HSR_DOWNLOAD = 0x00000010
  520. HSR_CHUNKED = 0x00000020
  521. INTERNET_COOKIE_IS_SECURE = 0x01
  522. INTERNET_COOKIE_IS_SESSION = 0x02
  523. INTERNET_COOKIE_THIRD_PARTY = 0x10
  524. INTERNET_COOKIE_PROMPT_REQUIRED = 0x20
  525. INTERNET_COOKIE_EVALUATE_P3P = 0x40
  526. INTERNET_COOKIE_APPLY_P3P = 0x80
  527. INTERNET_COOKIE_P3P_ENABLED = 0x100
  528. INTERNET_COOKIE_IS_RESTRICTED = 0x200
  529. INTERNET_COOKIE_IE6 = 0x400
  530. INTERNET_COOKIE_IS_LEGACY = 0x800
  531. FLAG_ICC_FORCE_CONNECTION = 0x00000001
  532. FLAGS_ERROR_UI_FILTER_FOR_ERRORS = 0x01
  533. FLAGS_ERROR_UI_FLAGS_CHANGE_OPTIONS = 0x02
  534. FLAGS_ERROR_UI_FLAGS_GENERATE_DATA = 0x04
  535. FLAGS_ERROR_UI_FLAGS_NO_UI = 0x08
  536. FLAGS_ERROR_UI_SERIALIZE_DIALOGS = 0x10
  537. INTERNET_ERROR_BASE = 12000
  538. ERROR_INTERNET_OUT_OF_HANDLES = (INTERNET_ERROR_BASE + 1)
  539. ERROR_INTERNET_TIMEOUT = (INTERNET_ERROR_BASE + 2)
  540. ERROR_INTERNET_EXTENDED_ERROR = (INTERNET_ERROR_BASE + 3)
  541. ERROR_INTERNET_INTERNAL_ERROR = (INTERNET_ERROR_BASE + 4)
  542. ERROR_INTERNET_INVALID_URL = (INTERNET_ERROR_BASE + 5)
  543. ERROR_INTERNET_UNRECOGNIZED_SCHEME = (INTERNET_ERROR_BASE + 6)
  544. ERROR_INTERNET_NAME_NOT_RESOLVED = (INTERNET_ERROR_BASE + 7)
  545. ERROR_INTERNET_PROTOCOL_NOT_FOUND = (INTERNET_ERROR_BASE + 8)
  546. ERROR_INTERNET_INVALID_OPTION = (INTERNET_ERROR_BASE + 9)
  547. ERROR_INTERNET_BAD_OPTION_LENGTH = (INTERNET_ERROR_BASE + 10)
  548. ERROR_INTERNET_OPTION_NOT_SETTABLE = (INTERNET_ERROR_BASE + 11)
  549. ERROR_INTERNET_SHUTDOWN = (INTERNET_ERROR_BASE + 12)
  550. ERROR_INTERNET_INCORRECT_USER_NAME = (INTERNET_ERROR_BASE + 13)
  551. ERROR_INTERNET_INCORRECT_PASSWORD = (INTERNET_ERROR_BASE + 14)
  552. ERROR_INTERNET_LOGIN_FAILURE = (INTERNET_ERROR_BASE + 15)
  553. ERROR_INTERNET_INVALID_OPERATION = (INTERNET_ERROR_BASE + 16)
  554. ERROR_INTERNET_OPERATION_CANCELLED = (INTERNET_ERROR_BASE + 17)
  555. ERROR_INTERNET_INCORRECT_HANDLE_TYPE = (INTERNET_ERROR_BASE + 18)
  556. ERROR_INTERNET_INCORRECT_HANDLE_STATE = (INTERNET_ERROR_BASE + 19)
  557. ERROR_INTERNET_NOT_PROXY_REQUEST = (INTERNET_ERROR_BASE + 20)
  558. ERROR_INTERNET_REGISTRY_VALUE_NOT_FOUND = (INTERNET_ERROR_BASE + 21)
  559. ERROR_INTERNET_BAD_REGISTRY_PARAMETER = (INTERNET_ERROR_BASE + 22)
  560. ERROR_INTERNET_NO_DIRECT_ACCESS = (INTERNET_ERROR_BASE + 23)
  561. ERROR_INTERNET_NO_CONTEXT = (INTERNET_ERROR_BASE + 24)
  562. ERROR_INTERNET_NO_CALLBACK = (INTERNET_ERROR_BASE + 25)
  563. ERROR_INTERNET_REQUEST_PENDING = (INTERNET_ERROR_BASE + 26)
  564. ERROR_INTERNET_INCORRECT_FORMAT = (INTERNET_ERROR_BASE + 27)
  565. ERROR_INTERNET_ITEM_NOT_FOUND = (INTERNET_ERROR_BASE + 28)
  566. ERROR_INTERNET_CANNOT_CONNECT = (INTERNET_ERROR_BASE + 29)
  567. ERROR_INTERNET_CONNECTION_ABORTED = (INTERNET_ERROR_BASE + 30)
  568. ERROR_INTERNET_CONNECTION_RESET = (INTERNET_ERROR_BASE + 31)
  569. ERROR_INTERNET_FORCE_RETRY = (INTERNET_ERROR_BASE + 32)
  570. ERROR_INTERNET_INVALID_PROXY_REQUEST = (INTERNET_ERROR_BASE + 33)
  571. ERROR_INTERNET_NEED_UI = (INTERNET_ERROR_BASE + 34)
  572. ERROR_INTERNET_HANDLE_EXISTS = (INTERNET_ERROR_BASE + 36)
  573. ERROR_INTERNET_SEC_CERT_DATE_INVALID = (INTERNET_ERROR_BASE + 37)
  574. ERROR_INTERNET_SEC_CERT_CN_INVALID = (INTERNET_ERROR_BASE + 38)
  575. ERROR_INTERNET_HTTP_TO_HTTPS_ON_REDIR = (INTERNET_ERROR_BASE + 39)
  576. ERROR_INTERNET_HTTPS_TO_HTTP_ON_REDIR = (INTERNET_ERROR_BASE + 40)
  577. ERROR_INTERNET_MIXED_SECURITY = (INTERNET_ERROR_BASE + 41)
  578. ERROR_INTERNET_CHG_POST_IS_NON_SECURE = (INTERNET_ERROR_BASE + 42)
  579. ERROR_INTERNET_POST_IS_NON_SECURE = (INTERNET_ERROR_BASE + 43)
  580. ERROR_INTERNET_CLIENT_AUTH_CERT_NEEDED = (INTERNET_ERROR_BASE + 44)
  581. ERROR_INTERNET_INVALID_CA = (INTERNET_ERROR_BASE + 45)
  582. ERROR_INTERNET_CLIENT_AUTH_NOT_SETUP = (INTERNET_ERROR_BASE + 46)
  583. ERROR_INTERNET_ASYNC_THREAD_FAILED = (INTERNET_ERROR_BASE + 47)
  584. ERROR_INTERNET_REDIRECT_SCHEME_CHANGE = (INTERNET_ERROR_BASE + 48)
  585. ERROR_INTERNET_DIALOG_PENDING = (INTERNET_ERROR_BASE + 49)
  586. ERROR_INTERNET_RETRY_DIALOG = (INTERNET_ERROR_BASE + 50)
  587. ERROR_INTERNET_HTTPS_HTTP_SUBMIT_REDIR = (INTERNET_ERROR_BASE + 52)
  588. ERROR_INTERNET_INSERT_CDROM = (INTERNET_ERROR_BASE + 53)
  589. ERROR_INTERNET_FORTEZZA_LOGIN_NEEDED = (INTERNET_ERROR_BASE + 54)
  590. ERROR_INTERNET_SEC_CERT_ERRORS = (INTERNET_ERROR_BASE + 55)
  591. ERROR_INTERNET_SEC_CERT_NO_REV = (INTERNET_ERROR_BASE + 56)
  592. ERROR_INTERNET_SEC_CERT_REV_FAILED = (INTERNET_ERROR_BASE + 57)
  593. ERROR_FTP_TRANSFER_IN_PROGRESS = (INTERNET_ERROR_BASE + 110)
  594. ERROR_FTP_DROPPED = (INTERNET_ERROR_BASE + 111)
  595. ERROR_FTP_NO_PASSIVE_MODE = (INTERNET_ERROR_BASE + 112)
  596. ERROR_GOPHER_PROTOCOL_ERROR = (INTERNET_ERROR_BASE + 130)
  597. ERROR_GOPHER_NOT_FILE = (INTERNET_ERROR_BASE + 131)
  598. ERROR_GOPHER_DATA_ERROR = (INTERNET_ERROR_BASE + 132)
  599. ERROR_GOPHER_END_OF_DATA = (INTERNET_ERROR_BASE + 133)
  600. ERROR_GOPHER_INVALID_LOCATOR = (INTERNET_ERROR_BASE + 134)
  601. ERROR_GOPHER_INCORRECT_LOCATOR_TYPE = (INTERNET_ERROR_BASE + 135)
  602. ERROR_GOPHER_NOT_GOPHER_PLUS = (INTERNET_ERROR_BASE + 136)
  603. ERROR_GOPHER_ATTRIBUTE_NOT_FOUND = (INTERNET_ERROR_BASE + 137)
  604. ERROR_GOPHER_UNKNOWN_LOCATOR = (INTERNET_ERROR_BASE + 138)
  605. ERROR_HTTP_HEADER_NOT_FOUND = (INTERNET_ERROR_BASE + 150)
  606. ERROR_HTTP_DOWNLEVEL_SERVER = (INTERNET_ERROR_BASE + 151)
  607. ERROR_HTTP_INVALID_SERVER_RESPONSE = (INTERNET_ERROR_BASE + 152)
  608. ERROR_HTTP_INVALID_HEADER = (INTERNET_ERROR_BASE + 153)
  609. ERROR_HTTP_INVALID_QUERY_REQUEST = (INTERNET_ERROR_BASE + 154)
  610. ERROR_HTTP_HEADER_ALREADY_EXISTS = (INTERNET_ERROR_BASE + 155)
  611. ERROR_HTTP_REDIRECT_FAILED = (INTERNET_ERROR_BASE + 156)
  612. ERROR_HTTP_NOT_REDIRECTED = (INTERNET_ERROR_BASE + 160)
  613. ERROR_HTTP_COOKIE_NEEDS_CONFIRMATION = (INTERNET_ERROR_BASE + 161)
  614. ERROR_HTTP_COOKIE_DECLINED = (INTERNET_ERROR_BASE + 162)
  615. ERROR_HTTP_REDIRECT_NEEDS_CONFIRMATION = (INTERNET_ERROR_BASE + 168)
  616. ERROR_INTERNET_SECURITY_CHANNEL_ERROR = (INTERNET_ERROR_BASE + 157)
  617. ERROR_INTERNET_UNABLE_TO_CACHE_FILE = (INTERNET_ERROR_BASE + 158)
  618. ERROR_INTERNET_TCPIP_NOT_INSTALLED = (INTERNET_ERROR_BASE + 159)
  619. ERROR_INTERNET_DISCONNECTED = (INTERNET_ERROR_BASE + 163)
  620. ERROR_INTERNET_SERVER_UNREACHABLE = (INTERNET_ERROR_BASE + 164)
  621. ERROR_INTERNET_PROXY_SERVER_UNREACHABLE = (INTERNET_ERROR_BASE + 165)
  622. ERROR_INTERNET_BAD_AUTO_PROXY_SCRIPT = (INTERNET_ERROR_BASE + 166)
  623. ERROR_INTERNET_UNABLE_TO_DOWNLOAD_SCRIPT = (INTERNET_ERROR_BASE + 167)
  624. ERROR_INTERNET_SEC_INVALID_CERT = (INTERNET_ERROR_BASE + 169)
  625. ERROR_INTERNET_SEC_CERT_REVOKED = (INTERNET_ERROR_BASE + 170)
  626. ERROR_INTERNET_FAILED_DUETOSECURITYCHECK = (INTERNET_ERROR_BASE + 171)
  627. ERROR_INTERNET_NOT_INITIALIZED = (INTERNET_ERROR_BASE + 172)
  628. ERROR_INTERNET_NEED_MSN_SSPI_PKG = (INTERNET_ERROR_BASE + 173)
  629. ERROR_INTERNET_LOGIN_FAILURE_DISPLAY_ENTITY_BODY = (INTERNET_ERROR_BASE + 174)
  630. INTERNET_ERROR_LAST = ERROR_INTERNET_LOGIN_FAILURE_DISPLAY_ENTITY_BODY
  631. NORMAL_CACHE_ENTRY = 0x00000001
  632. STICKY_CACHE_ENTRY = 0x00000004
  633. EDITED_CACHE_ENTRY = 0x00000008
  634. TRACK_OFFLINE_CACHE_ENTRY = 0x00000010
  635. TRACK_ONLINE_CACHE_ENTRY = 0x00000020
  636. SPARSE_CACHE_ENTRY = 0x00010000
  637. COOKIE_CACHE_ENTRY = 0x00100000
  638. URLHISTORY_CACHE_ENTRY = 0x00200000
  639. URLCACHE_FIND_DEFAULT_FILTER = NORMAL_CACHE_ENTRY \
  640. | COOKIE_CACHE_ENTRY \
  641. | URLHISTORY_CACHE_ENTRY \
  642. | TRACK_OFFLINE_CACHE_ENTRY \
  643. | TRACK_ONLINE_CACHE_ENTRY \
  644. | STICKY_CACHE_ENTRY
  645. CACHEGROUP_ATTRIBUTE_GET_ALL = (-1)
  646. CACHEGROUP_ATTRIBUTE_BASIC = 0x00000001
  647. CACHEGROUP_ATTRIBUTE_FLAG = 0x00000002
  648. CACHEGROUP_ATTRIBUTE_TYPE = 0x00000004
  649. CACHEGROUP_ATTRIBUTE_QUOTA = 0x00000008
  650. CACHEGROUP_ATTRIBUTE_GROUPNAME = 0x00000010
  651. CACHEGROUP_ATTRIBUTE_STORAGE = 0x00000020
  652. CACHEGROUP_FLAG_NONPURGEABLE = 0x00000001
  653. CACHEGROUP_FLAG_GIDONLY = 0x00000004
  654. CACHEGROUP_FLAG_FLUSHURL_ONDELETE = 0x00000002
  655. CACHEGROUP_SEARCH_ALL = 0x00000000
  656. CACHEGROUP_SEARCH_BYURL = 0x00000001
  657. CACHEGROUP_TYPE_INVALID = 0x00000001
  658. CACHEGROUP_READWRITE_MASK = \
  659. CACHEGROUP_ATTRIBUTE_TYPE \
  660. | CACHEGROUP_ATTRIBUTE_QUOTA \
  661. | CACHEGROUP_ATTRIBUTE_GROUPNAME \
  662. | CACHEGROUP_ATTRIBUTE_STORAGE
  663. GROUPNAME_MAX_LENGTH = 120
  664. GROUP_OWNER_STORAGE_SIZE = 4
  665. CACHE_ENTRY_ATTRIBUTE_FC = 0x00000004
  666. CACHE_ENTRY_HITRATE_FC = 0x00000010
  667. CACHE_ENTRY_MODTIME_FC = 0x00000040
  668. CACHE_ENTRY_EXPTIME_FC = 0x00000080
  669. CACHE_ENTRY_ACCTIME_FC = 0x00000100
  670. CACHE_ENTRY_SYNCTIME_FC = 0x00000200
  671. CACHE_ENTRY_HEADERINFO_FC = 0x00000400
  672. CACHE_ENTRY_EXEMPT_DELTA_FC = 0x00000800
  673. INTERNET_CACHE_GROUP_ADD = 0
  674. INTERNET_CACHE_GROUP_REMOVE = 1
  675. INTERNET_DIAL_FORCE_PROMPT = 0x2000
  676. INTERNET_DIAL_SHOW_OFFLINE = 0x4000
  677. INTERNET_DIAL_UNATTENDED = 0x8000
  678. INTERENT_GOONLINE_REFRESH = 0x00000001
  679. INTERENT_GOONLINE_MASK = 0x00000001
  680. INTERNET_AUTODIAL_FORCE_ONLINE = 1
  681. INTERNET_AUTODIAL_FORCE_UNATTENDED = 2
  682. INTERNET_AUTODIAL_FAILIFSECURITYCHECK = 4
  683. INTERNET_AUTODIAL_OVERRIDE_NET_PRESENT = 8
  684. INTERNET_AUTODIAL_FLAGS_MASK = (INTERNET_AUTODIAL_FORCE_ONLINE | INTERNET_AUTODIAL_FORCE_UNATTENDED | INTERNET_AUTODIAL_FAILIFSECURITYCHECK | INTERNET_AUTODIAL_OVERRIDE_NET_PRESENT)
  685. PROXY_AUTO_DETECT_TYPE_DHCP = 1
  686. PROXY_AUTO_DETECT_TYPE_DNS_A = 2
  687. INTERNET_CONNECTION_MODEM = 0x01
  688. INTERNET_CONNECTION_LAN = 0x02
  689. INTERNET_CONNECTION_PROXY = 0x04
  690. INTERNET_CONNECTION_MODEM_BUSY = 0x08
  691. INTERNET_RAS_INSTALLED = 0x10
  692. INTERNET_CONNECTION_OFFLINE = 0x20
  693. INTERNET_CONNECTION_CONFIGURED = 0x40
  694. INTERNET_CUSTOMDIAL_CONNECT = 0
  695. INTERNET_CUSTOMDIAL_UNATTENDED = 1
  696. INTERNET_CUSTOMDIAL_DISCONNECT = 2
  697. INTERNET_CUSTOMDIAL_SHOWOFFLINE = 4
  698. INTERNET_CUSTOMDIAL_SAFE_FOR_UNATTENDED = 1
  699. INTERNET_CUSTOMDIAL_WILL_SUPPLY_STATE = 2
  700. INTERNET_CUSTOMDIAL_CAN_HANGUP = 4
  701. INTERNET_DIALSTATE_DISCONNECTED = 1
  702. INTERNET_IDENTITY_FLAG_PRIVATE_CACHE = 0x01
  703. INTERNET_IDENTITY_FLAG_SHARED_CACHE = 0x02
  704. INTERNET_IDENTITY_FLAG_CLEAR_DATA = 0x04
  705. INTERNET_IDENTITY_FLAG_CLEAR_COOKIES = 0x08
  706. INTERNET_IDENTITY_FLAG_CLEAR_HISTORY = 0x10
  707. INTERNET_IDENTITY_FLAG_CLEAR_CONTENT = 0x20
  708. INTERNET_SUPPRESS_RESET_ALL = 0x00
  709. INTERNET_SUPPRESS_COOKIE_POLICY = 0x01
  710. INTERNET_SUPPRESS_COOKIE_POLICY_RESET = 0x02
  711. PRIVACY_TEMPLATE_NO_COOKIES = 0
  712. PRIVACY_TEMPLATE_HIGH = 1
  713. PRIVACY_TEMPLATE_MEDIUM_HIGH = 2
  714. PRIVACY_TEMPLATE_MEDIUM = 3
  715. PRIVACY_TEMPLATE_MEDIUM_LOW = 4
  716. PRIVACY_TEMPLATE_LOW = 5
  717. PRIVACY_TEMPLATE_CUSTOM = 100
  718. PRIVACY_TEMPLATE_ADVANCED = 101
  719. PRIVACY_TEMPLATE_MAX = PRIVACY_TEMPLATE_LOW
  720. PRIVACY_TYPE_FIRST_PARTY = 0
  721. PRIVACY_TYPE_THIRD_PARTY = 1
  722. # Generated by h2py from winhttp.h
  723. INTERNET_DEFAULT_PORT = 0
  724. INTERNET_DEFAULT_HTTP_PORT = 80
  725. INTERNET_DEFAULT_HTTPS_PORT = 443
  726. WINHTTP_FLAG_ASYNC = 0x10000000
  727. WINHTTP_FLAG_SECURE = 0x00800000
  728. WINHTTP_FLAG_ESCAPE_PERCENT = 0x00000004
  729. WINHTTP_FLAG_NULL_CODEPAGE = 0x00000008
  730. WINHTTP_FLAG_BYPASS_PROXY_CACHE = 0x00000100
  731. WINHTTP_FLAG_REFRESH = WINHTTP_FLAG_BYPASS_PROXY_CACHE
  732. WINHTTP_FLAG_ESCAPE_DISABLE = 0x00000040
  733. WINHTTP_FLAG_ESCAPE_DISABLE_QUERY = 0x00000080
  734. SECURITY_FLAG_IGNORE_UNKNOWN_CA = 0x00000100
  735. SECURITY_FLAG_IGNORE_CERT_DATE_INVALID = 0x00002000
  736. SECURITY_FLAG_IGNORE_CERT_CN_INVALID = 0x00001000
  737. SECURITY_FLAG_IGNORE_CERT_WRONG_USAGE = 0x00000200
  738. INTERNET_SCHEME_HTTP = (1)
  739. INTERNET_SCHEME_HTTPS = (2)
  740. WINHTTP_AUTOPROXY_AUTO_DETECT = 0x00000001
  741. WINHTTP_AUTOPROXY_CONFIG_URL = 0x00000002
  742. WINHTTP_AUTOPROXY_RUN_INPROCESS = 0x00010000
  743. WINHTTP_AUTOPROXY_RUN_OUTPROCESS_ONLY = 0x00020000
  744. WINHTTP_AUTO_DETECT_TYPE_DHCP = 0x00000001
  745. WINHTTP_AUTO_DETECT_TYPE_DNS_A = 0x00000002
  746. WINHTTP_TIME_FORMAT_BUFSIZE = 62
  747. ICU_NO_ENCODE = 0x20000000
  748. ICU_DECODE = 0x10000000
  749. ICU_NO_META = 0x08000000
  750. ICU_ENCODE_SPACES_ONLY = 0x04000000
  751. ICU_BROWSER_MODE = 0x02000000
  752. ICU_ENCODE_PERCENT = 0x00001000
  753. ICU_ESCAPE = (-2147483648)
  754. ICU_ESCAPE_AUTHORITY = 0x00002000
  755. ICU_REJECT_USERPWD = 0x00004000
  756. WINHTTP_ACCESS_TYPE_DEFAULT_PROXY = 0
  757. WINHTTP_ACCESS_TYPE_NO_PROXY = 1
  758. WINHTTP_ACCESS_TYPE_NAMED_PROXY = 3
  759. WINHTTP_OPTION_CALLBACK = 1
  760. WINHTTP_OPTION_RESOLVE_TIMEOUT = 2
  761. WINHTTP_OPTION_CONNECT_TIMEOUT = 3
  762. WINHTTP_OPTION_CONNECT_RETRIES = 4
  763. WINHTTP_OPTION_SEND_TIMEOUT = 5
  764. WINHTTP_OPTION_RECEIVE_TIMEOUT = 6
  765. WINHTTP_OPTION_RECEIVE_RESPONSE_TIMEOUT = 7
  766. WINHTTP_OPTION_HANDLE_TYPE = 9
  767. WINHTTP_OPTION_READ_BUFFER_SIZE = 12
  768. WINHTTP_OPTION_WRITE_BUFFER_SIZE = 13
  769. WINHTTP_OPTION_PARENT_HANDLE = 21
  770. WINHTTP_OPTION_EXTENDED_ERROR = 24
  771. WINHTTP_OPTION_SECURITY_FLAGS = 31
  772. WINHTTP_OPTION_SECURITY_CERTIFICATE_STRUCT = 32
  773. WINHTTP_OPTION_URL = 34
  774. WINHTTP_OPTION_SECURITY_KEY_BITNESS = 36
  775. WINHTTP_OPTION_PROXY = 38
  776. WINHTTP_OPTION_USER_AGENT = 41
  777. WINHTTP_OPTION_CONTEXT_VALUE = 45
  778. WINHTTP_OPTION_CLIENT_CERT_CONTEXT = 47
  779. WINHTTP_OPTION_REQUEST_PRIORITY = 58
  780. WINHTTP_OPTION_HTTP_VERSION = 59
  781. WINHTTP_OPTION_DISABLE_FEATURE = 63
  782. WINHTTP_OPTION_CODEPAGE = 68
  783. WINHTTP_OPTION_MAX_CONNS_PER_SERVER = 73
  784. WINHTTP_OPTION_MAX_CONNS_PER_1_0_SERVER = 74
  785. WINHTTP_OPTION_AUTOLOGON_POLICY = 77
  786. WINHTTP_OPTION_SERVER_CERT_CONTEXT = 78
  787. WINHTTP_OPTION_ENABLE_FEATURE = 79
  788. WINHTTP_OPTION_WORKER_THREAD_COUNT = 80
  789. WINHTTP_OPTION_PASSPORT_COBRANDING_TEXT = 81
  790. WINHTTP_OPTION_PASSPORT_COBRANDING_URL = 82
  791. WINHTTP_OPTION_CONFIGURE_PASSPORT_AUTH = 83
  792. WINHTTP_OPTION_SECURE_PROTOCOLS = 84
  793. WINHTTP_OPTION_ENABLETRACING = 85
  794. WINHTTP_OPTION_PASSPORT_SIGN_OUT = 86
  795. WINHTTP_OPTION_PASSPORT_RETURN_URL = 87
  796. WINHTTP_OPTION_REDIRECT_POLICY = 88
  797. WINHTTP_OPTION_MAX_HTTP_AUTOMATIC_REDIRECTS = 89
  798. WINHTTP_OPTION_MAX_HTTP_STATUS_CONTINUE = 90
  799. WINHTTP_OPTION_MAX_RESPONSE_HEADER_SIZE = 91
  800. WINHTTP_OPTION_MAX_RESPONSE_DRAIN_SIZE = 92
  801. WINHTTP_OPTION_CONNECTION_INFO = 93
  802. WINHTTP_OPTION_CLIENT_CERT_ISSUER_LIST = 94
  803. WINHTTP_OPTION_SPN = 96
  804. WINHTTP_OPTION_GLOBAL_PROXY_CREDS = 97
  805. WINHTTP_OPTION_GLOBAL_SERVER_CREDS = 98
  806. WINHTTP_OPTION_UNLOAD_NOTIFY_EVENT = 99
  807. WINHTTP_OPTION_REJECT_USERPWD_IN_URL = 100
  808. WINHTTP_OPTION_USE_GLOBAL_SERVER_CREDENTIALS = 101
  809. WINHTTP_LAST_OPTION = WINHTTP_OPTION_USE_GLOBAL_SERVER_CREDENTIALS
  810. WINHTTP_OPTION_USERNAME = 0x1000
  811. WINHTTP_OPTION_PASSWORD = 0x1001
  812. WINHTTP_OPTION_PROXY_USERNAME = 0x1002
  813. WINHTTP_OPTION_PROXY_PASSWORD = 0x1003
  814. WINHTTP_CONNS_PER_SERVER_UNLIMITED = (-1)
  815. WINHTTP_AUTOLOGON_SECURITY_LEVEL_MEDIUM = 0
  816. WINHTTP_AUTOLOGON_SECURITY_LEVEL_LOW = 1
  817. WINHTTP_AUTOLOGON_SECURITY_LEVEL_HIGH = 2
  818. WINHTTP_AUTOLOGON_SECURITY_LEVEL_DEFAULT = WINHTTP_AUTOLOGON_SECURITY_LEVEL_MEDIUM
  819. WINHTTP_OPTION_REDIRECT_POLICY_NEVER = 0
  820. WINHTTP_OPTION_REDIRECT_POLICY_DISALLOW_HTTPS_TO_HTTP = 1
  821. WINHTTP_OPTION_REDIRECT_POLICY_ALWAYS = 2
  822. WINHTTP_OPTION_REDIRECT_POLICY_LAST = WINHTTP_OPTION_REDIRECT_POLICY_ALWAYS
  823. WINHTTP_OPTION_REDIRECT_POLICY_DEFAULT = WINHTTP_OPTION_REDIRECT_POLICY_DISALLOW_HTTPS_TO_HTTP
  824. WINHTTP_DISABLE_PASSPORT_AUTH = 0x00000000
  825. WINHTTP_ENABLE_PASSPORT_AUTH = 0x10000000
  826. WINHTTP_DISABLE_PASSPORT_KEYRING = 0x20000000
  827. WINHTTP_ENABLE_PASSPORT_KEYRING = 0x40000000
  828. WINHTTP_DISABLE_COOKIES = 0x00000001
  829. WINHTTP_DISABLE_REDIRECTS = 0x00000002
  830. WINHTTP_DISABLE_AUTHENTICATION = 0x00000004
  831. WINHTTP_DISABLE_KEEP_ALIVE = 0x00000008
  832. WINHTTP_ENABLE_SSL_REVOCATION = 0x00000001
  833. WINHTTP_ENABLE_SSL_REVERT_IMPERSONATION = 0x00000002
  834. WINHTTP_DISABLE_SPN_SERVER_PORT = 0x00000000
  835. WINHTTP_ENABLE_SPN_SERVER_PORT = 0x00000001
  836. WINHTTP_OPTION_SPN_MASK = WINHTTP_ENABLE_SPN_SERVER_PORT
  837. WINHTTP_HANDLE_TYPE_SESSION = 1
  838. WINHTTP_HANDLE_TYPE_CONNECT = 2
  839. WINHTTP_HANDLE_TYPE_REQUEST = 3
  840. WINHTTP_AUTH_SCHEME_BASIC = 0x00000001
  841. WINHTTP_AUTH_SCHEME_NTLM = 0x00000002
  842. WINHTTP_AUTH_SCHEME_PASSPORT = 0x00000004
  843. WINHTTP_AUTH_SCHEME_DIGEST = 0x00000008
  844. WINHTTP_AUTH_SCHEME_NEGOTIATE = 0x00000010
  845. WINHTTP_AUTH_TARGET_SERVER = 0x00000000
  846. WINHTTP_AUTH_TARGET_PROXY = 0x00000001
  847. SECURITY_FLAG_SECURE = 0x00000001
  848. SECURITY_FLAG_STRENGTH_WEAK = 0x10000000
  849. SECURITY_FLAG_STRENGTH_MEDIUM = 0x40000000
  850. SECURITY_FLAG_STRENGTH_STRONG = 0x20000000
  851. WINHTTP_CALLBACK_STATUS_FLAG_CERT_REV_FAILED = 0x00000001
  852. WINHTTP_CALLBACK_STATUS_FLAG_INVALID_CERT = 0x00000002
  853. WINHTTP_CALLBACK_STATUS_FLAG_CERT_REVOKED = 0x00000004
  854. WINHTTP_CALLBACK_STATUS_FLAG_INVALID_CA = 0x00000008
  855. WINHTTP_CALLBACK_STATUS_FLAG_CERT_CN_INVALID = 0x00000010
  856. WINHTTP_CALLBACK_STATUS_FLAG_CERT_DATE_INVALID = 0x00000020
  857. WINHTTP_CALLBACK_STATUS_FLAG_CERT_WRONG_USAGE = 0x00000040
  858. WINHTTP_CALLBACK_STATUS_FLAG_SECURITY_CHANNEL_ERROR = (-2147483648)
  859. WINHTTP_FLAG_SECURE_PROTOCOL_SSL2 = 0x00000008
  860. WINHTTP_FLAG_SECURE_PROTOCOL_SSL3 = 0x00000020
  861. WINHTTP_FLAG_SECURE_PROTOCOL_TLS1 = 0x00000080
  862. WINHTTP_FLAG_SECURE_PROTOCOL_ALL = (WINHTTP_FLAG_SECURE_PROTOCOL_SSL2 | \
  863. WINHTTP_FLAG_SECURE_PROTOCOL_SSL3 | \
  864. WINHTTP_FLAG_SECURE_PROTOCOL_TLS1)
  865. WINHTTP_CALLBACK_STATUS_RESOLVING_NAME = 0x00000001
  866. WINHTTP_CALLBACK_STATUS_NAME_RESOLVED = 0x00000002
  867. WINHTTP_CALLBACK_STATUS_CONNECTING_TO_SERVER = 0x00000004
  868. WINHTTP_CALLBACK_STATUS_CONNECTED_TO_SERVER = 0x00000008
  869. WINHTTP_CALLBACK_STATUS_SENDING_REQUEST = 0x00000010
  870. WINHTTP_CALLBACK_STATUS_REQUEST_SENT = 0x00000020
  871. WINHTTP_CALLBACK_STATUS_RECEIVING_RESPONSE = 0x00000040
  872. WINHTTP_CALLBACK_STATUS_RESPONSE_RECEIVED = 0x00000080
  873. WINHTTP_CALLBACK_STATUS_CLOSING_CONNECTION = 0x00000100
  874. WINHTTP_CALLBACK_STATUS_CONNECTION_CLOSED = 0x00000200
  875. WINHTTP_CALLBACK_STATUS_HANDLE_CREATED = 0x00000400
  876. WINHTTP_CALLBACK_STATUS_HANDLE_CLOSING = 0x00000800
  877. WINHTTP_CALLBACK_STATUS_DETECTING_PROXY = 0x00001000
  878. WINHTTP_CALLBACK_STATUS_REDIRECT = 0x00004000
  879. WINHTTP_CALLBACK_STATUS_INTERMEDIATE_RESPONSE = 0x00008000
  880. WINHTTP_CALLBACK_STATUS_SECURE_FAILURE = 0x00010000
  881. WINHTTP_CALLBACK_STATUS_HEADERS_AVAILABLE = 0x00020000
  882. WINHTTP_CALLBACK_STATUS_DATA_AVAILABLE = 0x00040000
  883. WINHTTP_CALLBACK_STATUS_READ_COMPLETE = 0x00080000
  884. WINHTTP_CALLBACK_STATUS_WRITE_COMPLETE = 0x00100000
  885. WINHTTP_CALLBACK_STATUS_REQUEST_ERROR = 0x00200000
  886. WINHTTP_CALLBACK_STATUS_SENDREQUEST_COMPLETE = 0x00400000
  887. API_RECEIVE_RESPONSE = (1)
  888. API_QUERY_DATA_AVAILABLE = (2)
  889. API_READ_DATA = (3)
  890. API_WRITE_DATA = (4)
  891. API_SEND_REQUEST = (5)
  892. WINHTTP_CALLBACK_FLAG_RESOLVE_NAME = (WINHTTP_CALLBACK_STATUS_RESOLVING_NAME | WINHTTP_CALLBACK_STATUS_NAME_RESOLVED)
  893. WINHTTP_CALLBACK_FLAG_CONNECT_TO_SERVER = (WINHTTP_CALLBACK_STATUS_CONNECTING_TO_SERVER | WINHTTP_CALLBACK_STATUS_CONNECTED_TO_SERVER)
  894. WINHTTP_CALLBACK_FLAG_SEND_REQUEST = (WINHTTP_CALLBACK_STATUS_SENDING_REQUEST | WINHTTP_CALLBACK_STATUS_REQUEST_SENT)
  895. WINHTTP_CALLBACK_FLAG_RECEIVE_RESPONSE = (WINHTTP_CALLBACK_STATUS_RECEIVING_RESPONSE | WINHTTP_CALLBACK_STATUS_RESPONSE_RECEIVED)
  896. WINHTTP_CALLBACK_FLAG_CLOSE_CONNECTION = (WINHTTP_CALLBACK_STATUS_CLOSING_CONNECTION | WINHTTP_CALLBACK_STATUS_CONNECTION_CLOSED)
  897. WINHTTP_CALLBACK_FLAG_HANDLES = (WINHTTP_CALLBACK_STATUS_HANDLE_CREATED | WINHTTP_CALLBACK_STATUS_HANDLE_CLOSING)
  898. WINHTTP_CALLBACK_FLAG_DETECTING_PROXY = WINHTTP_CALLBACK_STATUS_DETECTING_PROXY
  899. WINHTTP_CALLBACK_FLAG_REDIRECT = WINHTTP_CALLBACK_STATUS_REDIRECT
  900. WINHTTP_CALLBACK_FLAG_INTERMEDIATE_RESPONSE = WINHTTP_CALLBACK_STATUS_INTERMEDIATE_RESPONSE
  901. WINHTTP_CALLBACK_FLAG_SECURE_FAILURE = WINHTTP_CALLBACK_STATUS_SECURE_FAILURE
  902. WINHTTP_CALLBACK_FLAG_SENDREQUEST_COMPLETE = WINHTTP_CALLBACK_STATUS_SENDREQUEST_COMPLETE
  903. WINHTTP_CALLBACK_FLAG_HEADERS_AVAILABLE = WINHTTP_CALLBACK_STATUS_HEADERS_AVAILABLE
  904. WINHTTP_CALLBACK_FLAG_DATA_AVAILABLE = WINHTTP_CALLBACK_STATUS_DATA_AVAILABLE
  905. WINHTTP_CALLBACK_FLAG_READ_COMPLETE = WINHTTP_CALLBACK_STATUS_READ_COMPLETE
  906. WINHTTP_CALLBACK_FLAG_WRITE_COMPLETE = WINHTTP_CALLBACK_STATUS_WRITE_COMPLETE
  907. WINHTTP_CALLBACK_FLAG_REQUEST_ERROR = WINHTTP_CALLBACK_STATUS_REQUEST_ERROR
  908. WINHTTP_CALLBACK_FLAG_ALL_COMPLETIONS = (WINHTTP_CALLBACK_STATUS_SENDREQUEST_COMPLETE \
  909. | WINHTTP_CALLBACK_STATUS_HEADERS_AVAILABLE \
  910. | WINHTTP_CALLBACK_STATUS_DATA_AVAILABLE \
  911. | WINHTTP_CALLBACK_STATUS_READ_COMPLETE \
  912. | WINHTTP_CALLBACK_STATUS_WRITE_COMPLETE \
  913. | WINHTTP_CALLBACK_STATUS_REQUEST_ERROR)
  914. WINHTTP_CALLBACK_FLAG_ALL_NOTIFICATIONS = (-1)
  915. WINHTTP_QUERY_MIME_VERSION = 0
  916. WINHTTP_QUERY_CONTENT_TYPE = 1
  917. WINHTTP_QUERY_CONTENT_TRANSFER_ENCODING = 2
  918. WINHTTP_QUERY_CONTENT_ID = 3
  919. WINHTTP_QUERY_CONTENT_DESCRIPTION = 4
  920. WINHTTP_QUERY_CONTENT_LENGTH = 5
  921. WINHTTP_QUERY_CONTENT_LANGUAGE = 6
  922. WINHTTP_QUERY_ALLOW = 7
  923. WINHTTP_QUERY_PUBLIC = 8
  924. WINHTTP_QUERY_DATE = 9
  925. WINHTTP_QUERY_EXPIRES = 10
  926. WINHTTP_QUERY_LAST_MODIFIED = 11
  927. WINHTTP_QUERY_MESSAGE_ID = 12
  928. WINHTTP_QUERY_URI = 13
  929. WINHTTP_QUERY_DERIVED_FROM = 14
  930. WINHTTP_QUERY_COST = 15
  931. WINHTTP_QUERY_LINK = 16
  932. WINHTTP_QUERY_PRAGMA = 17
  933. WINHTTP_QUERY_VERSION = 18
  934. WINHTTP_QUERY_STATUS_CODE = 19
  935. WINHTTP_QUERY_STATUS_TEXT = 20
  936. WINHTTP_QUERY_RAW_HEADERS = 21
  937. WINHTTP_QUERY_RAW_HEADERS_CRLF = 22
  938. WINHTTP_QUERY_CONNECTION = 23
  939. WINHTTP_QUERY_ACCEPT = 24
  940. WINHTTP_QUERY_ACCEPT_CHARSET = 25
  941. WINHTTP_QUERY_ACCEPT_ENCODING = 26
  942. WINHTTP_QUERY_ACCEPT_LANGUAGE = 27
  943. WINHTTP_QUERY_AUTHORIZATION = 28
  944. WINHTTP_QUERY_CONTENT_ENCODING = 29
  945. WINHTTP_QUERY_FORWARDED = 30
  946. WINHTTP_QUERY_FROM = 31
  947. WINHTTP_QUERY_IF_MODIFIED_SINCE = 32
  948. WINHTTP_QUERY_LOCATION = 33
  949. WINHTTP_QUERY_ORIG_URI = 34
  950. WINHTTP_QUERY_REFERER = 35
  951. WINHTTP_QUERY_RETRY_AFTER = 36
  952. WINHTTP_QUERY_SERVER = 37
  953. WINHTTP_QUERY_TITLE = 38
  954. WINHTTP_QUERY_USER_AGENT = 39
  955. WINHTTP_QUERY_WWW_AUTHENTICATE = 40
  956. WINHTTP_QUERY_PROXY_AUTHENTICATE = 41
  957. WINHTTP_QUERY_ACCEPT_RANGES = 42
  958. WINHTTP_QUERY_SET_COOKIE = 43
  959. WINHTTP_QUERY_COOKIE = 44
  960. WINHTTP_QUERY_REQUEST_METHOD = 45
  961. WINHTTP_QUERY_REFRESH = 46
  962. WINHTTP_QUERY_CONTENT_DISPOSITION = 47
  963. WINHTTP_QUERY_AGE = 48
  964. WINHTTP_QUERY_CACHE_CONTROL = 49
  965. WINHTTP_QUERY_CONTENT_BASE = 50
  966. WINHTTP_QUERY_CONTENT_LOCATION = 51
  967. WINHTTP_QUERY_CONTENT_MD5 = 52
  968. WINHTTP_QUERY_CONTENT_RANGE = 53
  969. WINHTTP_QUERY_ETAG = 54
  970. WINHTTP_QUERY_HOST = 55
  971. WINHTTP_QUERY_IF_MATCH = 56
  972. WINHTTP_QUERY_IF_NONE_MATCH = 57
  973. WINHTTP_QUERY_IF_RANGE = 58
  974. WINHTTP_QUERY_IF_UNMODIFIED_SINCE = 59
  975. WINHTTP_QUERY_MAX_FORWARDS = 60
  976. WINHTTP_QUERY_PROXY_AUTHORIZATION = 61
  977. WINHTTP_QUERY_RANGE = 62
  978. WINHTTP_QUERY_TRANSFER_ENCODING = 63
  979. WINHTTP_QUERY_UPGRADE = 64
  980. WINHTTP_QUERY_VARY = 65
  981. WINHTTP_QUERY_VIA = 66
  982. WINHTTP_QUERY_WARNING = 67
  983. WINHTTP_QUERY_EXPECT = 68
  984. WINHTTP_QUERY_PROXY_CONNECTION = 69
  985. WINHTTP_QUERY_UNLESS_MODIFIED_SINCE = 70
  986. WINHTTP_QUERY_PROXY_SUPPORT = 75
  987. WINHTTP_QUERY_AUTHENTICATION_INFO = 76
  988. WINHTTP_QUERY_PASSPORT_URLS = 77
  989. WINHTTP_QUERY_PASSPORT_CONFIG = 78
  990. WINHTTP_QUERY_MAX = 78
  991. WINHTTP_QUERY_CUSTOM = 65535
  992. WINHTTP_QUERY_FLAG_REQUEST_HEADERS = (-2147483648)
  993. WINHTTP_QUERY_FLAG_SYSTEMTIME = 0x40000000
  994. WINHTTP_QUERY_FLAG_NUMBER = 0x20000000
  995. HTTP_STATUS_CONTINUE = 100
  996. HTTP_STATUS_SWITCH_PROTOCOLS = 101
  997. HTTP_STATUS_OK = 200
  998. HTTP_STATUS_CREATED = 201
  999. HTTP_STATUS_ACCEPTED = 202
  1000. HTTP_STATUS_PARTIAL = 203
  1001. HTTP_STATUS_NO_CONTENT = 204
  1002. HTTP_STATUS_RESET_CONTENT = 205
  1003. HTTP_STATUS_PARTIAL_CONTENT = 206
  1004. HTTP_STATUS_WEBDAV_MULTI_STATUS = 207
  1005. HTTP_STATUS_AMBIGUOUS = 300
  1006. HTTP_STATUS_MOVED = 301
  1007. HTTP_STATUS_REDIRECT = 302
  1008. HTTP_STATUS_REDIRECT_METHOD = 303
  1009. HTTP_STATUS_NOT_MODIFIED = 304
  1010. HTTP_STATUS_USE_PROXY = 305
  1011. HTTP_STATUS_REDIRECT_KEEP_VERB = 307
  1012. HTTP_STATUS_BAD_REQUEST = 400
  1013. HTTP_STATUS_DENIED = 401
  1014. HTTP_STATUS_PAYMENT_REQ = 402
  1015. HTTP_STATUS_FORBIDDEN = 403
  1016. HTTP_STATUS_NOT_FOUND = 404
  1017. HTTP_STATUS_BAD_METHOD = 405
  1018. HTTP_STATUS_NONE_ACCEPTABLE = 406
  1019. HTTP_STATUS_PROXY_AUTH_REQ = 407
  1020. HTTP_STATUS_REQUEST_TIMEOUT = 408
  1021. HTTP_STATUS_CONFLICT = 409
  1022. HTTP_STATUS_GONE = 410
  1023. HTTP_STATUS_LENGTH_REQUIRED = 411
  1024. HTTP_STATUS_PRECOND_FAILED = 412
  1025. HTTP_STATUS_REQUEST_TOO_LARGE = 413
  1026. HTTP_STATUS_URI_TOO_LONG = 414
  1027. HTTP_STATUS_UNSUPPORTED_MEDIA = 415
  1028. HTTP_STATUS_RETRY_WITH = 449
  1029. HTTP_STATUS_SERVER_ERROR = 500
  1030. HTTP_STATUS_NOT_SUPPORTED = 501
  1031. HTTP_STATUS_BAD_GATEWAY = 502
  1032. HTTP_STATUS_SERVICE_UNAVAIL = 503
  1033. HTTP_STATUS_GATEWAY_TIMEOUT = 504
  1034. HTTP_STATUS_VERSION_NOT_SUP = 505
  1035. HTTP_STATUS_FIRST = HTTP_STATUS_CONTINUE
  1036. HTTP_STATUS_LAST = HTTP_STATUS_VERSION_NOT_SUP
  1037. WINHTTP_ADDREQ_INDEX_MASK = 0x0000FFFF
  1038. WINHTTP_ADDREQ_FLAGS_MASK = (-65536)
  1039. WINHTTP_ADDREQ_FLAG_ADD_IF_NEW = 0x10000000
  1040. WINHTTP_ADDREQ_FLAG_ADD = 0x20000000
  1041. WINHTTP_ADDREQ_FLAG_COALESCE_WITH_COMMA = 0x40000000
  1042. WINHTTP_ADDREQ_FLAG_COALESCE_WITH_SEMICOLON = 0x01000000
  1043. WINHTTP_ADDREQ_FLAG_COALESCE = WINHTTP_ADDREQ_FLAG_COALESCE_WITH_COMMA
  1044. WINHTTP_ADDREQ_FLAG_REPLACE = (-2147483648)
  1045. WINHTTP_IGNORE_REQUEST_TOTAL_LENGTH = 0
  1046. WINHTTP_ERROR_BASE = 12000
  1047. ERROR_WINHTTP_OUT_OF_HANDLES = (WINHTTP_ERROR_BASE + 1)
  1048. ERROR_WINHTTP_TIMEOUT = (WINHTTP_ERROR_BASE + 2)
  1049. ERROR_WINHTTP_INTERNAL_ERROR = (WINHTTP_ERROR_BASE + 4)
  1050. ERROR_WINHTTP_INVALID_URL = (WINHTTP_ERROR_BASE + 5)
  1051. ERROR_WINHTTP_UNRECOGNIZED_SCHEME = (WINHTTP_ERROR_BASE + 6)
  1052. ERROR_WINHTTP_NAME_NOT_RESOLVED = (WINHTTP_ERROR_BASE + 7)
  1053. ERROR_WINHTTP_INVALID_OPTION = (WINHTTP_ERROR_BASE + 9)
  1054. ERROR_WINHTTP_OPTION_NOT_SETTABLE = (WINHTTP_ERROR_BASE + 11)
  1055. ERROR_WINHTTP_SHUTDOWN = (WINHTTP_ERROR_BASE + 12)
  1056. ERROR_WINHTTP_LOGIN_FAILURE = (WINHTTP_ERROR_BASE + 15)
  1057. ERROR_WINHTTP_OPERATION_CANCELLED = (WINHTTP_ERROR_BASE + 17)
  1058. ERROR_WINHTTP_INCORRECT_HANDLE_TYPE = (WINHTTP_ERROR_BASE + 18)
  1059. ERROR_WINHTTP_INCORRECT_HANDLE_STATE = (WINHTTP_ERROR_BASE + 19)
  1060. ERROR_WINHTTP_CANNOT_CONNECT = (WINHTTP_ERROR_BASE + 29)
  1061. ERROR_WINHTTP_CONNECTION_ERROR = (WINHTTP_ERROR_BASE + 30)
  1062. ERROR_WINHTTP_RESEND_REQUEST = (WINHTTP_ERROR_BASE + 32)
  1063. ERROR_WINHTTP_CLIENT_AUTH_CERT_NEEDED = (WINHTTP_ERROR_BASE + 44)
  1064. ERROR_WINHTTP_CANNOT_CALL_BEFORE_OPEN = (WINHTTP_ERROR_BASE + 100)
  1065. ERROR_WINHTTP_CANNOT_CALL_BEFORE_SEND = (WINHTTP_ERROR_BASE + 101)
  1066. ERROR_WINHTTP_CANNOT_CALL_AFTER_SEND = (WINHTTP_ERROR_BASE + 102)
  1067. ERROR_WINHTTP_CANNOT_CALL_AFTER_OPEN = (WINHTTP_ERROR_BASE + 103)
  1068. ERROR_WINHTTP_HEADER_NOT_FOUND = (WINHTTP_ERROR_BASE + 150)
  1069. ERROR_WINHTTP_INVALID_SERVER_RESPONSE = (WINHTTP_ERROR_BASE + 152)
  1070. ERROR_WINHTTP_INVALID_HEADER = (WINHTTP_ERROR_BASE + 153)
  1071. ERROR_WINHTTP_INVALID_QUERY_REQUEST = (WINHTTP_ERROR_BASE + 154)
  1072. ERROR_WINHTTP_HEADER_ALREADY_EXISTS = (WINHTTP_ERROR_BASE + 155)
  1073. ERROR_WINHTTP_REDIRECT_FAILED = (WINHTTP_ERROR_BASE + 156)
  1074. ERROR_WINHTTP_AUTO_PROXY_SERVICE_ERROR = (WINHTTP_ERROR_BASE + 178)
  1075. ERROR_WINHTTP_BAD_AUTO_PROXY_SCRIPT = (WINHTTP_ERROR_BASE + 166)
  1076. ERROR_WINHTTP_UNABLE_TO_DOWNLOAD_SCRIPT = (WINHTTP_ERROR_BASE + 167)
  1077. ERROR_WINHTTP_NOT_INITIALIZED = (WINHTTP_ERROR_BASE + 172)
  1078. ERROR_WINHTTP_SECURE_FAILURE = (WINHTTP_ERROR_BASE + 175)
  1079. ERROR_WINHTTP_SECURE_CERT_DATE_INVALID = (WINHTTP_ERROR_BASE + 37)
  1080. ERROR_WINHTTP_SECURE_CERT_CN_INVALID = (WINHTTP_ERROR_BASE + 38)
  1081. ERROR_WINHTTP_SECURE_INVALID_CA = (WINHTTP_ERROR_BASE + 45)
  1082. ERROR_WINHTTP_SECURE_CERT_REV_FAILED = (WINHTTP_ERROR_BASE + 57)
  1083. ERROR_WINHTTP_SECURE_CHANNEL_ERROR = (WINHTTP_ERROR_BASE + 157)
  1084. ERROR_WINHTTP_SECURE_INVALID_CERT = (WINHTTP_ERROR_BASE + 169)
  1085. ERROR_WINHTTP_SECURE_CERT_REVOKED = (WINHTTP_ERROR_BASE + 170)
  1086. ERROR_WINHTTP_SECURE_CERT_WRONG_USAGE = (WINHTTP_ERROR_BASE + 179)
  1087. ERROR_WINHTTP_AUTODETECTION_FAILED = (WINHTTP_ERROR_BASE + 180)
  1088. ERROR_WINHTTP_HEADER_COUNT_EXCEEDED = (WINHTTP_ERROR_BASE + 181)
  1089. ERROR_WINHTTP_HEADER_SIZE_OVERFLOW = (WINHTTP_ERROR_BASE + 182)
  1090. ERROR_WINHTTP_CHUNKED_ENCODING_HEADER_SIZE_OVERFLOW = (WINHTTP_ERROR_BASE + 183)
  1091. ERROR_WINHTTP_RESPONSE_DRAIN_OVERFLOW = (WINHTTP_ERROR_BASE + 184)
  1092. ERROR_WINHTTP_CLIENT_CERT_NO_PRIVATE_KEY = (WINHTTP_ERROR_BASE + 185)
  1093. ERROR_WINHTTP_CLIENT_CERT_NO_ACCESS_PRIVATE_KEY = (WINHTTP_ERROR_BASE + 186)
  1094. WINHTTP_ERROR_LAST = (WINHTTP_ERROR_BASE + 186)
  1095. WINHTTP_NO_PROXY_NAME = None
  1096. WINHTTP_NO_PROXY_BYPASS = None
  1097. WINHTTP_NO_REFERER = None
  1098. WINHTTP_DEFAULT_ACCEPT_TYPES = None
  1099. WINHTTP_NO_ADDITIONAL_HEADERS = None
  1100. WINHTTP_NO_REQUEST_DATA = None