Security sandbox monitoring management system and method based on Kubernetes and medium

Through the security sandbox management system based on Kubernetes, the problems of low resource utilization and inconvenient management are solved, efficient monitoring and dynamic management of service sandboxes are achieved, and the optimal utilization of system resources and the stable operation of the sandbox are ensured.

CN118862053APending Publication Date: 2024-10-29SHANDONG INSPUR SCI RES INST CO LTD
View PDF 0 Cites 1 Cited by

Patent Information

Application Number
CN202410998167.5
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-07-24
Publication Date
2024-10-29

AI Technical Summary

Technical Problem

The existing security sandbox management system suffers from low resource utilization, inconvenient management, and effective monitoring of continuously running service sandboxes.

Method used

Adopt a security sandbox management system based on Kubernetes, including security sandbox deployment and management module, running status monitoring module, scheduling and resource allocation module, security sandbox cleaning and restart module, and security audit and logging module, through Kubernetes API, Technologies such as Prometheus, Elasticsearch, and Kibana enable dynamic management and monitoring of sandboxes.

Benefits of technology

It improves resource utilization, achieves stable operation and efficient management of the sandbox, reduces manual intervention by administrators, and ensures optimal utilization of system resources and continuous availability of the sandbox.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118862053A_ABST
    Figure CN118862053A_ABST
Patent Text Reader

Abstract

The invention relates to the field of data security, in particular to a security sandbox monitoring management system and method based on Kubernetes and a medium. The method comprises the following steps: firstly, creating a Deployment object of a sandbox application, and automatically selecting a proper node in a cluster to run an application copy in a deployment process; and collecting and storing monitoring data of the sandbox application and displaying the monitoring data. And performing dynamic extension according to the resource request and the limiting configuration. And setting a fault recovery mechanism, and automatically restarting the failed sandbox instance. According to the method, the Elasticsearch and the Fluentd are integrated to carry out log recording and centralized management, and the Kibana is used to carry out log visualization and search. According to the invention, dynamic management, scheduling and cleaning of the sandbox can be carried out according to real-time conditions of host resources, so that optimal utilization of system resources and stable operation of the safe sandbox are ensured.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the fields of data security and cloud computing, and in particular to a Kubernetes-based security sandbox monitoring management system, method and medium. Background Art

[0002] In current data security applications, security sandbox technology is widely used as an important means of security isolation to prevent malicious code from attacking the host system. By running applications in a restricted environment, the security sandbox effectively prevents malicious code from abusing and damaging system resources. Usually, the security sandbox is a virtual environment in which applications run but cannot directly access host system resources, and the host system cannot directly access the internal data or running status of the sandbox.

[0003] Security sandboxes can be divided into two categories based on their operation mode: computing sandboxes that run once and service sandboxes that work continuously. Computing sandboxes are usually destroyed after executing a specific computing task, while service sandboxes need to continue to run to provide services until the administrator manually shuts them down. However, due to the limited computing resources of the security sandbox server, when there are too many computing tasks, they will be queued for execution.

[0004] In order to effectively manage and monitor the operating status of the security sandbox, especially the continuous operation of the service sandbox, it is necessary to introduce an efficient monitoring and scheduling system that can dynamically manage, schedule and clean up the sandbox according to the real-time situation of the host resources to ensure the optimal utilization of system resources and the stable operation of the security sandbox. Summary of the invention

[0005] The technical problem to be solved by the present invention is to provide a Kubernetes-based security sandbox monitoring and management system, method and medium, aiming to solve the problems of low resource utilization, inconvenient management and effective monitoring of continuously running service sandboxes in existing security sandbox management systems.

[0006] In order to solve the technical problem, the technical solution adopted by the present invention is: a Kubernetes-based security sandbox management system, comprising: The secure sandbox deployment and management module is used to create and manage KubernetesDeployment objects for sandbox applications; The operation status monitoring module integrates Prometheus to collect and store the operation indicators of the sandbox application; The scheduling and resource allocation module uses the Kubernetes scheduler to allocate resources and automatically scale sandbox applications. The security sandbox cleanup and restart module realizes automatic recovery of applications through the update strategy and health check of KubernetesDeployment objects; The security audit and logging module integrates Elasticsearch and Kibana to implement log management and security auditing of sandbox applications.

[0007] Furthermore, the security sandbox deployment and management module uses the Kubernetes API or the kubectl command-line tool to create and configure the Deployment object of the sandbox application. In the io.kubernetes.client.openapi.models.V1Deployment class, the createSandboxDeployment method is used to create a security sandbox deployment. The createSandboxDeployment method uses the V1Deployment class in the Kubernetes Java client SDK to create a new sandbox deployment to ensure that the sandbox application can be expanded and managed on demand in the Kubernetes environment.

[0008] Furthermore, the running status monitoring module configures Prometheus to collect and store monitoring data of sandbox applications, monitor indicators of security sandbox applications, and use Grafana to display a visualization panel of monitoring data; in the io.prometheus.client.CollectorRegistry class, the register method is used to configure and register the Prometheus collector, and the CollectorRegistry class in the PrometheusJava client library is used to register and expose monitoring indicators, so that the Prometheus server collects and stores the running data of the sandbox application.

[0009] Furthermore, the operation status monitoring module performs monitoring and data analysis through PromQL.

[0010] Furthermore, the scheduling and resource allocation module and the resource allocation module use Kubernetes' resource request and limit configuration, and use Kubernetes' automatic horizontal scaler for dynamic expansion. In the io.kubernetes.client.openapi.models.V1PodSpec class, the resources method is used to configure the resource requests and limits of the sandbox application. The V1PodSpec class in the KubernetesJava client SDK is used to build the Pod specification of the sandbox application, including resource requests and limits, to ensure that the sandbox can allocate resources on demand and schedule them in the Kubernetes cluster.

[0011] Furthermore, the secure sandbox cleanup and restart module configures the update strategy and health check of the Deployment object to manage and restore the status of the sandbox application in an automated manner.

[0012] Furthermore, the security sandbox cleanup and restart module sets up Kubernetes' fault recovery mechanism to automatically restart failed sandbox instances; in the io.kubernetes.client.openapi.models.V1DeploymentSpec class, the replicas, strategy, and template methods are used to configure automatic horizontal scaling of the security sandbox application. These methods use the V1DeploymentSpec class in the Kubernetes Java client SDK to configure the deployment specifications of the security sandbox application, including the automatic rolling update strategy, to ensure that the sandbox automatically restarts and adjusts the number of instances when a failure occurs or resource requirements change.

[0013] Furthermore, the security audit and logging module integrates Elasticsearch as the log storage engine for sandbox applications, uses Fluentd or Filebeat as the data collector, and utilizes Kibana for real-time log analysis and security auditing.

[0014] The present invention also discloses a Kubernetes-based security sandbox monitoring and management method, comprising the following steps: S01) Security sandbox deployment and management. Use Kubernetes to deploy security sandbox applications. In the io.kubernetes.client.openapi.models.V1Deployment class, use the createSandboxDeployment method to create a security sandbox deployment. The createSandboxDeployment method uses the V1Deployment class in the Kubernetes Java client SDK to create a new sandbox deployment to ensure that the sandbox application can be expanded and managed on demand in the Kubernetes environment. S02) Operation status monitoring: configure Prometheus to collect and store the monitoring data of the sandbox application, and use Grafana to display the visualization panel of the monitoring data; in the io.prometheus.client.CollectorRegistry class, use the register method to configure and register the Prometheus collector; use the CollectorRegistry class in the PrometheusJava client library to register and expose monitoring indicators so that the Prometheus server can collect and store the operation data of the sandbox application in the future; S03) Scheduling and resource allocation, using Kubernetes' resource request and limit configuration, using Kubernetes' automatic horizontal scaler for dynamic expansion, in the io.kubernetes.client.openapi.models.V1PodSpec class, use the resources method to configure the resource request and limit of the sandbox application, and use the V1PodSpec class in the Kubernetes Java client SDK to build the Pod specification of the sandbox application, including resource requests and limits, to ensure that the sandbox can allocate resources on demand and schedule in the Kubernetes cluster; S04), clean up and restart the security sandbox, set up the Kubernetes fault recovery mechanism, automatically restart the failed sandbox instance, and use the replicas, strategy, and template methods in the io.kubernetes.client.openapi.models.V1DeploymentSpec class to configure the automatic horizontal expansion of the security sandbox application. These methods use the V1DeploymentSpec class in the Kubernetes Java client SDK to configure the deployment specifications of the security sandbox application, including the automatic rolling update strategy, to ensure that the sandbox can automatically restart and adjust the number of instances when a failure or resource demand changes; S05), security audit and logging, integrate Elasticsearch and Fluentd for logging and centralized management, use Kibana for log visualization and search, use the IndexRequest.source method in the org.elasticsearch.client.RestHighLevelClient class to configure and use Kibana for log visualization and search, and use the RestHighLevelClient class in the ElasticsearchJava client library to send the log data of the sandbox application to the Elasticsearch server for subsequent real-time log analysis, visualization, and search in Kibana.

[0015] The present invention also discloses a storage medium storing program instructions, which, when running, execute the above-mentioned Kubernetes-based security sandbox monitoring and management method.

[0016] Beneficial effects of the present invention: In order to effectively manage and monitor the operating status of the security sandbox, especially the continuous operation of the service sandbox, the present invention needs to introduce an efficient monitoring and scheduling system, which can dynamically manage, schedule and clean up the sandbox according to the real-time situation of the host resources to ensure the optimal utilization of system resources and the stable operation of the security sandbox. BRIEF DESCRIPTION OF THE DRAWINGS

[0017] Figure 1 It is a principle block diagram of Example 1; Figure 2 This is a flow chart of Example 2. DETAILED DESCRIPTION

[0018] In order to make the purpose, technical solutions and advantages of the embodiments of the present invention clearer, the technical solutions in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are part of the embodiments of the present invention, rather than all the embodiments. Based on the embodiments in the present invention, all other embodiments obtained by ordinary technicians in this field without making creative work are within the scope of protection of the present invention.

[0019] Example 1 This embodiment discloses a Kubernetes-based security sandbox monitoring and management system. Figure 1As shown, it includes a secure sandbox deployment and management module, which configures the KubernetesDeployment objects used to create and manage sandbox applications; uses the KubernetesAPI or kubectl command-line tool to create and configure the Deployment objects of the sandbox applications to ensure the elasticity and scalability of the sandbox applications in the cluster.

[0020] The operation status monitoring module integrates Prometheus to collect and store the operation indicators of the sandbox application. The operation status monitoring module configures the Prometheus client library to regularly expose monitoring indicators in the sandbox application, collects and stores data in real time through the Prometheus server, and supports administrators to monitor and analyze data through PromQL.

[0021] The scheduling and resource allocation module uses the Kubernetes scheduler to perform resource allocation and automatic expansion of sandbox applications. The scheduling and resource allocation module configures the resource requests and restrictions of sandbox applications, uses the Kubernetes scheduler to ensure appropriate scheduling and resource allocation of applications in the cluster, and uses the automatic horizontal scaler to automatically adjust the number of replicas according to load conditions.

[0022] The security sandbox cleanup and restart module realizes automatic recovery of applications through the update strategy and health check of KubernetesDeployment objects; the security sandbox cleanup and restart module configures the update strategy and health check of Deployment objects to manage and restore the status of sandbox applications in an automated manner to ensure the availability of applications in the event of failures or resource changes.

[0023] The security audit and logging module integrates Elasticsearch and Kibana to implement log management and security auditing of sandbox applications. Integrate Elasticsearch as the log storage engine for sandbox applications, use Fluentd or Filebeat as the data collector, and use Kibana for real-time log analysis and security auditing.

[0024] In this embodiment, you first need to create a Deployment object for the sandbox application through the Kubernetes control plane (such as the kubectl command line tool or the Kubernetes API). Deployment defines the sandbox application's image, number of replicas, environment variables and other parameters. During the deployment process, Kubernetes will automatically select the appropriate node in the cluster to run these application replicas, and use ReplicaSet to ensure that the number of replicas meets expectations, and can quickly recover even if a node or replica fails.

[0025] For running status monitoring, the system will integrate Prometheus for configuration. Prometheus is an open source monitoring solution. By integrating the Prometheus client library in the sandbox application, the application will regularly expose its own monitoring indicators (such as CPU usage, memory consumption, etc.). These indicators are exposed to the Prometheus server through the HTTP interface, which regularly captures and stores this data. Administrators can use the query language (PromQL) provided by Prometheus for real-time monitoring, alarm settings, and data analysis, so as to adjust the configuration and resource allocation of the sandbox application in a timely manner.

[0026] The scheduling and resource allocation module is managed by the Kubernetes scheduler. In the Deployment object, define the resource requests and restrictions of the sandbox application, such as the requested amount of CPU and memory. The Kubernetes scheduler will select the most suitable node to deploy and schedule the sandbox application based on the resource status of the nodes in the cluster and the needs of the application. In addition, Kubernetes also provides an automatic horizontal scaler (Horizontal Pod Autoscaler), which can automatically adjust the number of copies of the sandbox application according to the preset CPU utilization or other indicators to ensure the stability and performance of the system under high load conditions.

[0027] The cleanup and restart mechanism of the security sandbox is managed through Kubernetes' Deployment. The update strategy (such as rolling update) and health check (Probe) configuration in the Deployment object can ensure automatic restart and recovery when the sandbox application fails or resources are exhausted. The health check can regularly detect the status of the application and decide whether to restart the replica based on the preset success criteria. This automated mechanism can greatly improve the availability and reliability of the sandbox application and reduce the need for manual intervention by the administrator.

[0028] In the implementation, in order to achieve security auditing and logging, the system will integrate Elasticsearch and Kibana. Elasticsearch, as a distributed document storage and retrieval engine, is used to store the operation logs of sandbox applications. Fluentd or Filebeat, as data collectors, is responsible for collecting application logs and transmitting them to Elasticsearch. Kibana is the visualization interface of Elasticsearch. Administrators can use its powerful search and analysis functions to monitor the logs of sandbox applications in real time, discover potential security issues and abnormal situations, and take corresponding countermeasures.

[0029] Example 2 This embodiment discloses a security sandbox monitoring and management method based on Kubernetes, including the following steps: S01), security sandbox deployment and management, use Kubernetes to deploy security sandbox applications, the specific implementation process is: in the io.kubernetes.client.openapi.models.V1Deployment class, use the createSandboxDeployment method to create a security sandbox deployment. This method uses the V1Deployment class in the Kubernetes Java client SDK to create a new sandbox deployment to ensure that the sandbox application can be expanded and managed on demand in the Kubernetes environment.

[0030] S02) Operation status monitoring: configure Prometheus to collect and store the monitoring data of the sandbox application, and use Grafana to display the visualization panel of the monitoring data. The specific implementation process is: in the io.prometheus.client.CollectorRegistry class, use the register method to configure and register the Prometheus collector. Use the CollectorRegistry class in the PrometheusJava client library to register and expose monitoring indicators so that the Prometheus server can collect and store the operation data of the sandbox application.

[0031] S03), Scheduling and resource allocation, using Kubernetes' resource request and limit configuration, using Kubernetes' automatic horizontal scaler for dynamic expansion, the specific implementation process is: in the io.kubernetes.client.openapi.models.V1PodSpec class, use the resources method to configure the resource request and limit of the sandbox application. Use the V1PodSpec class in the Kubernetes Java client SDK to build the Pod specification of the sandbox application, including resource requests and limits, to ensure that the sandbox can allocate resources on demand and schedule in the Kubernetes cluster.

[0032] S04), clean up and restart the security sandbox, set up the Kubernetes fault recovery mechanism, and automatically restart the failed sandbox instance. The specific implementation process is: in the io.kubernetes.client.openapi.models.V1DeploymentSpec class, use the replicas, strategy, and template methods to configure the automatic horizontal expansion of the security sandbox application. These methods use the V1DeploymentSpec class in the Kubernetes Java client SDK to configure the deployment specifications of the security sandbox application, including the automatic rolling update strategy, to ensure that the sandbox can automatically restart and adjust the number of instances when a failure or resource demand changes.

[0033] S05), security audit and logging, integrating Elasticsearch and Fluentd for logging and centralized management, using Kibana for log visualization and search. The specific implementation process is: in the org.elasticsearch.client.RestHighLevelClient class, use the IndexRequest.source method to configure and use Kibana for log visualization and search. Use the RestHighLevelClient class in the ElasticsearchJava client library to send the log data of the sandbox application to the Elasticsearch server for subsequent real-time log analysis, visualization, and search in Kibana.

[0034] The above description is only the basic principle and preferred embodiments of the present invention. Improvements and substitutions made by those skilled in the art based on the present invention belong to the protection scope of the present invention.

Claims

1. A Kubernetes-based security sandbox management system, characterized by: include: The secure sandbox deployment and management module is used to create and manage KubernetesDeployment objects for sandbox applications; The operation status monitoring module integrates Prometheus to collect and store the operation indicators of the sandbox application; The scheduling and resource allocation module uses the Kubernetes scheduler to allocate resources and automatically scale sandbox applications. The security sandbox cleanup and restart module realizes automatic recovery of applications through the update strategy and health check of KubernetesDeployment objects; The security audit and logging module integrates Elasticsearch and Kibana to implement log management and security auditing of sandbox applications.

2. The Kubernetes-based security sandbox management system according to claim 1, characterized in that: The security sandbox deployment and management module uses the Kubernetes API or the kubectl command-line tool to create and configure the Deployment object of the sandbox application. In the io.kubernetes.client.openapi.models.V1Deployment class, the createSandboxDeployment method is used to create a security sandbox deployment. The createSandboxDeployment method uses the V1Deployment class in the Kubernetes Java client SDK to create a new sandbox deployment to ensure that the sandbox application can be expanded and managed on demand in the Kubernetes environment.

3. The Kubernetes-based security sandbox management system according to claim 1, characterized in that: The running status monitoring module configures Prometheus to collect and store monitoring data of sandbox applications, monitors the indicators of security sandbox applications, and uses Grafana to display the visualization panel of monitoring data; in the io.prometheus.client.CollectorRegistry class, use the register method to configure and register the Prometheus collector, and use the CollectorRegistry class in the PrometheusJava client library to register and expose monitoring indicators, so that the Prometheus server collects and stores the running data of the sandbox application.

4. The Kubernetes-based security sandbox management system according to claim 3, characterized in that: The operation status monitoring module performs monitoring and data analysis through PromQL.

5. The Kubernetes-based security sandbox management system according to claim 1, characterized in that: The scheduling and resource allocation module and the resource allocation module use Kubernetes' resource request and limit configuration, and use Kubernetes' automatic horizontal scaler for dynamic expansion. In the io.kubernetes.client.openapi.models.V1PodSpec class, use the resources method to configure the resource requests and limits of the sandbox application. Use the V1PodSpec class in the KubernetesJava client SDK to build the Pod specification of the sandbox application, including resource requests and limits, to ensure that the sandbox can allocate resources on demand and schedule in the Kubernetes cluster.

6. The Kubernetes-based security sandbox monitoring and management system according to claim 1, characterized in that: The secure sandbox cleanup and restart module configures the update strategy and health check of the Deployment object to manage and restore the status of the sandbox application in an automated manner.

7. The Kubernetes-based security sandbox monitoring and management system according to claim 6 is characterized in that: The security sandbox cleanup and restart module sets up Kubernetes' fault recovery mechanism to automatically restart failed sandbox instances. In the io.kubernetes.client.openapi.models.V1DeploymentSpec class, the replicas, strategy, and template methods are used to configure automatic horizontal expansion of the security sandbox application. These methods use the V1DeploymentSpec class in the Kubernetes Java client SDK to configure the deployment specifications of the security sandbox application, including the automatic rolling update strategy, to ensure that the sandbox automatically restarts and adjusts the number of instances when a failure occurs or resource requirements change.

8. The Kubernetes-based security sandbox monitoring and management system according to claim 1, characterized in that: The security audit and logging module integrates Elasticsearch as the log storage engine for sandbox applications, uses Fluentd or Filebeat as the data collector, and uses Kibana for real-time log analysis and security auditing.

9. A security sandbox monitoring and management method based on Kubernetes, characterized in that: The following steps are involved: S01) Security sandbox deployment and management. Use Kubernetes to deploy security sandbox applications. In the io.kubernetes.client.openapi.models.V1Deployment class, use the createSandboxDeployment method to create a security sandbox deployment. The createSandboxDeployment method uses the V1Deployment class in the Kubernetes Java client SDK to create a new sandbox deployment to ensure that the sandbox application can be expanded and managed on demand in the Kubernetes environment. S02) Operation status monitoring: configure Prometheus to collect and store the monitoring data of the sandbox application, and use Grafana to display the visualization panel of the monitoring data; in the io.prometheus.client.CollectorRegistry class, use the register method to configure and register the Prometheus collector; use the CollectorRegistry class in the PrometheusJava client library to register and expose monitoring indicators so that the Prometheus server can collect and store the operation data of the sandbox application in the future; S03) Scheduling and resource allocation, using Kubernetes' resource request and limit configuration, using Kubernetes' automatic horizontal scaler for dynamic expansion, in the io.kubernetes.client.openapi.models.V1PodSpec class, use the resources method to configure the resource request and limit of the sandbox application, and use the V1PodSpec class in the Kubernetes Java client SDK to build the Pod specification of the sandbox application, including resource requests and limits, to ensure that the sandbox can allocate resources on demand and schedule in the Kubernetes cluster; S04) Clean up and restart the security sandbox, set up the fault recovery mechanism of Kubernetes, automatically restart the failed sandbox instance, and use the replicas, strategy, and template methods in the io.kubernetes.client.openapi.models.V1DeploymentSpec class to configure the automatic horizontal expansion of the security sandbox application. These methods use the V1DeploymentSpec class in the Kubernetes Java client SDK to configure the deployment specification of the security sandbox application, including the automatic rolling update strategy, to ensure that the sandbox can automatically restart and adjust the number of instances when a failure or resource demand changes; S05), security audit and logging, integrate Elasticsearch and Fluentd for logging and centralized management, use Kibana for log visualization and search, use the IndexRequest.source method in the org.elasticsearch.client.RestHighLevelClient class to configure and use Kibana for log visualization and search, and use the RestHighLevelClient class in the ElasticsearchJava client library to send the log data of the sandbox application to the Elasticsearch server for subsequent real-time log analysis, visualization, and search in Kibana.

10. A storage medium storing program instructions, characterized in that: When the program instructions are running, they execute the Kubernetes-based security sandbox monitoring and management method as described in claim 9.

Citation Information

Cited By

  • Abnormal recovery control method for robot workstation

    CN122401450A