Related
Hello all,
I'm currently sat with my VF-UK HTC Magic and want to start pulling this thing apart a bit if it'll be of use to the more experienced on here, although I'm not 100% where to start.
Below is a breakdown of where I am at the moment, can people please post with further suggestions and what files/dumps from the device you'd like to see etc.
With adb loaded into root mode: (adb root)
Code:
C:\android-sdk-windows-1.5_r1\tools>adb shell
# ls
ls
sqlite_stmt_journals
cache
sdcard
etc
system
sys
sbin
proc
logo.rle
init.sapphire.rc
init.rc
init.goldfish.rc
init
default.prop
data
root
dev
I am in the process to pulling off these files to package up for others etc. however not having a great deal of experience I'm looking for some pointers as to which bits to pull off and upload?
I'm also in the process to playing with SQLite. Which I've successfully got into but my SQl experience is based on MS SQL so again getting my head around this with a view to locating and extracting the operator setting files etc.
Any tips, requests to try on the device (within reason) etc. please post
Thanks
I'm not sure if the forum rules would allow it, but you would get a million more page views (and therefore help) if you post this at the Dream section instead. The Dream and the Magic/Sapphire is basically the same phone anyways, except for the keyboard (or lack thereof) so I don't see the harm.
Jethro - Should Vodafone staff really be asking questions like this?
Tell'em armholes Jethro.
P.S keep the emails coming, We love you up at 2nd Line
Why not? This is an open source device, only the SIM belongs to VF. As I am not decompiling the SIM or even the radio stack at this point everything I'm accessing is within my rights - at least this is my grasp of the licensing side. The Linux kernel is obviously open source and Android itself is released using the Apache License.
"Like any free-software license, the Apache License allows the user of the software the freedom to use the software for any purpose, to distribute it, to modify it, and to distribute modified versions of the software."
So as far as my understanding goes I'm not contravening any licensing or contract, if anyone can provide evidence otherwise then please post and I’ll stand corrected.
Otherwise I'm cracking on with more adb fun today!
@jbelman
source is free, but not compiled binaries, so you are not allowed to 'hack'.
Can anyone explain exactly why the actual compiled binary licensing model differs from the source code?
thevery said:
@jbelman
source is free, but not compiled binaries, so you are not allowed to 'hack'.
Click to expand...
Click to collapse
And who cares about this? It's my phone, so I can even throw it out of the window, if I want.
@jbelman
How did you get the root rights? If I run adb root, I get an error message, that the adbd daemon cannot run with root rights in production builds.
I did some research with adb shell before.
I haven't found any hole I could use to get root rights. Your shell runs with user and group "shell". All the data on the NAND-Flash (Apps and so on) are saved with the user and group "system" and you are not even allowed to enter this directory with another user.
The SD-Card is mounted nosuid and noexec. So we can't execute a local root exploit or something like this from here.
Breaking out of the Java VM is also not possible, because every Application runs with an own user. What would perhaps be possible is exploiting the VM (if there is a security vulnerability in it) and executing a local root exploit (if there is any available for this kernel) from there.
I'm currently waiting for the first update Vodafone delivers. I will sniff the download source of it and save it on my computer to have a backup if anything goes wrong when I'm playing with other firmware versions. I don't want to brick my phone.
@ Matschkeks1988
Are you using 1.1 or 1.5 SDK? I used 1.5.
I'm also a bit loath to really screw around until I've got a stable replacement image etc. should I brick it. Fingers crossed we can grab using update like you suggest.
By the way if anyone has any issues with adb giving: error: more than one device and emulator (I got this after using pull command). Disconnect your device and run: adb kill-server. This will remove all the devices, plug back in and away you go again.
I appear to have a different version baseband, kernel and build:
Baseband:
62.47S.20.17U_2.22.19.07I
Kernel version:
2.6.27-00342-g1936dcd
Build number:
CRA71C
What's everyone else on?
Version
Baseband version
62.50S.20.17U_2.22.19.261
Kernel version
2.6.27-00392-g8312baf
[email protected]) (gcc version 4.2.1) #72
Build Number
CRB17
Vodafone contract phone
Baseband version
62.50S.20.17U_2.22.19.26I
Kernel version
2.6.27-00392-g8312baf
[email protected] #72
Build number
CRB17
Baseband version
62.50S.20.17U_2.22.19.26I
Kernel version
2.6.27-00392-g8312baf
andr[email protected] #72
Build number
CRB17
uk vodafone contract
Looks like Jethro's device is from a different pot.
Which hardware revision do you have? Do you have search button? Who much onboard storage? All of these things changed through the development process.....
Baseband version
62.50S.20.17U_2.22.19.26I
Kernel version
2.6.27-00392-g8312baf
[email protected] #72
Build number
CRB17
Click to expand...
Click to collapse
Same here. SFR/Vodafone (France) contract. Search HW key variant.
Baseband version
62.50S.20.17U_2.22.19.26I
Kernel version
2.6.27-00392-g8312baf
[email protected] #72
Build number
CRB17
The same for VF Spain.
IseeBrickedPhones said:
Looks like Jethro's device is from a different pot.
Which hardware revision do you have? Do you have search button? Who much onboard storage? All of these things changed through the development process.....
Click to expand...
Click to collapse
The hardware is normal. The difference appears to be software only.
My info:
http://i42.tinypic.com/jf8acw.png
Vodafone Spain
jbelman said:
The hardware is normal. The difference appears to be software only.
Click to expand...
Click to collapse
Does this mean you do not have a retail Magic? Where did you buy it from?
Yes VF Retail.
I have spoken to VF about this today and they are looking into why it was shipped as the build is pre-release, as such I can't perform a wireless update.
VF won't release a update to flash over USB either, something to do with Google.
I'm going to have to get it exchanged. So will continue my research on this earlier build while I have it.
I have recently unwillingly upgraded from my Samsung Mesmerize I500.01 to the newer Samsung Mesmerize I500.04 in the process of reinstalling my OpenVPN client (the whole reason my company pays for me to have the phone). I discovered that the version of the tun.ko module i have will not work with the newer phone.
I have scoured the internet trying as many different versions of the tun.ko as i could and none will work they all fail with "failed (exec format error)".
After realizing there may not be a pre-compiled one available i moved on to trying to compile my own (which I've never done) . Now it seems as though not only is my directory layout a bit different but I'm missing key files that are referenced in the process ( config.gz ) and cannot find any how-to's that take into account the unique obstacles of this particular version of phone. Of course if someone has this exact same phone and a working module that would be great otherwise I'd love to get help compiling my own.
The Phone is Samsung Mesmerize SCH-I500.EC10 Kernel Version 2.6.32.9 (no additional subversion) Firmware Version 2.2.1
I downloaded a couple source versions off of the Samsung site that seem to be for this phone but I'm not sure exactly which one i should use.
I have experience in Linux but none in development/compiling.
Help would be very much appreciated. And i did search for 4 full work days before posting this thread.
-Jace
Solution Found
After much trial and error i finally managed to compile a working Kernel module for this phone. I will post it here so others with this model may use it.
I know this is an old thread ... but I'm now looking for tun.ko for 2.3.4 ...
Or instructions on compiling it my self ...
Thanks
compiling
Guidojones,
I bellieve i have a document that i made while compiling my tun driver that should be able to help you through the process. I will scour for it this evening and see if i can't come up with something for you.
-Jace
tinookoo said:
Guidojones,
I bellieve i have a document that i made while compiling my tun driver that should be able to help you through the process. I will scour for it this evening and see if i can't come up with something for you.
-Jace
Click to expand...
Click to collapse
Tinookoo,
Were you able to find the document for creating the tun.ko file? I am also interested in compiling it for 2.3.4.
Thank you,
craknjak
i am looking for new threads please help me to find new threads
Hello!
I'm very new to the android os and owner of an infuse (android 2.2.1, kernel version: 2.6.32.9, froyo.uckd5) since a couple of weeks.
Honestly I feel a bit lost because I'm looking for a tun.ko module for this device and as far as I can see there isn't, at least for the production rom. All the tun.ko I found are compiled for kernel different from mine.
I really need openvpn and now I'm wondering if I should:
1) keep looking
2) figure out how to compile a tun.ko on my linux machine for the arm7 architecture
3) look at some modified rom with the module built in
Do you have any suggestion?
Thank you
Cheers
dventurin said:
Hello!
I'm very new to the android os and owner of an infuse (android 2.2.1, kernel version: 2.6.32.9, froyo.uckd5) since a couple of weeks.
Honestly I feel a bit lost because I'm looking for a tun.ko module for this device and as far as I can see there isn't, at least for the production rom. All the tun.ko I found are compiled for kernel different from mine.
I really need openvpn and now I'm wondering if I should:
1) keep looking
2) figure out how to compile a tun.ko on my linux machine for the arm7 architecture
3) look at some modified rom with the module built in
Do you have any suggestion?
Thank you
Cheers
Click to expand...
Click to collapse
3) As far as I can tell, all of the alternative kernels have this module. The Infused ROM contains the Voodoo kernel, but I believe you can run the Voodoo or Infusion kernels on the stock ROM.
ok I see.
Could you suggest to me a starting point to deal with the custom roms?
I'm have a good experience with linux since years but not enough on smart phones and android in general.
For instance, is there an official website for Infused ROM?
Any tip is welcome.
Thank you!
@dventurin - I had the same issue. I have the Infused rom installed and it has the same issue. I installed SL4A and wrote my own scripts, the app is what's broke everything works at the CLI. I then used Tasker but I think you can do it with Gscripts as well build my own shortcuts. As for where to find the Infused ROM look in the Dev section here. There a several ROM's available but I've only used Infused.
@3GBeyotch
were did you get the Infused rom? Is there an official website with documentation? Honestly I don't feel comfortable when I have to use stuff found on a forum: how can I trust them?
dventurin said:
were did you get the Infused rom? Is there an official website with documentation? Honestly I don't feel comfortable when I have to use stuff found on a forum: how can I trust them?
Click to expand...
Click to collapse
If you want the Infused ROM, head over to the "Infuse 4G Android Development" forum....
http://forum.xda-developers.com/forumdisplay.php?f=1161
From there, you will want to look at 2 threads....
1. You need to root your device first. Check out the very first thread (entitled: [How To] Root the Samsung Infuse 4G) shows how to root your device.....
http://forum.xda-developers.com/showthread.php?t=1082247
(the second link under SOURCE: has a video tutorial)
Side note: When downloading Superoneclick, make sure to get the one that has the drivers included. Also, make sure your external SD card is unmounted!
======================
2. Next, you'll need to install the Infused ROM. Look at the thread (entitled: [ROM] Infused v1.5.0 - (06/18/11) - Faster and smoother than ever!), which has the instructions, etc, for installing the Infused ROM.....
http://forum.xda-developers.com/showthread.php?t=1105413
You basically need to root your device first, then install the Infused ROM.
As far as feeling comfortable with using the sources from the forum, you have nothing to worry about. In regards to the Infused ROM, gtg465x is the one who developed it. All you have to do is follow the instructions, and if you feel uncomfortable about doing one of the steps, ask someone here!
I've had the Infused ROM installed now for a few weeks, and I have not been disappointed! Hope this helps.
Open VPN on Infused ROM tun.ko problems?
Greetings! This discussion is about what I am trying to solve, so I decided to post here. I have searched and read other threads, but can not figure out a solution. I am a noob in this.
Anyway, I also would like to make OpenVPN working on my Samsung Infuse.
I have rooted it, installed the Infused ROM Version 1.5.3 (awesme!)
About Phone gives me the following info:
Firmware version 2.2.1
Baseband version i997UCKE3
Kernel version 2.6.32.9
Build number Infused v1.5.3
No the problem. I have openvpn installed with OpenVPN Installer. My config, key, certificate files are in /sdcard/openvpn folder. Everything seems okay.
When I try to connect to my router at home, however, the tun.ko module would not load. It gives an error. I even tried to load it manually from the Terminal Emulator (insmod /system/lib/modules/tun.ko) It gives me an error still. The module file is in the folder.
What am I doing wrong? Has anyone been able to make openvpn work on the Infused ROM?
I had the same problem on the original AT&T ROM, but that one did not have the tun.ko at all, so it was understandable.
I would appreciate any suggestions.
Thank you in advance.
iovchinn said:
Greetings! This discussion is about what I am trying to solve, so I decided to post here. I have searched and read other threads, but can not figure out a solution. I am a noob in this.
Anyway, I also would like to make OpenVPN working on my Samsung Infuse.
I have rooted it, installed the Infused ROM Version 1.5.3 (awesme!)
About Phone gives me the following info:
Firmware version 2.2.1
Baseband version i997UCKE3
Kernel version 2.6.32.9
Build number Infused v1.5.3
No the problem. I have openvpn installed with OpenVPN Installer. My config, key, certificate files are in /sdcard/openvpn folder. Everything seems okay.
When I try to connect to my router at home, however, the tun.ko module would not load. It gives an error. I even tried to load it manually from the Terminal Emulator (insmod /system/lib/modules/tun.ko) It gives me an error still. The module file is in the folder.
What am I doing wrong? Has anyone been able to make openvpn work on the Infused ROM?
I had the same problem on the original AT&T ROM, but that one did not have the tun.ko at all, so it was understandable.
I would appreciate any suggestions.
Thank you in advance.
Click to expand...
Click to collapse
What's the error?
Entropy512 said:
What's the error?
Click to expand...
Click to collapse
OpenVPN Settings gives the following error: "FATAL: Cannot allocate tun/tap dev dynamically".
When I run "insmod /system/lib/modules/tun.ko" it gives me: "Failed (Exec format error)
Again, thank you for your response.
iovchinn said:
OpenVPN Settings gives the following error: "FATAL: Cannot allocate tun/tap dev dynamically".
When I run "insmod /system/lib/modules/tun.ko" it gives me: "Failed (Exec format error)
Again, thank you for your response.
Click to expand...
Click to collapse
out of curiosity, is there also a tun.ko in /lib/modules in addition to /system/lib/modules?
Entropy512 said:
out of curiosity, is there also a tun.ko in /lib/modules in addition to /system/lib/modules?
Click to expand...
Click to collapse
Man, my hat is off!
Indeed, there is one in /lib/modules and it did work when I tried to load it, instead of the one in /system/lib/modules/. Any idea, why the other one did not work? Not that it matters now.
Also, your signature says that you run Cyanogen Mod with Infuse. My understanding was that Infuse was not yet supported. Is it easy to install it? Any published instructions?
Again, thanks a bunch for the tip.
iovchinn said:
Man, my hat is off!
Indeed, there is one in /lib/modules and it did work when I tried to load it, instead of the one in /system/lib/modules/. Any idea, why the other one did not work? Not that it matters now.
Also, your signature says that you run Cyanogen Mod with Infuse. My understanding was that Infuse was not yet supported. Is it easy to install it? Any published instructions?
Again, thanks a bunch for the tip.
Click to expand...
Click to collapse
My guess is in your previous attempts to add a tun.ko module, you stuck one in /system/lib, or maybe gtg accidentally included some "cruft" in /system/lib that shouldn't be there.
As to CM7 - Right now it's a source-only unofficial build, links to the git repo are in the Development section. There are occasionally binary releases floating around, however not anywhere on these forums. Good things come to those who expand their horizons and do research.
Entropy512 said:
My guess is in your previous attempts to add a tun.ko module, you stuck one in /system/lib, or maybe gtg accidentally included some "cruft" in /system/lib that shouldn't be there.
As to CM7 - Right now it's a source-only unofficial build, links to the git repo are in the Development section. There are occasionally binary releases floating around, however not anywhere on these forums. Good things come to those who expand their horizons and do research.
Click to expand...
Click to collapse
It seems, you are right. /system/lib/modules/ has only one file in it and it is tun.ko. That one did not load. Must be some left-overs from previous reincarnation. The one in /lib/modules/ has lots of different *.ko files and tun.ko among them. This one loads just fine.
Again, thank you very much for your help.
Entropy512 said:
My guess is in your previous attempts to add a tun.ko module, you stuck one in /system/lib, or maybe gtg accidentally included some "cruft" in /system/lib that shouldn't be there.
As to CM7 - Right now it's a source-only unofficial build, links to the git repo are in the Development section. There are occasionally binary releases floating around, however not anywhere on these forums. Good things come to those who expand their horizons and do research.
Click to expand...
Click to collapse
By the way. Perhaps, I can get a bit more help with this. My joy was short-lived. My Infuse connects to my Tomato - no problem. However, it does not force traffic to the VPN tunnel. It is still using whatever service I connect: Wi-Fi, or Cell Provider's.
Any hints on how to fix it? I tried the "Fix HTC Routes" option in "OpenVPN Settings." No luck.
I would appreciate some help.
iovchinn said:
By the way. Perhaps, I can get a bit more help with this. My joy was short-lived. My Infuse connects to my Tomato - no problem. However, it does not force traffic to the VPN tunnel. It is still using whatever service I connect: Wi-Fi, or Cell Provider's.
Any hints on how to fix it? I tried the "Fix HTC Routes" option in "OpenVPN Settings." No luck.
I would appreciate some help.
Click to expand...
Click to collapse
Unfortunately someone else will have to help you there - I haven't used VPN functions on my phone.
iovchinn said:
By the way. Perhaps, I can get a bit more help with this. My joy was short-lived. My Infuse connects to my Tomato - no problem. However, it does not force traffic to the VPN tunnel. It is still using whatever service I connect: Wi-Fi, or Cell Provider's.
Any hints on how to fix it? I tried the "Fix HTC Routes" option in "OpenVPN Settings." No luck.
I would appreciate some help.
Click to expand...
Click to collapse
Having the same problem, am able to connect to openVPN running on ddwrt but the phone isn't directing traffic through it. Anyone have any ideas?
Does the OS itself include a text editor? I want to be able to ssh into my phone (a Samsung Galaxy SII running stock 2.3 if it's in any way relevant) and edit configuration files on the command line.
I have already installed an ssh server and have poked around in the OS and the only option I could find was sed which, although excellent for its intended task, is far from user friendly for editing config files.
I'm not surprised that there is no emacs, or even vi (my favourite) but I thought that at least ex would be available.
Just to make it absolutely clear, I am not looking for a marketplace type app, I am looking for command line editor within the OS itself.
lotus49 said:
Does the OS itself include a text editor? I want to be able to ssh into my phone (a Samsung Galaxy SII running stock 2.3 if it's in any way relevant) and edit configuration files on the command line.
I have already installed an ssh server and have poked around in the OS and the only option I could find was sed which, although excellent for its intended task, is far from user friendly for editing config files.
I'm not surprised that there is no emacs, or even vi (my favourite) but I thought that at least ex would be available.
Just to make it absolutely clear, I am not looking for a marketplace type app, I am looking for command line editor within the OS itself.
Click to expand...
Click to collapse
If you root, you can install busybox, which includes vi.
Excellent, that's what I needed to know.
I thought busybox was already installed because I remember seeing all the binaries in /system/bin linked to the same binary but having checked I see it's something called toolbox, which is presumably something similar but not as good.
Since I had already rooted my phone and in the process, installed busybox, I thought I was home and dry.
Unfortunately, when I tried running busybox, it appears that it doesn't include vi or at least the version I have doesn't.
Code:
# busybox vi
vi: applet not found
It looks like my problem is still unsolved after all .
Root Checker will verify if it's installed correctly. Advanced mode will list all the commands included. You can use this to install or update it.
Thanks for your help. The first app verified that I do have busybox installed but as I thought, my version doesn't include vi.
The second suggestion did try to install a newer (and more complete) version of busybox. It didn't appear to succeed but I'm reasonably confident of being able to debug this myself without further help.
I finally found a fix for wired tethering in Linux
A few of you may know that, for some reason, USB tethering with Linux stopped working after the update to Gingerbread. It still works with Windows, but Linux shows a 'bad crc' error in dmesg when USB tethering is activated. But someone figured out a fix, which I finally found and tested. I can confirm that it works with CM7 beta 2 using the built-in tethering option (and I am using it to write this post). The website where I found the patch did not mention what rom it was tested with, but since the patch is for a Linux module on the computer, it most likely won't matter.
Here is the website where I found the instructions - note that you will need to download the patch file, and make sure you have the Linux kernel source (that should be standard, but if you get an error about missing files...). Finally, be sure to pay attention to the punctuation used - code portions containing `uname -r` and M=`pwd` are NOT using the single quote - they are using the symbol located with the ~ (tilde) symbol, and this is extremely important. Anything contained in those symbols will be replaced with their output before execution of the command that contains them - similar to the use of parentheses in algebra.
The command uname -r returns the current kernel revision number, which is used to dynamically direct the commands to the most current source code.
`pwd` resolves to the Present Working Directory
If you prefer a more automated method, I have created a script that follows the commands from the above website, and packaged it with the patch file. Just extract both files into $HOME/Downloads (your Download directory in your home path), and run ./linux-rndis-patcher.sh - you may need to sudo chmod 0755 linux-rndis-patcher.sh first
I hope others find this as useful as I have. I take no credit - my contribution, the script, is a basic copy-and-paste job (tested and confirmed to work on the originating computer).
Update: the process works for the newer 3.2.0 kernel included in Linux 12.04, with slight modifications to match an updated directory structure in the source package. I updated my linux installation only to find that the old problem had returned. I am attaching a copy of the updated script - you can run it (make sure the patch file is in the correct directory) or simply use it as a command list.
Also, I should point out that this does not patch your kernel - it builds a patched stand alone module that can be used to override the built in version. This means it is easy enough to revert the process - more information is contained in the ubuntu wiki linked to from the site where I found the original information
Dude you are awesome, thank you for this!
Sent from my SPH-D700 using xda premium
Minor Correction
Well, I just realized that the script for 3.2 kernels didn't upload, but I can't get to my computer to fix that right now... so in the meantime, anyone who has upgraded to the 3.2 kernel can edit the 3.0 script
Two paths explicitly link to 3.0 directories, the just need to be changed to 3.2
Also, the path within the source code tree has changed - I will edit this post with the correct path momentarily, so stay tuned...
EDIT: I'm not sure what I was thinking about the path, but everything should be fine once both instances of "linux-source-3.0.0..." are edited to "...source-3.2.0"
Oh, and I renamed the patch file, so be sure to use the correct filename based on whether you download directly from the source or use the copy in my upload (identical aside from the filename)
Sent from my SPH-D700 using XDA
To clarify the bug here, the problem is that the Samsung Gingerbread USB gadget stack misspecifies a USB CDC union descriptor configuration that doesn't match what the device actually uses in RNDIS mode.
Windows, apparently, either ignores or doesn't care about the misconfiguration. Linux, while it's capable of detecting RNDIS interfaces in the absence of a CDC union description entirely, is "too strict" when the configuration is misspecified. So this patch makes Linux less strict in this regard.
So in short, the actual bug is in the device's kernel. But since RNDIS behavior is pretty much defined as "whatever Windows tolerates", it's reasonable and prudent to fix it on Linux USB hosts as well.
In any event, there's a few patches floating around for custom kernels to fix this problem on the device side, which is preferable as we don't really want to have to patch every Linux machine out there to deal with this issue. The one that we implemented for the CM9 kernel is here, and should've been included in our CM9 builds since alpha3 I believe.
Too true, I just haven't gotten around to figuring out how to patch the CM7 kernel yet so this works for me. Thanks for explaining the bug, so others will be aware that this is a workaround, not really a fix... I'll change the thread title, now that I think about it
Sent from my SPH-D700 using XDA
Yeah, there's a few changes in the CM9 kernel that need to be backported to CM7. Tortel is working on that now actually, so hopefully the next CM7 release will include the RNDIS fix among others.