Theory Behind CVE-2023-44487 (HTTP2 Rapid Reset) Explained | HTTP DoS
Summary
TLDRこの動画では、HTTP2 Rapid Reset攻撃について解説しています。この攻撃は、GoogleやAmazonなどのクラウドベンダーにも影響を与え、公開的に報告された大規模な影響をもたらしました。HTTP1とHTTP2の違い、特にHTTP2の二進制性とストリーム機能が攻撃にどのように関係するかを説明し、攻撃の仕組みとその影響を解説しています。
Takeaways
- 🌐 HTTP/2のRapid Reset攻撃について解説。CVE-2023-487が関連している。
- 🔍 攻撃の影響は広範囲で、Google、Amazon、Cloudflareなどのクラウドベンダーが公開して説明している。
- 📚 HTTP/1.1とHTTP/2の違いを説明。HTTP/1.1はテキストベースで、HTTP/2はバイナリベース。
- 🚫 HTTP/1.1では一度に一つのリクエストしか送ることができないのに対し、HTTP/2では複数のストリームを一つのTCP接続で送ることができる。
- 🔗 HTTP/2のストリームは、各リクエストに相当し、サーバーはそれらを並列で処理する。
- 💡 HTTP/2では、一つのTCP接続で約100個のストリーム(リクエスト)を送信できる可能性がある。
- 🛑 Rapid Reset攻撃では、リクエストを送信しながらrst stream frameを送ることで、サーバーのリソースを枯渇させる。
- 🔎 Google Cloudのドキュメントでは、HTTP/2のクライアントが一つのTCP接続で複数のストリームを開くことができ、各ストリームが一つのHTTPリクエストに対応するように説明されている。
- 📈 攻撃の仕組みは、リクエストを送信しながらrst stream frameを送信することで、サーバーは処理を開始するが、すぐにキャンセルする。
- 📖 HTTP reset攻撃について詳しく知るために、Googleで関連する記事を読むことを推奨する。
Q & A
ビデオで話されているHTTP2 Rapid Reset攻撃とは何ですか?
-HTTP2 Rapid Reset攻撃は、HTTP2プロトコルの特性を悪用したDoS攻撃で、サーバーのリソースを消費させるために多数のストリームを開設し、直ちにリセットする行為です。
CVE-2023-487はどのような意味を持ちますか?
-CVE-2023-487は、このHTTP2 Rapid Reset攻撃に割り当てられたCommon Vulnerabilities and ExposuresのIDです。
HTTP1とHTTP2の最大の違いは何ですか?
-HTTP1.1はテキストベースで、HTTP2はバイナリベースです。HTTP2はストリームと呼ばれる並列処理が可能で、HTTP1.1では1つのリクエストごとに1つのレスポンスが送られます。
HTTP2におけるストリームとは何ですか?
-HTTP2のストリームは、1つのTCP接続内で独立して送受信できるHTTPリクエストまたはレスポンスを表します。
HTTP2で多重化を利用することの利点は何ですか?
-HTTP2の多重化により、1つのTCP接続を通じて同時に複数のリクエストを送ることができます。これにより、通信効率が向上し、遅延が減ります。
RST_STREAMフレームとは何ですか?
-RST_STREAMフレームは、HTTP2でストリームを異常終了するためのフレームです。サーバーはこのフレームを受け取ると、対応するストリームの処理を中止します。
HTTP2 Rapid Reset攻撃の目的は何ですか?
-この攻撃の目的は、サーバーのリソースを消費させることです。攻撃者は多数のストリームを開設し、直ちにリセットすることで、サーバーのCPUやメモリなどのリソースを過負荷させ、サービスを妨害します。
Google Cloudはどのようにこの攻撃を検出しましたか?
-Google Cloudは、HTTP2で定義されているRST_STREAMフレームの異常なパターンを監視し、多数のストリームが開設されてからすぐに閉じられていることを検出し、この攻撃を検出しました。
HTTP2 Rapid Reset攻撃を防ぐ方法は何ですか?
-この攻撃を防ぐためには、サーバー側でストリームの状態を正しく管理し、異常なリセットパターンを検出するためのモニタリングシステムを構築することが重要です。また、セキュリティアップデートを適時適切に適用することも重要です。
HTTP2攻撃の影響を受けたクラウドベンダーには誰がいますか?
-Google、Amazon、Cloudflareなどの大規模なクラウドベンダーに影響がでました。
HTTP2攻撃が発生した際に推奨される対応策は何ですか?
-攻撃が発生した場合、関連する情報を収集し、セキュリティチームと協力して問題を分析し、適切な対策を講じることが推奨されます。また、最新のセキュリティ情報やアップデートに注意することも重要です。
Outlines
🌐 HTTP/2 Rapid Reset Attack Explained
この段落では、RahulがHTTP/2 Rapid Reset攻撃について説明しています。この攻撃はCVE-2023-487と呼ばれ、Google、Amazon、Cloudflareなどのクラウドベンダーが公開して検証した大規模な影響を受けています。動画では、攻撃がどのように実装され、HTTP/2の特徴がどのように攻撃に利用されるかについて説明します。また、HTTP/1とHTTP/2の違いについても説明し、リクエストのスモーギングとダウングレード攻撃に関する情報も提供します。
🚀 攻撃手法とHTTP/1.1の問題点
この段落では、RahulはHTTP/1.1でのリクエストの問題点を説明し、HTTP/2がどのようにその問題を解決したかを述べています。HTTP/1.1では、一度に一つのリクエストしか送信できず、サーバーからのレスポンスを受け取る前に多くのプロセスが行われます。しかし、HTTP/2では、一つのTCP接続で複数のストリーム(リクエスト)を送信でき、これにより並行処理が可能となり、効率が向上します。
🔄 HTTP/2の多重ストリーム機能と攻撃の可能性
この段落では、RahulはHTTP/2の多重ストリーム機能と、その機能が攻撃者にどのように悪用される可能性があるかについて説明しています。特に、rst streamフレーム(リセットストリームフレーム)を使用することで、攻撃者は一つのTCP接続で多数のストリームを送信し、サーバーのリソースを枯渇させることができます。この攻撃手法は、HTTP/2の規格上の問題を悪用しており、多数のストリームを迅速に開閉することでサーバーに影響を与えることがあります。
📚 詳細な攻撃方法と対策の解説
最後の段落では、RahulはHTTP/2 Rapid Reset攻撃の詳細なメカニズムと、どのようにしてサーバーのリソースを消費するかについて説明しています。また、この攻撃に関する多くの記事がGoogleで検索できることを示唆し、読者が攻撃に関する情報を深く理解するためのリソースを提供しています。ただし、この動画では実際に攻撃を試みることをお勧めしません。
Mindmap
Keywords
💡HTTP2
💡Rapid Reset Attack
💡CVE-2023-487
💡Binary
💡Streams
💡Content-Length
💡TLS Handshake
💡Multiplexing
💡RST Stream Frame
💡Server Resources
💡Google Cloud Documentation
Highlights
Rahul introduces the topic of the HTTP2 Rapid Reset attack, which has been given the CVE 2023-487.
The attack has a wide impact, prompting major cloud vendors like Google, Amazon, and Cloudflare to publicly disclose their experiences.
The video will discuss how the attack is implemented and how a feature of HTTP2 is turned against it.
There is an exploit available, though Rahul does not recommend trying it.
Rahul explains the differences between HTTP1 and HTTP2, noting that HTTP1.1 is textual while HTTP2 is binary.
In HTTP2, the content length header is not mandatory, reducing the prevalence of request smuggling.
HTTP2 allows for multiple streams (equivalent to HTTP requests) in one TCP connection, unlike HTTP1.1 which only allows one request at a time.
Multiplexing in HTTP2 means sending multiple requests simultaneously over one TCP connection, which can be abused for attacks.
Google Cloud documentation mentions that clients can open up to 100 streams per request on a single TCP connection.
The server processes all HTTP2 requests in parallel, which can be exploited by sending and canceling streams rapidly.
The Rapid Reset attack relies on sending a stream and immediately canceling it with a rst stream frame, exhausting server resources.
The attack allows sending over 100 streams on one TCP connection by continuously sending and canceling streams.
Rahul recommends reading more about the HTTP reset attack to understand its implications fully.
The video aims to provide insights into the HTTP2 Rapid Reset attack and its potential impact on server resources.
Transcripts
hello everybody my name is Rahul and in
this video we will be talking about the
http2 rapid reset attack which has been
given the cve 2023
487 now this attack has such a wide
impact that even the biggest cloud
vendors like Google Amazon and even
Cloud flare had to come up and publicly
disclose what they witnessing in the
wild so in this
video that we'll be going through uh how
that attack is actually implemented how
a feature of http2 turned against it and
there is also an exploit that you can
try but I won't recommend doing that but
before we move on with the video let's
talk about the differences of HTTP 1 and
two so that you have a better
understanding of how this attack
actually came into existence all right
so what is http1 and how it is different
from http2 now the biggest difference is
that HTTP 1.1 is textual in nature and
http2 is actually binary in nature so
what do I mean so in http2 uh if you
read the documentations what you'll find
reference in most of the places is the
word binary or streams all right but in
HTTP 1 you won't find that and if you
want to uh actually look into it what
you can do is just look up that whether
content length is mandatory for http2 or
not and you'll be quite surprised to
know that you don't actually need the
content length header to um to send
along with the HTTP to request and that
is one of the reasons uh why request
smuggling might not be that prevalent in
HTTP 2 you can try downgrading attacks
but that's a whole different video so
let's talk about CV 2023 487 now what
happens here is when it comes to http
1.1 you can only send one request at a
time and then uh what the server will do
is it will send one response now in
there is a whole lot of things happening
for example a three-way TLS handshake
will take place and a bunch of other
things before the server finally gives
you a response this is in terms of
https so this was a major problem right
because you can only have one request at
a time but you if you try to send in
multiple requests for example you can
try multiplexing so what would happen is
if the first request fails the
subsequent requests will also fail now
this is a big problem because if the
first one fails other will eventually
fail but with
http2 you can send in multiple streams
in one TCP connection and is May each
stream is equivalent to an HTTP request
so as you can see multiplexing that you
are sending in multiple requests at the
same time through one TCP connection now
the best part here is that you can send
in a lot of other streams or lot of
other requests in one TCP connection or
through one TCP connection now what do I
mean by that is I think it's a bit
contextual and how you configure your
server but from what I was reading
through the documentation U you can
actually send in about uh 100 streams or
100 requests through one TCP connection
and I'll show you where it is written in
a moment now if you send in 100
streams that's a big thing because you
sending a lot of traffic through one TCB
connection and that is where you can
abuse this feature now let's go here and
this is the Google Cloud documentation
that I'm reading on uh how they came
across the rapid reset so here it says
that http2 the client can open multiple
concurrent streams on a single TCP
connection and each stream corresponds
to one HTTP request some clients may
open 100 streams per request and the
server processes all these requests in
parallel so what will happen here is if
you send in two requests the server will
actually process both of these requests
parallely and then send you the response
back now this is the part where it's get
pretty interesting so here is a diagram
of
http1 so what is happening here is you
are sending in
one request there's a lot of things
happening but we'll not get into that
you'll get one response now with HTTP 2
you get a lot of streams a lot of
requests that you can send in with one
TCP connection and you get all those
responses back but it gets pretty
interesting because you can also abuse
this feature okay so let's try to uh see
what happens so there is a frame called
rst stream frame so
what happens here is as soon as you send
all these requests to the server you do
not wait for its response as long as
you're sending the request you also send
a frame called The rstd Stream frame
that we just learned about so this
attack primarily relies on you sending
the stream the server just begins to
process it but just after that you send
a rst stream frame and the server
cancels the processing now in this way
you can utilize this attack to send one
over 100 streams over one TCB connection
because you are sending a stream
cancelling it sending cancelling sending
cancelling in this way you can send a
lot of streams through one TCB
connection and exhaust the resources of
the server so this is how the h HTTP
reset attack comes into play now I
highly recommend that you actually go
and read Around the HTTP reset attack
there are a lot of Articles around it on
5.0 / 5 (0 votes)