I, recently started to work on Android features and analyzing some RAT (Remote Administration Tools) behaviors. I realized that Live Video Streaming is only supported for activity based on RATs. But I could stream the live video and audio without user notice.
I’m working on a research based Android Malware and decided to create a multi function RAT (Remote Administration Tool). I was working on Live Streams which I’ve found some RTMP based open sources projects including:From my GitHub: https://github.com/mirsamantajbakhsh/LiveHiddenCamera
https://github.com/fyhertz/libstreaming which, all have some kind of problems based on the requirements of a RAT. But the common one was that they all need an activity to include a
Therefore, I’ve started searching. Finally, I could create Live Hidden Camera which only needs a CONTEXT for stream live video, by combining these two projects:
The other motivation was that there was not (based on my search) any other library or code for stream live video and ausio. Source: https://github.com/wishihab/Android-RATList .
Therefore I decided to work on a Live Hidden Camera streamer for Android.
What Happens in Camera
Android only permits one application to access the camera hardware simultaneously. And only pass image data if the application (who opened camera) shows a preview to the user.
Bypassing the Preview
I’ve found a library in which bypass the camera preview by creating a fake surface (1*1) but the application has to have permission to alter (overlay) system display.
But problem still exists. I wanted to stream the live audio and video from android camera, and all the existed libraries (based on my search) were used SurfaceView such as:
I’ve decided to embed the idea from this library and tried to embed in this live rtmp streamer android application. After lots of effort, finally I could create the Live Hidden Camera library which streams live video and audio from android device without showing any preview to the user.
The library is uploaded to bintray and the source code (+ released aar file) is available in my Live Hidden Camera repository in my GitHub.
There are some problems and TODOs in the project (https://github.com/mirsamantajbakhsh/LiveHiddenCamera#Problems) which you can check.
Any contribution is welcomed.