Linux ip-148-66-134-25.ip.secureserver.net 3.10.0-1160.119.1.el7.tuxcare.els10.x86_64 #1 SMP Fri Oct 11 21:40:41 UTC 2024 x86_64
Apache
: 148.66.134.25 | : 3.135.220.219
66 Domain
8.0.30
amvm
www.github.com/MadExploits
Terminal
AUTO ROOT
Adminer
Backdoor Destroyer
Linux Exploit
Lock Shell
Lock File
Create User
CREATE RDP
PHP Mailer
BACKCONNECT
UNLOCK SHELL
HASH IDENTIFIER
CPANEL RESET
BLACK DEFEND!
README
+ Create Folder
+ Create File
/
usr /
lib /
fm-agent /
plugins /
[ HOME SHELL ]
Name
Size
Permission
Action
__pycache__
[ DIR ]
drwxr-xr-x
__init__.py
0
B
-rw-r--r--
apache.py
19.06
KB
-rw-r--r--
apache_kafka.py
12.9
KB
-rw-r--r--
apache_zookeeper.py
6.26
KB
-rw-r--r--
bandwidth.py
21.3
KB
-rw-r--r--
cassandra.py
9.21
KB
-rw-r--r--
cert.py
2.78
KB
-rw-r--r--
couch.py
9.5
KB
-rw-r--r--
cpu_usage.py
33
KB
-rw-r--r--
dem_plugin.py
6.08
KB
-rw-r--r--
disk.py
16.48
KB
-rw-r--r--
docker.py
38.41
KB
-rw-r--r--
elasticsearch.py
2.83
KB
-rw-r--r--
entropy.py
900
B
-rw-r--r--
exim.py
1.01
KB
-rw-r--r--
file_presence.py
5
KB
-rw-r--r--
haproxy.py
13.37
KB
-rw-r--r--
io_stats.py
13.41
KB
-rw-r--r--
jboss.py
13.46
KB
-rw-r--r--
jmx.py
8.02
KB
-rw-r--r--
linux_logs.py
3.4
KB
-rw-r--r--
lm_sensors.py
2.51
KB
-rw-r--r--
logstash_forwarder.py
1.58
KB
-rw-r--r--
memcache.py
5.99
KB
-rw-r--r--
memory_usage.py
26.11
KB
-rw-r--r--
mongo.py
15.96
KB
-rw-r--r--
mysql.py
19.74
KB
-rw-r--r--
nagios.py
5.36
KB
-rw-r--r--
nginx.py
11.96
KB
-rw-r--r--
nodejs.py
6.29
KB
-rw-r--r--
ntp.py
1.98
KB
-rw-r--r--
opcache.py
2.26
KB
-rw-r--r--
oracle.py
15.15
KB
-rw-r--r--
package_upgrade.py
8.08
KB
-rw-r--r--
phpfpm.py
5.51
KB
-rw-r--r--
ping.py
2.45
KB
-rw-r--r--
postfix.py
1.98
KB
-rw-r--r--
postgresql.py
19.13
KB
-rw-r--r--
process.py
16.32
KB
-rw-r--r--
rabbitmq.py
19.33
KB
-rw-r--r--
redis.py
11.19
KB
-rw-r--r--
sendmail.py
2.39
KB
-rw-r--r--
sysctl.py
1.46
KB
-rw-r--r--
tcp.py
6.26
KB
-rw-r--r--
template.py
3.28
KB
-rw-r--r--
tomcat.py
6.79
KB
-rw-r--r--
tomcat_jmx.py
15.82
KB
-rw-r--r--
unbound_dns.py
4.54
KB
-rw-r--r--
uptime.py
3.46
KB
-rw-r--r--
users.py
1.09
KB
-rw-r--r--
uwsgi.py
4.57
KB
-rw-r--r--
varnish.py
4.79
KB
-rw-r--r--
weblogic.py
13.38
KB
-rw-r--r--
weblogic12c.py
18.75
KB
-rw-r--r--
Delete
Unzip
Zip
${this.title}
Close
Code Editor : weblogic.py
import agent_util import os metrics = { #Work Manager Metrics "work_manager": { "type": "WorkManagerRuntime", "metrics": { "completed_requests": { "label": "The number of requests that have been processed", "property": "CompletedRequests" }, "pending_requests": { "label": "The number of waiting requests in the queue", "property": "PendingRequests" }, "stuck_thread_count": { "label": "The number of threads that are considered to be stuck on the basis of any stuck thread constraints", "property": "StuckThreadCount" } } }, #JDBC Data Source Metrics "jdbc_datasource": { "type": "JDBCDataSourceRuntime", "metrics": { "active_connections_current_count": { "label": "The number of connections currently in use by applications", "property": "ActiveConnectionsCurrentCount" } } }, #EJB Cache Metrics "ejb_cache": { "type": "EJBCacheRuntime", "metrics": { "activation_count": { "label": "Work Manager: The total number of beans from this EJB Home that have been activated", "property": "ActivationCount" }, "cache_access_count": { "label": "Work Manager: The total number of attempts to access a bean from the cache", "property": "CacheAccessCount" }, "cache_beans_current_count": { "label": "Work Manager: The total number of beans from this EJB Home currently in the EJB cache", "property": "CachedBeansCurrentCount" }, "cache_hit_count": { "label": "Work Manager: The total number of times an attempt to access a bean from the cache succeeded", "property": "CacheHitCount" }, "cache_miss_count": { "label": "Work Manager: The total number of times an attempt to access a bean from the cache failed", "property": "CacheMissCount" }, "passivation_count": { "label": "Work Manager: The total number of beans from this EJB Home that have been passivated", "property": "PassivationCount" } } }, #EJB Pool Metrics "ejb_pool": { "type": "EJBPoolRuntime", "metrics": { "access_total_count": { "label": "EJB Pool: The total number of times an attempt was made to get an instance from the free pool", "property": "AccessTotalCount" }, "beans_in_use_count": { "label": "EJB Pool: The total number of bean instances currently in use from the free pool", "property": "BeansInUseCount" }, "beans_in_use_current_count": { "label": "EJB Pool: The number of bean instances currently being used from the free pool", "property": "BeansInUseCurrentCount" }, "destroyed_total_count": { "label": "EJB Pool: The total number of times a bean instance from this pool was destroyed due to a non-application Exception being thrown from it", "property": "DestroyedTotalCount" }, "idle_beans_count": { "label": "EJB Pool: The total number of available bean instances in the free pool", "property": "IdleBeansCount" }, "miss_total_count": { "label": "EJB Pool: The total number of times a failed attempt was made to get an instance from the free pool", "property": "MissTotalCount" }, "pooled_beans_current_count": { "label": "EJB Pool: The current number of available bean instances in the free pool", "property": "PooledBeansCurrentCount" }, "timeout_total_count": { "label": "EJB Pool: The total number of Threads that have timed out waiting for an available bean instance from the free pool", "property": "TimeoutTotalCount" }, "waiter_current_count": { "label": "EJB Pool: The number of Threads currently waiting for an available bean instance from the free pool", "property": "WaiterCurrentCount" }, "waiter_total_count": { "label": "EJB Pool: The total number of Threads currently waiting for an available bean instance from the free pool", "property": "WaiterTotalCount" } } }, #EJB Transaction Metrics "ejb_transaction": { "type": "EJBTransactionRuntime", "metrics": { "transactions_committed_total_count": { "label": "EJB Transaction: The total number of transactions that have been committed for this EJB", "property": "TransactionsCommittedTotalCount" }, "transactions_rolled_back_total_count": { "label": "EJB Transaction: The total number of transactions that have been rolled back for this EJB", "property": "TransactionsRolledBackTotalCount" }, "transactions_timeout_total_count": { "label": "EJB Transaction: The total number of transactions that have timed out for this EJB", "property": "TransactionsTimedOutTotalCount" } } }, #Executive Queue Metrics "executive_queue": { "type": "ExecuteQueueRuntime", "metrics": { "execute_thread_current_idle_count": { "label": "Executive Queue: The number of idle threads assigned to the queue", "property": "ExecuteThreadCurrentIdleCount" }, "execute_thread_total_count": { "label": "Executive Queue: The total number of execute threads assigned to the queue", "property": "ExecuteThreadTotalCount" }, "pending_request_current_count": { "label": "Executive Queue: The number of waiting requests in the queue", "property": "PendingRequestCurrentCount" }, "pending_request_oldest_time": { "label": "Executive Queue: The time since the longest waiting request was placed in the queue", "property": "PendingRequestOldestTime" }, "serviced_request_total_count": { "label": "Executive Queue: The number of requests that have been processed by the queue", "property": "ServicedRequestTotalCount" } } }, #Servlet Metrics "servlet": { "type": "ServletRuntime", "metrics": { "execution_time_average": { "label": "Servlet: The average amount of time all invocations of the servlet have executed since created", "property": "ExecutionTimeAverage" }, "execution_time_high": { "label": "Servlet: The amount of time the single longest invocation of the servlet has executed since created", "property": "ExecutionTimeHigh" }, "execution_time_low": { "label": "Servlet: The amount of time the single shortest invocation of the servlet has executed since created", "property": "ExecutionTimeLow" }, "execution_time_total": { "label": "Servlet: The total amount of time all invocations of the servlet have executed since created", "property": "ExecutionTimeTotal" }, "invocation_total_count": { "label": "Servlet: The total count of the times this servlet has been invoked", "property": "InvocationTotalCount" }, "pool_max_capacity": { "label": "Servlet: The maximum capacity of this servlet for single thread model servlets", "property": "PoolMaxCapacity" }, "reload_total_count": { "label": "Servlet: The total count of the number of times this servlet has been reloaded", "property": "ReloadTotalCount" } } }, #Web App Component Metrics "web_app_component": { "type": "WebAppComponentRuntime", "metrics": { "open_sessions_current_count": { "label": "Web App Component: The current total number of open sessions in this module", "property": "OpenSessionsCurrentCount" }, "open_sessions_high_count": { "label": "Web App Component: The high water mark of the total number of open sessions in this server", "property": "OpenSessionsHighCount" }, "sessions_opened_total_count": { "label": "Web App Component: The total number of sessions opened", "property": "SessionsOpenedTotalCount" } } } } def get_metric(config, type, property=None): set_env_command = "" if 'wl_home' in config: set_env_command = ("CLASSPATH=%s " % os.path.join(config['wl_home'], "server/lib/weblogic.jar")) cmd = set_env_command + "java weblogic.Admin" if "username" in config: cmd += " -username %s" % config["username"] if "password" in config and config["password"].strip(): cmd += " -password %s" % config["password"].strip() cmd += " GET -pretty -type %s" % type if property: cmd += " -property %s" % property status, output = agent_util.execute_command(cmd) if status != 0: raise Exception(output) output = output.strip().split("\n")[-1] if not property: if output == "No MBeans found": raise Exception(output) else: return output else: parsed_output = output[output.index(":") + 1:].strip() return parsed_output class WeblogicPlugin(agent_util.Plugin): textkey = "weblogic" label = "Oracle WebLogic Webserver" @classmethod def get_metadata(self, config): status = agent_util.SUPPORTED msg = None # check if oracle weblogic is installed, running, and on path set_env_command = "" if 'wl_home' in config: set_env_command = ("CLASSPATH=%s " % os.path.join(config['wl_home'], "server/lib/weblogic.jar")) installed = False if agent_util.which("java"): cmd = set_env_command + "java weblogic.Admin" if "username" in config: cmd += " -username %s" % config["username"] if "password" in config and config["password"].strip(): cmd += " -password %s" % config["password"].strip() status, output = agent_util.execute_command(cmd) if status == 0: installed = True if not installed: self.log.info("Oracle weblogic was not found installed or not on path") status = agent_util.UNSUPPORTED return {} if not config: msg = "The [weblogic] configuration block was not found in the agent config file." self.log.info(msg) status = agent_util.MISCONFIGURED if status == agent_util.SUPPORTED and not ("wl_home" in config and "username" in config and "password" in config): msg = "Weblogic configuration parameters missing from the [weblogic] block of the agent config file." self.log.info(msg) status = agent_util.MISCONFIGURED if status == agent_util.SUPPORTED and not os.path.exists(os.path.join(config['wl_home'], "server/bin/setWLSEnv.sh")): msg ="Weblogic setWLSEnv.sh script not found" self.log.info(msg) status = agent_util.MISCONFIGURED if status == agent_util.SUPPORTED: try: output = get_metric(config, "ApplicationRuntime") except: self.log.exception("error getting weblogic metric") status = agent_util.MISCONFIGURED msg = "Unable to access Weblogic metrics. Please double check your Weblogic login username and password as well as wl_home in the agent config file." data = {} for type, vals in metrics.items(): try: output = get_metric(config, vals["type"]) except: continue for property, meta in vals["metrics"].items(): textkey = "%s.%s" % (type, property) data[textkey] = { "label": meta["label"][:100], "options": meta.get('options', None), "status": status, "error_message": msg } if "unit" in meta: data[textkey]["unit"] = meta["unit"] if not data: data = {'servlet': {"label": "WebLogic Servlets", "options": None, "status": status, "error_message": msg}} return data def check(self, textkey, data, config): try: type, property = textkey.split(".") except: return False if type not in metrics or property not in metrics[type]["metrics"]: return False val = int(get_metric(config, metrics[type]["type"], metrics[type]["metrics"][property]["property"])) self.log.debug("%s: %d" % (textkey, val)) return val
Close