h dZddlZddlZddlmZddlmZddlmZddl m Z ddl m Z ddl mZdd lmZdd lmZdd lmZdd lmZd ZGddeZdS)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 N)suppress)Path)CleanupRevertAPI)Core) LicenseCLN) MessageSource) restore_hits)MalwareHitStatus) MalwareHit)recurring_checki0*c2eZdZdZdxZZdZdZdZdZ dS)CleanupRevertPluginimunifyNcHttjdz |_dS)Ncleanup_revert)rrTMPDIR_cleanup_revert_flagselfs [/opt/imunify360/venv/lib/python3.11/site-packages/imav/malwarelib/plugins/cleanup_revert.py__init__zCleanupRevertPlugin.__init__+s $($5$58H$H!!!cK||_|tt|j|_dSN)_sink create_taskr PERIODprocess_cleanup_revert_task)rloopsinks r create_sourcez!CleanupRevertPlugin.create_source.sI %% @ #OF # #D$? @ @ B B   rcK|jrZ|jttj5|jd{VddddS#1swxYwYdSdSr)rcancelrasyncioCancelledErrorrs rshutdownzCleanupRevertPlugin.shutdown4s : ! J     '011 ! !j        ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! ! !sAAAcK|jr=|jjtzt jkrdSt jrdStj d{Vx}rPttj |tjx}r!t||j|jd{V|jdddS)N)statusesiT)modeexist_ok)rexistsstatst_mtimertimeris_freerpathslistr get_hitsr RESTORABLEr r initiatortouch)rfileshitss rrz*CleanupRevertPlugin.process_cleanup_revert:s  % , , . . *//11:VCikk F      F*022222222 25 E#$4$?t E #4T^DDDDDDDDD !''UT'BBBBBr) __name__ __module__ __qualname__r5rrrr"r'rrrrr'sgIEEIII   !!! CCCCCrr)__doc__r%r/ contextlibrpathlibr)defence360agent.api.server.cleanup_revertr defence360agent.contracts.configr!defence360agent.contracts.licenser!defence360agent.contracts.pluginsrimav.malwarelib.cleanup.storager imav.malwarelib.configr imav.malwarelib.modelr defence360agent.utilsr rrr<rrrHs* FFFFFF111111888888;;;;;;888888333333,,,,,,111111 &C&C&C&C&C-&C&C&C&C&Cr