ADP 1.6 - Kernel-UpdateHTC has signed the official image with wrong keys. See: http://groups.google.com/group/Android-DevPhone-Updating/browse_thread/thread/5b7c52f40d91d2ef It looks like that the new recovery (image/mode) operates with wrong keys. The only way to get this kernel-update installed (if you don't want to use fastboot) is to replace it. I've put a package together which helps to do that. It includes a recovery.img from cupcake (the one which was installed before). === AT YOUR OWN RISK === 1) You need to have "adb" in your PATH. adb is part of the Android-SDK (binary is located in "tools"-folder). 2) Download this package: replace_recovery.zip and extract it. 3) Execute "replace_recovery.bat" - Windows-users only (of course). => If you are using a Mac or Linux please follow instructions in "Linux_MAC_Howto.txt". ---- For ADP1.6 (Donut) ONLY! This kernel-update is for the OFFICIAL ADP1.6 FIRMWARE published by HTC only! You might have noticed that "Wifi Tether for Root Users" does not work anymore after updating your Android DevPhone 1 to ADP1.6 (donut) (official firmware from HTC). The new kernel does not support netfilter/iptables! To make our application run you have to replace the original kernel with our "netfilter-enabled" kernel. This kernel-update won't work correctly on other devices/firmwares. Don't apply this update on a HTC Magic for instance! ---- Instruction=== AT YOUR OWN RISK === 1) Install the official firmware (if not already installed) - ADP1.6 (donut) === MAKE SURE THE NEW FIRMWARE IS INSTALLED CORRECTLY === 2) Download the kernel-update from here 3) Copy adp-1_6-kernel-update.zip to you sd-card and rename it to "update.zip" 4) Reboot the device into recovery mode by holding down the HOME key during reboot. When the device enters recovery mode, it displays a "!" icon. 5) With the recovery console displayed, open the sliding keyboard and hold down the ALT+l key combination to enable log output in the recovery console. 6) Next, hold down the ALT+s key combination to install the update. An "installing update" icon and progress bar (or a similar status message) are displayed. When the progress bar completes, the installation is finished. 7) Press the HOME-BACK key combination to reboot. Enjoy! ---- SecurityThe kernel-update installs a su binary which is theoretically callable from any other installed application. If you want to close this "security hole" I recommend to install an application called "Superuser Whitelist" available here. I'm not sure under which license this app is distributed so I've decided to not include it in the kernel-update-package. |
Installed ADP1.6 and somehow lost root. Went to install this kernel update and it started installing and said "installation aborted". Now without root, I can't get back to a recovery image so I can restore my nandroid backups. Please help!
@mdfritz32: The stock ADP1.6 replaces the recovery-image by default! And the stock recovery-image does NOT support nandroid-backups. You don't lose root if you flash the ADP1.6. It's still there but /system/bin/su is missing. You are still root by using adb!
Type in a terminal (on your pc):
adb root
adb shell
(on the phone now - do what ever you want to do for example)
flash_image recovery /sdcard/recovery_i_want_to_install.img
The more interesting question is what kind of error did you receive when trying to apply my kernel?
@mdfritz:
and if flash_image is not found on your phone - you can still do it via fastboot:
fastboot erase recovery
fastboot flash recovery recovery_i_want_to_install.img
(see the htc-developer-site linked above on how to use fastboot. or google it.)
I just received the same error. I installed the ADP 1.6 image signed with the test keys that HTC put up on their site a day or two ago. They said that they signed the image with the wrong keys, and would release an update, so I wonder if that's the problem.
@gall.bladder: Oh ... thats the problem for sure! If the keys are not correct this update can't be applied. What I've done ... I've downloaded the package from htc, unzipped it (removed the recovery) and resigned the new zip. That's the reason why the kernel-update works for me and not for you ...
Do you have a link or something about the wrong keys htc has used?
Resigned the new zip? What can we do to make this new kernel update work?
I have the 1.6 update from HTC and recieve the same error trying to use this new tethering kernel. The log just says: Verifying update package... Installing update... Installation aborted.
It would be great if it were a little more informative.
@baffo32: since I don't know which keys were used by HTC there is not much I can do if you have already installed their update.
What you could do is to use the "fastboot"-method to install a new recovery-img. Then you have public known test-keys installed and the kernel-update will work.
What new recovery-img should I install?
There is some information at http://groups.google.com/group/Android-DevPhone-Updating/browse_thread/thread/54f7a05cc06c7072/7b7972ec6f1cad72 on the keysigning problem. Apparently new packages, which work more properly, were uploaded todayish, but they still are labeled as being test-key packages.
@baffo32: contact me via email and I will guide you how to do that.
Just wonder ... you guys have still root? Something like:
adb root
adb shell
id
gives an output like:
# id id uid=0(root) gid=0(root)
?
I still have root. I'm able to su in adb shell.
ok good. the flash_image command is not available ... right?
Yep. flash_image not found. I checked /system/bin, and it's not there.
I re-downloaded the recovery image just now from the HTC site, applied it, and tried to apply the adp-1_6-kernel-update.zip. It's still aborting.
I wonder if trying to install the recovery_testkeys.img from this page:
http://android-dls.com/wiki/index.php?title=Replace_Recovery_Partition
would work?
ah ... i think the problem is that the recovery is replaced with each reboot.
first do:
adb root
adb remount
adb shell
cat /system/etc/install-recovery.sh > /system/etc/install-recovery.sh.disabled
rm /system/etc/install-recovery.sh
cat /system/recovery-from-boot.p > /system/recovery-from-boot.p.disabled
rm /system/recovery-from-boot.p
Flash a recovery-image like before ... I would recommend this one (from cyanogen) - the one I'm using: http://n0rp.chemlab.org/android/cm-recovery-1.4.img
And ... if that works, try to apply the kernel-update.
I'm building my own 1.6 kernel and I have CONFIG_IP_NF_IPTABLES and CONFIG_IP_NF_IPTABLES set to Y, but its still not working.
Are there any other configuration options I need to enable for 1.6 kernel?
show log from the apk says
setting up firewall rules failed activating mac address control failed adding mac address for a allowed clients failed.
everything else succeeded.
thanks, Dave
I mean CONFIG_NETFILTER and CONFIG_IP_NF_IPTABLES of course..
@dwang5: yes, i've enabled a bunch of other kernel-options. here is the config: http://android-wifi-tether.googlecode.com/files/adp-1_6-kernel-config.gz
So I would just copy over the netfilter and ip_nf sections to my config?
@dwang5: i think so, yes.
Ok I did that but tethering still isn't working. Let me upload my config.gz and screen shot. I can't do it here. let create an issue.
Alright, I got it working!
The only issue is that the ADP 1.6 rom doesn't come with flash_image, so you have to get it out of the .zip of some other rom.
I used CyanogenMod? 4.0.3.1
So,
adb root adb remount adb push flash_image /system/bin/flash_image
copy the appropriate recovery image to /system/recovery.img
adb shell flash_image recovery /system/recovery.img
Reboot into recovery mode, apply update.zip, and you're good to go. I'm posting this while tethered right now.
gall.bladder: Could you please post a bit more detailed step by step instructions for somebody who has already updated to 1.6? What do you mean by "appropriate recovery image" ?
Thanks in advance
Hi harald,
I only installed new adp1.6 (the one supposed without problems) but when installing your kernel I also get the "installation aborted" message. Then running your application I get a message telling I have to be root to use the app.
Also note that with adp1.6 I still can be root uing adb but using the terminal emulator if I run the "su" command I get "su: uid 10025 not allowed to su". I wonder if this could also cause problems with your application.
@androidpwer: The app won't work without installing the kernel-update (which copies su-binary into /system/bin/ as well). When you have tried to apply the kernel-update did you get an message ... something like "verification failed"? If yes, it's exactly the problem mentioned above.
Otherwise please post your exact error-message.
Log message:
-- Install from sdcard... Finding update package... Opening update package... Verifying update package... Installing update... Installation aborted.
It's all I get. So doesn't seem to be the verification that fails.
Mmmmmhhh ... after gall.bladder replaced the recovery-image (which is responsible for doing the update) the update worked for him. So, I believe it's still a signature-problem of the orginial firmware.
To be honest ... I always take a look into firmwares before flashing - and this time I removed the radio- and recovery-image. :-). That's the reason why I had no problems ...
What you could do is to replace the recovery-image with "flash_image" (see gall.bladders-post) or use fastboot (depends on the SPL you have installed - original ADP?).
It's weird because I downloaded the images after JBQ from google confirmed the images are now OK on HTC site so the signature should be OK.
Anyway I did what gall.bladder did and now all also works for me, I can tether successfully with Android 1.6. Thanks harald and gall.bladder!
@androidpwer: which recovery.img have you used now?
@harald: The one you recommanded from cyanogen in a previous post of this thread.
@androidpwer: I think the recovery-img is reverted after each boot. So, could you please check that. Turn off you mobile and boot into recovery-mode by pressing "home" + "power". Is it still cyanogens-recovery?
Can you put ip-tables binary somewhere so I can copy it to my custom rom? the apk doesn't seem to copy it to /system/bin when I install the apk.
@harald: actually just before installing the kernel I tried and the cyaongen-recovery was reverted by the original recovery img after a reboot. But now after having successfully installed the kernel, I don't know why but it's still cyaongen-recovery.
If you are using an htc magic or mytouch3g, the iptables binary isn't in that build. You have to get it from the adp devphone rom and copy to your magic.
Once I did that, everything works.
Guys I have been trying for hours to get the freaking "flash_image" binary. I finally got it from some guy on irc and i put it in my system/bin folder and changed permissions. However when I try to execute it so that I can install cryogen's recovery image i get
# flash_image recovery system/recovery.img link_image1627?: 472 missing essential tablesCANNOT LINK EXECUTABLE
I'm really tired I think I'll just wait until you guys get the update to work with google's 1.6 recovery image _
After installing the official HTC 1.6 image signed with the wrong keys I too was stuck with
Here is how I finally managed to install adp 1.6
Some background first in case this does influence the outcome. I did fastboot install the system image before performing the following 3 steps. I'm not sure if that is relevant. Normally I use the recovery image but in desperation I started exploring
I used http://n0rp.chemlab.org/android/cm-recovery-1.4.img mentioned in a previous post
The steps are
Now reboot into recovery mode on the NEXT reboot. I found the recovery would switch back on a reboot as mentioned in a previous post. If you don't see Cyanogen's recovery menu then perform the fastboot steps again and make sure you go straight to recovery mode on the next reboot.
From cyanogens recovery install the update.zip via the menu. This installed without a hitch.
I then installed the tether app http://android-wifi-tether.googlecode.com/files/wireless_tether_1_60-pre3_htc.apk
I'm now happily tethering
thanks everybody for the helpful comments. The problem is that I was trying the fastboot command without going into fastboot mode before :) I think us novice users would appreciate it if you could write a bit more detailed instructions in the future. Thanks for a great app by the way!
The doc I worked off that explains fastboot mode is http://developer.htc.com/adp.html#s6 the fastboot executable can be downloaded from that link.
holding the back button on the android while rebooting puts the device into fastboot mode
./fastboot devices should report back with a device listed if not check your running fastboot as root ( or a user with sufficient permission to access the usb I think )
the adb command I use is part of the android 1.6 sdk http://developer.android.com/sdk/1.6_r1/index.html The adb executable is located in tools/ after you install the sdk. Same applies run adb devices to check your talking to the device.
another gotcha that tripped me up was
putting the android in debug mode so adb would talk to it. To do this
click menu button
select settings
select applications
select development
tick usb debugging
Now hopefully when you run adb devices you should see the device listed
Note: I not 100% certain about the need to run adb as root ( if your on linux ) I have had some different results with runing adb devices at any rate you need to see something like
I didn't know about fastboot either a few hours ago so bear that in mind when interpreting my instructions. I'm doing this brain dump from a n00bs perspective whilst its still fresh in my mind hopefully it will assist.
The adp-1_6-kernel-update file includes an unprotected su binary. For those running a Superuser.apk-protected su, delete the /system/bin/su from the zip and remove the relevant line from /META-INF/com/google/android/update-script.
@alan.blake I dont remember that usb debugging thing pre 1-6. I think it's a new thing. I used to be able to adb talk to my device without doing anything in particular.
I think your right about the usb debugging being new to 1.6. Apologies for any confusion.
Note that the OTA update to donut is not adequate for bypassing step 1 - or wasn't for me. I had the "adbd cannot run as root in production builds" problem. After installing the firmware from the website linked to in step 1, then doing the replace_recovery thing, then steps 2 to 7, it is working flawlessly for me. Yay & thanks so much!
Ok heres my problem after reading you guys post i really dont understand what to do to fix this problem. I still have root and since i cant flash any images to get my cyanogen recovery back i need some of you smart people to post a step by step tutorial on how to add the flash image file to our current roms so we can get back to Cyanogen recovery image. I already got the needed file on my computer to be pushed i just gotta understand how to do it.
Problem with the batch file:
remount failed: Operation not permitted failed to copy 'files_to_copy/flash_image' to '/system/bin/./flash_image': Read- only file system
Help?
answering myself: I had to upgrade adb since the version I had did not support the root command... Tethering now works. Thanks!!!
After first applying the replace_recovery.zip and then the adp-1_6-kernel-update.zip (as in the instructions) wifi-tethering now works!
Thank you.
I agree with the writer before me.
I did it this way. 1: upgraded to 1.6 2: applied replace_recovery.zip 3: applied adp-1_6-kernel-update.zip
It worked on the first try.
However it is still a bit unclear on this webpage (imho) if you need to apply replace_recovery.zip even after you downloaded the corrected 1.6 update. My experience is that you do.
Thanks, it works very well!
Can I replace The Kernel of my divice, SE Xperia X10i FW 023 rooted, with these files adp-1_6-kernel-update_usbtether_r3.zip. Thx.
Hello Everybody !
Just to help more newbies as me.
1 - Install the Android 1.6 here
http://developer.htc.com/adp.html
2 - Patch the kernel of the ADP 1.6 with replace_recovery.zip
AT YOUR OWN RISK
a) You need to have "adb" in your PATH. adb is part of the Android-SDK (binary is located in "tools"-folder).
b) Download this package: replace_recovery.zip and extract it.
http://android-wifi-tether.googlecode.com/files/replace_recovery.zip
c) Execute "replace_recovery.bat" - Windows-users only (of course).
3 - Update the ADP 1.6 with the adp-1_6-kernel-update.zip
AT YOUR OWN RISK
a) Install the official firmware (if not already installed) - ADP1.6 (donut)
MAKE SURE THE NEW FIRMWARE IS INSTALLED CORRECTLY
b) Download the kernel-update from here
http://android-wifi-tether.googlecode.com/files/adp-1_6-kernel-update_r2.zip
c) Copy adp-1_6-kernel-update.zip to you sd-card and rename it to "update.zip"
d) Reboot the device into recovery mode by holding down the HOME key during reboot. When the device enters recovery mode, it displays a "!" icon.
e) With the recovery console displayed, open the sliding keyboard and hold down the ALT+l key combination to enable log output in the recovery console.
f) Next, hold down the ALT+s key combination to install the update. An "installing update" icon and progress bar (or a similar status message) are displayed. When the progress bar completes, the installation is finished.
g) Press the HOME-BACK key combination to reboot. Enjoy!
Read all this page, you will understand better !
Thanks you for so great application. Now I can take hotel without wifi ! My android phone is my Wifi hot spot !
Cheers
I have read through this entire commentary as well as tried to follow the steps.
I am unable to install this though and here is why: 1) I downloaded the replace_recovery.zip pacakge, and executed "replace_recovery.bat": I get an "adbd cannot run as root in production builds" error.
2) I already have 1.6. I copy the kernel (renamed to update.zip) to my sd card. I reboot the device into recovery, and attempt to install the update. This is what I see: -- Install from sdcard... Finding update package... Opening update package... Verifying update package... E:No signature E:Verification failed Installation aborted.
Help please.
Hi I am a htc G1 1.6 drc92 user .I tried to update using ur file but I get an error about it only containing 7 files and then it aborts. What do I do?i I need the thether help me out, ps I do not have a pc now so I only use my g1 at the moment
I have the same issue as elemaeoh
Hi there, I've the same problem. My G1 keeps reporting that the verification failed... best, peter