🔐 Sid Gifari File Manager Pro
v8.0.5 | 2026-06-15 07:51:55 | PHP 8.1.34
📂
/ (Root)
/
opt
/
imunify360
/
venv
/
lib
/
python3.11
/
site-packages
/
defence360agent
/
migrations
📍 /opt/imunify360/venv/lib/python3.11/site-packages/defence360agent/migrations
🔄 Refresh
✏️
Editing: 051_cleanup_vd_license.py
Read Only
import json import logging from contextlib import suppress logger = logging.getLogger(__name__) class VirusdieLicense: CONFIG_FILE = "/usr/local/vdserver/config.json" def unregister(self): self._write_key("") def _write_key(self, key): with open(self.CONFIG_FILE) as read_file: content = json.load(read_file) content["vdbApiKey"] = key with open(self.CONFIG_FILE, "w") as write_file: json.dump( content, write_file, sort_keys=True, indent=2, separators=(",", ": "), ) def migrate(migrator, database, fake=False, **kwargs): """Write your migrations here.""" with suppress(FileNotFoundError): VirusdieLicense().unregister() def rollback(migrator, database, fake=False, **kwargs): """Write your rollback migrations here.""" pass
💾 Save Changes
❌ Cancel