#include <StringConstants.au3> ; to declare the Constants of StringRegExp
#include <Array.au3> ; UDF needed for _ArrayDisplay and _ArrayConcatenate
Local $sRegex = "(?si)^(get|post|head|options|put|delete|trace|connect) [\x09-\x0d -~]*? http\/(0\.9|1\.0|1\.1)|^http\/(0\.9|1\.0|1\.1) [1-5][0-9][0-9]"
Local $sString = "HTTP/1.1 206 Partial Content" & @CRLF & _
"Server: nginx" & @CRLF & _
"Date: Wed, 11 Nov 2015 03:56:37 GMT" & @CRLF & _
"Content-Type: application/octet-stream" & @CRLF & _
"Content-Length: 356602" & @CRLF & _
"Last-Modified: Sat, 09 May 2015 01:02:03 GMT" & @CRLF & _
"Connection: keep-alive" & @CRLF & _
"Cache-Control: no-store" & @CRLF & _
"Pragma: no-cache" & @CRLF & _
"Access-Control-Allow-Origin: *" & @CRLF & _
"Access-Control-Expose-Headers: X-TCP-Info,X-Session-Info" & @CRLF & _
"X-TCP-Info: h0=1468775468;h1=1393591241;h2=2806702307;h3=4238532199;h4=1088413687;" & @CRLF & _
"X-Session-Info: addr=14.203.114.166;port=64848;argp=6.r_LuFhNjxnyyv1lFwH73LPg5P97q98pNwisQ1a9GcfM" & @CRLF & _
"Content-Range: bytes 221217390-221573991/345312900" & @CRLF & _
"" & @CRLF & _
"...{moof....mfhd...........ctraf....tfhd... ............tfdt......." & @CRLF & _
".tj`...Asaiz........0...................................."
Local $aArray = StringRegExp($sString, $sRegex, $STR_REGEXPARRAYFULLMATCH)
; Present the entire match result
_ArrayDisplay($aArray, "Result")
Please keep in mind that these code samples are automatically generated and are not guaranteed to work. If you find any syntax errors, feel free to submit a bug report. For a full regex reference for AutoIt, please visit: https://www.autoitscript.com/autoit3/docs/functions/StringRegExp.htm