}gn fdZddlZGddeZGddeZGddeZdS) u  This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation, either version 3 of the License, or (at your option) any later version. This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License for more details. You should have received a copy of the GNU General Public License along with this program.  If not, see . Copyright © 2019 Cloud Linux Software Inc. This software is also available under ImunifyAV commercial license, see Nc0eZdZdZdZedZdS)ScanFailedErrorc||_||_||_|||_|||_||_||_dS)z In some scanners out and errors can be lists of bytes or bytes, we will convert all to string :param message: :param command: :param return_code: :param out: :param err: N)messagecommand return_code_convert_to_strouterrpathscan_id)selfrrrr r r r s R/opt/imunify360/venv/lib/python3.11/site-packages/imav/malwarelib/scan/__init__.py__init__zScanFailedError.__init__sV(  &'',,'',,  cfd|j|j|j|j|jS)Nz@Scan failed with {}: command: {} return code: {} out: {} err: {})formatrrrr r )rs r__str__zScanFailedError.__str__6s5 f     rc"t|tkr|St|tkrtj|St|t krdd|DS|dStd)Ncjg|]0}t|tkr|n|1S)typebytesdecode).0elems r z3ScanFailedError._convert_to_str..JsD&*$ZZ5%8%8DKKMMMdrz%Unsupported type to convert to string)rstrrosfsdecodelistjoin TypeError)objs rr zScanFailedError._convert_to_strBs 99  J #YY%  ;s## # #YY$  77 #  [2CDD DrN)__name__ __module__ __qualname__rr staticmethodr rrrrrsR8    EE\EEErrceZdZdS)ScanAlreadyCompleteErrorNr&r'r(rrrr+r+UDrr+ceZdZdS) ScanInfoErrorNr,rrrr/r/Yr-rr/)__doc__r Exceptionrr+r/rrrr2s* 9E9E9E9E9Ei9E9E9Ex     y        I     r