recover password without reflash


TrashyMG

Sarcasm Dispenser
Staff member
Joined
Jan 18, 2010
Messages
11,088
Well you should be looking at the newer up to date instructions...  Linux/Unix based OSs are made to be secure, cracking the password would be very difficult. 

What exactly are you saving on the firmware to really care about saving it? Flashing the firmware is a fairly painless process.

If you haven't used the Pandora in so long that you don't remember the password it's most likely on some very old Firmware version anyway.
 
Last edited by a moderator:

nik

Still Fresh
Joined
Nov 14, 2011
Messages
61
It's not that old and I figured maybe there's a handy alternative burried somewhere. Can I crack it somehow, I don't mind running some utility via some hacky method. Is there anyway I can mount pandora to laptop and then run some kind of rainbowtable something or other?
 

TrashyMG

Sarcasm Dispenser
Staff member
Joined
Jan 18, 2010
Messages
11,088
You can't put the Pandora in a mode to talk to another computer without logging in and changing a setting, However the current host mode utility will only talk to one of the SD cards not the internal NAND. You could create a Bootable SD card with Angstrom or Slackware and attempt to mount the NAND in write mode, from there you still would need to know how to hack the user/password information.. but it's easier just to reflash it, it's seriously only take a few minutes and any method to recover or change a password would take a lot more effort. 
 
Last edited by a moderator:

WizardStan

Mega GP Mania
Joined
May 24, 2008
Messages
16,733
Install the firmware to an SD card, mount the NAND, edit the /etc/passwd file on the mounted NAND and remove your password.

It can be done, but unless there's a specific reason you really really want to keep the firmware it is just easier to simply reflash.

edit: I apparently took, like, 15 minutes to write that.
 
Last edited by a moderator:

lomaxx

Active Member
Joined
Sep 22, 2008
Messages
747
It's a bit of an effort,yes, but there is no need to install the firmware to SD, if you want to change the password. But you WILL need an empty SDcard, that can be as small as you like (I just used a 32MB SDcard for testing) and on that you can set up a boot-able partition.

 The trick is to boot that SD-card, that contains nothing but a "autoboot.txt"-file that boots the nand, just like you would boot without SD-card with the exception of passing on an additional kernel-boot-parameter. Here is the content of that autoboot.txt


setenv bootargs 'ubi.mtd=4 ubi.mtd=3 root=ubi0:rootfs rootfstype=ubifs rw rootflags=bulk_read vram=6272K omapfb.vram=0:3000K mmc_core.removable=0 init=/bin/bash'; ubi part boot && ubifsmount boot && ubifsload ${loadaddr} uImage && bootm ${loadaddr}


The interesting bit is the part "init=/bin/bash", which will put the system into a mode where a bash-shell is running with root-rights. From there you can run "password <username>" (replace <username> with your actual username). I tried it and it works.

The most straight forward solution would be to create a very small image (less than a megabyte) of such an password-reset-SDcard that a windows-user without a lot of linux-experience can write to a SDcard and boot the pandora with.

I can try some more with this, but I haven't got much experience in creating sdcard-images in Linux that can be written with windows too. Not sure if there is some special treatment required besided using dd to make the image.

Sorry for the unfinished answer, but I need to hurry for lunch. ;)
 
Last edited by a moderator:

TrashyMG

Sarcasm Dispenser
Staff member
Joined
Jan 18, 2010
Messages
11,088
Well great, now I know how to hack every Pandora even ones that are not mine. you know how much responsibility you just gave me..
 

lomaxx

Active Member
Joined
Sep 22, 2008
Messages
747
Sooner or later in live you will have to take responsibility anyway. ;) And you don't help people by leaving them in the false believe that their data is safe if it actually isn't. That's maybe a method that Microsoft used for quite a while. Look around in the web. The part with the init=/bin/bash is known for a very long time for Linux-systems and i wouldn't even call it a hack. The rest was a matter of less than half an hour, putting info from the wiki and forum together. And I don't even think of myself as a Linux-expert. But I was kind of surprised (or maybe even a little shocked) too the first time I heard about that method.

One thing that will help you to keep your Pandora's or any other PC's system safe is to restrict access from boot-devices or encrypt the system/user-data. Or don't put or send sensible data on/from the system. In other words: Don't leave your Pandora lying around in places where a person with bad intentions has access to it.
 

elwing

Rabbit Addict
Joined
Feb 23, 2009
Messages
3,118
and obfuscation never was a security anyway.... if there is such a flaw there's no reason to hide it... well except if you're a bad guy :D
 

urjaman

"I Know. We're going for a ride."
Joined
Jan 6, 2009
Messages
1,111
Age
31
Location
Finland
Website
urjaman.dy.fi
Physical access to a device is the N°1 flaw.
I forgot my password on my SlackWare SD card.  Anyway to get at it?
Boot the slackware with init=/bin/bash and use passwd username (you may need to mount the root fs rw, eg. mount -o remount,rw /) (I have not used SL4P, but I guess edit boot.txt), or: :p
Mount the card on a linux system, open etc/shadow on the card (should be only root readable so you might need to be root on your PC),

Make a backup (just in case), edit your user password out - it is the second field, so eg "user::15776:0:..." is a row with no password (user:$... with password)

Your user should then have no password as if passwd -d username was used.
 
Last edited by a moderator:

Linux-SWAT

Hardcore Member
Joined
Feb 13, 2010
Messages
8,963
Edit /etc/shadow , and remove the part between the first :: , where you can see inside a * in non-logging accounts like haldaemon, nobody etc.

Leave this empty and you can boot without password.

The command to change password is passwd .
 

WizardStan

Mega GP Mania
Joined
May 24, 2008
Messages
16,733
In this vein, cop shows that always show the uber-hacker trying to crack a users password on their laptop always make me laugh. I'd just pull the hard drive and drop it into a system that I have full control over, but that's just me.
 

nik

Still Fresh
Joined
Nov 14, 2011
Messages
61
It's a bit of an effort,yes, but there is no need to install the firmware to SD, if you want to change the password. But you WILL need an empty SDcard, that can be as small as you like (I just used a 32MB SDcard for testing) and on that you can set up a boot-able partition.

 The trick is to boot that SD-card, that contains nothing but a "autoboot.txt"-file that boots the nand, just like you would boot without SD-card with the exception of passing on an additional kernel-boot-parameter. Here is the content of that autoboot.txt


setenv bootargs 'ubi.mtd=4 ubi.mtd=3 root=ubi0:rootfs rootfstype=ubifs rw rootflags=bulk_read vram=6272K omapfb.vram=0:3000K mmc_core.removable=0 init=/bin/bash'; ubi part boot && ubifsmount boot && ubifsload ${loadaddr} uImage && bootm ${loadaddr}


The interesting bit is the part "init=/bin/bash", which will put the system into a mode where a bash-shell is running with root-rights. From there you can run "password <username>" (replace <username> with your actual username). I tried it and it works.

The most straight forward solution would be to create a very small image (less than a megabyte) of such an password-reset-SDcard that a windows-user without a lot of linux-experience can write to a SDcard and boot the pandora with.

I can try some more with this, but I haven't got much experience in creating sdcard-images in Linux that can be written with windows too. Not sure if there is some special treatment required besided using dd to make the image.

Sorry for the unfinished answer, but I need to hurry for lunch. ;)
Dude, just awesome. I was getting ready to flash, then decided to check my post, then you came riding in, like knight in shining armor. That was easier than soap... Should be in the wiki.

The only question I have is, how do you start default desktop from bash prompt? (Not critical but would be nice to know.)

In any case: thank you, thank you, thank you!!!
 

nik

Still Fresh
Joined
Nov 14, 2011
Messages
61
How do I check what SuperZaxxon firmware my unit is on?
 

lomaxx

Active Member
Joined
Sep 22, 2008
Messages
747
The only question I have is, how do you start default desktop from bash prompt? (Not critical but would be nice to know.)
I can't recommend to start the desktop after booting the system in the above mentioned way and it's a bit complicated as well. That's really only for sort of low-level administrative tasks like changing the password or trying to reestablish a broken boot-process. In that state many environment-parameters are not set and many processes that normally would be running in the background are missing.

Not sure if the following is what you want, but after a normal boot you can get to the bash without starting xfce/minimenu by following the description in this post: http://boards.openpandora.org/index.php/topic/10374-superzaxxon-v152-released/page-6#entry195000

Edit: changed the URL

Actually you will rarely need this as "normal" user.
 
Last edited by a moderator:

urjaman

"I Know. We're going for a ride."
Joined
Jan 6, 2009
Messages
1,111
Age
31
Location
Finland
Website
urjaman.dy.fi
One might be able to transfer from a system with bash as "init" to a real system with an init by doing exec /sbin/init ... but I have not tested, it might fail in spectacular ways.
 
Top