1. Problem Description
The IP address on the Huawei switch is bound to the MAC address to establish an access control list. Only approved PCs can access the network.
2. Solutions
Create an access control list
> System-view: enters system mode.
] Acl number 6000 create an access control list
] Rule 0 deny
The DNS method is simple and practical to obtain the IP address of a server, as follows:
The following is a reference clip:Private void buttonip_click (Object sender, system. eventargs E){System. net. IPaddress [] Addresslist = DNS. gethostbyname (DNS. gethostname (). Addresslist;If (Addresslist. length> 1){Textlip. Text = Addresslist [0]. tostring ();Textsip. Text = Addresslist [1]. tostring ();}Else{Text
First introduce the service and then call the
This paper is reproduced from http://blog.sina.com.cn/s/blog_7eeb43210101hf7f.html
public class Computer {public static string CpuID;//1.cpu serial number public static string MacAddress;//2. Mac serial number public static string DiskID; 3. Hard disk ID public static string ipaddress; 4.ip address public static st
Use JavaScript to obtain the IP address and MAC address of the IE Client
In a B/S system, we often need to obtain some information about the client, such as IP and Mac, for identity authentication. In ASP. net, it is easy to get
IP address and MAC address relationship: IP address is based on the current IPV4 standard specified, not subject to hardware limitations easier to remember the address, length 4 bytes.
The following small series for everyone to bring an article WinForm C # get the MAC address, IP address, subnet mask, the default gateway instance. Small series feel very good, now share to everyone, also for everyone to make a reference. Let's take a look at it with a little knitting.
1. Add an assembly
2. Introd
IP Address Verification:/^ (\d|[ 1-9]\D|1\D{2}|2[0-5][0-5]) \. (\d| [1-9]\d|1\d{2}|2[0-5][0-5]) \. (\d| [1-9]\d|1\d{2}|2[0-5][0-5]) \. (\d| [1-9]\d|1\d{2}|2[0-5][0-5]) $/The format is made up of "." Divided by four parts, each part of the range is0-255;Each section of the regular can be divided into several parts to write:200-255;100-199;10-99;0-9;The corresponding regular expression for each part:2[0-5][0-
This article describes how to use php to obtain the IP address, host name, and mac address of all users in the LAN, if you need a php instance, you can refer to the php instance described in this article to obtain the computer IP address
Note: Relationship between the IP address and the MAC address: the IP address is specified according to the current IPv4 standard and is easy to remember without hardware restrictions. The length is 4 bytes. The
If it is a proxy server, the IP address is not a leak, so we can change their computer to proxy server to achieve the directory of hidden IP address, the specific method is as follows: Machine change to proxy server so as to achieve the purpose of hiding IP
$ String = "13826589549 ";
$ Pattern = "/(\ D {3}) \ D (\ D {2 })/";
$ Replacement = "\ $1 ***** \ $3 ";
Print preg_replace ($ pattern, $ replacement, $ string );
Output result: 138 **** 9549
The matching result is what I want, but the matching mode is incorrect. It can only match 7 digits, and the remaining 4 digits cannot match, and \ $3 does not exist at all.
Which of the following statements is true?
$ String = "13826589549 ";$ Pattern = "/(\ D {3}) \ D {4} (\ D {4 })/";$ Replacemen
Public class classnetgetmac{Public classnetgetmac (){}
[Dllimport ("iphlpapi. dll")]Private Static extern int sendarp (int32 DEST, int32 host, byte [] Mac, ref int32 length );[Dllimport ("ws2_32.dll")]Private Static extern int32 inet_addr (string IP );
/// /// Obtain the nic mac address based on the
This article describes how to obtain the mac address and IP address of a local machine using python, and describes how to obtain system information using Python, for more information about how to obtain the mac address and
1, the local area network by querying the other IP address can map the other MAC address to the host's Apr buffer table. Map host IP addresses to MacFirst, the shared LAN host is queried through the net viewSecond: Arbitrarily choose a computer name, forcing the use of IPv4
For J: = 0 to Networktypelist.count-1 do//Lists all workgroup names in each network typebegin//Lists all workgroup names in a network typeNetresource: = Tnetresource (networktypelist.items[j]^);//Network type informationGets a handle to the file resource for a network type, Netresource for the network type information, and Lphenum as the return name handleRes: = WNetOpenEnum (Resource_globalnet, Resourcetype_disk,Resourceusage_container, @NetResource, lphenum);If Res While true do//lists inform
Get the local IP address, Mac, get the corresponding IP through the domain name,Is the more common operation that network programming may encounter, so it is summarized as follows (3 functions are encapsulated),Directly on the code :#include Test RunThe results are as follows:Linux C Network Programming-Get local
PHP obtains the Mac address and absolute IP Address lt ;? Php/** CreatedonJun18, 2010 ** Tochangethetemplateforthisgeneratedfilegoto * Window-Preferences-PHPeclipse-PHP get Mac address and absolute
First, the service is introduced and then calledThis article is reproduced from http://blog.sina.com.cn/s/blog_7eeb43210101hf7f.html Public classComputer { Public Static stringCpuID;//1.cpu Serial Number Public Static stringMacAddress;//2.mac Serial Number Public Static stringDiskID;//3. Hard Drive ID Public Static stringIpAddress;//4.ip Addres
Get IP address via LAN MAC address[[email protected]cli]# Cat tmp.shfunction Get_all_arp_info (){Ip-s-S neigh flush all >/dev/nul For IP in ' seq 2 254 'DoPing 192.168.50. $ip-c1 >/dev/
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.