From ad9f410c7f3dfa698165b1e6f0e70699a46a6b52 Mon Sep 17 00:00:00 2001 From: David CARNOT Date: Wed, 19 Jun 2019 11:07:46 +0200 Subject: [PATCH] First version of GLPISCAN --- GLPIScan.py | 54 ++++++++ inc/Config.py | 153 +++++++++++++++++++++ inc/Credentials.py | 50 +++++++ inc/Exploits.py | 34 +++++ inc/Files.py | 31 +++++ inc/ImportPlugin.py | 16 +++ inc/Infos.py | 53 +++++++ inc/Plugins.py | 28 ++++ inc/__init__.py | 0 plugins/PluginAirwatchConnector.py | 21 +++ plugins/PluginAppsStructureInventory.py | 21 +++ plugins/PluginBadgesInventory.py | 21 +++ plugins/PluginBarcode.py | 21 +++ plugins/PluginBrowserNotification.py | 21 +++ plugins/PluginCartography.py | 21 +++ plugins/PluginCleanArchivedEmails.py | 21 +++ plugins/PluginCredit.py | 21 +++ plugins/PluginDashboard.py | 21 +++ plugins/PluginDataInjection.py | 21 +++ plugins/PluginDataflowsInventory.py | 21 +++ plugins/PluginDiagrams.py | 21 +++ plugins/PluginDomainsInventory.py | 21 +++ plugins/PluginEscalade.py | 21 +++ plugins/PluginFields.py | 21 +++ plugins/PluginFormCreator.py | 21 +++ plugins/PluginFunctionalAreas.py | 21 +++ plugins/PluginFusionInventory.py | 21 +++ plugins/PluginGLPICheckingVersion.py | 21 +++ plugins/PluginGenericObjectsManagement.py | 21 +++ plugins/PluginHistoricalPurge.py | 21 +++ plugins/PluginImpacts.py | 21 +++ plugins/PluginInventoryNumberGeneration.py | 21 +++ plugins/PluginItilCategoryGroups.py | 21 +++ plugins/PluginLaunchShellCommands.py | 21 +++ plugins/PluginMDTConnector.py | 21 +++ plugins/PluginMailAnalyzer.py | 21 +++ plugins/PluginMantis.py | 21 +++ plugins/PluginMask.py | 21 +++ plugins/PluginMetabase.py | 21 +++ plugins/PluginMoreReporting.py | 21 +++ plugins/PluginMyDashboard.py | 21 +++ plugins/PluginNetworkEquipmentBackup.py | 21 +++ plugins/PluginNews.py | 21 +++ plugins/PluginOpenVAS.py | 21 +++ plugins/PluginOrderManagement.py | 21 +++ plugins/PluginOrderService.py | 21 +++ plugins/PluginProcessmaker.py | 21 +++ plugins/PluginRacks.py | 21 +++ plugins/PluginRoom.py | 21 +++ plugins/PluginSCCM.py | 21 +++ plugins/PluginStatecheck.py | 21 +++ plugins/PluginTag.py | 21 +++ plugins/PluginTasksList.py | 21 +++ plugins/PluginTelegramBot.py | 21 +++ plugins/PluginTimelineticket.py | 21 +++ plugins/PluginTimezones.py | 21 +++ plugins/PluginTypology.py | 21 +++ plugins/PluginUninstall.py | 21 +++ plugins/PluginUsedItemsExport.py | 21 +++ plugins/PluginXivo.py | 21 +++ plugins/__init__.py | 0 61 files changed, 1490 insertions(+) create mode 100644 GLPIScan.py create mode 100644 inc/Config.py create mode 100644 inc/Credentials.py create mode 100644 inc/Exploits.py create mode 100644 inc/Files.py create mode 100644 inc/ImportPlugin.py create mode 100644 inc/Infos.py create mode 100644 inc/Plugins.py create mode 100644 inc/__init__.py create mode 100644 plugins/PluginAirwatchConnector.py create mode 100644 plugins/PluginAppsStructureInventory.py create mode 100644 plugins/PluginBadgesInventory.py create mode 100644 plugins/PluginBarcode.py create mode 100644 plugins/PluginBrowserNotification.py create mode 100644 plugins/PluginCartography.py create mode 100644 plugins/PluginCleanArchivedEmails.py create mode 100644 plugins/PluginCredit.py create mode 100644 plugins/PluginDashboard.py create mode 100644 plugins/PluginDataInjection.py create mode 100644 plugins/PluginDataflowsInventory.py create mode 100644 plugins/PluginDiagrams.py create mode 100644 plugins/PluginDomainsInventory.py create mode 100644 plugins/PluginEscalade.py create mode 100644 plugins/PluginFields.py create mode 100644 plugins/PluginFormCreator.py create mode 100644 plugins/PluginFunctionalAreas.py create mode 100644 plugins/PluginFusionInventory.py create mode 100644 plugins/PluginGLPICheckingVersion.py create mode 100644 plugins/PluginGenericObjectsManagement.py create mode 100644 plugins/PluginHistoricalPurge.py create mode 100644 plugins/PluginImpacts.py create mode 100644 plugins/PluginInventoryNumberGeneration.py create mode 100644 plugins/PluginItilCategoryGroups.py create mode 100644 plugins/PluginLaunchShellCommands.py create mode 100644 plugins/PluginMDTConnector.py create mode 100644 plugins/PluginMailAnalyzer.py create mode 100644 plugins/PluginMantis.py create mode 100644 plugins/PluginMask.py create mode 100644 plugins/PluginMetabase.py create mode 100644 plugins/PluginMoreReporting.py create mode 100644 plugins/PluginMyDashboard.py create mode 100644 plugins/PluginNetworkEquipmentBackup.py create mode 100644 plugins/PluginNews.py create mode 100644 plugins/PluginOpenVAS.py create mode 100644 plugins/PluginOrderManagement.py create mode 100644 plugins/PluginOrderService.py create mode 100644 plugins/PluginProcessmaker.py create mode 100644 plugins/PluginRacks.py create mode 100644 plugins/PluginRoom.py create mode 100644 plugins/PluginSCCM.py create mode 100644 plugins/PluginStatecheck.py create mode 100644 plugins/PluginTag.py create mode 100644 plugins/PluginTasksList.py create mode 100644 plugins/PluginTelegramBot.py create mode 100644 plugins/PluginTimelineticket.py create mode 100644 plugins/PluginTimezones.py create mode 100644 plugins/PluginTypology.py create mode 100644 plugins/PluginUninstall.py create mode 100644 plugins/PluginUsedItemsExport.py create mode 100644 plugins/PluginXivo.py create mode 100644 plugins/__init__.py diff --git a/GLPIScan.py b/GLPIScan.py new file mode 100644 index 0000000..0ac7ba1 --- /dev/null +++ b/GLPIScan.py @@ -0,0 +1,54 @@ +#!/usr/bin/python + +import os, argparse, chalk +from inc import Config, Infos, Credentials, Files, Plugins + +# Ugly way to clear shell +print("\033[H\033[J") +print(chalk.white(" ______ __ ______ __ ______ ______ ______ __ __ ", bold=True)) +print(chalk.white("/\\ ___\\ /\\ \\ /\\ == \\ /\\ \\ /\\ ___\\ /\\ ___\\ /\\ __ \\ /\\ \"-.\\ \\ ", bold=True)) +print(chalk.white("\\ \\ \\__ \\ \\ \\ \\____ \\ \\ __/ \\ \\ \\ \\ \\___ \\ \\ \\ \\____ \\ \\ __ \\ \\ \\ \\-. \\ ", bold=True)) +print(chalk.white(" \\ \\_____\\ \\ \\_____\\ \\ \\_\\ \\ \\_\\ \\/\\_____\\ \\ \\_____\\ \\ \\_\\ \\_\\ \\ \\_\\\"\\_\\", bold=True)) +print(chalk.white(" \\/_____/ \\/_____/ \\/_/ \\/_/ \\/_____/ \\/_____/ \\/_/\\/_/ \\/_/ \\/_/", bold=True)) +print(chalk.white(" v1.0 contact[@]digitemis.com\n\n\n", bold=True)) + +def parsing(): + parser = argparse.ArgumentParser(description='GLPI Vulnerability Scanner.') + parser.add_argument('-u', dest='url', metavar="url", required=True, help='URL of GLPI application') + parser.add_argument('-a', dest='allcheck', action='store_true', default=False, help='Perform allcheck') + parser.add_argument('-c', dest='credscheck', action='store_true', default=False, help='Perform Credential Check') + parser.add_argument('-f', dest='filescheck', action='store_true', default=False, help='Perform Files Check') + parser.add_argument('-p', dest='pluginscheck', action='store_true', default=False, help='Perform Plugin Check') + parser.add_argument('-d', dest='debug', action='store_true', default=False, help='Debug mode') + args = parser.parse_args() + + Config.DEBUG = args.debug + Config.BASE_URL = args.url + Config.ALLCHECK = args.allcheck + Config.CREDSCHECK = args.credscheck + Config.FILESCHECK = args.filescheck + Config.PLUGINSCHECK = args.pluginscheck + + if Config.DEBUG: + print("[DEBUG] Debug mode : ON") + print("[DEBUG] GLPI url : " + Config.BASE_URL) + print("[DEBUG] Checking everything : " + str(Config.ALLCHECK)) + print("[DEBUG] Checking Default Creds : " + str(Config.CREDSCHECK)) + print("[DEBUG] Checking Default File : " + str(Config.FILESCHECK)) + print("[DEBUG] Checking Default Plugins : " + str(Config.PLUGINSCHECK)) + print("") + +def main(): + parsing() + print(chalk.white("[+] GLPI Scan start : " + Config.BASE_URL + "\n", bold=True)) + if (Infos.UrlCheck().getInfo()): + if (Config.ALLCHECK or Config.CREDSCHECK): + Credentials.CredentialsCheck().credentials() + + if (Config.ALLCHECK or Config.FILESCHECK): + Files.FilesCheck().files() + + if (Config.ALLCHECK or Config.PLUGINSCHECK): + Plugins.PluginsCheck().plugins() + +main() diff --git a/inc/Config.py b/inc/Config.py new file mode 100644 index 0000000..9fa120b --- /dev/null +++ b/inc/Config.py @@ -0,0 +1,153 @@ +import requests +requests.packages.urllib3.disable_warnings() + +# Debug mode is disable by default +DEBUG = False + +# Base URL of the scanned GLPI +BASE_URL = "" + +# Root folder of the scanned GLPI +ROOT_DOC = "/" + +# Version of the scanned GLPI +VERSION = "" + +# By default do not perfom all checks on GLPI +ALLCHECK = False + +# By default do not perfom credentials checks on GLPI +CREDSCHECK = False + +# By default do not perfom files checks on GLPI +FILESCHECK = False + +# By default do not perfom plugins checks on GLPI +PLUGINSCHECK = False + +COOKIE = "" + +FILES = ['/ajax/telemetry.php', + '/CHANGELOG.md', + '/status.php', + '/files/_log/cron.log', + '/files/_log/event.log', + '/files/_log/php-errors.log'] + +FOLDERS = ['/files/', + '/files/_dumps/', + '/plugins/'] + +# ['USER', 'PASSWORD'] +USERS = [['glpi','glpi'], + ['post-only','postonly'], + ['tech','tech'], + ['normal', 'normal']] + +# ['URL_VERIFY', 'PLUGIN_NAME', 'PLUGIN_URL', 'PLUGIN_CLASS'] +PLUGINS = [['/plugins/addressing/LICENSE', 'IP Report', 'https://plugins.glpi-project.org/#/plugin/addressing', False], + ['/plugins/fusioninventory/js/footer.js', 'FusionInventory', 'https://plugins.glpi-project.org/#/plugin/fusioninventory', 'PluginFusionInventory'], + ['/plugins/dashboard/changelog.txt', 'Dashboard', 'https://plugins.glpi-project.org/#/plugin/dashboard', 'PluginDashboard'], + ['/plugins/datainjection/datainjection.xml', 'Data Injection', 'https://plugins.glpi-project.org/#/plugin/datainjection', 'PluginDataInjection'], + ['/plugins/fields/plugin.xml', 'Fields', 'https://plugins.glpi-project.org/#/plugin/field', 'PluginFields'], + ['/plugins/formcreator/package.json', 'FormCreator', 'https://plugins.glpi-project.org/#/plugin/formcreator', 'PluginFormCreator'], + ['/plugins/genericobject/genericobject.xml', 'Generic Objects Management', 'https://plugins.glpi-project.org/#/plugin/genericobject', 'PluginGenericObjectsManagement'], + ['/plugins/mreporting/mreporting.xml', 'More Reporting', 'https://plugins.glpi-project.org/#/plugin/mreporting', 'PluginMoreReporting'], + ['/plugins/ocsinventoryng/docs/CHANGELOG.txt', 'OCS Inventory NG', 'https://plugins.glpi-project.org/#/plugin/ocsinventoryng', False], + ['/plugins/reports/LICENSE', 'Reports', 'https://plugins.glpi-project.org/#/plugin/reports', False], + ['/plugins/pdf/LICENSE', 'PDF', 'https://plugins.glpi-project.org/#/plugin/pdf', False], + ['/plugins/archires/LICENSE', 'Network Architecture', 'https://plugins.glpi-project.org/#/plugin/archires', False], + ['/plugins/room/room.xml', 'Room Management', 'https://plugins.glpi-project.org/#/plugin/room', 'PluginRoom'], + ['/plugins/racks/locales/glpi.pot', 'Racks / Bays Management', 'https://plugins.glpi-project.org/#/plugin/racks', 'PluginRacks'], + ['/plugins/manageentities/LICENSE', 'Entities Management', 'https://plugins.glpi-project.org/#/plugin/manageentities', False], + ['/plugins/accounts/LICENSE', 'Accounts Inventory', 'https://plugins.glpi-project.org/#/plugin/accounts', False], + ['/plugins/appliances/LICENSE', 'Appliances Inventory', 'https://plugins.glpi-project.org/#/plugin/appliances', False], + ['/plugins/badges/locales/glpi.pot', 'Badges Inventory', 'https://plugins.glpi-project.org/#/plugin/badges', 'PluginBadgesInventory'], + ['/plugins/certificates/LICENSE', 'Certificates Inventory', 'https://plugins.glpi-project.org/#/plugin/certificates', False], + ['/plugins/databases/LICENSE', 'Databases Inventory', 'https://plugins.glpi-project.org/#/plugin/databases', False], + ['/plugins/domains/locales/glpi.pot', 'Domains Inventory', 'https://plugins.glpi-project.org/#/plugin/domains', 'PluginDomainsInventory'], + ['/plugins/financialreports/LICENSE', 'Financial Reports', 'https://plugins.glpi-project.org/#/plugin/financialreports', False], + ['/plugins/environment/LICENSE', 'Meta-Plugin Environment', 'https://plugins.glpi-project.org/#/plugin/environment', False], + ['/plugins/shellcommands/locales/glpi.pot', 'Launch Shell Commands', 'https://plugins.glpi-project.org/#/plugin/shellcommands', 'PluginLaunchShellCommands'], + ['/plugins/webapplications/LICENSE', 'Web Applications Inventory', 'https://plugins.glpi-project.org/#/plugin/webapplications', False], + ['/plugins/order/plugin.xml', 'Order Management', 'https://plugins.glpi-project.org/#/plugin/order', 'PluginOrderManagement'], + ['/plugins/uninstall/uninstall.xml', 'Uninstall', 'https://plugins.glpi-project.org/#/plugin/uninstall', 'PluginUninstall'], + ['/plugins/geninventorynumber/plugin.xml', 'Inventory Number Generation', 'https://plugins.glpi-project.org/#/plugin/geninventorynumber', 'PluginInventoryNumberGeneration'], + ['/plugins/behaviors/LICENSE', 'Behaviors', 'https://plugins.glpi-project.org/#/plugin/behaviors', False], + ['/plugins/barcode/barcode.xml', 'Barcode', 'https://plugins.glpi-project.org/#/plugin/barcode', 'PluginBarcode'], + ['/plugins/positions/locales/glpi.pot', 'Cartography', 'https://plugins.glpi-project.org/#/plugin/positions', 'PluginCartography'], + ['/plugins/typology/locales/glpi.pot', 'Typology', 'https://plugins.glpi-project.org/#/plugin/typology', 'PluginTypology'], + ['/plugins/mask/mask.xml', 'Mask', 'https://plugins.glpi-project.org/#/plugin/mask', 'PluginMask'], + ['/plugins/surveyticket/LICENSE', 'SurveyTicket', 'https://plugins.glpi-project.org/#/plugin/surveyticket', False], + ['/plugins/mantis/mantis.xml', 'MantisBT synchronization', 'https://plugins.glpi-project.org/#/plugin/mantis', 'PluginMantis'], + ['/plugins/reservation/LICENCE', 'Reservation', 'https://plugins.glpi-project.org/#/plugin/reservation', False], + ['/plugins/timezones/timezones.xml', 'Timezones', 'https://plugins.glpi-project.org/#/plugin/timezones', 'PluginTimezones'], + ['/plugins/sccm/sccm.xml', 'SCCM', 'https://plugins.glpi-project.org/#/plugin/sccm', 'PluginSCCM'], + ['/plugins/tag/plugin.xml', 'Tag', 'https://plugins.glpi-project.org/#/plugin/tag', 'PluginTag'], + ['/plugins/news/plugin.xml', 'News', 'https://plugins.glpi-project.org/#/plugin/news', 'PluginNews'], + ['/plugins/purgelogs/plugin.xml', 'Historical purge', 'https://plugins.glpi-project.org/#/plugin/purgelogs', 'PluginHistoricalPurge'], + ['/plugins/escalade/escalade.xml', 'Escalade', 'https://plugins.glpi-project.org/#/plugin/escalade', 'PluginEscalade'], + ['/plugins/moreticket/LICENSE', 'Moreticket', 'https://plugins.glpi-project.org/#/plugin/moreticket', False], + ['/plugins/itilcategorygroups/itilcategorygroups.xm l', 'ItilCategory Groups', 'https://plugins.glpi-project.org/#/plugin/itilcategorygroups', 'PluginItilCategoryGroups'], + ['/plugins/consumables/LICENSE', 'Consumables', 'https://plugins.glpi-project.org/#/plugin/consumables', False], + ['/plugins/printercounters/LICENSE', 'PrinterCounters', 'https://plugins.glpi-project.org/#/plugin/printercounters', False], + ['/plugins/processmaker/processmaker.xml', 'Processmaker', 'https://plugins.glpi-project.org/#/plugin/processmaker', 'PluginProcessmaker'], + ['/plugins/seasonality/README.md', 'Seasonality', 'https://plugins.glpi-project.org/#/plugin/seasonality', False], + ['/plugins/tasklists/locales/glpi.pot', 'Tasks List (Kanban)', 'https://plugins.glpi-project.org/#/plugin/tasklists', 'PluginTasksList'], + ['/plugins/mailanalyzer/mailanalyzer.xml', 'Mail Analyzer', 'https://plugins.glpi-project.org/#/plugin/mailanalyzer', 'PluginMailAnalyzer'], + ['/plugins/mydashboard/locales/glpi.pot', 'My Dashboard', 'https://plugins.glpi-project.org/#/plugin/mydashboard', 'PluginMyDashboard'], + ['/plugins/timelineticket/locales/glpi.pot', 'Timelineticket', 'https://plugins.glpi-project.org/#/plugin/timelineticket', 'PluginTimelineticket'], + ['/plugins/airwatch/airwatch.xml', 'Airwatch connector', 'https://plugins.glpi-project.org/#/plugin/airwatch', 'PluginAirwatchConnector'], + ['/plugins/archifun/funcarea.xml', 'Functional Areas', 'https://plugins.glpi-project.org/#/plugin/archifun', 'PluginFunctionalAreas'], + ['/plugins/useditemsexport/plugin.xml', 'Used items export', 'https://plugins.glpi-project.org/#/plugin/useditemsexport', 'PluginUsedItemsExport'], + ['/plugins/nebackup/nebackup.xml', 'Network Equipment Backup', 'https://plugins.glpi-project.org/#/plugin/nebackup', 'PluginNetworkEquipmentBackup'], + ['/plugins/openvas/openvas.xml', 'OpenVAS', 'https://plugins.glpi-project.org/#/plugin/openvas', 'PluginOpenVAS'], + ['/plugins/browsernotification/browsernotification.xml', 'Browser Notification', 'https://plugins.glpi-project.org/#/plugin/browsernotification', 'PluginBrowserNotification'], + ['/plugins/credit/plugin.xml', 'Credit', 'https://plugins.glpi-project.org/#/plugin/credit', 'PluginCredit'], + ['/plugins/xivo/xivo.xml', 'xivo', 'https://plugins.glpi-project.org/#/plugin/xivo', 'PluginXivo'], + ['/plugins/glpi2mdt/glpi2mdt.xml', 'GLPI to MDT connector', 'https://plugins.glpi-project.org/#/plugin/glpi2mdt', 'PluginMDTConnector'], + ['/plugins/telegrambot/telegrambot.xml', 'TelegramBot', 'https://plugins.glpi-project.org/#/plugin/telegrambot', 'PluginTelegramBot'], + ['/plugins/cleanarchivedemails/cleanarchivedemails.xml', 'Clean Archived Emails', 'https://plugins.glpi-project.org/#/plugin/cleanarchivedemails', 'PluginCleanArchivedEmails'], + ['/plugins/officeonline/js/officeonline.js', 'Office Online', 'https://plugins.glpi-project.org/#/plugin/officeonline', False], + ['/plugins/satisfaction/satisfaction.js', 'More satisfaction', 'https://plugins.glpi-project.org/#/plugin/satisfaction', False], + ['/plugins/gdrive/README.md', 'GDrive', 'https://plugins.glpi-project.org/#/plugin/GDrive', False], + ['/plugins/archisw/archisw.xml', 'Apps structure inventory', 'https://plugins.glpi-project.org/#/plugin/archisw', 'PluginAppsStructureInventory'], + ['/plugins/dataflows/dataflows.xml', 'Dataflows inventory', 'https://plugins.glpi-project.org/#/plugin/dataflows', 'PluginDataflowsInventory'], + ['/plugins/statecheck/statecheck.xml', 'Statecheck', 'https://plugins.glpi-project.org/#/plugin/statecheck', 'PluginStatecheck'], + ['/plugins/archimap/archimap.xml', 'Diagrams', 'https://plugins.glpi-project.org/#/plugin/archimap', 'PluginDiagrams'], + ['/plugins/metabase/metabase.xml', 'Metabase', 'https://plugins.glpi-project.org/#/plugin/metabase', 'PluginMetabase'], + ['/plugins/orderservice/orderservice.xml', 'Order Service', 'https://plugins.glpi-project.org/#/plugin/orderservice', 'PluginOrderService'], + ['/plugins/glpicheckingversion/glpicheckingversion.xml', 'GLPI Checking Version', 'https://plugins.glpi-project.org/#/plugin/glpicheckingversion', 'PluginGLPICheckingVersion'], + ['/plugins/taskdrop/LICENSE', 'Task n Drop', 'https://plugins.glpi-project.org/#/plugin/TaskDrop', False], + ['/plugins/impacts/impacts.xml', 'Impacts', 'https://plugins.glpi-project.org/#/plugin/impacts', 'PluginImpacts'], + ] + +# ['VENDOR', ['OPERANDE', 'VERSION'], 'DESC' ,'LINK', 'CVE'] +CVE = [ + ['GLPI', [['<', '0.80.2']], 'Sensitive information disclosure' ,'https://nvd.nist.gov/vuln/detail/CVE-2011-2720', 'CVE-2011-2720'], + ['GLPI', [['>=', '0.78'], ['<=', '0.80.61']], 'Remote file inclusion vulnerability in front/popup.php' ,'https://seclists.org/fulldisclosure/2012/Feb/157', 'CVE-2012-1037'], + ['GLPI', [['<', '0.83.3']], 'Cross-site request forgery (CSRF)' ,'http://www.prajalkulkarni.com/2012/10/multiple-csrf-and-xss-vulnerabilities.html', 'CVE-2012-4002'], + ['GLPI', [['<', '0.83.3']],'Multiple cross-site scripting', 'http://www.prajalkulkarni.com/2012/10/multiple-csrf-and-xss-vulnerabilities.html', 'CVE-2012-4003'], + ['GLPI', [['=', '0.83.9']], 'Unserialize() Remote Code Execution' ,'https://www.exploit-db.com/exploits/26530', 'CVE-2013-2225'], + ['GLPI', [['>=', '0.83'], ['<=', '0.83.8']], 'Multiple Error-based SQL Injection' ,'https://downloads.securityfocus.com/vulnerabilities/exploits/60693.txt', 'CVE-2013-2226'], + ['GLPI', [['<', '0.84.2']], 'GLPI install.php Remote Command Execution' ,'https://www.exploit-db.com/exploits/28483', 'CVE-2013-5696'], + ['GLPI', [['<', '0.84.7']], 'Access control defecting on cost criteria' ,'https://nvd.nist.gov/vuln/detail/CVE-2014-5032', 'CVE-2014-5032'], + ['GLPI', [['<', '0.84.8']], 'Directory traversal vulnerability in inc/autoload.function.php' ,'http://tlk.tuxfamily.org/doku.php?id=writeup:cve-2014-8360', 'CVE-2014-8360'], + ['GLPI', [['<', '0.85.1']], 'Blind SQL Injection in ajax/getDropdownValue.php' ,'https://www.exploit-db.com/exploits/35528', 'CVE-2014-9258'], + ['GLPI', [['<=', '0.85.2']], 'Privilege escalation' ,'https://seclists.org/fulldisclosure/2015/Feb/71', 'CVE-2015-7685'], + ['GLPI', [['>=', '0.85.0'], ['<=', '0.85.2']], 'Remote Code Execution' ,'https://seclists.org/fulldisclosure/2015/Feb/71', 'CVE-2015-7684'], + ['GLPI', [['=', '0.90.4']], 'Cross-Site Request Forgery' ,'https://nvd.nist.gov/vuln/detail/CVE-2016-7507', 'CVE-2016-7507'], + ['GLPI', [['=', '0.90.4']], 'Multiple SQL injection' ,'https://www.exploit-db.com/exploits/42262', 'CVE-2016-7508'], + ['GLPI', [['=', '0.90.4']], 'Store XSS in Ticket' ,'https://nvd.nist.gov/vuln/detail/CVE-2016-7509', 'CVE-2016-7509'], + ['GLPI', [['<=', '9.1.5']], 'front/backup.php file denial of service' ,'https://nvd.nist.gov/vuln/detail/CVE-2017-11183', 'CVE-2017-11183'], + ['GLPI', [['<', '9.1.5']], 'SQL injection in front/devicesoundcard.php' ,'https://github.com/glpi-project/glpi/issues/2450', 'CVE-2017-11183'], + ['GLPI', [['<=', '9.2.1']], 'Cross Site Scripting in /front/preference.php' ,'https://members.backbox.org/glpi-9-2-1-multiple-vulnerabilities/', 'CVE-2018-7563'], + ['GLPI', [['<', '9.1.5']], 'SQL injection in front/devicesoundcard.php' ,'https://github.com/glpi-project/glpi/issues/2449', 'CVE-2017-11184'], + ['GLPI', [['<', '9.1.5']], 'SQL injection in ajax/getDropdownValue.php' ,'https://github.com/glpi-project/glpi/issues/2456', 'CVE-2017-11329'], + ['GLPI', [['<', '9.1.5.1']], 'SQL injection in ajax/common.tabs.php' ,'https://github.com/glpi-project/glpi/issues/2475', 'CVE-2017-11474'], + ['GLPI', [['<', '9.1.5.1']], 'SQL injection in front/rulesengine.test.php' ,'https://github.com/glpi-project/glpi/issues/2476', 'CVE-2017-11475'], + ['GLPI', [['<=', '9.2.1']], 'Remote code execution' ,'https://github.com/bowline90/RemoteCodeUploadGLPI', 'CVE-2018-7562'], + ['GLPI', [['<=', '9.3.3']], 'Pre-authenticated SQL injection' ,'https://www.synacktiv.com/ressources/advisories/GLPI_9.3.3_SQL_Injection.pdf', 'CVE-2019-10232'], + ['GLPI', [['<=', '9.4.1.1']], 'Type juggling authentication bypass', 'https://www.synacktiv.com/ressources/GLPI_9.4.0_Type_juggling_auth_bypass.pdf', 'CVE-2019-10231'], + ['GLPI', [['<=', '9.4.1.1']], 'Timing attack user enumeration', 'https://www.synacktiv.com/ressources/GLPI_9.4.0_Timing_attack_user_enumeration.pdf', 'CVE-2019-10233'], + ['FusionInventory', [['<=', '9.4.0']], 'Arbitrary PHP function call', 'https://www.synacktiv.com/ressources/GLPI_FusionInventory_9.4.0_Arbitrary_call_user_func_array.pdf', 'CVE-2019-10477']] diff --git a/inc/Credentials.py b/inc/Credentials.py new file mode 100644 index 0000000..42738d6 --- /dev/null +++ b/inc/Credentials.py @@ -0,0 +1,50 @@ +#!/usr/bin/python + +import Config + +import requests, chalk + +class CredentialsCheck: + + def getLoginField(self, content): + login = content[content.find('= parse(v[1]): + return False + if v[0] == "<=" and parse(version) > parse(v[1]): + return False + if v[0] == ">" and parse(version) <= parse(v[1]): + return False + if v[0] == ">=" and parse(version) < parse(v[1]): + return False + if v[0] == "=" and parse(version) is not parse(v[1]): + return False + return True + + def getCVE(self, CVE): + print(chalk.red('\n\t[+] Vulnerable to: ' + CVE[2], bold=True)) + print("\t[+] Reference: " + CVE[3]) + if CVE[4]: + print("\t[+] CVE: " + CVE[4]) + + def verifExploit(self, module, version): + print(chalk.white('\t[+] Looking for [', bold=True) + chalk.yellow(module, bold=True) + chalk.white('] exploits depending on version [', bold=True) + chalk.yellow(version, bold=True) + chalk.white(']', bold=True)) + for CVE in Config.CVE: + if CVE[0] == module and self.verifVersion(version, CVE[1]): + self.getCVE(CVE) diff --git a/inc/Files.py b/inc/Files.py new file mode 100644 index 0000000..ce62f8d --- /dev/null +++ b/inc/Files.py @@ -0,0 +1,31 @@ +#!/usr/bin/python + +import Config + +import requests, chalk + +class FilesCheck: + + def getFile(self, file): + if Config.DEBUG: + print("[DEBUG] GET : " + Config.BASE_URL + file) + r = requests.get(Config.BASE_URL + file, verify=False) + if (r.status_code == 200): + print(chalk.white('[+] Interesting file found : ', bold=True) + chalk.red(Config.BASE_URL + file, bold=True)) + + def getFolder(self, folder): + if Config.DEBUG: + print("[DEBUG] GET : " + Config.BASE_URL + folder) + r = requests.get(Config.BASE_URL + folder, verify=False) + if (r.status_code == 200): + print(chalk.white('[+] Interesting folder found : ', bold=True) + chalk.red(Config.BASE_URL + folder, bold=True)) + + def files(self): + print(chalk.green('\n[+] Performing default files check', bold=True)) + print(chalk.green('==================================\n', bold=True)) + for file in Config.FILES: + self.getFile(file) + print(chalk.green('\n[+] Performing default folders check', bold=True)) + print(chalk.green('====================================\n', bold=True)) + for folder in Config.FOLDERS: + self.getFolder(folder) \ No newline at end of file diff --git a/inc/ImportPlugin.py b/inc/ImportPlugin.py new file mode 100644 index 0000000..b0f9d95 --- /dev/null +++ b/inc/ImportPlugin.py @@ -0,0 +1,16 @@ +#!/usr/bin/python + +import Config + +import importlib, inspect + +class ImportPlugin: + + def importModule(self, name): + if Config.DEBUG: + print("[!] Import Plugin : " + name) + module = importlib.import_module('plugins.' + name) + for name, obj in inspect.getmembers(module): + if inspect.isclass(obj): + return obj() + return None \ No newline at end of file diff --git a/inc/Infos.py b/inc/Infos.py new file mode 100644 index 0000000..6a76347 --- /dev/null +++ b/inc/Infos.py @@ -0,0 +1,53 @@ +#!/usr/bin/python + +import Config, Exploits + +from urlparse import urlparse +import requests, json, chalk + +class UrlCheck: + + def getURLBase(self, content): + if (content.find("'url_base': '") != -1): + url_base = content[content.find("'url_base': '")+len("'url_base': '"):] + url_base = url_base[:url_base.find("'")] + Config.BASE_URL = url_base + print(chalk.white('[+] url_base : ', bold=True) + chalk.yellow(Config.BASE_URL, bold=True)) + + def getRootDoc(self, content): + if (content.find("'root_doc': '") != -1): + root_doc = content[content.find("'root_doc': '")+len("'root_doc': '"):] + root_doc = root_doc[:root_doc.find("'")] + Config.ROOT_DOC = root_doc + print(chalk.white('[+] root_doc : ', bold=True) + chalk.yellow(Config.ROOT_DOC, bold=True)) + + def getVersion(self): + if Config.DEBUG: + print("[DEBUG] GET : " + Config.BASE_URL) + r = requests.get(Config.BASE_URL, verify=False) + version = r.content[r.content.find('?v=')+len('?v='):] + version = version[:version.find('"')] + Config.VERSION = version + print(chalk.white('[+] Version of GLPI : ', bold=True) + chalk.yellow(Config.VERSION, bold=True)) + Exploits.ExploitsCheck().verifExploit('GLPI', Config.VERSION) + + def checkServer(self): + try: + if Config.DEBUG: + print("[DEBUG] GET : " + Config.BASE_URL) + r = requests.get(Config.BASE_URL, timeout=10, verify=False) + print(chalk.white('[+] Server Header : ', bold=True) + chalk.yellow(r.headers['Server'], bold=True)) + self.getURLBase(r.content) + self.getRootDoc(r.content) + self.getVersion() + return True + except Exception as e: + print(chalk.red('[-] ' + Config.BASE_URL + ' seems not accessible', bold=True)) + return False + + def getInfo(self): + print(chalk.green('[+] Gathering basic information', bold=True)) + print(chalk.green('===============================\n', bold=True)) + if (self.checkServer()): + return True + return False \ No newline at end of file diff --git a/inc/Plugins.py b/inc/Plugins.py new file mode 100644 index 0000000..724bcb0 --- /dev/null +++ b/inc/Plugins.py @@ -0,0 +1,28 @@ +#!/usr/bin/python + +import Config + +from inc import ImportPlugin + +import requests, chalk + +class PluginsCheck: + + def getPlugin(self, plugin): + if Config.DEBUG: + print("[DEBUG] GET : " + Config.BASE_URL + plugin[0]) + r = requests.get(Config.BASE_URL + plugin[0], verify=False) + if (r.status_code == 200): + print(chalk.white('\n[+] Plugin [', bold=True) + chalk.yellow(plugin[1], bold=True) + chalk.white('] found !', bold=True)) + if plugin[3]: + obj = ImportPlugin.ImportPlugin().importModule(plugin[3]) + obj.initPlugin(plugin) + else: + print(chalk.white('\t[-] Version not found : ', bold=True) + chalk.yellow(Config.BASE_URL + plugin[0], bold=True)) + + + def plugins(self): + print(chalk.green('\n[+] Performing Plugins check', bold=True)) + print(chalk.green('============================', bold=True)) + for plugin in Config.PLUGINS: + self.getPlugin(plugin) diff --git a/inc/__init__.py b/inc/__init__.py new file mode 100644 index 0000000..e69de29 diff --git a/plugins/PluginAirwatchConnector.py b/plugins/PluginAirwatchConnector.py new file mode 100644 index 0000000..0194d2d --- /dev/null +++ b/plugins/PluginAirwatchConnector.py @@ -0,0 +1,21 @@ +#!/usr/bin/python + +from inc import Config, Exploits + +import requests, chalk + +class PluginAirwatchConnector: + + def getVersion(self, info): + if Config.DEBUG: + print("[DEBUG] GET : " + Config.BASE_URL + info[0]) + r = requests.get(Config.BASE_URL + info[0]) + content = r.content + version = content[content.find('') + len(''):] + version = version[:version.find('<')] + print(chalk.white('\t[+] Version of [', bold=True) + chalk.yellow(info[1], bold=True) + chalk.white('] : [', bold=True) + chalk.yellow(version, bold=True) + chalk.white(']', bold=True)) + return version + + def initPlugin(self, info): + version = self.getVersion(info) + Exploits.ExploitsCheck().verifExploit(info[1], version) diff --git a/plugins/PluginAppsStructureInventory.py b/plugins/PluginAppsStructureInventory.py new file mode 100644 index 0000000..f2ea294 --- /dev/null +++ b/plugins/PluginAppsStructureInventory.py @@ -0,0 +1,21 @@ +#!/usr/bin/python + +from inc import Config, Exploits + +import requests, chalk + +class PluginAppsStructureInventory: + + def getVersion(self, info): + if Config.DEBUG: + print("[DEBUG] GET : " + Config.BASE_URL + info[0]) + r = requests.get(Config.BASE_URL + info[0]) + content = r.content + version = content[content.find('') + len(''):] + version = version[:version.find('<')] + print(chalk.white('\t[+] Version of [', bold=True) + chalk.yellow(info[1], bold=True) + chalk.white('] : [', bold=True) + chalk.yellow(version, bold=True) + chalk.white(']', bold=True)) + return version + + def initPlugin(self, info): + version = self.getVersion(info) + Exploits.ExploitsCheck().verifExploit(info[1], version) diff --git a/plugins/PluginBadgesInventory.py b/plugins/PluginBadgesInventory.py new file mode 100644 index 0000000..5a1be37 --- /dev/null +++ b/plugins/PluginBadgesInventory.py @@ -0,0 +1,21 @@ +#!/usr/bin/python + +from inc import Config, Exploits + +import requests, chalk + +class PluginBadgesInventory: + + def getVersion(self, info): + if Config.DEBUG: + print("[DEBUG] GET : " + Config.BASE_URL + info[0]) + r = requests.get(Config.BASE_URL + info[0], verify=False) + content = r.content + version = content[content.find('Badges plugin ') + len('Badges plugin '):] + version = version[:version.find('\\')] + print(chalk.white('\t[+] Version of [', bold=True) + chalk.yellow(info[1], bold=True) + chalk.white('] : [', bold=True) + chalk.yellow(version, bold=True) + chalk.white(']', bold=True)) + return version + + def initPlugin(self, info): + version = self.getVersion(info) + Exploits.ExploitsCheck().verifExploit(info[1], version) diff --git a/plugins/PluginBarcode.py b/plugins/PluginBarcode.py new file mode 100644 index 0000000..ff76302 --- /dev/null +++ b/plugins/PluginBarcode.py @@ -0,0 +1,21 @@ +#!/usr/bin/python + +from inc import Config, Exploits + +import requests, chalk + +class PluginBarcode: + + def getVersion(self, info): + if Config.DEBUG: + print("[DEBUG] GET : " + Config.BASE_URL + info[0]) + r = requests.get(Config.BASE_URL + info[0]) + content = r.content + version = content[content.find('') + len(''):] + version = version[:version.find('<')] + print(chalk.white('\t[+] Version of [', bold=True) + chalk.yellow(info[1], bold=True) + chalk.white('] : [', bold=True) + chalk.yellow(version, bold=True) + chalk.white(']', bold=True)) + return version + + def initPlugin(self, info): + version = self.getVersion(info) + Exploits.ExploitsCheck().verifExploit(info[1], version) diff --git a/plugins/PluginBrowserNotification.py b/plugins/PluginBrowserNotification.py new file mode 100644 index 0000000..00f560d --- /dev/null +++ b/plugins/PluginBrowserNotification.py @@ -0,0 +1,21 @@ +#!/usr/bin/python + +from inc import Config, Exploits + +import requests, chalk + +class PluginBrowserNotification: + + def getVersion(self, info): + if Config.DEBUG: + print("[DEBUG] GET : " + Config.BASE_URL + info[0]) + r = requests.get(Config.BASE_URL + info[0]) + content = r.content + version = content[content.rfind('') + len(''):] + version = version[:version.find('<')] + print(chalk.white('\t[+] Version of [', bold=True) + chalk.yellow(info[1], bold=True) + chalk.white('] : [', bold=True) + chalk.yellow(version, bold=True) + chalk.white(']', bold=True)) + return version + + def initPlugin(self, info): + version = self.getVersion(info) + Exploits.ExploitsCheck().verifExploit(info[1], version) diff --git a/plugins/PluginCartography.py b/plugins/PluginCartography.py new file mode 100644 index 0000000..536ff14 --- /dev/null +++ b/plugins/PluginCartography.py @@ -0,0 +1,21 @@ +#!/usr/bin/python + +from inc import Config, Exploits + +import requests, chalk + +class PluginCartography: + + def getVersion(self, info): + if Config.DEBUG: + print("[DEBUG] GET : " + Config.BASE_URL + info[0]) + r = requests.get(Config.BASE_URL + info[0], verify=False) + content = r.content + version = content[content.find('Positions plugin ') + len('Positions plugin '):] + version = version[:version.find('\\')] + print(chalk.white('\t[+] Version of [', bold=True) + chalk.yellow(info[1], bold=True) + chalk.white('] : [', bold=True) + chalk.yellow(version, bold=True) + chalk.white(']', bold=True)) + return version + + def initPlugin(self, info): + version = self.getVersion(info) + Exploits.ExploitsCheck().verifExploit(info[1], version) diff --git a/plugins/PluginCleanArchivedEmails.py b/plugins/PluginCleanArchivedEmails.py new file mode 100644 index 0000000..f5f93bd --- /dev/null +++ b/plugins/PluginCleanArchivedEmails.py @@ -0,0 +1,21 @@ +#!/usr/bin/python + +from inc import Config, Exploits + +import requests, chalk + +class PluginCleanArchivedEmails: + + def getVersion(self, info): + if Config.DEBUG: + print("[DEBUG] GET : " + Config.BASE_URL + info[0]) + r = requests.get(Config.BASE_URL + info[0]) + content = r.content + version = content[content.find('') + len(''):] + version = version[:version.find('<')] + print(chalk.white('\t[+] Version of [', bold=True) + chalk.yellow(info[1], bold=True) + chalk.white('] : [', bold=True) + chalk.yellow(version, bold=True) + chalk.white(']', bold=True)) + return version + + def initPlugin(self, info): + version = self.getVersion(info) + Exploits.ExploitsCheck().verifExploit(info[1], version) diff --git a/plugins/PluginCredit.py b/plugins/PluginCredit.py new file mode 100644 index 0000000..8b3a328 --- /dev/null +++ b/plugins/PluginCredit.py @@ -0,0 +1,21 @@ +#!/usr/bin/python + +from inc import Config, Exploits + +import requests, chalk + +class PluginCredit: + + def getVersion(self, info): + if Config.DEBUG: + print("[DEBUG] GET : " + Config.BASE_URL + info[0]) + r = requests.get(Config.BASE_URL + info[0]) + content = r.content + version = content[content.find('') + len(''):] + version = version[:version.find('<')] + print(chalk.white('\t[+] Version of [', bold=True) + chalk.yellow(info[1], bold=True) + chalk.white('] : [', bold=True) + chalk.yellow(version, bold=True) + chalk.white(']', bold=True)) + return version + + def initPlugin(self, info): + version = self.getVersion(info) + Exploits.ExploitsCheck().verifExploit(info[1], version) diff --git a/plugins/PluginDashboard.py b/plugins/PluginDashboard.py new file mode 100644 index 0000000..71a4e0e --- /dev/null +++ b/plugins/PluginDashboard.py @@ -0,0 +1,21 @@ +#!/usr/bin/python + +from inc import Config, Exploits + +import requests, chalk + +class PluginDashboard: + + def getVersion(self, info): + if Config.DEBUG: + print("[DEBUG] GET : " + Config.BASE_URL + info[0]) + r = requests.get(Config.BASE_URL + info[0], verify=False) + content = r.content + version = content[content.find('Version ') + len('Version '):] + version = version[:version.find(':')] + print(chalk.white('\t[+] Version of [', bold=True) + chalk.yellow(info[1], bold=True) + chalk.white('] : [', bold=True) + chalk.yellow(version, bold=True) + chalk.white(']', bold=True)) + return version + + def initPlugin(self, info): + version = self.getVersion(info) + Exploits.ExploitsCheck().verifExploit(info[1], version) diff --git a/plugins/PluginDataInjection.py b/plugins/PluginDataInjection.py new file mode 100644 index 0000000..388a844 --- /dev/null +++ b/plugins/PluginDataInjection.py @@ -0,0 +1,21 @@ +#!/usr/bin/python + +from inc import Config, Exploits + +import requests, chalk + +class PluginDataInjection: + + def getVersion(self, info): + if Config.DEBUG: + print("[DEBUG] GET : " + Config.BASE_URL + info[0]) + r = requests.get(Config.BASE_URL + info[0]) + content = r.content + version = content[content.find('') + len(''):] + version = version[:version.find('<')] + print(chalk.white('\t[+] Version of [', bold=True) + chalk.yellow(info[1], bold=True) + chalk.white('] : [', bold=True) + chalk.yellow(version, bold=True) + chalk.white(']', bold=True)) + return version + + def initPlugin(self, info): + version = self.getVersion(info) + Exploits.ExploitsCheck().verifExploit(info[1], version) diff --git a/plugins/PluginDataflowsInventory.py b/plugins/PluginDataflowsInventory.py new file mode 100644 index 0000000..c84bc33 --- /dev/null +++ b/plugins/PluginDataflowsInventory.py @@ -0,0 +1,21 @@ +#!/usr/bin/python + +from inc import Config, Exploits + +import requests, chalk + +class PluginDataflowsInventory: + + def getVersion(self, info): + if Config.DEBUG: + print("[DEBUG] GET : " + Config.BASE_URL + info[0]) + r = requests.get(Config.BASE_URL + info[0]) + content = r.content + version = content[content.find('') + len(''):] + version = version[:version.find('<')] + print(chalk.white('\t[+] Version of [', bold=True) + chalk.yellow(info[1], bold=True) + chalk.white('] : [', bold=True) + chalk.yellow(version, bold=True) + chalk.white(']', bold=True)) + return version + + def initPlugin(self, info): + version = self.getVersion(info) + Exploits.ExploitsCheck().verifExploit(info[1], version) diff --git a/plugins/PluginDiagrams.py b/plugins/PluginDiagrams.py new file mode 100644 index 0000000..4c736ac --- /dev/null +++ b/plugins/PluginDiagrams.py @@ -0,0 +1,21 @@ +#!/usr/bin/python + +from inc import Config, Exploits + +import requests, chalk + +class PluginDiagrams: + + def getVersion(self, info): + if Config.DEBUG: + print("[DEBUG] GET : " + Config.BASE_URL + info[0]) + r = requests.get(Config.BASE_URL + info[0], verify=False) + content = r.content + version = content[content.find('') + len(''):] + version = version[:version.find('<')] + print(chalk.white('\t[+] Version of [', bold=True) + chalk.yellow(info[1], bold=True) + chalk.white('] : [', bold=True) + chalk.yellow(version, bold=True) + chalk.white(']', bold=True)) + return version + + def initPlugin(self, info): + version = self.getVersion(info) + Exploits.ExploitsCheck().verifExploit(info[1], version) diff --git a/plugins/PluginDomainsInventory.py b/plugins/PluginDomainsInventory.py new file mode 100644 index 0000000..da75a21 --- /dev/null +++ b/plugins/PluginDomainsInventory.py @@ -0,0 +1,21 @@ +#!/usr/bin/python + +from inc import Config, Exploits + +import requests, chalk + +class PluginDomainsInventory: + + def getVersion(self, info): + if Config.DEBUG: + print("[DEBUG] GET : " + Config.BASE_URL + info[0]) + r = requests.get(Config.BASE_URL + info[0], verify=False) + content = r.content + version = content[content.find('Domains plugin ') + len('Domains plugin '):] + version = version[:version.find('\\')] + print(chalk.white('\t[+] Version of [', bold=True) + chalk.yellow(info[1], bold=True) + chalk.white('] : [', bold=True) + chalk.yellow(version, bold=True) + chalk.white(']', bold=True)) + return version + + def initPlugin(self, info): + version = self.getVersion(info) + Exploits.ExploitsCheck().verifExploit(info[1], version) diff --git a/plugins/PluginEscalade.py b/plugins/PluginEscalade.py new file mode 100644 index 0000000..00c2d53 --- /dev/null +++ b/plugins/PluginEscalade.py @@ -0,0 +1,21 @@ +#!/usr/bin/python + +from inc import Config, Exploits + +import requests, chalk + +class PluginEscalade: + + def getVersion(self, info): + if Config.DEBUG: + print("[DEBUG] GET : " + Config.BASE_URL + info[0]) + r = requests.get(Config.BASE_URL + info[0]) + content = r.content + version = content[content.find('') + len(''):] + version = version[:version.find('<')] + print(chalk.white('\t[+] Version of [', bold=True) + chalk.yellow(info[1], bold=True) + chalk.white('] : [', bold=True) + chalk.yellow(version, bold=True) + chalk.white(']', bold=True)) + return version + + def initPlugin(self, info): + version = self.getVersion(info) + Exploits.ExploitsCheck().verifExploit(info[1], version) diff --git a/plugins/PluginFields.py b/plugins/PluginFields.py new file mode 100644 index 0000000..8bb490d --- /dev/null +++ b/plugins/PluginFields.py @@ -0,0 +1,21 @@ +#!/usr/bin/python + +from inc import Config, Exploits + +import requests, chalk + +class PluginFields: + + def getVersion(self, info): + if Config.DEBUG: + print("[DEBUG] GET : " + Config.BASE_URL + info[0]) + r = requests.get(Config.BASE_URL + info[0]) + content = r.content + version = content[content.find('') + len(''):] + version = version[:version.find('<')] + print(chalk.white('\t[+] Version of [', bold=True) + chalk.yellow(info[1], bold=True) + chalk.white('] : [', bold=True) + chalk.yellow(version, bold=True) + chalk.white(']', bold=True)) + return version + + def initPlugin(self, info): + version = self.getVersion(info) + Exploits.ExploitsCheck().verifExploit(info[1], version) diff --git a/plugins/PluginFormCreator.py b/plugins/PluginFormCreator.py new file mode 100644 index 0000000..be7d8df --- /dev/null +++ b/plugins/PluginFormCreator.py @@ -0,0 +1,21 @@ +#!/usr/bin/python + +from inc import Config, Exploits + +import requests, chalk + +class PluginFormCreator: + + def getVersion(self, info): + if Config.DEBUG: + print("[DEBUG] GET : " + Config.BASE_URL + info[0]) + r = requests.get(Config.BASE_URL + info[0], verify=False) + content = r.content + version = content[content.find('"version": "') + len('"version": "'):] + version = version[:version.find('"')] + print(chalk.white('\t[+] Version of [', bold=True) + chalk.yellow(info[1], bold=True) + chalk.white('] : [', bold=True) + chalk.yellow(version, bold=True) + chalk.white(']', bold=True)) + return version + + def initPlugin(self, info): + version = self.getVersion(info) + Exploits.ExploitsCheck().verifExploit(info[1], version) diff --git a/plugins/PluginFunctionalAreas.py b/plugins/PluginFunctionalAreas.py new file mode 100644 index 0000000..4818aad --- /dev/null +++ b/plugins/PluginFunctionalAreas.py @@ -0,0 +1,21 @@ +#!/usr/bin/python + +from inc import Config, Exploits + +import requests, chalk + +class PluginFunctionalAreas: + + def getVersion(self, info): + if Config.DEBUG: + print("[DEBUG] GET : " + Config.BASE_URL + info[0]) + r = requests.get(Config.BASE_URL + info[0]) + content = r.content + version = content[content.find('') + len(''):] + version = version[:version.find('<')] + print(chalk.white('\t[+] Version of [', bold=True) + chalk.yellow(info[1], bold=True) + chalk.white('] : [', bold=True) + chalk.yellow(version, bold=True) + chalk.white(']', bold=True)) + return version + + def initPlugin(self, info): + version = self.getVersion(info) + Exploits.ExploitsCheck().verifExploit(info[1], version) diff --git a/plugins/PluginFusionInventory.py b/plugins/PluginFusionInventory.py new file mode 100644 index 0000000..140fac8 --- /dev/null +++ b/plugins/PluginFusionInventory.py @@ -0,0 +1,21 @@ +#!/usr/bin/python + +from inc import Config, Exploits + +import requests, chalk + +class PluginFusionInventory: + + def getVersion(self, info): + if Config.DEBUG: + print("[DEBUG] GET : " + Config.BASE_URL + info[0]) + r = requests.get(Config.BASE_URL + info[0], verify=False) + content = r.content + version = content[content.find('FusionInventory ') + len('FusionInventory '):] + version = version[:version.find(' ')] + print(chalk.white('\t[+] Version of [', bold=True) + chalk.yellow(info[1], bold=True) + chalk.white('] : [', bold=True) + chalk.yellow(version, bold=True) + chalk.white(']', bold=True)) + return version + + def initPlugin(self, info): + version = self.getVersion(info) + Exploits.ExploitsCheck().verifExploit(info[1], version) diff --git a/plugins/PluginGLPICheckingVersion.py b/plugins/PluginGLPICheckingVersion.py new file mode 100644 index 0000000..526ecc7 --- /dev/null +++ b/plugins/PluginGLPICheckingVersion.py @@ -0,0 +1,21 @@ +#!/usr/bin/python + +from inc import Config, Exploits + +import requests, chalk + +class PluginGLPICheckingVersion: + + def getVersion(self, info): + if Config.DEBUG: + print("[DEBUG] GET : " + Config.BASE_URL + info[0]) + r = requests.get(Config.BASE_URL + info[0], verify=False) + content = r.content + version = content[content.find('') + len(''):] + version = version[:version.find('<')] + print(chalk.white('\t[+] Version of [', bold=True) + chalk.yellow(info[1], bold=True) + chalk.white('] : [', bold=True) + chalk.yellow(version, bold=True) + chalk.white(']', bold=True)) + return version + + def initPlugin(self, info): + version = self.getVersion(info) + Exploits.ExploitsCheck().verifExploit(info[1], version) diff --git a/plugins/PluginGenericObjectsManagement.py b/plugins/PluginGenericObjectsManagement.py new file mode 100644 index 0000000..a38edfb --- /dev/null +++ b/plugins/PluginGenericObjectsManagement.py @@ -0,0 +1,21 @@ +#!/usr/bin/python + +from inc import Config, Exploits + +import requests, chalk + +class PluginGenericObjectsManagement: + + def getVersion(self, info): + if Config.DEBUG: + print("[DEBUG] GET : " + Config.BASE_URL + info[0]) + r = requests.get(Config.BASE_URL + info[0]) + content = r.content + version = content[content.find('') + len(''):] + version = version[:version.find('<')] + print(chalk.white('\t[+] Version of [', bold=True) + chalk.yellow(info[1], bold=True) + chalk.white('] : [', bold=True) + chalk.yellow(version, bold=True) + chalk.white(']', bold=True)) + return version + + def initPlugin(self, info): + version = self.getVersion(info) + Exploits.ExploitsCheck().verifExploit(info[1], version) diff --git a/plugins/PluginHistoricalPurge.py b/plugins/PluginHistoricalPurge.py new file mode 100644 index 0000000..72ff1fa --- /dev/null +++ b/plugins/PluginHistoricalPurge.py @@ -0,0 +1,21 @@ +#!/usr/bin/python + +from inc import Config, Exploits + +import requests, chalk + +class PluginHistoricalPurge: + + def getVersion(self, info): + if Config.DEBUG: + print("[DEBUG] GET : " + Config.BASE_URL + info[0]) + r = requests.get(Config.BASE_URL + info[0]) + content = r.content + version = content[content.find('') + len(''):] + version = version[:version.find('<')] + print(chalk.white('\t[+] Version of [', bold=True) + chalk.yellow(info[1], bold=True) + chalk.white('] : [', bold=True) + chalk.yellow(version, bold=True) + chalk.white(']', bold=True)) + return version + + def initPlugin(self, info): + version = self.getVersion(info) + Exploits.ExploitsCheck().verifExploit(info[1], version) diff --git a/plugins/PluginImpacts.py b/plugins/PluginImpacts.py new file mode 100644 index 0000000..abe292c --- /dev/null +++ b/plugins/PluginImpacts.py @@ -0,0 +1,21 @@ +#!/usr/bin/python + +from inc import Config, Exploits + +import requests, chalk + +class PluginImpacts: + + def getVersion(self, info): + if Config.DEBUG: + print("[DEBUG] GET : " + Config.BASE_URL + info[0]) + r = requests.get(Config.BASE_URL + info[0], verify=False) + content = r.content + version = content[content.find('') + len(''):] + version = version[:version.find('<')] + print(chalk.white('\t[+] Version of [', bold=True) + chalk.yellow(info[1], bold=True) + chalk.white('] : [', bold=True) + chalk.yellow(version, bold=True) + chalk.white(']', bold=True)) + return version + + def initPlugin(self, info): + version = self.getVersion(info) + Exploits.ExploitsCheck().verifExploit(info[1], version) diff --git a/plugins/PluginInventoryNumberGeneration.py b/plugins/PluginInventoryNumberGeneration.py new file mode 100644 index 0000000..573f49a --- /dev/null +++ b/plugins/PluginInventoryNumberGeneration.py @@ -0,0 +1,21 @@ +#!/usr/bin/python + +from inc import Config, Exploits + +import requests, chalk + +class PluginInventoryNumberGeneration: + + def getVersion(self, info): + if Config.DEBUG: + print("[DEBUG] GET : " + Config.BASE_URL + info[0]) + r = requests.get(Config.BASE_URL + info[0]) + content = r.content + version = content[content.find('') + len(''):] + version = version[:version.find('<')] + print(chalk.white('\t[+] Version of [', bold=True) + chalk.yellow(info[1], bold=True) + chalk.white('] : [', bold=True) + chalk.yellow(version, bold=True) + chalk.white(']', bold=True)) + return version + + def initPlugin(self, info): + version = self.getVersion(info) + Exploits.ExploitsCheck().verifExploit(info[1], version) diff --git a/plugins/PluginItilCategoryGroups.py b/plugins/PluginItilCategoryGroups.py new file mode 100644 index 0000000..ba610c3 --- /dev/null +++ b/plugins/PluginItilCategoryGroups.py @@ -0,0 +1,21 @@ +#!/usr/bin/python + +from inc import Config, Exploits + +import requests, chalk + +class PluginItilCategoryGroups: + + def getVersion(self, info): + if Config.DEBUG: + print("[DEBUG] GET : " + Config.BASE_URL + info[0]) + r = requests.get(Config.BASE_URL + info[0]) + content = r.content + version = content[content.find('') + len(''):] + version = version[:version.find('<')] + print(chalk.white('\t[+] Version of [', bold=True) + chalk.yellow(info[1], bold=True) + chalk.white('] : [', bold=True) + chalk.yellow(version, bold=True) + chalk.white(']', bold=True)) + return version + + def initPlugin(self, info): + version = self.getVersion(info) + Exploits.ExploitsCheck().verifExploit(info[1], version) diff --git a/plugins/PluginLaunchShellCommands.py b/plugins/PluginLaunchShellCommands.py new file mode 100644 index 0000000..88a894b --- /dev/null +++ b/plugins/PluginLaunchShellCommands.py @@ -0,0 +1,21 @@ +#!/usr/bin/python + +from inc import Config, Exploits + +import requests, chalk + +class PluginLaunchShellCommands: + + def getVersion(self, info): + if Config.DEBUG: + print("[DEBUG] GET : " + Config.BASE_URL + info[0]) + r = requests.get(Config.BASE_URL + info[0], verify=False) + content = r.content + version = content[content.find('Shellcommands plugin ') + len('Shellcommands plugin '):] + version = version[:version.find('\\')] + print(chalk.white('\t[+] Version of [', bold=True) + chalk.yellow(info[1], bold=True) + chalk.white('] : [', bold=True) + chalk.yellow(version, bold=True) + chalk.white(']', bold=True)) + return version + + def initPlugin(self, info): + version = self.getVersion(info) + Exploits.ExploitsCheck().verifExploit(info[1], version) diff --git a/plugins/PluginMDTConnector.py b/plugins/PluginMDTConnector.py new file mode 100644 index 0000000..c52ae2b --- /dev/null +++ b/plugins/PluginMDTConnector.py @@ -0,0 +1,21 @@ +#!/usr/bin/python + +from inc import Config, Exploits + +import requests, chalk + +class PluginMDTConnector: + + def getVersion(self, info): + if Config.DEBUG: + print("[DEBUG] GET : " + Config.BASE_URL + info[0]) + r = requests.get(Config.BASE_URL + info[0]) + content = r.content + version = content[content.find('') + len(''):] + version = version[:version.find('<')] + print(chalk.white('\t[+] Version of [', bold=True) + chalk.yellow(info[1], bold=True) + chalk.white('] : [', bold=True) + chalk.yellow(version, bold=True) + chalk.white(']', bold=True)) + return version + + def initPlugin(self, info): + version = self.getVersion(info) + Exploits.ExploitsCheck().verifExploit(info[1], version) diff --git a/plugins/PluginMailAnalyzer.py b/plugins/PluginMailAnalyzer.py new file mode 100644 index 0000000..c174d91 --- /dev/null +++ b/plugins/PluginMailAnalyzer.py @@ -0,0 +1,21 @@ +#!/usr/bin/python + +from inc import Config, Exploits + +import requests, chalk + +class PluginMailAnalyzer: + + def getVersion(self, info): + if Config.DEBUG: + print("[DEBUG] GET : " + Config.BASE_URL + info[0]) + r = requests.get(Config.BASE_URL + info[0]) + content = r.content + version = content[content.find('') + len(''):] + version = version[:version.find('<')] + print(chalk.white('\t[+] Version of [', bold=True) + chalk.yellow(info[1], bold=True) + chalk.white('] : [', bold=True) + chalk.yellow(version, bold=True) + chalk.white(']', bold=True)) + return version + + def initPlugin(self, info): + version = self.getVersion(info) + Exploits.ExploitsCheck().verifExploit(info[1], version) diff --git a/plugins/PluginMantis.py b/plugins/PluginMantis.py new file mode 100644 index 0000000..690d05a --- /dev/null +++ b/plugins/PluginMantis.py @@ -0,0 +1,21 @@ +#!/usr/bin/python + +from inc import Config, Exploits + +import requests, chalk + +class PluginMantis: + + def getVersion(self, info): + if Config.DEBUG: + print("[DEBUG] GET : " + Config.BASE_URL + info[0]) + r = requests.get(Config.BASE_URL + info[0]) + content = r.content + version = content[content.find('') + len(''):] + version = version[:version.find('<')] + print(chalk.white('\t[+] Version of [', bold=True) + chalk.yellow(info[1], bold=True) + chalk.white('] : [', bold=True) + chalk.yellow(version, bold=True) + chalk.white(']', bold=True)) + return version + + def initPlugin(self, info): + version = self.getVersion(info) + Exploits.ExploitsCheck().verifExploit(info[1], version) diff --git a/plugins/PluginMask.py b/plugins/PluginMask.py new file mode 100644 index 0000000..6f94ae0 --- /dev/null +++ b/plugins/PluginMask.py @@ -0,0 +1,21 @@ +#!/usr/bin/python + +from inc import Config, Exploits + +import requests, chalk + +class PluginMask: + + def getVersion(self, info): + if Config.DEBUG: + print("[DEBUG] GET : " + Config.BASE_URL + info[0]) + r = requests.get(Config.BASE_URL + info[0]) + content = r.content + version = content[content.rfind('') + len(''):] + version = version[:version.find('<')] + print(chalk.white('\t[+] Version of [', bold=True) + chalk.yellow(info[1], bold=True) + chalk.white('] : [', bold=True) + chalk.yellow(version, bold=True) + chalk.white(']', bold=True)) + return version + + def initPlugin(self, info): + version = self.getVersion(info) + Exploits.ExploitsCheck().verifExploit(info[1], version) diff --git a/plugins/PluginMetabase.py b/plugins/PluginMetabase.py new file mode 100644 index 0000000..3a86a20 --- /dev/null +++ b/plugins/PluginMetabase.py @@ -0,0 +1,21 @@ +#!/usr/bin/python + +from inc import Config, Exploits + +import requests, chalk + +class pluginDiagrams: + + def getVersion(self, info): + if Config.DEBUG: + print("[DEBUG] GET : " + Config.BASE_URL + info[0]) + r = requests.get(Config.BASE_URL + info[0], verify=False) + content = r.content + version = content[content.find('') + len(''):] + version = version[:version.find('<')] + print(chalk.white('\t[+] Version of [', bold=True) + chalk.yellow(info[1], bold=True) + chalk.white('] : [', bold=True) + chalk.yellow(version, bold=True) + chalk.white(']', bold=True)) + return version + + def initPlugin(self, info): + version = self.getVersion(info) + Exploits.ExploitsCheck().verifExploit(info[1], version) diff --git a/plugins/PluginMoreReporting.py b/plugins/PluginMoreReporting.py new file mode 100644 index 0000000..5c4e165 --- /dev/null +++ b/plugins/PluginMoreReporting.py @@ -0,0 +1,21 @@ +#!/usr/bin/python + +from inc import Config, Exploits + +import requests, chalk + +class PluginMoreReporting: + + def getVersion(self, info): + if Config.DEBUG: + print("[DEBUG] GET : " + Config.BASE_URL + info[0]) + r = requests.get(Config.BASE_URL + info[0], verify=False) + content = r.content + version = content[content.find('') + len(''):] + version = version[:version.find('<')] + print(chalk.white('\t[+] Version of [', bold=True) + chalk.yellow(info[1], bold=True) + chalk.white('] : [', bold=True) + chalk.yellow(version, bold=True) + chalk.white(']', bold=True)) + return version + + def initPlugin(self, info): + version = self.getVersion(info) + Exploits.ExploitsCheck().verifExploit(info[1], version) diff --git a/plugins/PluginMyDashboard.py b/plugins/PluginMyDashboard.py new file mode 100644 index 0000000..0ad0c5a --- /dev/null +++ b/plugins/PluginMyDashboard.py @@ -0,0 +1,21 @@ +#!/usr/bin/python + +from inc import Config, Exploits + +import requests, chalk + +class PluginMyDashboard: + + def getVersion(self, info): + if Config.DEBUG: + print("[DEBUG] GET : " + Config.BASE_URL + info[0]) + r = requests.get(Config.BASE_URL + info[0], verify=False) + content = r.content + version = content[content.find('Project-Id-Version: GLPI - MyDashboard plugin ') + len('Project-Id-Version: GLPI - MyDashboard plugin '):] + version = version[:version.find('\\')] + print(chalk.white('\t[+] Version of [', bold=True) + chalk.yellow(info[1], bold=True) + chalk.white('] : [', bold=True) + chalk.yellow(version, bold=True) + chalk.white(']', bold=True)) + return version + + def initPlugin(self, info): + version = self.getVersion(info) + Exploits.ExploitsCheck().verifExploit(info[1], version) diff --git a/plugins/PluginNetworkEquipmentBackup.py b/plugins/PluginNetworkEquipmentBackup.py new file mode 100644 index 0000000..51d14fd --- /dev/null +++ b/plugins/PluginNetworkEquipmentBackup.py @@ -0,0 +1,21 @@ +#!/usr/bin/python + +from inc import Config, Exploits + +import requests, chalk + +class PluginNetworkEquipmentBackup: + + def getVersion(self, info): + if Config.DEBUG: + print("[DEBUG] GET : " + Config.BASE_URL + info[0]) + r = requests.get(Config.BASE_URL + info[0]) + content = r.content + version = content[content.rfind('') + len(''):] + version = version[:version.find('<')] + print(chalk.white('\t[+] Version of [', bold=True) + chalk.yellow(info[1], bold=True) + chalk.white('] : [', bold=True) + chalk.yellow(version, bold=True) + chalk.white(']', bold=True)) + return version + + def initPlugin(self, info): + version = self.getVersion(info) + Exploits.ExploitsCheck().verifExploit(info[1], version) diff --git a/plugins/PluginNews.py b/plugins/PluginNews.py new file mode 100644 index 0000000..df172fe --- /dev/null +++ b/plugins/PluginNews.py @@ -0,0 +1,21 @@ +#!/usr/bin/python + +from inc import Config, Exploits + +import requests, chalk + +class PluginNews: + + def getVersion(self, info): + if Config.DEBUG: + print("[DEBUG] GET : " + Config.BASE_URL + info[0]) + r = requests.get(Config.BASE_URL + info[0]) + content = r.content + version = content[content.find('') + len(''):] + version = version[:version.find('<')] + print(chalk.white('\t[+] Version of [', bold=True) + chalk.yellow(info[1], bold=True) + chalk.white('] : [', bold=True) + chalk.yellow(version, bold=True) + chalk.white(']', bold=True)) + return version + + def initPlugin(self, info): + version = self.getVersion(info) + Exploits.ExploitsCheck().verifExploit(info[1], version) diff --git a/plugins/PluginOpenVAS.py b/plugins/PluginOpenVAS.py new file mode 100644 index 0000000..a6435a2 --- /dev/null +++ b/plugins/PluginOpenVAS.py @@ -0,0 +1,21 @@ +#!/usr/bin/python + +from inc import Config, Exploits + +import requests, chalk + +class PluginOpenVAS: + + def getVersion(self, info): + if Config.DEBUG: + print("[DEBUG] GET : " + Config.BASE_URL + info[0]) + r = requests.get(Config.BASE_URL + info[0]) + content = r.content + version = content[content.find('') + len(''):] + version = version[:version.find('<')] + print(chalk.white('\t[+] Version of [', bold=True) + chalk.yellow(info[1], bold=True) + chalk.white('] : [', bold=True) + chalk.yellow(version, bold=True) + chalk.white(']', bold=True)) + return version + + def initPlugin(self, info): + version = self.getVersion(info) + Exploits.ExploitsCheck().verifExploit(info[1], version) diff --git a/plugins/PluginOrderManagement.py b/plugins/PluginOrderManagement.py new file mode 100644 index 0000000..ca6a5e2 --- /dev/null +++ b/plugins/PluginOrderManagement.py @@ -0,0 +1,21 @@ +#!/usr/bin/python + +from inc import Config, Exploits + +import requests, chalk + +class PluginOrderManagement: + + def getVersion(self, info): + if Config.DEBUG: + print("[DEBUG] GET : " + Config.BASE_URL + info[0]) + r = requests.get(Config.BASE_URL + info[0]) + content = r.content + version = content[content.find('') + len(''):] + version = version[:version.find('<')] + print(chalk.white('\t[+] Version of [', bold=True) + chalk.yellow(info[1], bold=True) + chalk.white('] : [', bold=True) + chalk.yellow(version, bold=True) + chalk.white(']', bold=True)) + return version + + def initPlugin(self, info): + version = self.getVersion(info) + Exploits.ExploitsCheck().verifExploit(info[1], version) diff --git a/plugins/PluginOrderService.py b/plugins/PluginOrderService.py new file mode 100644 index 0000000..3a86a20 --- /dev/null +++ b/plugins/PluginOrderService.py @@ -0,0 +1,21 @@ +#!/usr/bin/python + +from inc import Config, Exploits + +import requests, chalk + +class pluginDiagrams: + + def getVersion(self, info): + if Config.DEBUG: + print("[DEBUG] GET : " + Config.BASE_URL + info[0]) + r = requests.get(Config.BASE_URL + info[0], verify=False) + content = r.content + version = content[content.find('') + len(''):] + version = version[:version.find('<')] + print(chalk.white('\t[+] Version of [', bold=True) + chalk.yellow(info[1], bold=True) + chalk.white('] : [', bold=True) + chalk.yellow(version, bold=True) + chalk.white(']', bold=True)) + return version + + def initPlugin(self, info): + version = self.getVersion(info) + Exploits.ExploitsCheck().verifExploit(info[1], version) diff --git a/plugins/PluginProcessmaker.py b/plugins/PluginProcessmaker.py new file mode 100644 index 0000000..8f082aa --- /dev/null +++ b/plugins/PluginProcessmaker.py @@ -0,0 +1,21 @@ +#!/usr/bin/python + +from inc import Config, Exploits + +import requests, chalk + +class PluginProcessmaker: + + def getVersion(self, info): + if Config.DEBUG: + print("[DEBUG] GET : " + Config.BASE_URL + info[0]) + r = requests.get(Config.BASE_URL + info[0]) + content = r.content + version = content[content.rfind('') + len(''):] + version = version[:version.find('<')] + print(chalk.white('\t[+] Version of [', bold=True) + chalk.yellow(info[1], bold=True) + chalk.white('] : [', bold=True) + chalk.yellow(version, bold=True) + chalk.white(']', bold=True)) + return version + + def initPlugin(self, info): + version = self.getVersion(info) + Exploits.ExploitsCheck().verifExploit(info[1], version) diff --git a/plugins/PluginRacks.py b/plugins/PluginRacks.py new file mode 100644 index 0000000..56c87ab --- /dev/null +++ b/plugins/PluginRacks.py @@ -0,0 +1,21 @@ +#!/usr/bin/python + +from inc import Config, Exploits + +import requests, chalk + +class PluginRacks: + + def getVersion(self, info): + if Config.DEBUG: + print("[DEBUG] GET : " + Config.BASE_URL + info[0]) + r = requests.get(Config.BASE_URL + info[0], verify=False) + content = r.content + version = content[content.find('Racks plugin ') + len('Racks plugin '):] + version = version[:version.find('\\')] + print(chalk.white('\t[+] Version of [', bold=True) + chalk.yellow(info[1], bold=True) + chalk.white('] : [', bold=True) + chalk.yellow(version, bold=True) + chalk.white(']', bold=True)) + return version + + def initPlugin(self, info): + version = self.getVersion(info) + Exploits.ExploitsCheck().verifExploit(info[1], version) diff --git a/plugins/PluginRoom.py b/plugins/PluginRoom.py new file mode 100644 index 0000000..82defb5 --- /dev/null +++ b/plugins/PluginRoom.py @@ -0,0 +1,21 @@ +#!/usr/bin/python + +from inc import Config, Exploits + +import requests, chalk + +class PluginRoom: + + def getVersion(self, info): + if Config.DEBUG: + print("[DEBUG] GET : " + Config.BASE_URL + info[0]) + r = requests.get(Config.BASE_URL + info[0]) + content = r.content + version = content[content.rfind('') + len(''):] + version = version[:version.find('<')] + print(chalk.white('\t[+] Version of [', bold=True) + chalk.yellow(info[1], bold=True) + chalk.white('] : [', bold=True) + chalk.yellow(version, bold=True) + chalk.white(']', bold=True)) + return version + + def initPlugin(self, info): + version = self.getVersion(info) + Exploits.ExploitsCheck().verifExploit(info[1], version) diff --git a/plugins/PluginSCCM.py b/plugins/PluginSCCM.py new file mode 100644 index 0000000..b87e031 --- /dev/null +++ b/plugins/PluginSCCM.py @@ -0,0 +1,21 @@ +#!/usr/bin/python + +from inc import Config, Exploits + +import requests, chalk + +class PluginSCCM: + + def getVersion(self, info): + if Config.DEBUG: + print("[DEBUG] GET : " + Config.BASE_URL + info[0]) + r = requests.get(Config.BASE_URL + info[0]) + content = r.content + version = content[content.find('') + len(''):] + version = version[:version.find('<')] + print(chalk.white('\t[+] Version of [', bold=True) + chalk.yellow(info[1], bold=True) + chalk.white('] : [', bold=True) + chalk.yellow(version, bold=True) + chalk.white(']', bold=True)) + return version + + def initPlugin(self, info): + version = self.getVersion(info) + Exploits.ExploitsCheck().verifExploit(info[1], version) diff --git a/plugins/PluginStatecheck.py b/plugins/PluginStatecheck.py new file mode 100644 index 0000000..ffe6c1f --- /dev/null +++ b/plugins/PluginStatecheck.py @@ -0,0 +1,21 @@ +#!/usr/bin/python + +from inc import Config, Exploits + +import requests, chalk + +class PluginStatecheck: + + def getVersion(self, info): + if Config.DEBUG: + print("[DEBUG] GET : " + Config.BASE_URL + info[0]) + r = requests.get(Config.BASE_URL + info[0], verify=False) + content = r.content + version = content[content.find('') + len(''):] + version = version[:version.find('<')] + print(chalk.white('\t[+] Version of [', bold=True) + chalk.yellow(info[1], bold=True) + chalk.white('] : [', bold=True) + chalk.yellow(version, bold=True) + chalk.white(']', bold=True)) + return version + + def initPlugin(self, info): + version = self.getVersion(info) + Exploits.ExploitsCheck().verifExploit(info[1], version) diff --git a/plugins/PluginTag.py b/plugins/PluginTag.py new file mode 100644 index 0000000..d26f125 --- /dev/null +++ b/plugins/PluginTag.py @@ -0,0 +1,21 @@ +#!/usr/bin/python + +from inc import Config, Exploits + +import requests, chalk + +class PluginTag: + + def getVersion(self, info): + if Config.DEBUG: + print("[DEBUG] GET : " + Config.BASE_URL + info[0]) + r = requests.get(Config.BASE_URL + info[0]) + content = r.content + version = content[content.find('') + len(''):] + version = version[:version.find('<')] + print(chalk.white('\t[+] Version of [', bold=True) + chalk.yellow(info[1], bold=True) + chalk.white('] : [', bold=True) + chalk.yellow(version, bold=True) + chalk.white(']', bold=True)) + return version + + def initPlugin(self, info): + version = self.getVersion(info) + Exploits.ExploitsCheck().verifExploit(info[1], version) diff --git a/plugins/PluginTasksList.py b/plugins/PluginTasksList.py new file mode 100644 index 0000000..f2c808d --- /dev/null +++ b/plugins/PluginTasksList.py @@ -0,0 +1,21 @@ +#!/usr/bin/python + +from inc import Config, Exploits + +import requests, chalk + +class PluginTasksList: + + def getVersion(self, info): + if Config.DEBUG: + print("[DEBUG] GET : " + Config.BASE_URL + info[0]) + r = requests.get(Config.BASE_URL + info[0], verify=False) + content = r.content + version = content[content.find('Tasklists plugin ') + len('Tasklists plugin '):] + version = version[:version.find('\\')] + print(chalk.white('\t[+] Version of [', bold=True) + chalk.yellow(info[1], bold=True) + chalk.white('] : [', bold=True) + chalk.yellow(version, bold=True) + chalk.white(']', bold=True)) + return version + + def initPlugin(self, info): + version = self.getVersion(info) + Exploits.ExploitsCheck().verifExploit(info[1], version) diff --git a/plugins/PluginTelegramBot.py b/plugins/PluginTelegramBot.py new file mode 100644 index 0000000..d4a8007 --- /dev/null +++ b/plugins/PluginTelegramBot.py @@ -0,0 +1,21 @@ +#!/usr/bin/python + +from inc import Config, Exploits + +import requests, chalk + +class PluginTelegramBot: + + def getVersion(self, info): + if Config.DEBUG: + print("[DEBUG] GET : " + Config.BASE_URL + info[0]) + r = requests.get(Config.BASE_URL + info[0]) + content = r.content + version = content[content.find('') + len(''):] + version = version[:version.find('<')] + print(chalk.white('\t[+] Version of [', bold=True) + chalk.yellow(info[1], bold=True) + chalk.white('] : [', bold=True) + chalk.yellow(version, bold=True) + chalk.white(']', bold=True)) + return version + + def initPlugin(self, info): + version = self.getVersion(info) + Exploits.ExploitsCheck().verifExploit(info[1], version) diff --git a/plugins/PluginTimelineticket.py b/plugins/PluginTimelineticket.py new file mode 100644 index 0000000..2f21de0 --- /dev/null +++ b/plugins/PluginTimelineticket.py @@ -0,0 +1,21 @@ +#!/usr/bin/python + +from inc import Config, Exploits + +import requests, chalk + +class PluginTimelineticket: + + def getVersion(self, info): + if Config.DEBUG: + print("[DEBUG] GET : " + Config.BASE_URL + info[0]) + r = requests.get(Config.BASE_URL + info[0], verify=False) + content = r.content + version = content[content.find('Project-Id-Version: GLPI - Timelineticket plugin ') + len('Project-Id-Version: GLPI - Timelineticket plugin '):] + version = version[:version.find('\\')] + print(chalk.white('\t[+] Version of [', bold=True) + chalk.yellow(info[1], bold=True) + chalk.white('] : [', bold=True) + chalk.yellow(version, bold=True) + chalk.white(']', bold=True)) + return version + + def initPlugin(self, info): + version = self.getVersion(info) + Exploits.ExploitsCheck().verifExploit(info[1], version) diff --git a/plugins/PluginTimezones.py b/plugins/PluginTimezones.py new file mode 100644 index 0000000..5054dfb --- /dev/null +++ b/plugins/PluginTimezones.py @@ -0,0 +1,21 @@ +#!/usr/bin/python + +from inc import Config, Exploits + +import requests, chalk + +class PluginTimezones: + + def getVersion(self, info): + if Config.DEBUG: + print("[DEBUG] GET : " + Config.BASE_URL + info[0]) + r = requests.get(Config.BASE_URL + info[0]) + content = r.content + version = content[content.find('') + len(''):] + version = version[:version.find('<')] + print(chalk.white('\t[+] Version of [', bold=True) + chalk.yellow(info[1], bold=True) + chalk.white('] : [', bold=True) + chalk.yellow(version, bold=True) + chalk.white(']', bold=True)) + return version + + def initPlugin(self, info): + version = self.getVersion(info) + Exploits.ExploitsCheck().verifExploit(info[1], version) diff --git a/plugins/PluginTypology.py b/plugins/PluginTypology.py new file mode 100644 index 0000000..e1cfe54 --- /dev/null +++ b/plugins/PluginTypology.py @@ -0,0 +1,21 @@ +#!/usr/bin/python + +from inc import Config, Exploits + +import requests, chalk + +class PluginTypology: + + def getVersion(self, info): + if Config.DEBUG: + print("[DEBUG] GET : " + Config.BASE_URL + info[0]) + r = requests.get(Config.BASE_URL + info[0], verify=False) + content = r.content + version = content[content.find('Typology plugin ') + len('Typology plugin '):] + version = version[:version.find('\\')] + print(chalk.white('\t[+] Version of [', bold=True) + chalk.yellow(info[1], bold=True) + chalk.white('] : [', bold=True) + chalk.yellow(version, bold=True) + chalk.white(']', bold=True)) + return version + + def initPlugin(self, info): + version = self.getVersion(info) + Exploits.ExploitsCheck().verifExploit(info[1], version) diff --git a/plugins/PluginUninstall.py b/plugins/PluginUninstall.py new file mode 100644 index 0000000..89965f1 --- /dev/null +++ b/plugins/PluginUninstall.py @@ -0,0 +1,21 @@ +#!/usr/bin/python + +from inc import Config, Exploits + +import requests, chalk + +class PluginUninstall: + + def getVersion(self, info): + if Config.DEBUG: + print("[DEBUG] GET : " + Config.BASE_URL + info[0]) + r = requests.get(Config.BASE_URL + info[0]) + content = r.content + version = content[content.find('') + len(''):] + version = version[:version.find('<')] + print(chalk.white('\t[+] Version of [', bold=True) + chalk.yellow(info[1], bold=True) + chalk.white('] : [', bold=True) + chalk.yellow(version, bold=True) + chalk.white(']', bold=True)) + return version + + def initPlugin(self, info): + version = self.getVersion(info) + Exploits.ExploitsCheck().verifExploit(info[1], version) diff --git a/plugins/PluginUsedItemsExport.py b/plugins/PluginUsedItemsExport.py new file mode 100644 index 0000000..666b937 --- /dev/null +++ b/plugins/PluginUsedItemsExport.py @@ -0,0 +1,21 @@ +#!/usr/bin/python + +from inc import Config, Exploits + +import requests, chalk + +class PluginUsedItemsExport: + + def getVersion(self, info): + if Config.DEBUG: + print("[DEBUG] GET : " + Config.BASE_URL + info[0]) + r = requests.get(Config.BASE_URL + info[0]) + content = r.content + version = content[content.find('') + len(''):] + version = version[:version.find('<')] + print(chalk.white('\t[+] Version of [', bold=True) + chalk.yellow(info[1], bold=True) + chalk.white('] : [', bold=True) + chalk.yellow(version, bold=True) + chalk.white(']', bold=True)) + return version + + def initPlugin(self, info): + version = self.getVersion(info) + Exploits.ExploitsCheck().verifExploit(info[1], version) diff --git a/plugins/PluginXivo.py b/plugins/PluginXivo.py new file mode 100644 index 0000000..29b93d6 --- /dev/null +++ b/plugins/PluginXivo.py @@ -0,0 +1,21 @@ +#!/usr/bin/python + +from inc import Config, Exploits + +import requests, chalk + +class PluginXivo: + + def getVersion(self, info): + if Config.DEBUG: + print("[DEBUG] GET : " + Config.BASE_URL + info[0]) + r = requests.get(Config.BASE_URL + info[0]) + content = r.content + version = content[content.find('') + len(''):] + version = version[:version.find('<')] + print(chalk.white('\t[+] Version of [', bold=True) + chalk.yellow(info[1], bold=True) + chalk.white('] : [', bold=True) + chalk.yellow(version, bold=True) + chalk.white(']', bold=True)) + return version + + def initPlugin(self, info): + version = self.getVersion(info) + Exploits.ExploitsCheck().verifExploit(info[1], version) diff --git a/plugins/__init__.py b/plugins/__init__.py new file mode 100644 index 0000000..e69de29