/foundation/communication/wifi/wifi/services/wifi_standard/wifi_framework/wifi_toolkit/net_helper/ |
H A D | network_interface.cpp | 140 bool NetworkInterface::AddIpAddress(const std::string &interfaceName, const BaseAddress &ipAddress) in AddIpAddress() argument 142 if (!ipAddress.IsValid()) { in AddIpAddress() 143 WIFI_LOGE("Add IP address [%{private}s] is not valid.", ipAddress.GetAddressWithString().c_str()); in AddIpAddress() 148 if (IsExistAddressForInterface(interfaceName, ipAddress)) { in AddIpAddress() 151 ipAddress.GetAddressWithString().c_str()); in AddIpAddress() 155 if (!IpAddressChange(interfaceName, ipAddress, true)) { in AddIpAddress() 158 ipAddress.GetAddressWithString().c_str()); in AddIpAddress() 164 bool NetworkInterface::DelIpAddress(const std::string &interfaceName, const BaseAddress &ipAddress) in DelIpAddress() argument 166 if (!ipAddress.IsValid()) { in DelIpAddress() 167 WIFI_LOGE("Del IP address [%{private}s] is not valid.", ipAddress in DelIpAddress() 319 IpAddressChange( const std::string &interface, const BaseAddress &ipAddress, bool action, bool dad) IpAddressChange() argument [all...] |
H A D | network_interface.h | 91 * @param ipAddress - Specifies the IPv4 or IPv6 address to be added. [input] 94 bool AddIpAddress(const std::string &interfaceName, const BaseAddress &ipAddress); 101 * @param ipAddress - Specifies the IPv4 or IPv6 address to be deleted. [input] 104 bool DelIpAddress(const std::string &interfaceName, const BaseAddress &ipAddress); 151 * @param ipAddress - IP address. [input] 156 bool IpAddressChange(const std::string &interface, const BaseAddress &ipAddress, bool action, bool dad = false);
|
H A D | dhcpd_interface.h | 57 * @param ipAddress - The dhcp server address 62 const std::string &ipAddress = "", bool isIpV4 = true, const int32_t &leaseTime = DHCP_LEASE_TIME); 86 const std::string &ipAddress) const; 89 const std::vector<Ipv6Address> &vecIpv6Addr, const std::string &ipAddress, bool isIpV4);
|
H A D | dhcpd_interface.cpp | 55 const std::string &ipAddress, bool isIpV4, const int32_t &leaseTime) in StartDhcpServerFromInterface() 65 if (!AssignIpAddr(mBindIpv4, mBindIpv6, vecIpv4Addr, vecIpv6Addr, ipAddress, isIpV4)) { in StartDhcpServerFromInterface() 175 const std::vector<Ipv6Address> &vecIpv6Addr, const std::string &ipAddress, bool isIpV4) in AssignIpAddr() 178 ipv4 = AssignIpAddrV4(vecIpv4Addr, IP_V4_MASK, ipAddress); in AssignIpAddr() 223 const std::string &ipAddress) const in AssignIpAddrV4() 231 std::string destIpAddress = ipAddress.empty() ? IP_V4_DEFAULT : ipAddress; in AssignIpAddrV4() 54 StartDhcpServerFromInterface(const std::string &ifaceName, Ipv4Address &ipv4, Ipv6Address &ipv6, const std::string &ipAddress, bool isIpV4, const int32_t &leaseTime) StartDhcpServerFromInterface() argument 174 AssignIpAddr(Ipv4Address &ipv4, Ipv6Address &ipv6, const std::vector<Ipv4Address> &vecIpv4Addr, const std::vector<Ipv6Address> &vecIpv6Addr, const std::string &ipAddress, bool isIpV4) AssignIpAddr() argument
|
/foundation/communication/dhcp/services/dhcp_server/src/ |
H A D | dhcp_address_pool.cpp | 145 lease.ipAddress = distIp; in CheckRangeAvailability() 274 AddressBinding *FindBindingByIp(uint32_t ipAddress) in FindBindingByIp() argument 282 if (binding && ipAddress == binding->ipAddress) { in FindBindingByIp() 301 int IsReservedIp(DhcpAddressPool *pool, uint32_t ipAddress) in IsReservedIp() argument 306 if (!ipAddress) { in IsReservedIp() 309 if (pool->leaseTable.count(ipAddress) >0) { in IsReservedIp() 310 AddressBinding *lease = &pool->leaseTable[ipAddress]; in IsReservedIp() 328 if (!binding->ipAddress) { in AddBinding() 405 if (!lease || !lease->ipAddress || IsEmptyHWAdd in AddLease() 421 GetLease(DhcpAddressPool *pool, uint32_t ipAddress) GetLease() argument [all...] |
/foundation/communication/netmanager_base/services/netconnmanager/src/ |
H A D | net_http_probe.cpp | 237 std::string ipAddress; in GetAddrInfo() local 255 if (ipAddress.find(ip) != std::string::npos) { in GetAddrInfo() 258 ipAddress = ipAddress.empty() ? (ipAddress + ip) : (ipAddress + ADDR_SEPARATOR + ip); in GetAddrInfo() 260 return ipAddress; in GetAddrInfo() 438 bool NetHttpProbe::SetResolveOption(ProbeType probeType, const std::string &domain, const std::string &ipAddress, in SetResolveOption() argument 446 if (ipAddress.empty()) { in SetResolveOption() 447 NETMGR_LOG_E("ipAddress i in SetResolveOption() 490 std::string ipAddress; SendDnsProbe() local [all...] |
/foundation/communication/dhcp/test/unittest/services/dhcp_server/unittest/ |
H A D | dhcp_address_pool_test.cpp | 92 bind.ipAddress = testIp1; in HWTEST_F() 97 bind.ipAddress = testIp2; in HWTEST_F() 125 bind.ipAddress = testIp1; in HWTEST_F() 130 bind.ipAddress = testIp2; in HWTEST_F() 175 bind.ipAddress = testIp1; in HWTEST_F() 180 bind.ipAddress = testIp2; in HWTEST_F() 208 bind.ipAddress = testIp1; in HWTEST_F() 213 bind.ipAddress = testIp2; in HWTEST_F() 223 bind.ipAddress = testIp1; in HWTEST_F() 225 bind.ipAddress in HWTEST_F() [all...] |
/foundation/communication/dhcp/test/unittest/services/dhcp_client/ |
H A D | dhcp_client_service_impl_test.cpp | 285 std::string ipAddress = "2001:0db8:85a3:0000:0000:8a2e:0370:7334"; in HWTEST_F() local 286 bool result = dhcpClientImpl->IsGlobalIPv6Address(ipAddress); in HWTEST_F() 289 ipAddress = "3001:0db8:85a3:0000:0000:8a2e:0370:7334"; in HWTEST_F() 290 result = dhcpClientImpl->IsGlobalIPv6Address(ipAddress); in HWTEST_F() 293 ipAddress = "1001:0db8:85a3:0000:0000:8a2e:0370:7334"; in HWTEST_F() 294 result = dhcpClientImpl->IsGlobalIPv6Address(ipAddress); in HWTEST_F() 297 ipAddress = ""; in HWTEST_F() 298 result = dhcpClientImpl->IsGlobalIPv6Address(ipAddress); in HWTEST_F()
|
/foundation/communication/wifi_lite/interfaces/wifiservice/ |
H A D | wifi_device_config.h | 131 unsigned int ipAddress;
member 224 unsigned int ipAddress;
member
|
H A D | station_info.h | 56 unsigned int ipAddress;
member
|
H A D | wifi_linked_info.h | 76 unsigned int ipAddress;
member
|
/foundation/communication/wifi/wifi/test/wifi_standard/wifi_framework/wifi_toolkit/unittest/ |
H A D | dhcpd_interface_test.cpp | 100 * @tc.desc: StartDhcpServer with ipAddress fail 111 std::string ipAddress = "10"; in HWTEST_F() local 112 pDhcpdInterface->StartDhcpServerFromInterface(ifaceName, ipv4, ipv6, ipAddress, isIpV4); in HWTEST_F() 116 * @tc.desc: StartDhcpServer with ipAddress succeed 127 std::string ipAddress = "192.168.62.0"; in HWTEST_F() local 128 pDhcpdInterface->StartDhcpServerFromInterface(ifaceName, ipv4, ipv6, ipAddress, isIpV4); in HWTEST_F() 132 * @tc.desc: StartDhcpServer wifh ipAddress fail
|
/foundation/communication/wifi/wifi/interfaces/kits/c/ |
H A D | wifi_device_config.h | 171 unsigned int ipAddress; member 268 unsigned int ipAddress; member
|
H A D | station_info.h | 58 unsigned int ipAddress; member
|
H A D | wifi_linked_info.h | 77 unsigned int ipAddress; member
|
H A D | wifi_hotspot_config.h | 99 char ipAddress[WIFI_MAX_IPV4_LEN]; member
|
/foundation/communication/wifi/wifi/frameworks/native/interfaces/ |
H A D | wifi_ap_msg.h | 154 ipAddress = newIpAddress; in SetIpAddress() 159 return ipAddress; in GetIpAddress() 178 std::string ipAddress; /* Hotspot IP address of the dhcp server */ member
|
/foundation/communication/wifi/wifi/test/wifi_standard/native/ |
H A D | wifi_c_hotspot_test.cpp | 68 result.ipAddress = g_status; in GetStationListTest() 113 memcpy_s(config.ipAddress, WIFI_MAX_IPV4_LEN, "192.168.1.12", 12); in HWTEST_F() 177 memcpy_s(config.ipAddress, WIFI_MAX_IPV4_LEN, "192.168.1.1222555454545", WIFI_MAX_IPV4_LEN); in HWTEST_F()
|
/foundation/communication/dhcp/test/fuzztest/dhcpbinding_fuzzer/ |
H A D | dhcpbinding_fuzzer.cpp | 39 binding.ipAddress = static_cast<uint32_t>(data[0]); in IsExpireTest() 53 binding.ipAddress = static_cast<uint32_t>(data[0]); in WriteAddressBindingTest() 70 binding.ipAddress = static_cast<uint32_t>(data[0]); in ParseAddressBindingTest()
|
/foundation/CastEngine/castengine_cast_plus_stream/src/channel/src/tcp/ |
H A D | tcp_connection.cpp | 51 if (channelRequest_.remoteDeviceInfo.ipAddress.empty() || channelRequest_.remotePort == INVALID_PORT) { in Connect() 59 int port = socket_.Bind(channelRequest_.localDeviceInfo.ipAddress, channelRequest_.localPort); in Connect() 60 CLOGD("Start server socket, localIp:%s, bindPort:%{public}d", channelRequest_.localDeviceInfo.ipAddress.c_str(), in Connect() 62 bool ret = socket_.Connect(channelRequest_.remoteDeviceInfo.ipAddress, channelRequest_.remotePort); in Connect() 82 int port = socket_.Bind(request.localDeviceInfo.ipAddress, request.localPort); in StartListen() 83 CLOGD("Start server socket, localIp:%s, bindPort:%{public}d", request.localDeviceInfo.ipAddress.c_str(), port); in StartListen()
|
/foundation/CastEngine/castengine_cast_framework/service/src/session/src/channel/src/tcp/ |
H A D | tcp_connection.cpp | 51 if (channelRequest_.remoteDeviceInfo.ipAddress.empty() || channelRequest_.remotePort == INVALID_PORT) { in Connect() 59 int port = socket_.Bind(channelRequest_.localDeviceInfo.ipAddress, channelRequest_.localPort); in Connect() 60 CLOGD("Start server socket, localIp:%s, bindPort:%{public}d", channelRequest_.localDeviceInfo.ipAddress.c_str(), in Connect() 62 bool ret = socket_.Connect(channelRequest_.remoteDeviceInfo.ipAddress, channelRequest_.remotePort); in Connect() 82 int port = socket_.Bind(request.localDeviceInfo.ipAddress, request.localPort); in StartListen() 83 CLOGD("Start server socket, localIp:%s, bindPort:%{public}d", request.localDeviceInfo.ipAddress.c_str(), port); in StartListen()
|
/foundation/communication/dhcp/services/dhcp_server/include/ |
H A D | dhcp_address_pool.h | 60 int IsReservedIp(DhcpAddressPool *pool, uint32_t ipAddress); 67 AddressBinding *GetLease(DhcpAddressPool *pool, uint32_t ipAddress);
|
/foundation/communication/wifi/wifi/services/wifi_standard/wifi_framework/wifi_manage/wifi_self_cure/ |
H A D | multi_gateway.cpp | 57 std::string ipAddress = IpTools::ConvertIpv4Address(ipInfo.ipAddress); in GetGatewayAddr() local 67 arpChecker.Start(ifName, macAddress, ipAddress, m_gwIpAddr); in GetGatewayAddr()
|
/foundation/communication/wifi/wifi/interfaces/inner_api/ |
H A D | wifi_msg.h | 198 unsigned int ipAddress; member 231 ipAddress = 0; in WifiLinkedInfo() 357 WifiLinkAddress ipAddress; member in OHOS::Wifi::DisconnectedReason::DisconnectDetailReason::StaticIpAddress 365 return IpTools::ConvertIpv4Mask(ipAddress.prefixLength); in GetIpv4Mask() 370 return IpTools::ConvertIpv6Mask(ipAddress.prefixLength); in GetIpv6Mask() 567 unsigned int ipAddress; /* ip address */ member 578 ipAddress = 0; in IpInfo()
|
/foundation/communication/wifi/wifi/services/wifi_standard/wifi_framework/wifi_manage/wifi_common/ |
H A D | wifi_net_agent.cpp | 134 bool WifiNetAgent::AddRoute(const std::string interface, const std::string ipAddress, int prefixLength) in AddRoute() argument 138 unsigned int ipInt = IpTools::ConvertIpv4Address(ipAddress); in AddRoute() 159 LOGI("Add route, interface: %{public}s, destAddress: %{public}s, ipAddress: %{public}s, prefixLength: %{public}d", in AddRoute() 160 interface.c_str(), IpAnonymize(destAddress).c_str(), IpAnonymize(ipAddress).c_str(), prefixLength); in AddRoute() 161 netsysService->NetworkAddRoute(OHOS::nmd::LOCAL_NETWORK_NETID, interface, destAddress, ipAddress); in AddRoute() 166 bool WifiNetAgent::DelInterfaceAddress(const std::string interface, const std::string ipAddress, int prefixLength) in DelInterfaceAddress() argument 168 int32_t result = NetConnClient::GetInstance().DelInterfaceAddress(interface, ipAddress, prefixLength); in DelInterfaceAddress() 289 netAddr->address_ = IpTools::ConvertIpv4Address(wifiIpInfo.ipAddress); 384 std::string strLocalRoute = IpTools::ConvertIpv4Address(wifiIpInfo.ipAddress & wifiIpInfo.netmask);
|