[THM][Note] Wireshark: Traffic Analysis

https://tryhackme.com/room/wiresharktrafficanalysis

Task2


Which UDP port in the 55-70 port range is open?

考え方)

  • udpのポートが空いていない場合は、icmpが返ってくる。
  • 空いている場合は、何も返ってこない。
  • ポート範囲(55~70)でudpを指定して、エラーが返ってきているポートを目視で省くと、残るポートは1つだけ。

フィルター例)

udp.dstport in { 55..70 }

Task3


What is the number of HTTP packets received by the attacker?

カラムの追加手順)

考え方)

httpプロトコルと、怪しいMACアドレス宛で絞る

http && eth.dst == 00:0c:29:e2:18:b4

What is the number of sniffed username&password entries?

考え方)

  • 先程の結果から、loginに関連しそうなパケットの中身をみて、パラメーターが「uname」ということが解った。
  • 以下のフィルターを使用
eth.dst == 00:0c:29:e2:18:b4 && http contains "uname"
  • 結果は7件だが、ログイン以外のパスも含まれているので、URLや中身をよく見る。

Task4

What is the MAC address of the host “Galaxy A30”?

考え方)

  • 本タスクの説明のコンテキストで考えると、「Host Name」は、dhcpから調査できると仮定。
  • 出題にある、「Galaxy A30」をそのままコピペしてフィルターしても0件。本来はもっと違う表記と考えられる。
  • さて、どうする?

How many NetBIOS registration requests does the “LIVALJM” workstation have?

考え方)

  • 「Register」でフィルターしたいが、フィルターコードがわからないので、とりあえずnbnsでフィルター。
  • そうするとNetBIOSのパケットだけになる。
  • Info列を見ると、「Registration ・・・」がある。どうやらコレで絞れそう。
  • 対象のパケットの詳細ペインより、Flagsの中身をみる。
  • 対象となるフラグの部分を右クリックして、フィルターに反映させる。
  • 作成されたフィルターに出題のホスト名を条件に追加してフィルターする。
nbns.name contains "LIVALJM" && nbns.flags.opcode == 5

Which host requested the IP address “172.16.13.85”?

考え方)

  • とりあえず、dhcpでフィルター
  • リストからそれっぽいもの「Request」を見つけて詳細ペインで内容を確認。
  • Requested IP Addressがあるので、右クリックでフィルターに反映させる。ここでのIPアドレスの中身は重要ではない。検索フィルターを再利用したいだけ。
  • 右クリックから作成したフィルターのIPアドレスの部分を出題のものに書き換える。
dhcp.option.requested_ip_address == 172.16.13.85
  • 検索結果のパケット詳細ペインからホスト名を探す。

What is the IP address of the user “u5”? (Enter the address in defanged format.)

考え方)

デファング形式とあるので、注意。

リファング:192.168.1.2

デファング:192[.]168[.]1[.]2

Task5


Use the “Desktop/exercise-pcaps/dns-icmp/icmp-tunnel.pcap” file.
Investigate the anomalous packets. Which protocol is used in ICMP tunnelling?

考え方)

  • icmp and data.len > 64などで、異常なものだけをフィルター
  • Lengthでソートをかけて、サイズの大きいものを注意深く見ていく。
  • ひたすらみていく、、、
  • もっと良い方法はないか?
  • データ部分に、diffie-hellmanとか、sha256とか、おなじみのプロトコルのキーワードが見つかる。さて、もっとよく見ると答も書いてある。

Task6

How many incorrect login attempts are there?

考え方)

  • PASS、USER、QUITなどファイル取得に関係のないメソッドを省いて、リクエストを検索
ftp.request && ftp.request.command != "PASS" && ftp.request.command != "USER" && ftp.request.command != "QUIT"

検証)(“PASS” | “USER” | “QUIT”)の様に纏められないか?

  • ファイル名が見つかる
  • 視点をレスポンスに変えてフィルターを実行
ftp.response.arg contains "resume.doc"

Task7

Investigate the user agents. What is the number of anomalous  “user-agent” types?

考え方)

  • User-Agentをカラムにすると見やすい


What is the packet number with a subtle spelling difference in the user agent field?

考え方)

  • 兎に角よく見る

Locate the “Log4j” attack starting phase and decode the base64 command. What is the IP address contacted by the adversary? (Enter the address in defanged format and exclude “{}”.)

考え方)

  • log4jの特性でcontainsを使ってフィルター

(ip contains "jndi") or ( ip contains "Exploit") or (frame contains "jndi") or ( frame contains "Exploit")

  • フィルター結果からPOSTを探す(log4jの攻撃はPOSTから開始される)。
  • パケットを見つけたら右クリックして、「Fllow」=>「HTTP Stream」で流れを見る。
  • Base64をデコード
  • でファンク方式で回答。

Task9


What is the packet number where “empty password” was submitted?

考え方)

デフォルトでは、Denyのルールが作成されるが、問題はAllowを出題しているの注意。

コメントを残す

メールアドレスが公開されることはありません。 が付いている欄は必須項目です