It gets tricky when you have to escalate an user and the machine doesn’t require a password as such. ‘become’, ‘become_pass’ or anything does not work. You might encounter this error :
“Timeout (62s) waiting for privilege escalation prompt:”
in those cases try using :
And dont club it with anything else. Hope it works !
In one of the projects we had to have an https authentication to be able to get to the home page for security reasons. We were looking at various options to get through the authentication during the web driver tests. These were the few options we came across :
- Remove the authentication itself ! Not a good idea, because we were having client specific information public, on the internet.
- Another option is this , where they inspect each driver’s methods and call its version of HTTP basic as needed. For us it dint work either.
- Another option is to use this URL : https://<username>:<password>@<actual_url> and it generally bypasses the authentication. The only problem we had was, in nginx, you usually hit a blank “Site Content” page after which you are actually redirected to your site. But in this case, the redirection was not happening. Also with this method you would be exposing username and password in codebase if done in a simple way.
- Next was to use the AutoAuth plugin of firefox.
This is plugin is simple. If there is a saved username and password in your profile , it directly fills in the data and takes you to the home page of the site. But here you have the task of entering the credentials the very first time and save it.
Typically centOS doesn’t have a GUI. We need to install the xvfb and start firefox in a display with it. After a huge setup process we were able to finally see firefox run with a GUI using VNC viewer. Finally we tried opening our site in that firefox but we weren’t able to enter the credentials. It might be because of some limitations on firefox running on CentOS. But only if we could enter the credentials the very first time and save it ,we could be able to run the tests without entering the credentials.
After few google searches we tried using Saved Password Editor plugin for firefox. With the CentOS GUI we were able to at least open this plugin and enter the credentials by clicking add new. All details are straight forward, except you would be specifying “Restricted” in “Annotation” when its a java script popup (which is the case here and other web server level authentications ).
After entering the credentials in the saved password manager, when you open the site autoauth automatically authenticates you in to the web page. After this the web driver ran like a breeze !
I am not a big fan of vanilla Android looks, may be from the functionality stand point or the amount of bloatware (in other for eg HTC sense, touchwiz) I think vanilla is great. I haven’t used many ROMS apart from Cyanogenmod and MIUI. Cyanogenmod is one of the highly acclaimed ROMS out there, but I am not a great fan of it because of the vanilla style.
I have heard decent things about ROMS like Carbon, Pixeldroid, but I like and prefer MIUI. It might have that ‘colorful’ look, but the menus, settings, notifications menu, etc are pretty neat and easy to use. I was already running 4.2.2 MIUI V5 on my mobile for about a year now, and was waiting for a proper upgrade. I know there a bunch of 5.X.X ROMS out there, but I wanted something to suite my taste. Finally I found the link here (xda link). Its not an official MIUI release for m7. But this is an unofficial stable V6 running 4.4.2.
I had a little older version of CWM recovery, not sure if using that or not deleting data and cache were reasons for improper installation. I updated to the latest of TWRP. The best way to install is using ‘fastboot’ command. Flashifty or TWRP app dint do the job for me. After a proper install of TWRP i finally installed V6.
The next think I notice is the ‘HTC logo’ which was acting as a menu button earlier is not functioning now. After a decent research I found ElementalX kernel should do the magic. Even after trying installing a couple of times I wasnt able to get it work. Finally the xda devs original MIUI post itself had a link to the proper ElementalX kernel. For the nth and the last time and I tried to install. And voila … it did work. There are a bunch of tweaks you can make, while installing the kernel. One point to note is that, there was some kind of OTA for V6, after which the kernel was gone. I am not exactly sure how could we handle that.
Another challenge was installing gapps. There is this useless error which comes up in playstore which says ‘no connection’ (or sorts) even though you have proper internet on your mobile. The best way to get through this is flashing the gapps. Again I was able to find it in the orginal xda post.
MIUI V6 with Kernel ElementalX is one of the best combination for HTC m7 out there. Please dont forget to read the contents of xda posts before installing a ROM, like I did. Happy ROMing !!
I had a thought to try out few stuffs with the Raspberry Pi 2 after buying it recently. The one thing which is easy and quite useful is creating a media/entertainment center. There are many blogs and tutorials out there. But this might be very specific to Installing using MacBook Pro, using a external HDD and an android remote. The RasPi with good amount of interface is very easier to set up and running. All you would need is :
- A PC/Mac (I used mac) to install to the card
- An sd card, 8 GB, class 10 (for stability and speed)
- Raspberry Pi 2
- Keyboard and Mouse
- Edimax WiFi adaptor (if using wireless Internet/ Android remote)
- Yatse/Kore Android app (Android remote)
- Power adaptor. Recommended 5V , 2A power supply.
Use the SD card adaptor to plug it into the slot (in case of mac) or a suitable microSD/SD card reader to mount the card. Mac has a weird issue of some times not recognizing the sd card. Its a very silly issue, chk this out to solve the problem(Yeah it solved my problem). Next step after mounting is the installation.
You can download OSMC here. Download the installer which will guide you through the installation process. Either you can choose to download the img file separately and use it during the installation process or you can choose to allow the installer to download the image. I used the version “2015.06-1” to install. According to the blog it was a latest stable version. Not sure why they dint have “RC” tagged to it.
After a successful install plug the microSD card to the RasPi. Connect power supply and HDMI cable and turn the power on and the TV. Thats it ! You would see a OSMC booting and eventually in few secs to the GUI. A mouse would be sufficient for the initial setup. Though selecting from a list (say language selection) can get tricky, because of the mouse sensitivity. I selected Dutch by mistake and took me a little while to figure it out.
I wanted to control OSMC using Android app. For this either you can connect RasPi using ethernet or a WiFi adaptor (I used Edimax). Using the WiFi adaptor was pretty straight forward. I plugged it and it worked right out of box (without any configuration or settings), but might require going into settings screen and selecting wireless. Select the wifi network and connect.
After connecting OSMC to your local network you can install either Yatse or Kore. I prefer to use Kore because it has got seek bar for videos. Inside app you can add device and it would immediately recognize the OSMC(kodi) running in your local network, select and you are all setup to use your android as a full function remote.
Next I tried to connect my external HDD, but it failed to mount. After a little research I figured out that you need to edit the file /boot/config.txt and add this max_usb_current=1. You can change the file by doing ssh into RasPi. The username/password is osmc/osmc. What you are essentially doing is changing the default current to 1A. Check this out for more information on this.
So there you have it. A media center which could play movies from your external HDD and also controllable from your android/iphone.
Recently I subscribed for Tikona broadband here in Chennai. It was a direct RJ45 ethernet cable for input. I dint think much before buying a Wifi router. I bought a D-Link 2750u ADSL2 modem + router. I thought this would be right thing to do because in case I change my internet provider it would easier to use the same modem. But after a a little digging I almost believed that this wouldn’t work with RJ45 cable but a ADSL line only. Before I lost hope I took a lot of time to figure out in various sites how to configure my modem+ router to work as a pure router.
Another minor problem which I had was the h/w version of the modem which I had. There are many versions of 2750u. Mine was V1. You could easily check the version on the modem of 2750u. V1 was not a common one and finding a firmware was a little difficult. For V1 i installed the one here in the downloads tab which has ‘V1’ on it. And finally I found the steps here, reply #73 from a person akhileshgs . Frist, thanks a lot to him. The steps which he put there :
- Reset router
- Internet Setup–> WAN Access Type–>>Ethernet
- Select Bridge and protocol and go down and select apply (Without changing any defaults)
- Wireless basic–> Uncheck multiAP isolation
- Change country to India
- Wireless Security–>Security mode–> WPA Only and change the password at the bottom (Without changing any defaults)
- Local Network–> Uncheck Enable DHCP Server
- Go to Setup Wizard–> Change WAN access type to Ethernet and select Bridge as protocol
He also provides step by step screenshots here . (Also available in original post ).
Thanks to the original poster again. I hope this post could be found much more easier than the original.