#include <StringConstants.au3> ; to declare the Constants of StringRegExp
#include <Array.au3> ; UDF needed for _ArrayDisplay and _ArrayConcatenate
Local $sRegex = "(?m)^(?!.*(?:is OK|is a broken|file could not be opened)).*"
Local $sString = "eth0" & @CRLF & _
"10.0.11.196" & @CRLF & _
"00:0C:29:AF:6A:A7" & @CRLF & _
"parameters passed to uvscan: --DRIVER /opt/McAfee/uvscan/datfiles/current -- ANALYZE --AFC=32 ATIME-PRESERVE --PLAD --RPTALL RPTOBJECTS SUMMARY --UNZIP -- RECURSIVE --SHOWCOMP --MIME --THREADS=4 /tmp" & @CRLF & _
"temp XML output is: /tmp/HIQZRq7t2R" & @CRLF & _
"McAfee VirusScan Command Line for Linux64 Version: 6.0.5.614" & @CRLF & _
"Copyright (C) 2014 McAfee, Inc." & @CRLF & _
"(408) 988-3832 LICENSED COPY - April 03 2016" & @CRLF & _
"" & @CRLF & _
"AV Engine version: 5700.7163 for Linux64." & @CRLF & _
"Dat set version: 8124 created Apr 3 2016" & @CRLF & _
"Scanning for 670707 viruses, trojans and variants." & @CRLF & _
"" & @CRLF & _
"" & @CRLF & _
"No file or directory found matching /root/SVN/swd-lhn-build/trunk/utils/ATIME-PRESERVE" & @CRLF & _
"" & @CRLF & _
"No file or directory found matching /root/SVN/swd-lhn-build/trunk/utils/RPTOBJECTS" & @CRLF & _
"" & @CRLF & _
"No file or directory found matching /root/SVN/swd-lhn-build/trunk/utils/SUMMARY" & @CRLF & _
"/tmp/tmp.BQshVRSiBo ... is OK." & @CRLF & _
"/tmp/keyring-F6vVGf/socket ... file could not be opened." & @CRLF & _
"/tmp/keyring-F6vVGf/socket.ssh ... file could not be opened." & @CRLF & _
"/tmp/keyring-F6vVGf/socket.pkcs11 ... file could not be opened." & @CRLF & _
"/tmp/yum.log ... is OK." & @CRLF & _
"/tmp/tmp.oW75zGUh4S ... is OK." & @CRLF & _
"/tmp/.X11-unix/X0 ... file could not be opened." & @CRLF & _
"/tmp/tmp.LCZ9Ji6OLs ... is OK." & @CRLF & _
"/tmp/tmp.QdAt1TNQSH ... is OK." & @CRLF & _
"/tmp/ks-script-MqIN9F ... is OK." & @CRLF & _
"/tmp/tmp.mHXPvYeKjb/mcupgrade.conf ... is OK." & @CRLF & _
"/tmp/tmp.mHXPvYeKjb/uvscan/uninstall-uvscan ... is OK." & @CRLF & _
"/tmp/tmp.mHXPvYeKjb/mcscan ... is OK." & @CRLF & _
"/tmp/tmp.mHXPvYeKjb/uvscan/install-uvscan ... is OK." & @CRLF & _
"/tmp/tmp.mHXPvYeKjb/uvscan/readme.txt ... is OK." & @CRLF & _
"/tmp/tmp.mHXPvYeKjb/uvscan/uvscan_secure ... is OK." & @CRLF & _
"/tmp/tmp.mHXPvYeKjb/uvscan/signlic.txt ... is OK." & @CRLF & _
"/tmp/tmp.mHXPvYeKjb/uvscan/uvscan ... is OK." & @CRLF & _
"/tmp/tmp.mHXPvYeKjb/uvscan/liblnxfv.so.4 ... is OK."
Local $aArray = StringRegExp($sString, $sRegex, $STR_REGEXPARRAYGLOBALFULLMATCH)
Local $aFullArray[0]
For $i = 0 To UBound($aArray) -1
_ArrayConcatenate($aFullArray, $aArray[$i])
Next
$aArray = $aFullArray
; 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