NixCraft has a nifty little guide on how to recover password on a protected grub boot loader and you forgot both root and grub password.
It's all here
If you have, a password protected grub boot loader and you forgot both root and grub password then you can recover grub-boot loader password using following method/Procedure:
* Use Knoppix cd
* Remove password from Grub configuration file
* Reboot system
* Change root password
* Setup new Grub password if required (optional)