Changes

135 bytes removed ,  22:30, 21 June 2019
→‎sfdnsres: real cmd names
Line 245: Line 245:  
! Cmd || Name
 
! Cmd || Name
 
|-
 
|-
| 0 || SetDnsAddressesPrivate (stubbed, returns 0x7FE03)
+
| 0 || SetDnsAddressesPrivateRequest (stubbed, returns 0x7FE03)
 
|-
 
|-
| 1 || GetDnsAddressPrivate (stubbed, returns 0x7FE03)
+
| 1 || GetDnsAddressPrivateRequest (stubbed, returns 0x7FE03)
 
|-
 
|-
| 2 || GetHostByName
+
| 2 || GetHostByNameRequest
 
|-
 
|-
| 3 || GetHostByAddr
+
| 3 || GetHostByAddrRequest
 
|-
 
|-
| 4 || GetHostStringError
+
| 4 || GetHostStringErrorRequest
 
|-
 
|-
| 5 || GetGaiStringError
+
| 5 || GetGaiStringErrorRequest
 
|-
 
|-
| 6 || [[#GetAddrInfo]]
+
| 6 || [[#GetAddrInfoRequest]]
 
|-
 
|-
| 7 || GetNameInfo
+
| 7 || GetNameInfoRequest
 
|-
 
|-
| 8 || RequestCancelHandle
+
| 8 || GetCancelHandleRequest
 
|-
 
|-
| 9 || CancelSocketCall
+
| 9 || CancelRequest
 
|-
 
|-
| 10 || [5.0.0+]
+
| 10 || [5.0.0+] GetHostByNameRequestWithOptions
 
|-
 
|-
| 11 || [5.0.0+] [[#ClearDnsIpServerAddressArray]] (made-up name)
+
| 11 || [5.0.0+] GetHostByAddrRequestWithOptions
 
|-
 
|-
| 12 || [5.0.0+]
+
| 12 || [5.0.0+] GetAddrInfoRequestWithOptions
 
|-
 
|-
| 13 || [5.0.0+]
+
| 13 || [5.0.0+] GetNameInfoRequestWithOptions
 
|-
 
|-
| 14 || [5.0.0+]
+
| 14 || [5.0.0+] ResolverSetOptionRequest
 
|-
 
|-
| 15 || [5.0.0+]
+
| 15 || [5.0.0+] ResolverGetOptionRequest
 
|}
 
|}
   −
== GetAddrInfo ==
+
== GetAddrInfoRequest ==
 
Takes three type 5 buffers (host, port, and hints), and a type 6 buffer (the output addrinfos). Also takes a u8 (padded to 4 bytes so the next raw parameter can align), a u32, and a u64. The u8 is a boolean for whether to enable "nsd resolve" (1) or not (0). Not sure what the u32 is. It seems to either come from a parameter to <tt>GetAddrInfo</tt> or be zero. The u64 is most likely a placeholder for the server to copy the PID into and should be zero. Both hints and the output buffer contain serialized addrinfo chains. The hints buffer is sized 0x400 bytes long by default, and the output buffer 0x1000 bytes.
 
Takes three type 5 buffers (host, port, and hints), and a type 6 buffer (the output addrinfos). Also takes a u8 (padded to 4 bytes so the next raw parameter can align), a u32, and a u64. The u8 is a boolean for whether to enable "nsd resolve" (1) or not (0). Not sure what the u32 is. It seems to either come from a parameter to <tt>GetAddrInfo</tt> or be zero. The u64 is most likely a placeholder for the server to copy the PID into and should be zero. Both hints and the output buffer contain serialized addrinfo chains. The hints buffer is sized 0x400 bytes long by default, and the output buffer 0x1000 bytes.
   Line 317: Line 317:     
The list should be terminated with a sentinel four-byte zero value.
 
The list should be terminated with a sentinel four-byte zero value.
  −
== ClearDnsIpServerAddressArray ==
  −
This function clears <code>nn::socket::resolver::g_DnsIpServerAddressArray</code>, setting its length to 0 as well. The array initially contains IPs filled by <code>bsdconfig</code>, a privileged service handling DHCP and such.
  −
  −
Takes no arguments, doesn't return anything, never fails.
      
= nsd:u, nsd:a =
 
= nsd:u, nsd:a =