mac-address

How to get an IP address from Mac address programmatically on Android?

时光毁灭记忆、已成空白 提交于 2019-12-21 12:23:19
问题 Programmatically, I got Mac addresses of other Wifi enabled devices from my device on the same network. Same I need to apply here. Is there any apps or any other possibilities to get an IP addresses of each wifi enabled devices on the network by using those Mac addresses on Android? 回答1: If you're looking for an android app, you could try Network Discovery which work very well and can list all the devices on your local network with the corresponding IP and address. If you're looking for code

Formatting MAC address byte array to String

时光总嘲笑我的痴心妄想 提交于 2019-12-21 11:35:25
问题 I am using this code to find the MAC address of a machine. This code prints directly the MAC address, but I want to return it as a string. I am completely confused. please help. try { InetAddress add = InetAddress.getByName("10.123.96.102"); NetworkInterface ni1 = NetworkInterface.getByInetAddress(add); if (ni1 != null) { byte[] mac1 = ni1.getHardwareAddress(); if (mac1 != null) { for (int k = 0; k < mac1.length; k++) { System.out.format("%02X%s", mac1[k], (k < mac1.length - 1) ? "-" : ""); }

iOS: UDID deprecated… MAC address?

人盡茶涼 提交于 2019-12-21 07:56:05
问题 As we know Apple is deprecating developers' access to UDID. But to my knowledge it is possible to get an iDevice's MAC address. So what's the difference then? Both MAC address and UDID are unique identifier of a hardware, which is not app specific. 回答1: Some obvious differences between UDID's and MAC addresses: It's conceivable that a device might have more than one MAC address. Guaranteeing uniqueness for MAC addresses isn't Apple's responsibility. UDID's and MAC differ in size and format. I

MAC Address from IP across network

一曲冷凌霜 提交于 2019-12-21 06:38:12
问题 I hope you're all well. I'm wondering if you could help me or point me in the right direction. I'm currently working on a project that centers around network management. Due to severe time constraints where possible I'm using opensource code. The issue I'm having is that part of the project requires me to be able to capture the MAC addresses of all of the devices that are connected to the network. My knowledge of network orientated programming is limited as I have been working in other areas

Setting a VM's mac address in Vagrant

*爱你&永不变心* 提交于 2019-12-20 09:10:50
问题 The documentation lists that the mac address of a VM can be set in the Vagrantfile, however everything I add seems to end up being a syntax error. Anyone successfully done this? 回答1: I used this: config.vm.network :bridged , :mac => "080027XXXXXX" and got what I wanted. The docs are unclear on what the syntax for the options hash were, and there seemed to be no example on what this should look like. So, here it is! Bridged with a mac address (edited of course). This brings up eth1 with the

Why can't the server get the client MAC address, like the client IP?

我们两清 提交于 2019-12-18 14:51:57
问题 From what I know, all the MAC addresses that the packet gone through are in the packet. This is because that each packet that goes in a certain path, should also be returned in similar path. So, if the router of the server know about the mac address of the client (all of them), why the server page (like aspx) cannot have this information? Please, give an explanation. (don't just tell me that I'm wrong). If I understand it correctly, the client sends a packet that contains it's MAC address.

How to get uuid or mac address from client in Java?

情到浓时终转凉″ 提交于 2019-12-18 12:37:35
问题 I'm looking for a solution for a Java based webapplication to uniquely identify the client. The server is in the same network as the clients and I thought that using the MAC address would be a good solution. The problem is I can't work with cookies because they can be deleted client-side and I can't use the IP because they could just issue a new DHCP lease renewal. So I would like to fallback to the MAC address of the clients. I'm aware that there is no java built in feature to get the MAC

C++: Get MAC address of network adapters on Vista?

此生再无相见时 提交于 2019-12-17 23:37:58
问题 We are currently using the NetBios method, and it works ok under XP. Preliminary tests under Vista show that it also works, but there are caveats - NetBIOS has to be present, for instance, and from what I've been reading, the order of the adapters is bound to change. Our alternative method - with SNMPExtensionQuery - seems to be broken under Vista. The question is: do you know of a reliable way to get a list of the local MAC addresses on a Vista machine? Backwards compatibility with XP is a

Get MAC address of remote PC?

给你一囗甜甜゛ 提交于 2019-12-17 14:52:13
问题 I need to get the MAC address from a PC. The code I've written so far is here (this is only a small part of the code). public byte[] getMac(L2PcInstance player) { try { NetworkInterface ni = NetworkInterface.getByInetAddress(player.getClient().getConnectionAddress()); if (ni != null) { byte[] mac = ni.getHardwareAddress(); if (mac != null) { return mac; } } } catch (SocketException e) { _log.log(Level.SEVERE, "No MAC address.", e); } return null; } This code finds the MAC of the PC I run it

how to spoof MAC address via code

吃可爱长大的小学妹 提交于 2019-12-17 12:41:50
问题 I'm trying to spoof the MAC address of the computer that executes my program. Right now I'm getting the current MAC address of the machine using the 'getmac' command via cmd, then I want to change it via the 'RegistryKey' class(windows.system32). The issue is that I don't know the string to pass to the OpenSubKey method. For example this is the method to read the current MAC with registry key reading: private string readMAC() { RegistryKey rkey; string MAC; rkey = Registry.LocalMachine