Socket Operations
WSAStartup
Initializes the Windows Sockets API.Highest version of Windows Sockets specification that the caller can use
Pointer to WSADATA structure to receive details of the Windows Sockets implementation
gethostbyname
Retrieves host information corresponding to a hostname.Pointer to null-terminated hostname
- Hostname being resolved
URL Operations
URLDownloadToFileW
Downloads a file from the internet to a local file.Pointer to controlling IUnknown interface
URL to download from (cannot be NULL)
Path to save the downloaded file
Reserved, must be 0
Pointer to callback for progress notifications
- URL being accessed
- Destination file path
- INET_E_DOWNLOAD_FAILURE if URL is NULL or invalid
URLDownloadToCacheFileW
Downloads a file from the internet to the cache.Pointer to controlling IUnknown interface
URL to download from (cannot be NULL)
Buffer to receive the path to cached file
Size of the file name buffer in characters
Reserved, must be 0
Pointer to callback for progress notifications
- URL being accessed
- INET_E_DOWNLOAD_FAILURE if URL is NULL or invalid
Internet Operations
InternetOpenUrlW
Opens a resource specified by a URL (Unicode version).Handle returned by InternetOpen
URL to open
Additional headers to send
Length of additional headers
Flags controlling the operation
Application-defined context value
- URL being accessed
InternetOpenUrlA
Opens a resource specified by a URL (ANSI version).Handle returned by InternetOpen
URL to open
Additional headers to send
Length of additional headers
Flags controlling the operation
Application-defined context value
- URL being accessed
Configuration
Network operations can be disabled by setting thedisable_internet configuration flag. When enabled:
- WSAStartup returns WSASYSNOTREADY
- Other network operations are still monitored but may be blocked