Buggy ADB pull & Android File Transfer on Mac OS X

Recently I needed to move my file from my One Plus (yes – I’m back to iOS). For this move I needed to transfer my previous images / files from the android phone to my computer.

The only thing is each time I tried to use Android File Transfer, it stalls in the middle of the progress after copying few files. I thoguht ok, let’s go back to CLI, so ADB was an obvious backup plan; however the last did not sustain as well. The phone keeps disconnecting and I got frustrated with this buggy design of both. (@Google – Why is this OK?)

Turns out that CLI is indeed a life saver especially for a linux user like me. What I did is really simple and effective.

The idea:
Run scp in adb shell connect back to your mac / linux box (Windows users you will find a way too – SFTP server?)

The implementation:

...Read More

Generate Alpha-Numeric Strings in Python (for BruteForce Attacks)

While I was coding the ‘Twitter Short Handles Finder‘ I needed an efficient Alpha-Numeric Strings generator in Python. I coded this from scratch:

Read More

Both of Qatar Telecoms: Ooredoo and Vodafone do NOT use HTTPS by Default

I was astonished by the fact that both Ooredoo and Vodafone the only telecom operators in Qatar still do not use HTTPS by default leaving user credentials to be easy targets for hackers.

To make a change I just pushed a Github commit to the famous HTTPS Everywhere Browsers Extension for both operators websites:

You can also contribute to this project by adding rules and tweak the code on Github.

Read More

Check All Checkboxes at Once from Browser’s URL

If you face a website with lot of checkboxes to check but they did not implement a ‘check all’ button. You can copy and past this code into your browser’s URL address:

Note that sometimes your browsers (Chrome in my case) scizes the ‘javascript:‘ part from such addresses. You need to type ‘Javascript:‘ manually

Read More

C0de-Puzzle: Printing int in reverse without IF statement

Challenge:  Write a function, that delivers following output: "1 2 3 4 5 4 3 2 1".

  • You only can use: 1 for loop, 2 int variables.
  • You must not use: IF terms, another function.
  • Do not hardcode the output (do NOT do: print("123454321")


STOP and think about a solution.

Read More

Finding longest path of a specially-shaped graph in O(Log(n))

First of all let’s clear thing up:

Finding the longest path of a graph algorithm is NOT the inverse of Dijkstra’s algorithm of finding the shortest path. In fact finding the longest path of a graph in NP-Hard problem.

In our case, the graph is a tree-shaped graph, more like a triangle.

Read More

Reversing a doubly linked list data structure in C++


Read More

Hacking short distance devices

Hacking is not only for computer, software, or websites. Any device can be hacked. I lately started having interests in Software Defined Radio where I was able to ‘sniff’ data of signals around me. One particularly interesting signal was the short distances devices. These include:

  • Car remotes system. Also called: Remote Keyless System
  • Garage Remotes
  • Other home equipment remotes switches.

Some of these systems are known to have security flaws in them. Some have no security mechanisms. It is worth reading how these stuff work before going deeper into hacking them.


  • Programming skills in: C++ or Java or Python.
  • A micro-conotroller (Teensy, Aurdino) Raspberry Pi is ok too.
  • 315Mhz / 430Mhz Transceiver. I bough this one > XD-RD-5V.




Read More

Clean Your Mac OS X from the Ads Injecting Malware

If you’re suffering from an ads injecting malware like this one:

Usually it is a black box showing at the button of any website you visit form any browser: Safari, Chrome, Firefox.
Don’t try to remove a plugin or extension. This malware is not a browser add-in.
I have wrote a tiny bash script to run in your mac and it will clean your system.
You can download it form here – just run it as sudo.

You can easily view the source of the script by opening it in your fav text editor.

credits: Thanks to this guy here who mentioned the process name and how to clean it.

Read More

Mixing different RAM Sizes in One Computer

Can you install different sizes of RAM into a single motherboard and it will still work? Yes you can!
There a tiny tricks you will need:

  1. Make sure you’re buying same speed/voltage/non-ECC sticks.
  2. When installing them install them in this way:   || Slot#1:[1GB+512Mb] || Slot#2:[1GB+512Mb] ||

I tried to install them in other order but all my tries have failed. The only thing that worked is installing them in the order I mentioned above.

~ Happy upgrading.

Read More