webOS Nation Forums >  webOS apps and software >  webOS development > Post OS1.04 - pinging 'the collective' for new install method
Post OS1.04 - pinging 'the collective' for new install method

  Reply
 
LinkBack Thread Tools Display Modes
Old 06/29/2009, 04:59 PM   #1 (permalink)
Member
 
Join Date: Jun 2009
Location: kansas city, mo
Posts: 633
Likes Received: 0
Thanks: 85
Thanked 303 Times in 146 Posts
Default Post OS1.04 - pinging 'the collective' for new install method

Update: We have a method working thanks to greg roll. This method is much easier than all of the initial installation steps for the SDK method.

Here are detailed instructions...
http://www.webos-internals.org/wiki/...talling_An_Ipk

See post for other methods that could still be pursued.

Original initiative posted...

Quote:
Ping

xorg@borg:/# ping thecollective.borg.com

Pinging the collective for a new mission. The United Federation of Palm has plugged the email link method for installing apps with webOS 1.04. The new mission is to find another way to load apps on a stock Pre w/out needing to use the SDK or rooting the phone. For those fully assimilated, share your ideas with the collective and let's operate as a single hive mind.

Hella lame, enough of that, on to the good stuff…


Purpose
Provide homebrewers a way to widely distribute apps, allowing easy install for the average consumer. The rooting and SDK methods are not exactly consumer oriented.

Goal
- Create a simple, consumer friendly, more secure way to load apps on a stock Pre
- Pre must be non-rooted
- No SDK installation (though simplifying that method could be a start)


Ideas to Explore...

Mimic the SDK install method w/out SDK
greg_roll discovered that the SDK method pushes this command with palm-install...

luna-send -i palm://com.palm.appinstaller/installNoVerify '{"target": "/media/internal/developer/FILENAME.ipk", "subscribe": true}'

More here. I dropped an ipk in /media/internal/developer (the USB drive) and ran this command from root and it installed.

Perhaps this command can be executed with webOS Doctor only installed or maybe with just 3rd party novacom drivers. The curious thing about webOS Doctor is that it doesn't require Dev mode ('roar' pointed this out).

Update: We essentially have this working thanks to greg. Is much easier than all of the initial installation steps for the SDK method. See page 10 of this thread.

Here are detailed instructions...
http://predev.wikidot.com/installing...st-1-04-update


Loading via USB drive, triggered by external web page
Could an external web page be created that uses a <script> tag to reference JavaScript and execute an SDK installer command against an ipk that exists in /media/internal (the usb drive)? Or execute a provided shell script that the user puts in the usb drive with the ipk? The luna command above could then be pushed. I'm a unix/linux guy, not a web developer.

The user experience would then be to copy the ipk to the USB drive (with sh script if needed) and then visit a web page to complete install.

BTW, I also experimented with trying to trigger things in the web browser with file:///media/internal/index.html and the like with no luck. Browser doesn't appear to support it. Also tried palm:// commands. No luck so far but it could probably be looked into further.

Spoof download of real app
When downloading an app from the app store, it temporarily places the .ipk file in /media/internal/downloads, which is also accessible from the USB drive. When the file download completes, it unpackages in the same dir with a subdir of _tmp*(package name). Watch this folder while downloading an app from the app catalog. Also check out /var/log/messages for hints with what is going on.

I've been tinkering with placing a homebrew app in place of the original .ipk as well as in the _tmp dir. The Pre will overwrite the files no matter the permissions, but this is still worth looking further into. There are several challenges to this, but worth exploring more.

Look for USB folder
Look for code in the OS that may already allow loading apps if dropped in some USB folder that may not exist yet.

Spoof a valid resource ID to launch an ipk package
Check out /usr/palm/command-resource-handlers.json , which launches apps based on file extension or commands. While likely a stretch, if you rename a .ipk with the extension of an app that launches, maybe there is a way to get the launching app to trigger an install.

Tools
To search for a string through entire system...
find / -type f -exec grep -l "searchstring" {} \;

Or from directory you are standing in...
find . -type f -exec grep -l "searchstring" {} \;

To search files by file name...
find / -name "filename" -print

Check logs for clues when researching how something behaves...
/var/log (especially messages and installer.log, use 'tail -f' command to watch live)

The Collective
Please post your ideas for any of the above or any new approaches. If we operate as a hive, a collective with a single mind, we can get it done. Healthy, half-glass full collaboration and experimentation is key. You will be credited for any breakthrough that leads to a solution.

Attention Palm
I intend to keep this white hat and completely in the open. By placing in a public forum, all ideas will be known to you. PM me if you have a comment on the effort. I have sent an email to webos-security@palm to inform Palm this effort is in progress. - xorg

Attention Contributors
I have been in contact with Palm and they are aware of this initiative (and likely monitoring this thread). They seem to be OK with it as long as we keep it white hat. Please follow white hat guidelines if you want to participate. Also lookup responsible disclosure, which I've been trying to follow by making all ideas available to Palm as they progress.

Hopefully we'll find a way that allows apps to be very easily installed and requires a conscious effort by the end user, therefore being relatively more secure than the email link method. Maybe we can find the right balance of liberty and security that works effectively for Palm, end users/consumers and homebrewers.

In the meantime, for those who want to load apps via the SDK, here is that method...
http://forums.precentral.net/web-os-...pre-howto.html

Edit:
Also being tracked on the Dev Wiki...
pre dev wiki: Installing Apps on a Stock Pre (post 1.04 update)

Last edited by xorg; 07/23/2009 at 09:43 AM.
xorg is offline   Reply With Quote
Old 06/29/2009, 05:13 PM   #2 (permalink)
Member
 
Join Date: Jun 2009
Posts: 28
Likes Received: 0
Thanks: 0
Thanked 1 Time in 1 Post
Default

As i posted in the old homebrew thread, with a rooted pre you can...

Simply, use ar to extract the ipk - then extract the data.tar.gz, cd into the usr/palm/applications dir, then using your rooted pre with ssh and sftp, copy recursively the (in the case of the translator app) de.umass.translate directory to your pre's /usr/palm/applications directory.
xstaticxgpx is offline   Reply With Quote
Old 06/29/2009, 05:18 PM   #3 (permalink)
Member
 
SirWill's Avatar
 
Join Date: Jun 2009
Location: Everett, WA
Posts: 441
Likes Received: 0
Thanks: 63
Thanked 48 Times in 41 Posts
Default

Quote:
Originally Posted by xstaticxgpx View Post
As i posted in the old homebrew thread, with a rooted pre you can...

Simply, use ar to extract the ipk - then extract the data.tar.gz, cd into the usr/palm/applications dir, then using your rooted pre with ssh and sftp, copy recursively the (in the case of the translator app) de.umass.translate directory to your pre's /usr/palm/applications directory.
There are many ways of installing on a rooted pre. I think what the community is after a way for homebrew to be sideloaded without rooting ones pre.
SirWill is offline   Reply With Quote
Old 06/29/2009, 05:18 PM   #4 (permalink)
Member
 
Join Date: Jun 2009
Location: kansas city, mo
Posts: 633
Likes Received: 0
Thanks: 85
Thanked 303 Times in 146 Posts
Default

Yes, the goal is do this on non-rooted Pre and without the SDK. The purpose is to allow homebrewers distribute apps for a stock Pre with no mods.
xorg is offline   Reply With Quote
Old 06/29/2009, 05:21 PM   #5 (permalink)
Member
 
Join Date: Jun 2009
Posts: 28
Likes Received: 0
Thanks: 0
Thanked 1 Time in 1 Post
Default

I understand that, but it's so ridiculously easy to root the pre and you have so many benefits why would anyone not want to do it?
xstaticxgpx is offline   Reply With Quote
Old 06/29/2009, 05:24 PM   #6 (permalink)
Member
 
Join Date: Jun 2009
Location: kansas city, mo
Posts: 633
Likes Received: 0
Thanks: 85
Thanked 303 Times in 146 Posts
Default

^That's not a consumer friendly method.
xorg is offline   Reply With Quote
Old 06/29/2009, 05:25 PM   #7 (permalink)
Member
 
Blubble's Avatar
 
Join Date: Jun 2009
Location: Silicon Valley, California
Posts: 1,025
Likes Received: 0
Thanks: 37
Thanked 444 Times in 161 Posts
Default

Regardless of how easy you think it is, the vast majority of users won't root their Pres. I have heard that it will void your warranty although I am not sure that it's true.

Heck, I am a software developer and I haven't rooted mine and don't plan to do so. I am happy to use the palm-install from the SDK.
Blubble is offline   Reply With Quote
Old 06/29/2009, 05:35 PM   #8 (permalink)
Member
 
SirWill's Avatar
 
Join Date: Jun 2009
Location: Everett, WA
Posts: 441
Likes Received: 0
Thanks: 63
Thanked 48 Times in 41 Posts
Default

Another reason for not rooting would be a developer who wants to sell an application that for what ever reason Palm will not put in the app store. They should have a easy way of distributing the application.

I feel that the most secure way of offering the loading of software would be USB. Another thought would be possibly a USB one time load of an application that in itself would be Homebrew Catalog that would allow you to download from a catalog via wireless.

The downside to that method would be having to maintain a public software repository. It wouldn't have to host the software but rather it would be a link essentially that would transfer it from the developers hosting.

Maybe the application could be configurable for 'Sources' Either way, you have to find a way to get any application on to the device.
SirWill is offline   Reply With Quote
Old 06/29/2009, 05:37 PM   #9 (permalink)
Member
 
Join Date: Oct 2007
Posts: 534
Likes Received: 0
Thanks: 18
Thanked 16 Times in 11 Posts
Default

i was just grep'ing around and found ApplicationPath=* in /etc/palm/

has anyone tried changing that to something within /media/internal/ ? I'm working right now or i'd give it a shot
__________________
http://phwelo.mobi
for any questions or to send a donation: phwelo@gmail.com
phwelo is offline   Reply With Quote
Old 06/29/2009, 05:44 PM   #10 (permalink)
Member
 
Join Date: Jun 2009
Location: kansas city, mo
Posts: 633
Likes Received: 0
Thanks: 85
Thanked 303 Times in 146 Posts
Default

^Yes, I've done that (dsevil posted about it) but obviously the Pre must be rooted to add the additional path. The goal is to find something in the existing OS that we can utilize.
xorg is offline   Reply With Quote
Old 06/29/2009, 05:48 PM   #11 (permalink)
Member
 
Join Date: Oct 2007
Posts: 534
Likes Received: 0
Thanks: 18
Thanked 16 Times in 11 Posts
Default

ah and here i am searching for the easiest option for myself, sorry
__________________
http://phwelo.mobi
for any questions or to send a donation: phwelo@gmail.com
phwelo is offline   Reply With Quote
Old 06/29/2009, 05:49 PM   #12 (permalink)
Member
 
Join Date: Oct 2007
Posts: 534
Likes Received: 0
Thanks: 18
Thanked 16 Times in 11 Posts
Default

has anyone who's done this browser download hack tried downloading a signed ipk? what are the results of that? i wonder if once palm implements browser downloads we might be able to "side load" them like that..
__________________
http://phwelo.mobi
for any questions or to send a donation: phwelo@gmail.com
phwelo is offline   Reply With Quote
Old 06/29/2009, 05:54 PM   #13 (permalink)
Member
 
NoRemorse's Avatar
 
Join Date: Apr 2009
Posts: 119
Likes Received: 0
Thanks: 10
Thanked 19 Times in 12 Posts
Default

Why not just make a user friendly front end to browse a folder for packages, then envoke the 'palm-install -d usb [DIR]' command, to push an unsigned app to the phone that is in dev mode?

Of course the end user would have to be responsible for getting the palm SDK/palm-install.

Just an idea... It's easier than rooting the phone, and can't really be shut off by Palm as it's how developers use the phone to test applications.


Hell, I might write an application like that, because it's easier than using the CL to package/install.

It's also slightly a pain that Eclipse will generate a project and the structure, but not a new scene. typing 'palm-generate -f new_scene -d "name=HELL" ./again' over and Over and OVER.

I'm just ranting now.

EDIT:

Ahh, you said with out the SDK, so you're gonna need to find out what exactly palm-install does, and how to mimic it.
NoRemorse is offline   Reply With Quote
Old 06/29/2009, 06:45 PM   #14 (permalink)
Member
 
Join Date: Jun 2009
Location: Germany
Posts: 122
Likes Received: 0
Thanks: 13
Thanked 395 Times in 32 Posts
Default

does the palm-install routine work with non rooted phones? because the procedure palm-install invokes is fairly trivial.
roar is offline   Reply With Quote
Old 06/29/2009, 06:50 PM   #15 (permalink)
Member
 
sacherjj's Avatar
 
Join Date: Jun 2009
Location: Indianapolis, IN
Posts: 1,686
Likes Received: 0
Thanks: 41
Thanked 365 Times in 215 Posts
Default

The install method from the SDK uses Java programs to handle the process. Unless code was written to perform the same function, or Palm gave their blessing for distributing a palm_install SDK-lite, this would not be a possible route. This also has the problems of average users getting into Dev mode and then remembering to get back out.

I guess capturing the USB exchange might give some details as to the low level actions of a NovaCom install process.
sacherjj is offline   Reply With Quote
Old 06/29/2009, 07:00 PM   #16 (permalink)
Member
 
Join Date: Jun 2009
Location: Germany
Posts: 122
Likes Received: 0
Thanks: 13
Thanked 395 Times in 32 Posts
Default

how do you put a phone in dev mode?

edit: found it: "upupdowndownleftrightleftrightbastar" so you can't do that remotely (say from an app on your pc) and the palm-install routine won't work unless the phone is in dev mode, as far as I understood. So it would be no problem to write an app that does the same what palm-install does, but it's useless for anyone who isn't eager to switch to this dev mode and back again...

Last edited by roar; 06/29/2009 at 07:12 PM.
roar is offline   Reply With Quote
Old 06/29/2009, 07:31 PM   #17 (permalink)
Member
 
sacherjj's Avatar
 
Join Date: Jun 2009
Location: Indianapolis, IN
Posts: 1,686
Likes Received: 0
Thanks: 41
Thanked 365 Times in 215 Posts
Default

Quote:
Originally Posted by roar View Post
but it's useless for anyone who isn't eager to switch to this dev mode and back again...
Correct. Plus you have the added problem of Dev mode opening up a bunch of ports which can cause issues. This could open up security risks if the users don't disable dev mode, which doesn't automagically happen with a reboot.
sacherjj is offline   Reply With Quote
Old 06/29/2009, 08:17 PM   #18 (permalink)
Member
 
Join Date: Jun 2009
Posts: 14
Likes Received: 0
Thanks: 1
Thanked 2 Times in 2 Posts
Default

Anyone looked at the DocView app? any possible methods of making a call? how about PDF View? any Java support from within there? I'm going to start digging myself, after I finish checking everything out after the 1.0.4 upgrade.
PreNomadBrad is offline   Reply With Quote
Old 06/30/2009, 07:31 AM   #19 (permalink)
Member
 
Join Date: Jun 2009
Location: kansas city, mo
Posts: 633
Likes Received: 0
Thanks: 85
Thanked 303 Times in 146 Posts
Default

^Good idea, something to check into.

I'm looking more into spoofing a download.

Simplifying the SDK method might be the shortest path if someone could look more into that. Sounds like it would require the nova drivers as well though for Dev mode. Could grep system for konami code and trace path from there to get some ideas.

How to search entire system for a string...
find / -type f -exec grep -l "upupdowndown" {} \;
xorg is offline   Reply With Quote
Old 06/30/2009, 08:18 AM   #20 (permalink)
Member
 
Join Date: Jun 2009
Location: kansas city, mo
Posts: 633
Likes Received: 0
Thanks: 85
Thanked 303 Times in 146 Posts
Default

Am hoping to have a method more consumer friendly than the SDK method but let's talk about minimum requirements to go down that path (as noremorse suggested) and simplify it...

- need to punch in konami code, enable Dev mode and reboot
- need novacom drivers
- need similar install.bat method

Any other minimum requirements? If we create a gui-based install program for windows/mac that includes the drivers and performs same function of the palm_install bat, this could simplify app installation for users instead of having to load and setup the SDK. Bypassing the nova drivers would be even better if possible.

This could be a path of least resistance for a consumer friendly method until coming up with a better method that needs no mods on a stock Pre.

Last edited by xorg; 06/30/2009 at 01:03 PM.
xorg is offline   Reply With Quote
Reply

 

Thread Tools
Display Modes


LinkBacks (?)
LinkBack to this Thread: http://forums.webosnation.com/webos-development/189497-post-os1-04-pinging-collective-new-install-method.html
Posted By For Type Date
Forums webOS &bull; View topic - Vista x64 USB Installation Problems [resolved] This thread Refback 07/21/2009 12:37 PM
Tutorials webOS Installing An Ipk - WebOS Internals This thread Refback 07/19/2009 05:57 PM
WebOS installer 非官方推出 - Palm Web OS - MAXPDA论坛 This thread Refback 07/17/2009 08:45 PM
New & Upcoming in Homebrew: Active Home Screen, an App Installer, & a Fart App | Premazing.com This thread Refback 07/15/2009 11:45 PM
New & Upcoming in Homebrew: Active Home Screen, an App Installer, & a Fart App This thread Refback 07/14/2009 06:03 PM
Google Reader - PreCentral.net This thread Refback 07/13/2009 10:43 PM
Apps | Premazing.com This thread Refback 07/13/2009 03:02 PM
Palm Pre highly anticipated homebrew updates | Palm WebOS This thread Refback 07/13/2009 12:31 PM
[ZT]一个不错新的三方软件 - Palm Pre,webOS 讨论 - [吹友吧·风语](Palm Pre论坛) Palm Pre,智能手机,Palm Treo,Centro,iPhone,blackberry,QWERTY,全键盘 - Powered by Discuz! This thread Refback 07/13/2009 11:45 AM
pre dev wiki: Installing Homebrew Apps on Stock Pre without Rooting This thread Refback 07/06/2009 03:39 PM
将pre转成一个网络服务器 - Palm Pre,webOS - [吹友吧·风语](Palm Pre论坛) Palm Pre,智能手机,Palm Treo,Centro,iPhone,blackberry,QWERTY,全键盘 - Powered by Discuz! This thread Refback 06/30/2009 07:22 PM
Palm Kills Homemade Apps With Latest Pre Firmware - Page 2 - Brighthand.com Smartphone and PDA Discussion Forums This thread Refback 06/29/2009 08:03 PM
pre dev wiki: Installing Apps on a Stock Pre (post 1.04 update) This thread Refback 06/29/2009 05:13 PM


 


Content Relevant URLs by vBSEO 3.6.0