Can I change my Hero's ID on a wireless network? - Hero, G2 Touch General

My Hero ID shows up on my wireless network as UNKNOWN, is there a way to change this? I know there was in WinMo, but I can't find anything in Android.
Thanks.

Do you mean the hostname?
I've not tried it but try setting it in /etc/hostname, and add it to the end of the localhost line in /etc/hosts, might work..

Hi Sam, thanks for the reply. Not sure what you mean by hostname.
I'm referring to how the phone is identified on a wireless network. With my WinMo devices I gave the phone a name in the Device ID section. Then, when I go to my router, I am able to see IP address, Device Name, and MAC address.
I cannot find any settings in the Hero that allow me to specify a device name, so it always shows up as UNKNOWN on the network.

Linux / unix
Deke
a Hosts file is a file that links IP address with Names... Windows have them UNIX and macs... etc...
its a file you will rarely see in windows. but in unix/linux you very well could.. as Android is based on Linux i beleive the sugesstion mentioned is to edit this file on your phone and ad the Local host (the phone itself) in there with the name you want it to have...
In UNIX (which i use) i can totaly see this working but have no idea if this will work on the phone, and you will need it to be 'rooted'
this means have access to the Administrators privlages to edit files...
(in linux root = Administrator)
there are posts on the forums on how to root your phone and it will open up function to you but at the same time will allow you to happly **** up the system files if you dont know what your doing and make your phone into a nice paperweight...
hope this helps

Hi Bobro; very helpful, thanks.
So basically I can't do something as simple as give my phone a useful ID without rooting it? I would regard that as a fundamental requirement, so it seems a bit foolish to omit the functionality from Android.

Related

Hacking the G1 through wifi?

I know this is a little overboard. But i got to thinking last night that...
1. Our phones run a linux OS
2. Have exploited a super user root account which should be usable at any point while on the phone
3. Has wifi capabilities built in to connect and obtain a routable internal ip address
What is to prevent someone that knows what their doing from accessing the phone and messing up through the internal network.... or pretty much a basic hack. The phone runs nothing different (well a little different) linux distro with all commands still available. The root account doesnt even have a password to protect it and im scared to set one for fear of messing something up (supposed to have no password). I dont know if i needed root access for it to automatically know what the password is as most apps are made to probably not need a password. So whats to stop someone from hacking into the G1 and pretty much screwing everything up
The fact that there is no SSH/Telnet server running by default, so you can not make a remote connection to your phone without explicitly starting said server on the phone first.
daveid said:
The fact that there is no SSH/Telnet server running by default, so you can not make a remote connection to your phone without explicitly starting said server on the phone first.
Click to expand...
Click to collapse
good point but what about using exploits that could or have been found in the distro that this is based on or made from. When connected to any internal network you dont need a telnet or ssh tunnel to "remote" into the computer, just use commonly found exploits (if any?)
whats going to prevent this??
this bad boy right here:
http://forum.xda-developers.com/showthread.php?t=449536
well then andrew theres the answer to your question...
inpherno3 said:
good point but what about using exploits that could or have been found in the distro that this is based on or made from. When connected to any internal network you dont need a telnet or ssh tunnel to "remote" into the computer, just use commonly found exploits (if any?)
Click to expand...
Click to collapse
An "exploit" still requires some avenue of access. What you mean by an exploit is, for example; someone listening in as you log in as a regular user over telnet who then later logs in as the same user, but uses a KERNEL BUG to grab root access. This still requires a telnet server to be running. If your telnet server is NOT running, then they can't EXPLOIT the KERNEL BUG to steal root access. Another example is running unknown code on some remote web page, which then exploits a BROWSER BUG, for example; http://www.microsoft.com/technet/security/advisory/961051.mspx
You see, it doesn't matter if someone is connected to the same network, if there is no way into your computer, there is nothing they can do, even if you don't have a protected root account.
And if it makes you feel better, there's no reason you can't run iptables firewall on your phone. It is kernel supported and there are executables compiled for this device.

Off Topic: Virgin Mobile Mifi Device

Guys, I knwo this is not on the topic of the hero, but maybe some of you knwo how this works, have modified the file, or something, but I need some help.
This device allows me to forward ports. I need ports forwarded for all my IPs from .2 to .6, but the config file doesn't really let me do that I dont think...
I have tried adding each IP seperated by a comma, but don't think that works. I also tried adding a new block of 'ports' and adding each Ip to them, as you can see in the file I attached with (1) in the filename.
'
Someone help, please?
The files are supposed to be .xml but this forum dont allow those.
also, I've noticed this thing has a PRL, too... I wonder if I can change that to the one my hero has. this 61006 is freakin garbage.
hey Jerry - I've got the Virgin Mobile MiFi as well (and LOVE it!!)... I don't have it with me right now, but just making sure that you have tried the GUI for configuring the port forwarding, right? I've not ever looked at the port forwarding admin screen, so maybe it doesn't offer what you want in via the browser based admin, but just wanted to double check that you had checked out the 192.168.1.1 panel.
I'll try to help more if I can later.
--bp

[Q] Which file/property tells apps phone HAS internet access?

Hi,
I'm working to get reverse tethering (internet passthrough) working through a Linux pc. The app that comes with the phone is for Windows only. I have got to the stage where I can bridge the interfaces on the pc, get a dhcp address on the phone's usb interface, set the route and access the internet (from some apps). However, other apps don't even bother to try to connect if the phone tells them it has no access. This must be set in a property somewhere, but I don't know where? Can anybody help find it and tell me how to set it?
Cheers!
They probably only ask this class, directly or automatically when creating a connection :
http://developer.android.com/reference/android/net/ConnectivityManager.html
You will probably need to browse the Android SDK sources, but looking at this class, this will not help you much as the connectivity itself is hidden behind a IDL interface :
http://android.git.kernel.org/?p=pl...ore/java/android/net/ConnectivityManager.java
Thanks for the reply faugusztin.
Sounds too complex for me to set, unless there are ways to do this indirectly.

gtablet Device name on the network

Does anyone know how to change the device name on the gtablet? I now have the ablilty to hook me gtablet up to my corporate network, so I went into the DHCP server to make a reservation for the device the name that it displays is andoid_XXXXXXXXXXXXXXXXX.mydomain.com replace the X with Hex numbers and letters. I would like to change the name on the device so that other admins know what the device is and don't delete if from the reservation pool.
i was thinking
IpadCrusher.mydomin.com
I too would like to know how to change the hostname (device name).
Viper Tablet
greyspacealien said:
Does anyone know how to change the device name on the gtablet? I now have the ablilty to hook me gtablet up to my corporate network, so I went into the DHCP server to make a reservation for the device the name that it displays is andoid_XXXXXXXXXXXXXXXXX.mydomain.com replace the X with Hex numbers and letters. I would like to change the name on the device so that other admins know what the device is and don't delete if from the reservation pool.
i was thinking
IpadCrusher.mydomin.com
Click to expand...
Click to collapse
I still like Viper Tablet for the Viewsonic VEGAn build when ever it goes final!
I would also like to know. I keep getting hassled by my Network Admins because every time I load a new ROM, the "xxxxx" changes and it looks like a new device. Same thing happens with my HTC Incredible Phone.
I'm jealous because I can't even logon to my works corporate network. Device keeps failing to assign an i.p address.
I get connected via wifi if I assign a static address, but android doesn't support http proxy or something, so the username/logon screen never comes up
greyspacealien said:
Does anyone know how to change the device name on the gtablet? I now have the ablilty to hook me gtablet up to my corporate network, so I went into the DHCP server to make a reservation for the device the name that it displays is andoid_XXXXXXXXXXXXXXXXX.mydomain.com replace the X with Hex numbers and letters. I would like to change the name on the device so that other admins know what the device is and don't delete if from the reservation pool.
i was thinking
IpadCrusher.mydomin.com
Click to expand...
Click to collapse
If you are rooted and have a robust busybox installed, after reboot you could execute the following command:
busybox hostname YourDevice
You could setup a gscript script and run it before you turn on your wifi or download autostart and have your script run automatically after a reboot.
Your network admins actually allow this thing on your corporate network?? Oh my.
In Linux, the computer name is stored in the /etc/hosts file. You might try editing your hosts file and put in:
127.0.0.2 name.site name
NMCBR600 said:
In Linux, the computer name is stored in the /etc/hosts file. You might try editing your hosts file and put in:
127.0.0.2 name.site name
Click to expand...
Click to collapse
If you get a fixed IP address or one with reservation each time you connect to your wifi router, this may work.
I have a home built dd-wrt wireless distribution system at home and was playing with the hosts file to see how my wds interpreted hosts file and it didn't work but that is just my homegrown system. my 2wire router didn't interpret it either (gave the random android_xxxxxxxxxxx device name.
Of course, you could just give them the MAC address of your wireless card which you can get by doing #busybox ifconfig in a terminal session and tell them the name you want and they can create an Arec in the dns names.
roebeet said:
Your network admins actually allow this thing on your corporate network?? Oh my.
Click to expand...
Click to collapse
Actually, no. However, connecting to MS Exchange with Sync logs the Device ID into Exchange. So, each time I load a different ROM, I log a new ID. Drives them nuts.
I did some research today though and found an app called Android ID Changerthat will allow me to see my DeviceID and modify it. I reinstalled my orginal ROM, recorded the ID, reloaded Vegan and changed the ID to the original device information. Works very well.
I found this post in another forum that may work for you:
http://forum.xda-developers.com/showpost.php?p=9560696&postcount=1
Please note that if you do use setprop you would have to reset it after each reboot. I think adding a correlating line in build.prop (if one exists) would be a better alternative. Otherwise, they discuss unpacking/repacking the boot.img to make it permanent.
roebeet said:
Your network admins actually allow this thing on your corporate network?? Oh my.
Click to expand...
Click to collapse
I am one of the net admins
I wouldn't say its on the corprate network, its on the corprate wireless network, I can get to the web and the intranet but that is about it we have it pretty locked down. I have it teathered to my phone most of the day. Its fun to take it to a meeting and have all of the iPad users say is that the new iPad I just laugh and think YOU WISH.
Roebeet I know I have talked about this before with you, I like you would like to get my usb air card working on this bad boy that would solve all fo my connections issues. Im not the smartest guy with linux but I could spend some time if I could find some info about it.
I had found this site a while ago but could not get the drivers to install I'm sure its because we don't have source code.
http://sierrawireless.custhelp.com/...ting-system-?-(-v.1.7.34)#Driver_Installation

MAC Address Spoofing

Being overly paranoid I'm always trying to make it harder for companies to track my device. Anyway, my most recent discovery is spoofing the MAC Address on my 3T so that wifi companies can't track it.
*** This requires root ***
I have it working in Marshmallow 6.0.1 (not tried it in Nougat)
Only attempt this if you understand MAC Addresses and be sure to note down your original/official MAC Address. Open /persist/wlan_mac.bin and take a copy of the contents before attempting the below.
Some background reading if you're not familiar with MAC Addresses.
Code:
ifconfig wlan0
will tell you all you need to know about the current state of your wireless adapter
The first command generates a MAC Address. I've hardcoded the first 6 characters of mine and randomly generate the remaining 6. It should generate a perfectly valid address but please post if it doesn't (or you have a better bash line).
The second sed command is to replace the MAC Address in the persisted wlan file. It's this command that needs to run as root.
You should be able to run these in something like Termux (make sure you're running as root by running "su" first). I actually run them using Tasker as "Code/Run Shell" commands.
Finally you need to enable then disable Airplane Mode for the change to take affect.
Here are the commands:
Code:
MAC=C0EEFB$(od -txC -An -N3 /dev/random| tr -d ' ')
Code:
sed -i "/Intf0MacAddress=/c\Intf0MacAddress=${MAC}" /persist/wlan_mac.bin
Code:
settings put global airplane_mode_on 1; am broadcast -a android.intent.action.AIRPLANE_MODE --ez state true
Code:
settings put global airplane_mode_on 0; am broadcast -a android.intent.action.AIRPLANE_MODE --ez state false
Code:
ifconfig wlan0 | grep HWaddr
Why don't you write a shell script that saves the old mac address to a text file and then create the new one. And each time the user executes the shell script to spoof the mac address it appends to the existing log file in a new line the old mac address before changed again. That was if you ever need to revert it, you can look at the log file.
BTW, thanks for the share!
bealer said:
Being overly paranoid I'm always trying to make it harder for companies to track my device. Anyway, my most recent discovery is spoofing the MAC Address on my 3T so that wifi companies can't track it.
Click to expand...
Click to collapse
Can't we just use this?
https://play.google.com/store/apps/details?id=eu.chainfire.pryfi
knpk13 said:
Can't we just use this?
https://play.google.com/store/apps/details?id=eu.chainfire.pryfi
Click to expand...
Click to collapse
I dont think that it will work since our devices are F2FS i saw this on reddit the other day.
using a custom mac address
Newbie here. Just wondering how I could use a specific mac address instead of a random generated number.
Thanks in advance.
m0d hippĀ„ said:
Why don't you write a shell script that saves the old mac address to a text file and then create the new one. And each time the user executes the shell script to spoof the mac address it appends to the existing log file in a new line the old mac address before changed again. That was if you ever need to revert it, you can look at the log file.
Click to expand...
Click to collapse
Yeah definitely things to improve,automating storing the original being one of them. I'll maybe follow up with that.
I didn't want to mask the main two commands too much with others around them. There are a few (older) ways to do this but this was the only way I could get it to work. And it's not a complete app/solution, more teaching a man to fish sort of thing.
knpk13 said:
Can't we just use this?
https://play.google.com/store/apps/details?id=eu.chainfire.pryfi
Click to expand...
Click to collapse
You can although
a) OP3T isn't listed as a supported device, I didn't try it
b) You can't automate it with that app very easily. Mine changes via Tasker state/events every day so I don't need to bother doing it myself.
gxyf106 said:
Newbie here. Just wondering how I could use a specific mac address instead of a random generated number.
Click to expand...
Click to collapse
Easiest way is just to change the first command and hardcode the MAC you want, ie
Code:
MAC=C0EEFB998877
Termux says
Sh: MAC: Not Found after running second command. Any idea what went wrong?
gxyf106 said:
Termux says
Sh: MAC: Not Found after running second command. Any idea what went wrong?
Click to expand...
Click to collapse
Ah oops, that's an error in me typing it out. The 2nd command should contain:
Code:
${MAC}
The brackets were causing it to try and evaluate MAC as a command (rather than a variable). I'll update the OP.
I can confirm this works. many thanks!!
Android is using randomized MAC adress when searching for wifi networks, this is not needed.
Michalko5896 said:
Android is using randomized MAC adress when searching for wifi networks, this is not needed.
Click to expand...
Click to collapse
As of 6.0 it was my understanding that Android uses a generated MAC for scanning/probing networks. But when actually making a connection, the real MAC is used (so as not to cause network issues). So this post is still relevant. I'm generating a new MAC every day or two as I use a number of public open wifi connections.
Also working on my hostname being random, and trying to stop all traffic on an open wifi network until my vpn is up.
Some might argue it's OTT, but I'd say it's just good practise (certainly the last point).
bealer said:
As of 6.0 it was my understanding that Android uses a generated MAC for scanning/probing networks. But when actually making a connection, the real MAC is used (so as not to cause network issues). So this post is still relevant. I'm generating a new MAC every day or two as I use a number of public open wifi connections.
Also working on my hostname being random, and trying to stop all traffic on an open wifi network until my vpn is up.
Some might argue it's OTT, but I'd say it's just good practise (certainly the last point).
Click to expand...
Click to collapse
Well, if you are concerned about your safety, don't connect to any Wi-Fi / BT devices that you don't trust.
Michalko5896 said:
Well, if you are concerned about your safety, don't connect to any Wi-Fi / BT devices that you don't trust.
Click to expand...
Click to collapse
The MAC address spoofing is more about privacy in terms of trying to be anonymous, making it *harder* to track where I connect etc...
Trust is a slightly more complex, non-binary issue.
bealer said:
The MAC address spoofing is more about privacy in terms of trying to be anonymous, making it *harder* to track where I connect etc...
Trust is a slightly more complex, non-binary issue.
Click to expand...
Click to collapse
MAC aadress is only used in local network, it does not go further than the very network you are connected to. What kind of advantage does MAC spoofing give you?
There's still your device ID, browser information and other stuff, that can actually reach the service you are connecting to.
Someguyfromhell said:
MAC aadress is only used in local network, it does not go further than the very network you are connected to. What kind of advantage does MAC spoofing give you?
There's still your device ID, browser information and other stuff, that can actually reach the service you are connecting to.
Click to expand...
Click to collapse
It stops wifi services tracking my phone. For example I use the wifi on the London Underground. Every time I connect to their wifi they'd know exactly where, when, how long, possibly my DNS requests just based on my MAC. It's all information that can be used for profiling or sold on (if that was part of the terms). They still may not known who I am exactly, but I'd rather they weren't able to identify/target me if it meant simply randomising my MAC. As mentioned Android already does this when scanning for networks.
Device Id isn't given, unless you mean hostname (which can be randomised too). If you're using HTTPS based websites then all browser traffic is encrypted via SSL. If you're not, then yeah it's possible to packet sniff your traffic (which is illegal), see what you're browsing, what your browser is, even part (but not all I believe) of your MAC etc...
Try Pry-Fi
Chainfire already has Pry-Fi for that. It has worked flawlessly for me.
first of all thank you for the commands but somehow this does not work with my Oneplus 3 (without T) on Sultans CM13. The address does not change after entering the commands, the commands do not show any error message.
Any advice?
Furthermore Pry-Fi seems to be able to change the MAC but it crashes sometimes and it seems to loose my saved WiFis. Furthermore i am not able to connect to my home AP after changing the MAC with Pry Fi. :-/
Someguyfromhell said:
MAC aadress is only used in local network, it does not go further than the very network you are connected to. What kind of advantage does MAC spoofing give you?
There's still your device ID, browser information and other stuff, that can actually reach the service you are connecting to.
Click to expand...
Click to collapse
Many public, free hotspots that require accepting terms on "walled garden" page today are tracking MAC address, DHCP-assigned IP address, and DHCP lease and active session time stamps. Example hotspots include Starbucks, hotels, etc. These hotspot network operator have logs to trace IPs back to MACs at a specific point in time until the logs are disposed.

Categories

Resources