Online code editing system and device and related product
By introducing code protection devices and configuring code security protection logic in the online IDE system, the shortcomings of existing online IDEs in code security protection are solved, real-time analysis of code editing and call requests and security policy application are realized, and the security and user experience of the code are improved.
Patent Information
- Application Number
- CN202411765052.8
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-04
- Publication Date
- 2025-03-25
AI Technical Summary
The existing online IDE has shortcomings in code security protection, and it is impossible to utilize the deep monitoring conditions of the online IDE to achieve better protection effects.
Introduce code protection devices and configure code security protection logic to comprehensively monitor and control the duplex interaction between the browser, trusted components and online IDE modules and their associated components, real-time analysis of code editing and call requests and security policy application.
Through an enhanced security monitoring mechanism, it effectively prevents unauthorized or malicious code access and operations, improves the security of the code, and provides flexible and powerful security policy application capabilities.
Smart Images

Figure CN119690396A_ABST
Abstract
Description
Technical Field
[0001] The present invention belongs to the field of data processing, and in particular relates to an online code editing system, device and related products. Background Art
[0002] Online IDE is a development tool that allows developers to use it directly on the Internet. It provides an environment that integrates code editing, compiling, debugging and running. It allows developers to access the online IDE through a browser and directly use remote development resources for software development. Most existing online IDEs focus on the functional implementation of the IDE itself. For code security, they only rely on the server deployment of the online IDE itself to achieve access isolation. For example, a common method is to determine the permissions of the user who initiates access on the server side of the code repository, and perform access release or access prohibition operations based on the permission results.
[0003] However, since online IDE is different from local IDE, the core service of online IDE runs on the server side, which has the conditions for deeper monitoring. The current technical solution cannot take advantage of this advantage of online IDE and cannot achieve better protection effect. Summary of the invention
[0004] Based on the above problems, the embodiments of the present application provide an online code editing system, device and related products to solve the above problems existing in the prior art.
[0005] An embodiment of the present application provides an online code editing system, which includes: a code protection device, a browser, a trusted component, an online IDE module, and an online IDE associated component. The code protection device is configured with code security protection logic, the browser and the trusted component are both communicatively connected to the code protection device, and the code protection device is communicatively connected to the online IDE module, so that the duplex interaction between the browser and at least one of the online IDE module and the online IDE associated component, the duplex interaction between the trusted component and the online IDE module, and the duplex interaction between the trusted component and at least one of the online IDE module and the online IDE associated component are all controlled by the code security protection logic configured on the code protection device, and the duplex interaction is based on a code editing request and a code editing function call request, and the code editing request and the code editing function call request are both generated by the browser.
[0006] The embodiment of the present application also provides a code protection device, comprising: the code protection device is configured with code security protection logic, the code protection device is deployed between the browser and the online IDE module communication, and is located between the trusted component and the online IDE module communication, so that at least one of the following duplex interactions is controlled by the code security protection logic configured on the code protection device: Duplex interaction between the browser and the online IDE module; Duplex interaction between the browser and components associated with the online IDE; duplex interaction between the trusted component and the online IDE module; Duplex interaction between the trusted component and the online IDE associated component; The duplex interaction is based on a code editing request and a code editing function calling request, and both the code editing request and the code editing function calling request are generated through the browser.
[0007] The embodiment of the present application further provides a computer storage medium, on which a computer executable program is stored. When the computer executable program is run, the set code security protection logic is implemented to control at least one of the following duplex interactions to perform online code editing: Duplex interaction between browser and online IDE modules; Duplex interaction between the browser and online IDE-related components; Duplex interaction between the trusted component and the online IDE module; Duplex interaction between the trusted component and the online IDE associated component; The duplex interaction is based on a code editing request and a code editing function calling request, and both the code editing request and the code editing function calling request are generated through the browser.
[0008] The present application provides an online code editing system, device and related products. The online code editing system proposed in the present application has the following technical advantages: (1) This application adds a layer of active security monitoring mechanism to the online IDE by adding a code protection device. The code security protection logic configured on the code protection device can monitor and analyze in real time the interaction requests between the browser and the online IDE module and the online IDE-related components, including code editing requests and code editing function call requests.
[0009] (2) The system design ensures that all duplex interactions between the browser and the online IDE module, between the browser and the online IDE associated components, and between the trusted components and the online IDE module (and its associated components) are controlled by the code protection device. This comprehensive monitoring mechanism effectively prevents unauthorized or malicious code access and operation, and improves code security.
[0010] (3) The code security protection logic on the code protection device can be customized and refined according to specific security requirements. For example, different access rights and editing rights can be set for different users, different projects or different code areas to achieve refined security management. Compared with the traditional access isolation method based on server deployment, this provides more flexible and powerful security policy application capabilities.
[0011] (4) The core service of the online IDE runs on the server side, which provides the conditions for deeper monitoring. This application fully utilizes this advantage through the code protection device to achieve deep analysis and real-time monitoring of code editing and call requests. This mechanism can timely detect and prevent potential security threats, such as code injection, unauthorized access, etc., thereby improving the security of the code.
[0012] (5) This application enhances code security without sacrificing user experience. The browser, as the main interface for users to interact with the online IDE, remains unchanged, and users can continue to edit code and call functions through the browser. The code protection device works silently in the background, providing users with imperceptible security protection. BRIEF DESCRIPTION OF THE DRAWINGS
[0013] In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, it is possible to obtain other drawings based on these drawings without paying creative labor.
[0014] Figure 1 This is a structural diagram of an online code editing system according to an embodiment of the present application.
[0015] Figure 2 This is a schematic diagram of the structure of a code protection device according to an embodiment of the present application. DETAILED DESCRIPTION
[0016] The implementation of any technical solution of the embodiments of the present application does not necessarily require achieving all of the above advantages at the same time.
[0017] In order to enable those skilled in the art to better understand the scheme of the present invention, the technical scheme 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 only part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.
[0018] Figure 1 This is a schematic diagram of the structure of an online code editing system according to an embodiment of the present application. Figure 1 The online code editing system shown includes: a code protection device, a browser, a trusted component, an online IDE module, and an online IDE associated component. The code protection device is configured with code security protection logic. The browser and the trusted component are both communicated with the code protection device. The code protection device is communicated with the online IDE module, so that the duplex interaction between the browser and at least one of the online IDE module and the online IDE associated component, the duplex interaction between the trusted component and the online IDE module, and the duplex interaction between the trusted component and at least one of the online IDE module and the online IDE associated component are all controlled by the code security protection logic configured on the code protection device. The duplex interaction is based on a code editing request and a code editing function call request. The code editing request and the code editing function call request are both generated by the browser.
[0019] The online code editing system proposed in this application, by introducing a code protection device and configuring sophisticated code security protection logic, comprehensively monitors and controls the duplex interaction between the browser, trusted components and the online IDE module and its associated components, effectively solving the shortcomings of existing online IDEs in terms of code security protection. The system makes full use of the conditions of deep monitoring on the online IDE server side, realizes real-time analysis and security policy application of code editing and call requests, which not only enhances the security of the code, but also maintains a good user experience, providing developers with a safe, efficient and flexible online development environment.
[0020] Optionally, the online IDE associated components include a first component, a second component, and a third component, the first component at least includes a code repository for code storage and management, the second component is configured to allow users to directly access it when performing online code editing, and the third component is configured to allow users to access it after approval when performing online code editing.
[0021] To this end, in combination with the technical solution of this application, the online IDE-related components are subdivided into a first component (code repository), a second component (direct access component) and a third component (approval access component), which has the following technical benefits: (1) The first component, the code repository, is specifically used for code storage and management. This clear division of components helps to implement key functions such as code version control, backup and recovery, and permission management, thereby ensuring the integrity and security of the code. Through the centralized management of the code repository, the loss, tampering, or unauthorized access of the code can be effectively prevented, providing developers with a reliable code storage environment.
[0022] (2) The second component is configured to allow users to directly access required resources, such as documents, tools, etc., when performing online code editing. This direct access mechanism reduces the time users spend searching and obtaining resources and improves editing efficiency. At the same time, since all access is monitored and controlled by the code protection device, this direct access does not sacrifice code security.
[0023] (3) The third component is configured so that users need to be approved before they can access certain sensitive or high-risk online code editing operations. This approval mechanism provides an additional security barrier for sensitive operations, preventing unauthorized or malicious access and operations. At the same time, the approval process can also be customized according to actual needs to meet the security requirements of different projects and users, enhancing the flexibility and security of access control.
[0024] Optionally, the code security protection logic includes: permission control logic, which is used to authenticate the user's permission when receiving a code editing request initiated by the user through the browser.
[0025] Optionally, the permission control logic includes permission authentication logic to authenticate at least one of the following permissions: The right to call the online IDE module; access rights of the first component; direct access to the second component; Approved access rights to the third component.
[0026] To this end, the permission control logic in the code security protection logic is further refined into authentication of specific permissions, including calling permissions for online IDE modules, access permissions for the first component (code repository), direct access permissions for the second component, and approved access permissions for the third component. This has the following technical benefits: (1) By refining the permission control logic, the system can accurately divide and manage permissions for different users and different operations. This refined permission management not only improves the security of the code, but also ensures that users can only access and operate the resources they are authorized to, avoiding the risk of permission abuse and misoperation.
[0027] (2) The permission control logic authenticates the calling permissions of the online IDE module to ensure that only users with corresponding permissions can call the core functions of the IDE, such as compiling and debugging. This effectively prevents unauthorized access and operation and protects the security of the code.
[0028] Authenticating access permissions to the first component (code repository) ensures that access to the code repository is strictly controlled. Only authorized users can access and modify the code, preventing code leakage and tampering.
[0029] (3) The direct access permission authentication of the second component allows users to directly access commonly used resources, such as public library files, without additional approval after identity authentication, thus improving editing efficiency.
[0030] The third component, approved access rights authentication, provides additional security for sensitive or high-risk operations. When users perform these operations, they need to go through an approval process to ensure the legality and security of the operations.
[0031] (4) By refining the permission control logic, the system can flexibly configure permission policies according to different projects, user roles and security requirements. This flexibility enables the system to adapt to various complex security scenarios and provides developers with a secure and efficient online development environment.
[0032] Optionally, the permission control logic further includes: permission management logic to manage permissions in at least one of the following ways and perform permission authentication accordingly: For the first component, permissions can be inherited based on the hierarchical relationship between the users and user groups; For the second component, no permission determination is performed when accessing, and / or, no permission determination is performed when accessing and permissions are inherited based on the hierarchical relationship between the users and user groups, and / or, permission determination is performed when accessing; For the third component, permission approval is automatically initiated when access is made.
[0033] To this end, the permission management logic further included in the permission control logic brings the following technical benefits to the online code editing system through the careful management of permissions and authorization authentication based on them: (1) For the first component (code repository), the permission management logic supports permission inheritance based on the hierarchical relationship between users and user groups. This means that when users are assigned to a user group, they can automatically inherit the permissions of the user group. This hierarchical permission management mechanism greatly simplifies the permission allocation process, making permission management more efficient and easier to maintain. At the same time, it also ensures the consistency of permissions within the organization and avoids confusion and conflicts in permission allocation.
[0034] (2) For the second component (direct access component), the permission management logic provides a variety of access control strategies. Based on actual needs, the system can choose not to make permission determinations and allow all users to access directly; or combine the hierarchical relationship between users and user groups to make permissions inheritable while retaining permission determinations for specific users; or even perform strict permission determinations on all access. This flexibility enables the system to adapt to different security needs and usage scenarios, ensuring both efficiency and security.
[0035] (3) For the third component (approval access component), the permission management logic automatically initiates permission approval when accessing. This automated approval process not only improves the efficiency of approval, but also ensures the consistency and fairness of approval. Through preset approval rules and processes, the system can automatically approve the user's access request and decide whether to allow access based on the approval results. This effectively prevents unapproved access and operations and enhances the security of the code.
[0036] (4) The refinement and flexible configuration of permission management logic make the system easier to expand and maintain. As the organization grows and changes, the system can easily adjust permission policies and management mechanisms to adapt to new security requirements and usage scenarios. This scalability and maintainability provide strong support for the long-term development of the system.
[0037] Optionally, the code security protection logic includes: a page control logic for authenticating the page control authority of the user when editing the code upon receiving a code editing request initiated by the user through the browser.
[0038] Optionally, the page control logic includes at least one of the following: Copy and paste control logic for at least one of the page and the file; Page watermark control logic, used to configure watermarks for pages; For users with only browsing permissions, code editing is not allowed, only content browsing is allowed.
[0039] To this end, when the page control logic in the code security protection logic receives a code editing request initiated by the user through the browser, it authenticates the user's page control authority when editing the code, and includes copy and paste control logic, page watermark control logic, and browsing authority control logic, which has the following technical benefits: (1) Page control permission authentication ensures that only authorized users can access and edit the code, which greatly enhances the system's access control capabilities. Through fine-grained permission management, users' operations on the code editing page can be precisely controlled, effectively preventing unauthorized access and modification.
[0040] (2) Copy and paste control logic can restrict users from copying and pasting code, especially when sensitive or proprietary code is involved. This control can prevent code from being easily leaked to unauthorized personnel and protect intellectual property and trade secrets.
[0041] (3) Page watermark control logic By adding a watermark to the page, the source and ownership of the code can be clearly identified. This not only helps to trace the code when it is leaked or illegally used, but also enhances the traceability and auditability of the code.
[0042] (4) For users with only browsing permissions, code editing is not allowed, only content browsing is allowed. This setting not only meets the needs of different user roles, but also improves the security of the system. Browsing users will not accidentally modify the code, and will not introduce security risks due to misoperation.
[0043] (5) The page control logic provides fine-grained permission management functions, which can assign different page control permissions to users according to their roles, responsibilities and needs. This flexibility enables the system to adapt to various complex organizational structures and business processes, improving the system's availability and adaptability.
[0044] Optionally, if the type of the online IDE module is a front-end type, the page control logic is nested in the upper layer of the online IDE module to authenticate the page control authority of the user when editing the code through one layer; if the type of the online IDE module is a back-end type, the page control logic is nested in the upper layer of the mirror of the online IDE module to authenticate the page control authority of the user when editing the code through two layers.
[0045] To this end, the page control logic is nested at different levels according to the type of online IDE module (front-end or back-end), and the page control permissions of users when editing code are authenticated, which brings the following technical benefits: (1) By embedding the page control logic in the upper layer of the front-end online IDE module, the system can authenticate the page control permissions of users before they edit the code. This pre-authorization authentication mechanism effectively prevents unauthorized users from accessing or tampering with the code, and enhances the security of the code editing process.
[0046] For back-end online IDE modules, the page control logic is nested in the upper layer of the image and undergoes two layers of permission authentication, further improving security. This multi-level authentication mechanism makes it more difficult for malicious attackers to bypass the security line, thereby protecting the integrity and stability of the code editing environment.
[0047] (2) Different levels of nesting are performed according to the type of online IDE module, so that the system can flexibly configure access control policies according to different security requirements and usage scenarios. For back-end type IDE modules that require higher security, a multi-level authentication mechanism is adopted; for front-end type IDE modules, the appropriate authentication level can be selected according to the actual situation to balance security and ease of use.
[0048] (3) The nested design of page control logic makes the system easier to expand and maintain. As technology develops and organizational needs change, the system can easily adjust the location and authentication mechanism of page control logic to adapt to new security requirements and usage scenarios. This design improves the scalability and maintainability of the system and reduces long-term operation and maintenance costs.
[0049] (4) Although security is the primary consideration, the technical solution of this application also takes into account user experience. For front-end online IDE modules, by nesting page control logic in the upper layer and performing permission authentication, the security of the code editing process can be ensured without affecting the user experience. For back-end IDE modules, although a multi-level authentication mechanism is adopted, the system can reduce the impact on users by optimizing the authentication process and providing clear feedback information, thereby improving the user experience.
[0050] Optionally, the code security protection logic includes: suspicious module offline logic, which is used to perform suspicious monitoring on the online IDE module, so that when it is determined that the online IDE module has a security risk, the online IDE module is invisible to the user.
[0051] To this end, the suspicious module offline logic introduced as part of the code security protection logic monitors the online IDE modules for suspicion and makes the module invisible to users when it is determined that there is a security risk. This has the following technical benefits: (1) The suspicious module offline logic can monitor the operating status of online IDE modules in real time, and promptly detect and respond to potential security risks. Once suspicious behavior or security vulnerabilities are found in a module, the system can immediately take measures to take the module offline, thereby preventing the security risks from further expanding and protecting the security of user code and data.
[0052] (2) For users, the logic of taking suspicious modules offline can prevent them from coming into contact with online IDE modules that pose security risks, thereby reducing problems such as editing interruptions and data loss caused by module failures or security vulnerabilities. This helps improve user experience and enhance users’ trust and satisfaction with online IDE systems.
[0053] (3) The logic of taking suspicious modules offline helps maintain the stability of the online IDE system. By promptly taking modules with potential safety hazards offline, the system can avoid chain reactions caused by single module failures and maintain overall smooth and reliable operation.
[0054] (4) When an online IDE module is marked as suspicious and taken offline, the system administrator or developer can quickly intervene to conduct in-depth analysis and repair the module. This mechanism helps speed up the repair of security vulnerabilities and reduce the impact time of security vulnerabilities on the system.
[0055] (5) The logic of removing suspicious modules from the system is an important part of the code security protection logic. Together with other security mechanisms, it forms the security line of the online IDE system. By removing modules with potential security risks in a timely manner, the system can effectively reduce the risk of being attacked and improve overall security.
[0056] Optionally, probes are configured for the online IDE module to perform suspicious monitoring on instances running the online IDE module, and to determine whether partial or complete abnormalities occur in the functions of the online IDE module, thereby determining whether the online IDE module has safety hazards. The number and type of the probes match the functional division logic of the online IDE module.
[0057] Probes are configured for online IDE modules to monitor suspicious instances running the module, and to determine whether the functions of the online IDE modules are abnormal, and then determine whether there are security risks. At the same time, the number and type of probes are matched with the functional division logic of the online IDE modules, which has the following technical benefits: (1) The probe can monitor the operating status of the online IDE module in real time, including key indicators such as CPU usage, memory usage, and response time. Through preset thresholds and algorithms, the probe can promptly detect abnormal behaviors in the module operation, such as performance degradation, response delay, etc., and provide early warning information to system administrators so that timely measures can be taken to prevent the occurrence of safety hazards.
[0058] (2) The configuration of the probes matches the functional division logic of the online IDE modules, which means that each probe monitors a specific functional module. This precise positioning method helps to quickly identify the problem, avoids the tedious process of comprehensive troubleshooting of the entire system, and improves the efficiency of problem solving.
[0059] (3) Through the monitoring of the probe, the system administrator can promptly discover and fix potential problems in the online IDE module to prevent these problems from further deteriorating and causing system crashes or data loss. This helps improve the stability of the system and ensures that users can continue to use the online IDE for code editing and development work in a stable and stable manner.
[0060] (4) The probe can monitor the security status of online IDE modules, including whether there are security vulnerabilities such as malicious code injection and SQL injection. Once a security risk is found, the probe will immediately trigger an early warning mechanism and may automatically take measures, such as isolating the affected module, to prevent the security vulnerability from being exploited. This helps to enhance the security of the system and protect the security of user code and data.
[0061] (5) The probe can monitor the resource usage of online IDE modules, such as CPU and memory usage. By collecting this data, system administrators can understand the resource requirements of the modules and allocate and optimize resources accordingly. This helps improve resource utilization and avoid resource waste and overconsumption.
[0062] (6) The monitoring data of the probe can be connected to the automated operation and maintenance system to realize automatic fault discovery, diagnosis and repair. This reduces the need for manual intervention, improves operation and maintenance efficiency, and reduces operation and maintenance costs.
[0063] (7) Through the monitoring and early warning mechanism of the probe, system administrators can promptly discover and resolve problems in the online IDE module, ensuring that users can smoothly perform code editing and development work. This helps improve the user experience and enhance users' trust and satisfaction with the online IDE system.
[0064] Optionally, the number of probes is equal to the number of functional divisions in the online IDE module, and the type of probe is configured according to the abnormal configuration code table. For example, if the front-end type online IDE module has 7 functional modules, the number of probes configured for it is 7, and the probe type is configured based on the functions to be implemented by these 7 functional modules and the corresponding front-end abnormal configuration code table; while the back-end type IDE has 1 module, the number of probes configured for it is 1, and the probe type is configured according to the overall function of the back-end type IDE.
[0065] To this end, the number of probes is equal to the number of functional divisions in the online IDE module, and the type of probe is configured according to the abnormal configuration code table. This has the following technical benefits: (1) Since the number of probes is equal to the number of functional divisions, each functional module has a corresponding probe for monitoring. This ensures the accuracy of monitoring and can promptly detect and locate anomalies or safety hazards in specific functional modules.
[0066] (2) The probe type is configured according to the exception configuration code table, which means that each probe monitors a specific type of exception or problem. When a problem occurs, the system can quickly obtain detailed exception information through the corresponding probe, thereby efficiently diagnosing the problem.
[0067] (3) This design makes the system highly extensible. When a new functional module is added to the online IDE module, it is only necessary to increase the corresponding number and type of probes, without the need for large-scale modification or reconstruction of the entire monitoring system.
[0068] (4) Since the number of probes is equal to the number of functional divisions and the probe types are precisely configured, unnecessary monitoring and data processing are avoided, thereby reducing system resource consumption. This is of great significance for improving system performance and response speed.
[0069] (5) Through accurate monitoring and efficient problem diagnosis, the system can promptly detect and handle potential security risks, thereby improving overall security. At the same time, since the probe type is configured according to the abnormal configuration code table, this can also prevent malicious users from bypassing monitoring by constructing specific types of input.
[0070] Optionally, when it is determined that the online IDE module has a potential safety hazard, the code security protection logic generates a module offline instruction to offline the online IDE module with the potential safety hazard and thereby make the online IDE module invisible to the user.
[0071] Therefore, when it is determined that an online IDE module has a potential safety hazard, the code security protection logic generates a module offline instruction to offline the online IDE module with the potential safety hazard, thereby making the module invisible to the user, which has the following technical benefits: (1) Once a security risk is found in an online IDE module, the system can immediately generate an offline instruction to remove the module from service and hide it from users. This immediate isolation mechanism effectively prevents the further spread of security risks and protects user data and system security.
[0072] (2) Making online IDE modules with potential safety hazards invisible to users can prevent users from misoperating the modules, thereby reducing security risks caused by improper user behavior. This helps maintain the overall security and stability of the system.
[0073] (3) By automatically generating offline instructions and executing them quickly, the system can respond quickly to security incidents and reduce the impact of security risks on business operations. This rapid response mechanism is crucial to maintaining the reputation and user trust of the online IDE system.
[0074] (4) The automated offline processing process simplifies security management and reduces the need for manual intervention. System administrators can focus more on other security matters, improving the efficiency and accuracy of security management.
[0075] Optionally, based on the above technical description, in an online IDE environment based on container deployment, in order to effectively deal with the possible risk of code asset leakage, a protection mechanism for a fast offline module is adopted. This mechanism is significantly different from the monitoring offline method of a container cluster. Specifically, the monitoring offline of a container cluster is usually initiated at the cluster level, and it relies on the abnormal detection of the cluster monitoring system to trigger the offline operation. However, in the present application, in the online IDE system, the protection trigger of the fast offline module is implemented based on probes. These probes are carefully configured and closely correspond to the functional division of the online IDE modules. They can monitor the operating status of the modules in real time and detect abnormal behavior. Once the probes detect an abnormal situation, such as a potential risk of code leakage, they will immediately trigger the protection mechanism and actively disconnect from the abnormal module, thereby quickly curbing further leakage of code assets.
[0076] If the abnormal situation persists, the system will further offline the abnormal online IDE instance based on the abnormal information provided by the probe. In this process, the abnormal detection of the probe becomes the key point to trigger the rapid offline operation, ensuring that the system can respond to potential security threats in the first time and effectively protect the security of the user's code assets.
[0077] Figure 2 The present application also provides a schematic diagram of the structure of a code protection device. Figure 2 As shown, it includes: the code protection device is configured with code security protection logic, the code protection device is deployed between the browser and the online IDE module communication, and is located between the trusted component and the online IDE module communication, so that at least one of the following duplex interactions is controlled by the code security protection logic configured on the code protection device: Duplex interaction between the browser and the online IDE module; Duplex interaction between the browser and components associated with the online IDE; Duplex interaction between the trusted component and the online IDE module; Duplex interaction between the trusted component and the online IDE associated component; The duplex interaction is based on a code editing request and a code editing function calling request, and both the code editing request and the code editing function calling request are generated through the browser.
[0078] The embodiment of the present application further provides a computer storage medium, characterized in that a computer executable program is stored on the computer storage medium, and when the computer executable program is run, a set code security protection logic is implemented to control at least one of the following duplex interactions to perform online code editing: Duplex interaction between browser and online IDE modules; Duplex interaction between the browser and online IDE-related components; Duplex interaction between the trusted component and the online IDE module; Duplex interaction between the trusted component and the online IDE associated component; The duplex interaction is based on a code editing request and a code editing function calling request, and both the code editing request and the code editing function calling request are generated through the browser.
[0079] The exemplary description of the above code protection device and computer storage medium can be found in the above Figure 1 The records are not repeated here.
[0080] It should be noted that the same or similar parts between the various embodiments in this specification can be referred to each other, and each embodiment focuses on the differences from other embodiments. In particular, for the device and system embodiments, since they are basically similar to the method embodiments, the description is relatively simple, and the relevant parts can be referred to the partial description of the method embodiments. The device and system embodiments described above are merely schematic, wherein the modules described as separate components may or may not be physically separated, and the components indicated as modules may or may not be physical modules, that is, they may be located in one place, or may be distributed on multiple network modules. It is suspected that some or all of the modules are selected according to actual needs to achieve the purpose of the scheme of this embodiment. It is suspected that ordinary technicians in this field can understand and implement it without paying creative labor.
[0081] The above is only a specific implementation of the present application, but the protection scope of the present application is not limited thereto. Any changes or substitutions that can be easily thought of by a person skilled in the art within the technical scope disclosed in the present application should be included in the protection scope of the present application. Therefore, the protection scope of the present application should be based on the protection scope of the claims.
Claims
1. An online code editing system, characterized in that: include: A code protection device, a browser, a trusted component, an online IDE module, and an online IDE associated component. The code protection device is configured with code security protection logic. The browser and the trusted component are both connected to the code protection device in communication. The code protection device is connected to the online IDE module in communication, so that the duplex interaction between the browser and at least one of the online IDE module and the online IDE associated component, the duplex interaction between the trusted component and the online IDE module, and the duplex interaction between the trusted component and at least one of the online IDE module and the online IDE associated component are all controlled by the code security protection logic configured on the code protection device. The duplex interaction is based on a code editing request and a code editing function call request. The code editing request and the code editing function call request are both generated by the browser.
2. An online code editing system according to claim 1, characterized in that: The online IDE associated components include a first component, a second component, and a third component. The first component at least includes a code repository for code storage and management. The second component is configured to allow users to directly access it when performing online code editing. The third component is configured to allow users to access it after approval when performing online code editing.
3. An online code editing system according to claim 2, characterized in that: The code security protection logic includes: an authority control logic, which is used to authenticate the authority of the user when receiving a code editing request initiated by the user through the browser.
4. An online code editing system according to claim 2, characterized in that: The permission control logic includes permission authentication logic to authenticate at least one of the following permissions: The right to call the online IDE module; access rights of the first component; direct access to the second component; Approved access rights to the third component.
5. An online code editing system according to claim 1, characterized in that: The permission control logic also includes: permission management logic to manage permissions in at least one of the following ways and perform permission authentication accordingly: For the first component, permissions can be inherited based on the hierarchical relationship between the users and user groups; For the second component, no permission determination is performed when accessing, and / or, no permission determination is performed when accessing and permissions are inherited based on the hierarchical relationship between the users and user groups, and / or, permission determination is performed when accessing; For the third component, permission approval is automatically initiated when access is made.
6. An online code editing system according to any one of claims 1 to 5, characterized in that: The code security protection logic includes: a page control logic, which is used to authenticate the page control authority of the user when editing the code when receiving a code editing request initiated by the user through the browser.
7. An online code editing system according to claim 6, characterized in that: The page control logic includes at least one of the following: Copy and paste control logic for at least one of the page and the file; Page watermark control logic, used to configure watermarks for pages; For users with only browsing permissions, code editing is not allowed, only content browsing is allowed.
8. An online code editing system according to claim 6, characterized in that: If the type of the online IDE module is a front-end type, the page control logic is nested in the upper layer of the online IDE module to authenticate the page control authority of the user when editing the code through a layer; If the type of the online IDE module is a backend type, the page control logic is nested in the upper layer of the image of the online IDE module, so as to authenticate the page control authority of the user when editing the code through the two layers.
9. A code protection device, characterized in that: include: The code protection device is configured with code security protection logic, and the code protection device is deployed between the browser and the online IDE module communication, and is located between the trusted component and the online IDE module communication, so that at least one of the following duplex interactions is controlled by the code security protection logic configured on the code protection device: Duplex interaction between the browser and the online IDE module; Duplex interaction between the browser and components associated with the online IDE; Duplex interaction between the trusted component and the online IDE module; Duplex interaction between the trusted component and the online IDE associated component; The duplex interaction is based on a code editing request and a code editing function calling request, and both the code editing request and the code editing function calling request are generated through the browser.
10. A computer storage medium, characterized in that: The computer storage medium stores a computer executable program, which, when executed, implements a set code security protection logic to control at least one of the following duplex interactions to perform online code editing: Duplex interaction between browser and online IDE modules; Duplex interaction between the browser and online IDE-related components; Duplex interaction between the trusted component and the online IDE module; Duplex interaction between the trusted component and the online IDE associated component; The duplex interaction is based on a code editing request and a code editing function calling request, and both the code editing request and the code editing function calling request are generated through the browser.
Citation Information
Patent Citations
Online programming system, online programming method and related products
CN113094613A
Code editing method, device and system, computer equipment and storage medium
CN115220713A
Behavior management system and method for trusted space, computer equipment and storage medium
CN117852021A