§ KcÂz¦]ãó—dZddlZddlmZmZddlmZmZddlm Z m Z m Z ddl m Z ddlmZmZddlmZGd „d e ¦«ZGd „d e¦«ZGd „de¦«ZdS)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)ÚCoreÚANTIVIRUS_MODE)Úrun_cmd_and_logÚ OsReleaseInfo)ÚAbstractFeatureÚ FeatureErrorÚ FeatureStatus)ÚPATCHMAN_PACKAGE)ÚREALTIME_PACKAGEÚ is_installed©r có¾—eZdZUdZdZeed<dZeed<dZeed<dZ eed<e d„¦«Z de fd „Z ejd „¦«Zejd „¦«Zd ede fd „ZdS)Ú_AbstractPackageFeaturezO Provides an interface for installing *PACKAGE_NAME* in the background NÚNAMEÚ PACKAGE_NAMEÚINSTALL_LOG_FILE_MASKÚREMOVE_LOG_FILE_MASKcóJ—tj¦«tjzrdndS)Nzapt-getÚyum)rÚid_likeÚDEBIAN©Úselfs úJ/opt/imunify360/venv/lib/python3.11/site-packages/imav/patchman/feature.pyÚpackage_managerz'_AbstractPackageFeature.package_manager1s)€õÔ$Ñ&Ô&­Ô)=Ñ=ð ˆIˆIàð óÚreturncƒóK—|jS©Nr rs rÚ_check_installed_implz-_AbstractPackageFeature._check_installed_impl9sèè€ØÔ Ð rcƒóK—t|j›d|j›|jt t jd¬¦«¬¦«ƒd{V—†S)Nz -y install Únoninteractive)ÚDEBIAN_FRONTEND)Úenv)rrrrÚdictÚosÚenvironrs rÚinstallz_AbstractPackageFeature.install<skèè€å$ØÔ#Ð DÐ D°Ô1BÐ DÐ DØ Ô &Ý•R”ZÐ1AÐBÑBÔBð ñ ô ð ð ð ð ð ð ð rcƒóZK—t|j›d|j›|j¦«ƒd{V—†S)Nz -y remove )rrrrrs rÚremovez_AbstractPackageFeature.removeDsSèè€å$ØÔ#Ð CÐ C°Ô0AÐ CÐ CØ Ô %ñ ô ð ð ð ð ð ð ð rÚstatuscƒó^K—| ¦«ƒd{V—†dd}||kS)NÚitemsr+)r+)rr+Úcurrent_statuss rÚ has_statusz"_AbstractPackageFeature.has_statusKs:èè€Ø $§ ¢ ¡ ¤ Ð-Ð-Ð-Ð-Ð-Ð-¨wÔ7¸ÔAˆØ Ò'Ð'r)Ú__name__Ú __module__Ú __qualname__Ú__doc__rÚstrÚ__annotations__rrrÚpropertyrÚboolr rÚraise_if_shouldnt_install_nowr(Úraise_if_shouldnt_remove_nowr*r r/©rrrr'sø€€€€€€ððð€Dˆ#ÐÐÑØ€L#ÐÐÑØ!%И3Ð%Ð%Ñ%Ø $И#Ð$Ð$Ñ$à ð ð ñ„Xð ð!¨Tð!ð!ð!ð!ðÔ2ð ð ñ3Ô2ð ðÔ1ð ð ñ2Ô1ð ð ( }ð(¸ð(ð(ð(ð(ð(ð(rrcóX—eZdZdZeZdej›dZdej›dZ e d„¦«Z dS)ÚPatchmanFeatureÚpatchmanú /var/log/z/install-patchman.log.*z/remove-patchman.log.*có—t¦«Sr)Úis_patchman_installedrs rr zPatchmanFeature.is_installedVs€å$Ñ&Ô&Ð&rN) r0r1r2rr rrÚPRODUCTrrr6r r:rrr<r<Ps]€€€€€Ø €DØ#€LØM¨¬ ÐMÐMÐMÐØK t¤|ÐKÐKÐKÐà ð'ð'ñ„Xð'ð'ð'rr<cón‡—eZdZdZeZdej›dZdej›dZ e de fd„¦«Z ˆfd„Z ˆxZS)ÚRealtimeFeaturez realtime-avr>z/install-realtime-av.log.*z/remove-realtime-av.log.*rcó—t¦«Sr)Úis_realtime_av_installedrs rr zRealtimeFeature.is_installedcs€å'Ñ)Ô)Ð)rcƒó„•K—tstd¦«‚t¦« ¦«ƒd{V—†dS)NzKCan't remove imunify-realtime-av, since it is a part of imunify360-firewall)rrÚsuperr*)rÚ __class__s €rr*zRealtimeFeature.removegsTøèè€Ýð Ýð<ñôð õ‰gŒgnŠnÑÔÐÐÐÐÐÐÐÐÐr)r0r1r2rr rrrArrr6r7r r*Ú __classcell__)rHs@rrCrC[s’ø€€€€€Ø €DØ#€LàrPsXðððð* € € € àAÐAÐAÐAÐAÐAÐAÐAØ@Ð@Ð@Ð@Ð@Ð@Ð@Ð@ððððððððððð 5Ð4Ð4Ð4Ð4Ð4ðððððððððFÐEÐEÐEÐEÐEð&(ð&(ð&(ð&(ð&(˜oñ&(ô&(ð&(ðR'ð'ð'ð'ð'Ð-ñ'ô'ð'ðððððÐ-ñôðððr