MCPcopy Create free account
hub / github.com/apache/impala / GetRemoteAddress

Function GetRemoteAddress

be/src/util/webserver.cc:269–276  ·  view source on GitHub ↗

Return the address of the remote user from the squeasel request info.

Source from the content-addressed store, hash-verified

267
268// Return the address of the remote user from the squeasel request info.
269kudu::Sockaddr GetRemoteAddress(const struct sq_request_info* req) {
270 struct sockaddr_in addr;
271 memset(&addr, 0, sizeof(addr));
272 addr.sin_family = AF_INET;
273 addr.sin_port = NetworkByteOrder::FromHost16(req->remote_port);
274 addr.sin_addr.s_addr = NetworkByteOrder::FromHost32(req->remote_ip);
275 return kudu::Sockaddr(addr);
276}
277
278
279// Performs a step of SPNEGO authorization by parsing the HTTP Authorization header

Callers 4

BeginRequestCallbackMethod · 0.85
HandleSpnegoMethod · 0.85
HandleBasicMethod · 0.85

Calls 1

SockaddrClass · 0.70

Tested by

no test coverage detected