Home
last modified time | relevance | path

Searched refs:clientAddr (Results 1 - 25 of 29) sorted by relevance

12

/foundation/communication/dsoftbus/tests/core/transmission/trans_channel/tcp_direct/unittest/
H A Dtrans_tcp_direct_listener_test.cpp114 ConnectOption *clientAddr = (ConnectOption *)SoftBusMalloc(sizeof(ConnectOption)); in HWTEST_F() local
115 ASSERT_TRUE(clientAddr != nullptr); in HWTEST_F()
121 int32_t ret = CreateSessionConnNode(module, fd, chanId, clientAddr); in HWTEST_F()
134 ConnectOption *clientAddr = (ConnectOption *)SoftBusMalloc(sizeof(ConnectOption)); in HWTEST_F() local
135 ASSERT_TRUE(clientAddr != nullptr); in HWTEST_F()
140 int32_t ret = TdcOnConnectEvent(module, cfd, clientAddr); in HWTEST_F()
153 ConnectOption *clientAddr = (ConnectOption *)SoftBusMalloc(sizeof(ConnectOption)); in HWTEST_F() local
154 ASSERT_TRUE(clientAddr != nullptr); in HWTEST_F()
159 int32_t ret = TdcOnConnectEvent(module, cfd, clientAddr); in HWTEST_F()
/foundation/CastEngine/castengine_wifi_display/services/network/session/
H A Dudp_session.cpp113 struct sockaddr_in clientAddr; in OnSessionReadble() local
115 retCode = ::recvfrom(fd, buf->Data(), DEAFULT_READ_BUFFER_SIZE, 0, (struct sockaddr *)&clientAddr, &len); in OnSessionReadble()
117 GetAnonyString(inet_ntoa(clientAddr.sin_addr)).c_str(), clientAddr.sin_port); in OnSessionReadble()
/foundation/communication/dsoftbus/core/connection/common/src/
H A Dsoftbus_tcp_socket.c407 static int32_t AcceptTcpClient(int32_t fd, ConnectOption *clientAddr, int32_t *cfd) in AcceptTcpClient() argument
409 CONN_CHECK_AND_RETURN_RET_LOGW(clientAddr != NULL, SOFTBUS_INVALID_PARAM, CONN_COMMON, in AcceptTcpClient()
410 "invalid param, clientAddr is null"); in AcceptTcpClient()
419 clientAddr->type = CONNECT_TCP; in AcceptTcpClient()
420 clientAddr->socketOption.port = GetTcpSockPort(*cfd); in AcceptTcpClient()
421 clientAddr->socketOption.protocol = LNN_PROTOCOL_IP; in AcceptTcpClient()
424 clientAddr->socketOption.addr, sizeof(clientAddr->socketOption.addr)); in AcceptTcpClient()
432 clientAddr->socketOption.addr, sizeof(clientAddr in AcceptTcpClient()
[all...]
H A Dsoftbus_base_listener.c849 ConnectOption clientAddr = { in ProcessSpecifiedServerAcceptEvent() local
859 status = SOFTBUS_TEMP_FAILURE_RETRY(socketIf->AcceptClient(listenFd, &clientAddr, &clientFd)); in ProcessSpecifiedServerAcceptEvent()
865 ConvertAnonymizeIpAddress(animizedIp, IP_LEN, clientAddr.socketOption.addr, IP_LEN); in ProcessSpecifiedServerAcceptEvent()
870 listener->onConnectEvent(module, clientFd, &clientAddr); in ProcessSpecifiedServerAcceptEvent()
/foundation/CastEngine/castengine_wifi_display/services/network/server/
H A Dudp_server.cpp141 struct sockaddr_in clientAddr; in OnServerReadable() local
143 retCode = ::recvfrom(fd, buf->Data(), DEAFULT_READ_BUFFER_SIZE, 0, (struct sockaddr *)&clientAddr, &len); in OnServerReadable()
145 inet_ntoa(clientAddr.sin_addr), clientAddr.sin_port, len); in OnServerReadable()
167 BaseNetworkSession::Ptr session = FindOrCreateSession(clientAddr); in OnServerReadable()
H A Dtcp_server.cpp112 struct sockaddr_in clientAddr; in OnServerReadable() local
115 int32_t clientFd = SocketUtils::AcceptSocket(fd, &clientAddr, &addrLen); in OnServerReadable()
/foundation/communication/dsoftbus/core/transmission/trans_channel/tcp_direct/src/
H A Dtrans_tcp_direct_listener.c152 static int32_t CreateSessionConnNode(ListenerModule module, int fd, int32_t chanId, const ConnectOption *clientAddr) in CreateSessionConnNode() argument
168 conn->appInfo.peerData.port = clientAddr->socketOption.port; in CreateSessionConnNode()
177 if (strcpy_s(conn->appInfo.peerData.addr, sizeof(conn->appInfo.peerData.addr), clientAddr->socketOption.addr) != in CreateSessionConnNode()
183 conn->appInfo.protocol = clientAddr->socketOption.protocol; in CreateSessionConnNode()
207 static int32_t TdcOnConnectEvent(ListenerModule module, int cfd, const ConnectOption *clientAddr) in TdcOnConnectEvent() argument
209 if (cfd < 0 || clientAddr == NULL) { in TdcOnConnectEvent()
231 ret = CreateSessionConnNode(module, cfd, channelId, clientAddr); in TdcOnConnectEvent()
/foundation/communication/dsoftbus/sdk/transmission/trans_channel/tcp_direct/src/
H A Dclient_trans_tcp_direct_listener.c60 const ConnectOption *clientAddr) in ClientTdcOnConnectEvent()
64 (void)clientAddr; in ClientTdcOnConnectEvent()
59 ClientTdcOnConnectEvent(ListenerModule module, int cfd, const ConnectOption *clientAddr) ClientTdcOnConnectEvent() argument
/foundation/communication/netmanager_base/services/netmanagernative/src/netsys/
H A Dfwmark_network.cpp136 struct sockaddr_un clientAddr; in SendMessage() local
137 socklen_t len = sizeof(clientAddr); in SendMessage()
139 clientSockfd = accept(*serverSockfd, reinterpret_cast<struct sockaddr *>(&clientAddr), &len); in SendMessage()
/foundation/communication/dsoftbus/tests/core/authentication/unittest/
H A Dauth_tcp_connection_test.cpp180 ConnectOption clientAddr; in HWTEST_F() local
181 (void)memset_s(&clientAddr, sizeof(ConnectOption), 0, sizeof(ConnectOption)); in HWTEST_F()
182 int32_t ret = OnConnectEvent(module, cfd, &clientAddr); in HWTEST_F()
185 ret = OnConnectEvent(module, cfd, &clientAddr); in HWTEST_F()
/foundation/communication/dsoftbus/core/connection/interface/
H A Dsoftbus_base_listener.h45 int32_t (*onConnectEvent)(ListenerModule module, int32_t cfd, const ConnectOption *clientAddr);
H A Dsoftbus_socket.h63 int32_t (*AcceptClient)(int32_t fd, ConnectOption *clientAddr, int32_t *cfd);
/foundation/communication/netmanager_base/services/netmanagernative/src/netsys/dnsresolv/
H A Ddns_proxy_listen.cpp252 auto clientAddr = std::make_unique<AlignedSockAddr>(); in GetRequestAndTransmit() local
253 if (clientAddr == nullptr) { in GetRequestAndTransmit()
254 NETNATIVE_LOGE("clientAddr mem failed"); in GetRequestAndTransmit()
261 reinterpret_cast<sockaddr *>(&(clientAddr->sin)), &len); in GetRequestAndTransmit()
265 reinterpret_cast<sockaddr *>(&(clientAddr->sin6)), &len); in GetRequestAndTransmit()
275 DnsParseBySocket(recvBuff, clientAddr); in GetRequestAndTransmit()
H A Ddns_resolv_listen.cpp384 sockaddr_un clientAddr = {0}; in StartListen() local
385 socklen_t len = sizeof(clientAddr); in StartListen()
387 int clientSockFd = accept(serverSockFd_, (sockaddr *)&clientAddr, &len); in StartListen()
/foundation/communication/wifi/wifi/services/wifi_standard/wifi_framework/wifi_manage/wifi_p2p/
H A Dwifi_p2p_group_manager.cpp157 std::string clientAddr = client->GetDeviceAddress(); in GetNetworkIdFromClients() local
158 std::transform(clientAddr.begin(), clientAddr.end(), clientAddr.begin(), ::tolower); in GetNetworkIdFromClients()
159 if (clientAddr == deviceAddr) { in GetNetworkIdFromClients()
/foundation/communication/dsoftbus/components/nstackx/nstackx_util/core/
H A Dnstackx_socket.c411 struct sockaddr_in clientAddr; in AcceptSocket() local
412 socklen_t addrLen = sizeof(clientAddr); in AcceptSocket()
413 (void)memset_s(&clientAddr, addrLen, 0, addrLen); in AcceptSocket()
427 clientSocket->sockfd = accept(serverSocket->sockfd, (struct sockaddr *)&clientAddr, &addrLen); in AcceptSocket()
438 clientSocket->dstAddr = clientAddr; in AcceptSocket()
/foundation/communication/netmanager_base/services/netmanagernative/src/manager/
H A Dvpn_manager.cpp301 sockaddr_in clientAddr; in StartUnixSocketListen() local
302 socklen_t len = sizeof(clientAddr); in StartUnixSocketListen()
304 int32_t clientFd = accept(serverfd, reinterpret_cast<sockaddr *>(&clientAddr), &len); in StartUnixSocketListen()
/foundation/communication/dsoftbus/adapter/common/bus_center/network/
H A Dlnn_netlink_monitor.c190 static int32_t NetlinkOnConnectEvent(ListenerModule module, int32_t cfd, const ConnectOption *clientAddr) in NetlinkOnConnectEvent() argument
194 (void)clientAddr; in NetlinkOnConnectEvent()
/foundation/communication/dsoftbus/tests/core/connection/common/fuzztest/connectioncommon_fuzzer/
H A Dconnectioncommon_fuzzer.cpp54 static int32_t ConnectEvent(ListenerModule module, int32_t cfd, const ConnectOption *clientAddr) in ConnectEvent() argument
/foundation/communication/dsoftbus/core/connection/tcp/src/
H A Dsoftbus_tcp_connect_manager.c71 static int32_t TcpOnConnectEvent(ListenerModule module, int32_t cfd, const ConnectOption *clientAddr);
216 static int32_t TcpOnConnectEvent(ListenerModule module, int32_t cfd, const ConnectOption *clientAddr) in TcpOnConnectEvent() argument
218 if (cfd < 0 || clientAddr == NULL) { in TcpOnConnectEvent()
219 CONN_LOGE(CONN_COMMON, "cfd is invalid or clientAddr is null. cfd=%{public}d", cfd); in TcpOnConnectEvent()
244 clientAddr->socketOption.addr) != EOK) { in TcpOnConnectEvent()
247 tcpConnInfoNode->info.socketInfo.port = clientAddr->socketOption.port; in TcpOnConnectEvent()
250 tcpConnInfoNode->info.socketInfo.protocol = clientAddr->socketOption.protocol; in TcpOnConnectEvent()
/foundation/CastEngine/castengine_wifi_display/services/network/socket/
H A Dsocket_utils.cpp502 int32_t SocketUtils::AcceptSocket(int32_t fd, struct sockaddr_in *clientAddr, socklen_t *addrLen) in AcceptSocket() argument
505 RETURN_INVALID_IF_NULL(clientAddr); in AcceptSocket()
507 int32_t clientFd = accept(fd, reinterpret_cast<struct sockaddr *>(clientAddr), addrLen); in AcceptSocket()
H A Dsocket_utils.h57 static int32_t AcceptSocket(int32_t fd, struct sockaddr_in *clientAddr, socklen_t *addrLen);
/foundation/communication/dsoftbus/core/authentication/src/
H A Dauth_tcp_connection.c65 int32_t __attribute__((weak)) RouteBuildServerAuthManager(int32_t cfd, const ConnectOption *clientAddr) in RouteBuildServerAuthManager() argument
68 (void)clientAddr; in RouteBuildServerAuthManager()
268 static int32_t OnConnectEvent(ListenerModule module, int32_t cfd, const ConnectOption *clientAddr) in OnConnectEvent() argument
296 if (RouteBuildServerAuthManager(cfd, clientAddr) != SOFTBUS_OK) { in OnConnectEvent()
/foundation/communication/dsoftbus/core/bus_center/lnn/lane_hub/lane_manager/src/
H A Dlnn_lane_reliability.c222 static int32_t LaneDetectOnConnectEvent(ListenerModule module, int32_t cfd, const ConnectOption *clientAddr) in LaneDetectOnConnectEvent() argument
226 (void)clientAddr; in LaneDetectOnConnectEvent()
/foundation/communication/dsoftbus/tests/adapter/unittest/
H A Dsoftbus_socket_test.cpp510 SoftBusSockAddrIn clientAddr; in HWTEST_F() local
511 int32_t ret = SoftBusSocketGetLocalName(socketFd, (SoftBusSockAddr *)&clientAddr); in HWTEST_F()
561 SoftBusSockAddrIn clientAddr; in HWTEST_F() local
562 ret = SoftBusSocketGetLocalName(socketFd, (SoftBusSockAddr *)&clientAddr); in HWTEST_F()
579 SoftBusSockAddrIn clientAddr; in HWTEST_F() local
580 ret = SoftBusSocketGetLocalName(socketFd, (SoftBusSockAddr *)&clientAddr); in HWTEST_F()

Completed in 21 milliseconds

12