WO2018121442A1 - 软件信息的处理方法和装置及存储介质、电子装置 - Google Patents

软件信息的处理方法和装置及存储介质、电子装置 Download PDF

Info

Publication number
WO2018121442A1
WO2018121442A1 PCT/CN2017/118035 CN2017118035W WO2018121442A1 WO 2018121442 A1 WO2018121442 A1 WO 2018121442A1 CN 2017118035 W CN2017118035 W CN 2017118035W WO 2018121442 A1 WO2018121442 A1 WO 2018121442A1
Authority
WO
WIPO (PCT)
Prior art keywords
directory
target
software
feature
current
Prior art date
Application number
PCT/CN2017/118035
Other languages
English (en)
French (fr)
Inventor
饶帅
Original Assignee
腾讯科技(深圳)有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 腾讯科技(深圳)有限公司 filed Critical 腾讯科技(深圳)有限公司
Publication of WO2018121442A1 publication Critical patent/WO2018121442A1/zh

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/10File systems; File servers
    • G06F16/14Details of searching files based on file metadata
    • G06F16/148File search processing
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/10File systems; File servers
    • G06F16/14Details of searching files based on file metadata
    • G06F16/156Query results presentation
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/10File systems; File servers
    • G06F16/16File or folder operations, e.g. details of user interfaces specifically adapted to file systems
    • G06F16/162Delete operations

Definitions

  • the present application relates to the field of computers, and in particular, to a method and device for processing software information, and a storage medium and an electronic device.
  • PC Personal Computer
  • the push-loading software usually protects itself from being easily discovered and uninstalled by the user through protective behavior (for example, the complexity of the uninstaller interaction design), when the user finds that the PC machine behaves abnormally, it is often difficult to find the corresponding software source, even if found, It is difficult to bypass the uninstallation barrier of the software settings and thoroughly clean the software.
  • some security products provide software uninstallation functions and plug-in cleanup functions.
  • software uninstallation or plug-in cleanup all kinds of software derivative information (each piece of feature information including files, registry, process, etc.) configured by each feature in the feature library are used for file features, registry features, processes.
  • the feature and other category features are sequentially matched to detect software derivatives in the user's machine. Because the items to be configured in the configuration list are very cumbersome, once the configuration list is incomplete or there is no configuration list for the new derivative, the related derivative will be missing from the user machine and the entire software cannot be completely cleaned up.
  • the embodiment of the present application provides a method and device for processing software information, and a storage medium and an electronic device, so as to at least solve the technical problem that the software information of the target software is processed.
  • a method for processing software information including: acquiring a to-be-detected directory in an operating system installed on a terminal; searching and pre-acquiring a feature library in the to-be-detected directory At least one feature matching target directory; in the case of finding the target directory, detecting software information of the target software corresponding to the target directory in the operating system; displaying the detected on the terminal Software information of the target software.
  • a software information processing apparatus including: an obtaining unit configured to acquire a to-be-detected directory in an operating system installed on the terminal; and a searching unit configured to be in the Detecting, in the to-be-detected directory, a target directory that matches at least one feature in the pre-acquired feature database; and detecting, configured to detect, in the case that the target directory is found, the target operating directory in the operating system Corresponding software information of the target software; a display unit configured to display the detected software information of the target software on the terminal.
  • a storage medium which may store an execution instruction set to execute a processing method of software information in the above embodiment.
  • an electronic device comprising a memory, a processor, and a computer program stored on the memory and executable on the processor, wherein the processor executes the software by using a computer program Information processing method.
  • the method for matching the target directory in the directory to be detected in the feature library is detected, and the target directory matching the at least one feature in the feature library acquired in advance is detected in the to-be-detected directory, and the target directory is detected.
  • FIG. 1 is a schematic diagram of a hardware environment of a method for processing software information according to an embodiment of the present application
  • FIG. 2 is a flowchart of a method for processing optional software information according to an embodiment of the present application
  • FIG. 3 is a schematic diagram of an optional hard disk partition root directory according to an embodiment of the present application.
  • FIG. 4 is a schematic diagram of a single feature in an optional feature library in accordance with an embodiment of the present application.
  • FIG. 5 is a schematic diagram of an optional push-load software feature library according to an embodiment of the present application.
  • FIG. 6 is a flowchart of an optional user using a security product killing function according to an embodiment of the present application.
  • FIG. 7 is a schematic diagram of an optional security product prompting interface when an optional user uses a killing function according to an embodiment of the present application
  • FIG. 8 is a flow chart of an optional security product silent scan according to an embodiment of the present application.
  • FIG. 9 is a schematic diagram of a prompt page when an optional product silent scan is completed according to an embodiment of the present application.
  • FIG. 10 is a schematic diagram of detecting an amount of machine and a cleaning effect of the push-loading software when an optional detection function is used according to an embodiment of the present application;
  • FIG. 11 is a schematic diagram of an optional security product actively detecting and prompting detection of the amount of machine and cleaning effect of the push-loading software according to an embodiment of the present application;
  • FIG. 12 is a schematic flow chart of an optional security product framework according to an embodiment of the present application.
  • FIG. 13 is a schematic diagram of an optional device for detecting software information according to an embodiment of the present application.
  • FIG. 14 is a structural block diagram of a terminal according to an embodiment of the present application.
  • Hard disk partition refers to each partition generated after partitioning the hard disk, for example, C disk, D disk, E disk, etc.
  • the root directory of the hard disk partition refers to the directory under each hard disk partition.
  • C: ⁇ AAA is the root directory of the C drive
  • the first-level subdirectory refers to the directory of each folder or file in the current directory, for example, C: ⁇ AAA ⁇ BBB, which is the first-level subdirectory of C: ⁇ AAA;
  • the directory name of the directory refers to the folder name of the folder corresponding to the directory or the file name of the file.
  • the directory name of the directory C: ⁇ AAA ⁇ BBB is BBB).
  • Software derivative refers to the location shortcuts released in the PC machine operating system after the software installation is completed (1) desktop, start menu, quick launch bar, etc.; (2) boot self-starting items, software service items, software drivers, Software uninstallation information, plug-in items; (3) software sub-files in the installation directory, process information, etc.
  • an embodiment of a method for processing software information is provided.
  • the foregoing method for processing software information may be applied to a hardware environment formed by the server 102 and the terminal 104 as shown in FIG. 1.
  • the server 102 is connected to the terminal 104 through a network.
  • the network includes but is not limited to a wide area network, a metropolitan area network, or a local area network.
  • the terminal 104 is not limited to a PC, a mobile phone, a tablet, or the like.
  • the processing method of the software information in the embodiment of the present application may be performed by the server 102, may be performed by the terminal 104, or may be performed by the server 102 and the terminal 104 in common.
  • the method for processing the software information of the terminal 104 in the embodiment of the present application may also be performed by a client installed thereon.
  • the server 102 and the terminal 104 are jointly executed, the server 102 issues a feature database to the terminal 104, and the terminal 104 processes the software information of the target software according to the feature library sent by the server.
  • FIG. 2 is a flowchart of a method for processing optional software information according to an embodiment of the present application. As shown in FIG. 2, the method may include the following steps:
  • Step S202 Acquire a to-be-detected directory in an operating system installed on the terminal.
  • the preset condition here may be a preset time condition or a preset event condition.
  • the preset time condition may be a specific time or time period (for example, XXXX year XX XX day 21:00), or may be a cycle time or time period (for example, 21:00 every day, 21:00 every day) ).
  • the preset event condition may be that the occupancy rate of the CPU is lower than a predetermined value (for example, 30%), and the triggering condition of the operation is specifically acquired, and may be set as needed, and is not specifically limited herein.
  • the directory to be detected when the directory to be detected in the operating system installed on the terminal is obtained, the directory to be detected may be obtained in multiple manners. For example, the root directory collection and the sub-directory collections in each hard disk partition of the operating system may be obtained, and all the acquired directory collections (the root directory collection and the sub-directory collections at each level) are taken as the to-be-detected directory.
  • the root directory of each hard disk partition of the operating system may be obtained; the root directory generated by the operating system installation (for example, C: ⁇ WINDOWS) is filtered out from the root directory to obtain the target root directory. Collection; filter the first-level subdirectory generated by the operating system installation from the default program installation directory of the operating system and all the first-level subdirectories under the default program data directory to obtain the target subdirectory collection; the target root directory collection and target A subdirectory collection is used as the directory to be detected.
  • the directory to be detected is a directory for performing software information detection.
  • the root directory generated by the operating system installation can include the following four: C: ⁇ Windows, C: ⁇ Windows ⁇ Program Files, C: ⁇ Windows ⁇ Program Files (86) and C: ⁇ Windows ⁇ users, the combination of the root directories other than the above four root directories, is the target root directory collection;
  • the default program installation directory of the operating system includes: C: ⁇ Windows ⁇ Program Files and C: ⁇ Windows ⁇ Program Files(86),
  • the default program data directory includes: C: ⁇ Windows ⁇ users, all the first-level subdirectories under these three root directories filter out the first-level subdirectories generated when the operating system is installed. , get the target subdirectory collection.
  • enumeration can be used to enumerate all subdirectory information in a common installation location in the system as the to-be-detected directory:
  • Step S204 Search for a target directory that matches at least one feature in the feature library acquired in advance in the to-be-detected directory.
  • step S204 a target directory matching at least one feature in the pre-acquired feature library is searched in the to-be-detected directory, wherein the feature library includes at least one feature.
  • the features included in the feature library are used to match the target directory, and each directory in the detection directory can be matched by matching one by one.
  • the directories in the directory to be detected may be selected one by one, and then compared with the features included in the feature library to determine whether the two match.
  • the current directory in the directory to be detected is matched with the software directory feature in the current feature in the feature library. If the current directory matches the software catalog feature successfully, the current directory is taken as a target directory.
  • the software directory feature is used to indicate the first regular expression or the directory name of the pre-set software installation directory (for example, the software installation directory is C: ⁇ program files ⁇ software install, the software installation directory is named software install).
  • the software catalog feature is used to represent the first regular expression, it indicates that the software catalog feature can include a regular expression class wildcard.
  • the software catalog feature is "eprjacy + regular expression class wildcard", and the regular expression class wildcard indicates that any of the characters in the directory can be here. If the directory name of the current directory is "eprjacya", the two can match successfully.
  • the preset software installation directory may be preset by the user before performing software information detection.
  • the current directory that is successfully matched may be verified by matching the file names in the current directory.
  • the file names in the current directory are matched by string matching or regular expression matching. For example, if the directory name of the current directory satisfies the first regular expression, or if the directory name of the current directory is the same as the string of the directory name of the software installation directory, it is determined whether the current feature indicates that the current feature indicates Regular expression matching for file names in the current directory. Perform different operations based on different judgment results:
  • the current feature indicates that a regular expression matching needs to be performed on the file name in the current directory
  • the second regular expression indicated by the feature if it is determined that the file name in the current directory has the first target file name, it is determined that the current directory matches the software directory feature successfully;
  • the file name in the current directory has a second target file name, wherein the second target file name has a string and a file name.
  • the character string of the preset file name of the feature representation is the same; if it is determined that the file name of the current directory has the second target file name, it is determined that the current directory matches the software directory feature successfully.
  • All the acquired directories to be inspected (the directory to be detected) in step S202 are matched with the latest feature database.
  • Figure 4 contains a software feature, in which the software features of the "badware software A" consist of five components:
  • the software name -- hits the directory feature and is displayed on the security product interface.
  • the software directory feature--the software installation directory name matches the to-be-detected directory recorded in step S202. You can include regular expression class wildcards to extend feature coverage.
  • the directory needs to be wild--when this record is true, it means that the "software directory feature" contains the regular expression class wildcard. This tag is set up separately to prioritize this tag before matching the directory feature, if no regular class match is needed. A perfect matching algorithm is used to improve feature matching efficiency.
  • the file needs to be wild--when this record is true, it means that the "file name feature" contains the regular expression class wildcard.
  • the mark is set separately to prioritize the mark before matching the file feature, if no regular class match is needed. A perfect matching algorithm is used to improve feature matching efficiency. The default is false when not filled.
  • the feature library of the push-loading software is formed, and the shape can be as shown in FIG. 5.
  • the directory name of the directory to be detected is compared with the "software directory feature" string, and if the string does not satisfy the equality condition, the directory feature is considered to be missed. At this point, continue to match the next software feature. If you hit the directory feature, go to the next step.
  • the general After hitting the directory feature, enumerate all the sub-files in the directory and record them (the enumeration operation is time-consuming, and only enumerate the directory to save the number of enumerations), the general first determines whether the file needs to be wildcarded. Then, it is judged whether the "file name feature in the directory" exists in the list of subfiles enumerated in this step. If it exists, it is considered that the software features of this article are successfully matched, and the promotion software exists in the system.
  • the target directory matching the at least one feature in the pre-acquired feature library can be searched in the to-be-detected directory.
  • Step S206 in the case that the target directory is found, the software information of the target software corresponding to the target directory in the operating system is detected.
  • step S206 in the case where the target directory is found, the software information of the target software corresponding to the target directory in the operating system is detected, wherein one or more of the found target directories may be present.
  • the target software corresponding to the target directory may be a bad software, and the bad software may be silently installed in the user terminal.
  • the software information of the target software corresponding to the target directory may include software derivatives of the target software.
  • the software information corresponding to the target directory may be searched for in the software derivative information scanned in advance from the operating system, and the found software information is used as the software information.
  • Software information for the target software may include a target directory, or the directory pointed to by the software information (for example, a shortcut) corresponding to the target directory includes a target directory, and if the software derivative information is multiple, It can have both software information containing the target directory and a directory pointing to the software information corresponding to the target directory of the target directory.
  • the software derivative information may include at least one of the following: a shortcut, a startup item information, a service item, an uninstall registration information, and process information; and correspondingly, the software information corresponding to the target directory may include At least one of the following: target shortcut, target launch item information, target service item, target uninstall registration information, target process information.
  • the shortcut obtained by scanning from the operating system in advance, the startup item information previously scanned from the operating system, the service item scanned in advance from the operating system, and the pre-operational operation may be sequentially operated.
  • the uninstall registration information scanned in the system and the process information scanned from the operating system in advance are searched for software information corresponding to the target directory.
  • Target process information in the process information scanned from the operating system in advance, wherein the target process information includes a target directory.
  • the order of the above-mentioned search and the type of the software-derived information to be found can be set as needed, which is not specifically limited in this embodiment.
  • the operating system when the operating system is in an idle state, the operating system may be scanned to obtain software derivative information, and the obtained software derivative information is used to search for software information corresponding to the target directory. For example, it may be determined whether the operating system is in an idle state (for example, when the CPU usage is less than or equal to a preset CPU occupation threshold, determining that the operating system is in an idle state); when determining that the operating system is in an idle state, scanning the operating system. Get software derivative information.
  • the following describes how to detect the software information of the target software corresponding to the target directory in the operating system in combination with a specific example.
  • step 2) Similar to step 1), comparing the regular startup item information, if the recorded startup item points to the information containing the software directory feature, the startup item is a startup item derivative of the target software, and the startup item is recorded.
  • step 1) Similar to step 1), continue to compare the service, uninstall the registration information, process and other information, obtain the service item including the software directory feature, uninstall the registration information and the process, and then obtain the service item, the uninstall registration information and the process as the target A derivative of the software's startup items, records the resulting service items, uninstall registration information, and processes.
  • the address of the registry can be as follows: HKEY_LOCAL_MACHINE ⁇ SOFTWARE ⁇ Microsoft ⁇ Windows ⁇ CurrentVersio n ⁇ run). Records the startup registry location and its pointing information in a one-to-one correspondence.
  • the registry directory can be:
  • the registry's directory can be:
  • HKEY_LOCAL_MACHINE SOFTWARE ⁇ Microsoft ⁇ Windows ⁇ CurrentV ersion ⁇ Uninsta.
  • Step S208 displaying the detected software information of the target software on the terminal.
  • the detected software information of the target software is displayed on the terminal, wherein the displayed software information may include a software name.
  • the scan result may be displayed to the user on the interface of the security product, and after the user selects the process, all the software derivatives are processed in sequence, which may include:
  • the directory in the directory to be detected, the target directory, the root directory, the first-level subdirectory, and the like may also be expressed as the address, path, and the like of the folder or file, and those skilled in the art should understand that The above terms are only different in the way they are expressed, and the specific content is consistent.
  • steps S202 to S208 detecting the target directory of the target software corresponding to the found target directory in the operating system by searching the target directory that matches the at least one feature in the pre-acquired feature database in the to-be-detected directory. And displaying the detected software information of the target software on the terminal, which can solve the technical problem that the omission of the software information of the target software is processed, thereby achieving the technical effect of improving the accuracy of the software information detection.
  • the obtaining the to-be-detected directory in the operating system installed on the terminal includes:
  • the target root directory set and the target sub-directory set are used as the to-be-detected directory.
  • the directory to be detected is obtained. While comprehensively analyzing the directories of each hard disk partition of the operating system, the analysis scope is narrowed, and the reliability and efficiency of the directory to be detected are improved.
  • searching, in the to-be-detected directory, a target directory that matches at least one feature in the pre-acquired feature library includes:
  • Determining the target directory by matching the current directory in the directory to be detected with the software directory features in the current feature in the feature library, and providing two different software directory features for representing the first regular expression or preset
  • the directory name of the software installation directory is more convenient and flexible than the related technology in detecting the specific single feature, and the detection efficiency is improved.
  • matching the current directory in the to-be-detected directory with the software directory feature in the current feature in the feature library includes:
  • matching the current directory in the directory to be detected with the software directory feature in the current feature in the feature library includes:
  • the directory name of the current directory is compared with the directory name of the software installation directory indicated by the software directory feature; the directory name and the software installation directory in the current directory. If the directory name of the two directories is the same, it is determined that the current directory matches the software directory feature successfully.
  • determining that the current directory and the software directory feature match successfully comprises:
  • determining that the current directory and the software directory feature match successfully comprises:
  • the matching result is verified by the file name in the current directory, which avoids the occurrence of the matching error problem and improves the correct matching rate between the current directory and the software directory feature.
  • detecting software information of the target software corresponding to the target directory in the operating system includes:
  • the found software information is used as the software information of the target software.
  • the software derivative information scanned from the operating system is searched to obtain the software information of the target software. Since the software derivative information is searched according to the target directory rather than the specific feature, the efficiency of acquiring the software information of the target software can be improved. .
  • searching for software information corresponding to the target directory in the software derivative information scanned in advance from the operating system includes at least one of the following:
  • S13 Find a target service item in a service item scanned in advance from the operating system, where the directory pointed to by the target service item includes a target directory;
  • the software derivative information may include: a shortcut, a startup item information, a service item, an uninstall registration information, and process information; and the software information corresponding to the target directory may include: a target shortcut, a target startup Item information, target service item, target uninstall registration information, target process information.
  • the shortcut, the startup item information, the service item, the uninstall registration information, and the process information are scanned respectively, and the software information corresponding to the target directory is obtained, and the software derivative can be comprehensively detected, and the detection feature is efficient and the coverage is wide.
  • the method before the software information corresponding to the target directory is searched for in the software derivative information scanned in the operating system, the method further includes:
  • the operating system When the operating system is in an idle state, the operating system is scanned to obtain software derivative information, which can utilize the resources of the operating system reasonably, thereby avoiding problems such as the card machine caused by scanning the operating system, thereby improving the user experience.
  • the method further includes:
  • the software information of the target software is deleted in the operating system, and the software information of the target software can be cleared according to the instruction, and the software information of the target software is used to occupy the system resources, thereby ensuring a high clear success rate.
  • the method according to the above embodiment can be implemented by means of software plus a necessary general hardware platform, and of course, by hardware, but in many cases, the former is A better implementation.
  • the technical solution of the present application which is essential or contributes to the related art, may be embodied in the form of a software product stored in a storage medium (such as ROM/RAM, disk, CD-ROM).
  • the instructions include a number of instructions for causing a terminal device (which may be a cell phone, a computer, a server, or a network device, etc.) to perform the methods described in various embodiments of the present application.
  • an optional specific application of an optional processing method for implementing the above software information is provided.
  • the application environment of the embodiment of the present application may be, but is not limited to, the reference to the application environment in the foregoing embodiments.
  • the embodiment of the present application there is a omission in the related art to process the software information of the target software, and the function of quickly detecting and cleaning the push-install software is added in the security product killing function. Since the new push software is constantly appearing in the Internet environment, the embodiment of the present application not only considers the manner of detecting and cleaning the push software, but also considers the continuous operation cost of the related technical solution. While providing the user with the push-to-install software clean-up function, comprehensive consideration of feature configuration cost, network bandwidth, function occupies PC system resources and other factors, without slowing down the product killing function experience, can quickly respond to newly emerging push-load software .
  • the security product provided in the embodiment of the present application can comprehensively detect and clean the push software derivative when applying the product function, and the detection feature is efficient and wide coverage, the cleaning effect is thorough, the high cleaning success rate can be ensured, and the PC is effectively reduced.
  • Machine security risks improve the ability of security products to cover and solve security problems, and at the same time actively detect whether there is push software installed in the system idle time, and if it is found to prompt users to optimize the user experience.
  • a security product for implementing the above processing method of software information.
  • the security product is not limited by the operating system version, product version, etc., and can not only display the matching result of the feature library and the local plug-in when the user triggers the killing function.
  • the original technical solution is low in efficiency and consumes large resources, it is also suitable for the product to actively push the scan result to the user after the silent scan, and the user can actively prompt the security risk without the user participation.
  • FIG. 6 is a flowchart of an optional user using a security product killing function according to an embodiment of the present application. As shown in FIG. 6, the process includes the following steps:
  • Step S602 receiving an indication of using a killing class function.
  • This indication can be triggered by the user by clicking the corresponding button on the security product interface.
  • step S604 the scanning module is loaded.
  • Step S606 reading the promotion software library.
  • Each feature information in the promotion software library contains only file derivatives.
  • Step S608 detecting a directory feature.
  • step S610 it is determined whether all software features are detected. If yes, step S612 is performed. Otherwise, step S606 is performed.
  • Step S612 displaying the result on the killing interface of the security product.
  • FIG. 8 is a flowchart of an optional security product silent scanning according to an embodiment of the present application. As shown in FIG. 8 , the process includes the following steps:
  • Step S802 the security product actively triggers the detection function when the machine is idle.
  • the machine here is the machine to which the security product is installed or connected to the security product via a cloud connection.
  • step S804 the scanning module is loaded.
  • Step S806 reading the promotion software library.
  • Each feature information in the promotion software library contains only file derivatives.
  • Step S808 detecting a directory feature.
  • step S810 it is determined whether all software features are detected or not. If yes, step S812 is performed; otherwise, step S806 is performed.
  • step S812 the pop-up window displays the result.
  • the detection result is displayed to the user by popping up the window.
  • the prompt page when the product silent scan is completed can be as shown in Figure 9.
  • the amount of machine and the cleaning effect of the push-out software detected when the above-mentioned user actively uses the detection function are as shown in FIG.
  • the daily detection of the risk machine quantity (user active trigger detection) is about 10w, and the processing success rate is stable at 97.6% or above.
  • the unsuccessful processing is mainly due to the existence of other promotion sources repeatedly releasing the push software on the machine.
  • the amount of machine and the cleaning effect of actively detecting and prompting the detection of the push-loading software are as shown in FIG.
  • the amount of machines with push-loaded software is more than 50w on average, which is five times that of the user triggering the detection scenario (the data shown in Figure 10).
  • the application displayed in the new scenario significantly improves the security products. Push the software to detect the effect.
  • the processing rate is about 45% on average, and the user processing rate is exceeded when most of the security products pop-up window (the average processing rate in other categories of security products is about 10%, absolutely Most users directly click "close” to show that users have higher acceptance of this function.
  • the processing success rate is as high as the user's active triggering scenario, which ensures a better user experience.
  • the security products provided in this embodiment can be developed using the fast and flexible scripting language lua and the conventional C++ language.
  • the C++ language is responsible for developing the underlying interface code and scheduling code
  • the lua language is responsible for developing the scanning logic and cleaning up the logic code.
  • the scheduling module is configured to detect whether the system environment and the current software signature database are up-to-date when the user actively triggers the killing function or automatically triggers the product itself, and schedules the data update module and the detection module.
  • the data update module is responsible for pulling the latest database when the server is triggered, ensuring that the function of the function is implemented to deliver the latest library on demand in real time.
  • the detection module and the clearing module are mainly responsible for comparing the native installation software through the software signature database, and cleaning the software and all its derivatives after hitting.
  • the above security products are mainly embodied in the data on-demand real-time update mechanism, detection module and removal module.
  • the detection module logic is used to execute the various method steps in Embodiment 1 above.
  • the thoroughness of the cleaning software effect is ensured.
  • the technology relied on the operators to manually configure various software derivatives to be deleted, which was prone to configuration omissions or software updates, resulting in poor cleaning results.
  • the embodiments of the present application can completely discover various derivatives of software from a technical point of view without relying on cumbersome manual configuration. While greatly reducing the manual configuration work cost of the operator, it can ensure the thoroughness of the software function and give the user the best product experience.
  • the response time can be directly raised to 1 minute level (extract feature + release) from the push software installation, and even the second level response in emergency situations, which improves the timeliness of the push software response.
  • the method for processing software information provided in the embodiment of the present application reduces the time complexity of the original matching technology by reducing the matching feature, and reduces the user PC resource occupied by the user in the case of function triggering (cpu usage rate) , memory, etc., so you can add a silent scan in the security product and prompt the user to perform the corresponding processing function (using the relevant technology for silent scanning users will find that the system is obviously slow), greatly expanding the coverage of the cleaning software functional scene. There is no need to wait until the user uses the security product to detect it, thus ensuring that the push software is found in the user's machine earlier than other security products.
  • FIG. 13 is a schematic diagram of an apparatus for detecting software information according to an embodiment of the present application. As shown in FIG. 13, the apparatus may include:
  • the obtaining unit 1302 is configured to obtain a to-be-detected directory in an operating system installed on the terminal;
  • the searching unit 1304 is configured to search, in the to-be-detected directory, a target directory that matches at least one feature in the pre-acquired feature library;
  • the detecting unit 1306 is configured to detect software information of the target software corresponding to the target directory in the operating system when the target directory is found;
  • the display unit 1308 is configured to display the detected software information of the target software on the terminal.
  • the obtaining unit 1302 in this embodiment may be configured to perform step S202 in the first embodiment of the present application.
  • the searching unit 1304 in this embodiment may be configured to perform step S204 in Embodiment 1 of the present application.
  • the detecting unit 1306 in the embodiment may be configured to perform step S206 in Embodiment 1 of the present application, and the display unit 1308 in this embodiment may be configured to perform step S208 in Embodiment 1 of the present application.
  • modules are the same as the examples and application scenarios implemented by the corresponding steps, but are not limited to the contents disclosed in the above embodiment 1. It should be noted that the foregoing module may be implemented in a hardware environment as shown in FIG. 1 as part of the device, and may be implemented by software or by hardware.
  • the preset condition here may be a preset time condition or a preset event condition.
  • the preset time condition may be a specific time or time period (for example, XXXX year XX XX day 21:00), or may be a cycle time or time period (for example, 21:00 every day, 21:00 every day) ).
  • the preset event condition may be that the occupancy rate of the CPU is lower than a predetermined value (for example, 30%), and the triggering condition of the operation is specifically acquired, and may be set as needed, and is not specifically limited herein.
  • the directory to be detected when the directory to be detected in the operating system installed on the terminal is obtained, the directory to be detected may be obtained in multiple manners. For example, the root directory collection and the sub-directory collections in each hard disk partition of the operating system may be obtained, and all the acquired directory collections (the root directory collection and the sub-directory collections at each level) are taken as the to-be-detected directory.
  • the root directory of each hard disk partition of the operating system may be obtained; the root directory generated by the operating system installation (for example, C: ⁇ WINDOWS) is filtered out from the root directory to obtain the target root directory. Collection; filter the first-level subdirectory generated by the operating system installation from the default program installation directory of the operating system and all the first-level subdirectories under the default program data directory to obtain the target subdirectory collection; the target root directory collection and target A subdirectory collection is used as the directory to be detected.
  • the directory to be detected is a directory for performing software information detection.
  • enumeration can be used to enumerate all subdirectory information in a common installation location in the system as the to-be-detected directory:
  • the feature library includes at least one feature.
  • the features included in the feature library are used to match the target directory, and each directory in the detection directory can be matched by matching one by one.
  • the directories in the directory to be detected may be selected one by one, and then compared with the features included in the feature library to determine whether the two match.
  • the current directory in the directory to be detected is matched with the software directory feature in the current feature in the feature library. If the current directory matches the software catalog feature successfully, the current directory is taken as a target directory.
  • the software directory feature is used to indicate the first regular expression or the directory name of the pre-set software installation directory (for example, the software installation directory is C: ⁇ program files ⁇ software install, the software installation directory is named software install).
  • the software catalog feature is used to represent the first regular expression, it indicates that the software catalog feature can include a regular expression class wildcard.
  • the software catalog feature is "eprjacy + regular expression class wildcard", and the regular expression class wildcard indicates that any of the characters in the directory can be here. If the directory name of the current directory is "eprjacya", the two can match successfully.
  • the preset software installation directory may be preset by the user before performing software information detection.
  • the current directory that is successfully matched may be verified by matching the file names in the current directory.
  • the file names in the current directory are matched by string matching or regular expression matching. For example, if the directory name of the current directory satisfies the first regular expression, or if the directory name of the current directory is the same as the string of the directory name of the software installation directory, it is determined whether the current feature indicates that the current feature indicates Regular expression matching for file names in the current directory. Perform different operations based on different judgment results:
  • the current feature indicates that a regular expression matching needs to be performed on the file name in the current directory
  • the second regular expression indicated by the feature if it is determined that the file name in the current directory has the first target file name, it is determined that the current directory matches the software directory feature successfully;
  • the file name in the current directory has a second target file name, wherein the second target file name has a string and a file name.
  • the character string of the preset file name of the feature representation is the same; if it is determined that the file name of the current directory has the second target file name, it is determined that the current directory matches the software directory feature successfully.
  • the software information of the target software corresponding to the target directory in the operating system is detected, wherein the searched target directory may have one or more.
  • the target software corresponding to the target directory may be a bad software, and the bad software may be silently installed in the user terminal.
  • the software information of the target software corresponding to the target directory may include software derivatives of the target software.
  • the software information corresponding to the target directory may be searched for in the software derivative information scanned in advance from the operating system, and the found software information is used as the software information.
  • Software information for the target software may include a target directory, or the directory pointed to by the software information (for example, a shortcut) corresponding to the target directory includes a target directory, and if the software derivative information is multiple, It can have both software information containing the target directory and a directory pointing to the software information corresponding to the target directory of the target directory.
  • the software derivative information may include at least one of the following: a shortcut, a startup item information, a service item, an uninstall registration information, and process information; and correspondingly, the software information corresponding to the target directory may include At least one of the following: target shortcut, target launch item information, target service item, target uninstall registration information, target process information.
  • the shortcut obtained by scanning from the operating system in advance, the startup item information previously scanned from the operating system, the service item scanned in advance from the operating system, and the pre-operational operation may be sequentially operated.
  • the uninstall registration information scanned in the system and the process information scanned from the operating system in advance are searched for software information corresponding to the target directory.
  • Target process information in the process information scanned from the operating system in advance, wherein the target process information includes a target directory.
  • the order of the above-mentioned search and the type of the software-derived information to be found can be set as needed, which is not specifically limited in this embodiment.
  • the operating system when the operating system is in an idle state, the operating system may be scanned to obtain software derivative information, and the obtained software derivative information is used to search for software information corresponding to the target directory. For example, it may be determined whether the operating system is in an idle state (for example, when the CPU usage is less than or equal to a preset CPU occupation threshold, determining that the operating system is in an idle state); when determining that the operating system is in an idle state, scanning the operating system. Get software derivative information.
  • the detected software information of the target software is displayed on the terminal, wherein the displayed software information may include a software name.
  • the scan result may be displayed to the user on the interface of the security product, and after the user selects the process, all the software derivatives are processed in sequence, which may include:
  • the directory in the directory to be detected, the target directory, the root directory, the first-level subdirectory, and the like may also be expressed as the address, path, and the like of the folder or file, and those skilled in the art should understand that The above terms are only different in the way they are expressed, and the specific content is consistent.
  • the obtaining unit 1302 includes:
  • the first filtering module is configured to filter the root directory generated by the operating system installation from the root directory to obtain the target root directory collection;
  • the second filtering module is configured to filter the first-level sub-directory generated by the operating system installation from the default program installation directory of the operating system and all the first-level subdirectories under the default program data directory, to obtain the target sub-directory set;
  • the obtaining unit 1302 is further configured to use the target root directory set and the target sub-directory set as the to-be-detected directory.
  • the directory to be detected is obtained. While comprehensively analyzing the directories of each hard disk partition of the operating system, the analysis scope is narrowed, and the reliability and efficiency of the directory to be detected are improved.
  • the searching unit 1304 includes: a first matching module, where
  • a first matching module configured to match a current directory in the directory to be detected with a software directory feature in a current feature in the feature library, wherein the software directory feature is used to represent the first regular expression or a preset software installation directory Directory name;
  • the searching unit 1304 is further configured to use the current directory as a target directory if the current directory and the software directory feature match successfully.
  • Determining the target directory by matching the current directory in the directory to be detected with the software directory features in the current feature in the feature library, and providing two different software directory features for representing the first regular expression or preset
  • the directory name of the software installation directory is more convenient and flexible than the related technology in detecting the specific single feature, and the detection efficiency is improved.
  • the first matching module is further configured to determine whether the current feature indicates that a regular expression matching is required; and when determining that the current feature indicates that a regular expression matching is needed, determining a directory name of the current directory. Whether the first regular expression indicated by the software catalog feature is satisfied; if the directory name of the current directory satisfies the first regular expression, it is determined that the current directory matches the software catalog feature successfully.
  • the first matching module is further configured to determine whether the current feature indicates that a regular expression matching is required; and when determining that the current feature indicates that a regular expression matching is needed, determining a directory name of the current directory. Whether the first regular expression indicated by the software catalog feature is satisfied; when it is determined that the current feature indicates that regular expression matching is not required, the directory name of the current directory and the directory name of the software installation directory indicated by the software catalog feature are stringed. Comparison; if the directory name of the current directory is the same as the string of the directory name of the software installation directory, it is determined that the current directory matches the software directory feature successfully.
  • the first matching module includes:
  • the first determining sub-module is configured to determine whether the current feature indicates that a regular expression matching needs to be performed on the file name in the current directory;
  • the second determining sub-module is configured to determine, when the current feature indication needs to perform regular expression matching on the file name in the current directory, whether the first target file name exists in the file name in the current directory, wherein the first target file The name satisfies the second regular expression indicated by the file name feature in the current feature;
  • the first determining submodule is configured to determine that the current directory matches the software catalog feature successfully if it is determined that the file name in the current directory has the first target file name.
  • the first matching module includes:
  • the third determining sub-module is configured to determine whether the current feature indicates that a regular expression matching needs to be performed on the file name in the current directory;
  • the fourth determining sub-module is configured to determine, when the current feature indication does not need to perform a regular expression matching on the file name in the current directory, whether the file name in the current directory has a second target file name, wherein the second target The string of the file name is the same as the string of the pre-set file name indicated by the file name feature;
  • the second determining submodule is configured to determine that the current directory matches the software catalog feature successfully if it is determined that the file name in the current directory has the second target file name.
  • the matching result is verified by the file name in the current directory, which avoids the occurrence of the matching error problem and improves the correct matching rate between the current directory and the software directory feature.
  • the detecting unit 1306 includes: a searching module, where
  • a search module configured to search for software information corresponding to the target directory in software derivative information previously scanned from the operating system, wherein the software information corresponding to the target directory includes a target directory, and/or, with the target directory The directory pointed to by the corresponding software information contains the target directory;
  • the detecting unit is further configured to use the found software information as software information of the target software.
  • the software derivative information scanned from the operating system is searched to obtain the software information of the target software. Since the software derivative information is searched according to the target directory rather than the specific feature, the efficiency of acquiring the software information of the target software can be improved. .
  • the lookup module includes at least one of the following:
  • the first search submodule is configured to search for a target shortcut in a shortcut that is previously scanned from the operating system, where the directory pointed to by the target shortcut includes a target directory;
  • a second search sub-module configured to search for target startup item information in the startup item information that is previously scanned from the operating system, where the directory pointed to by the target startup item information includes a target directory;
  • a third search submodule configured to search for a target service item in a service item scanned in advance from the operating system, where the directory pointed to by the target service item includes a target directory;
  • a fourth search sub-module configured to search for the target uninstallation registration information in the uninstall registration information that is previously scanned from the operating system, where the directory pointed to by the target uninstall registration information includes the target directory;
  • a fifth search submodule configured to search for target process information in the process information that is previously scanned from the operating system, where the target process information includes a target directory;
  • the software derivative information includes: a shortcut, a startup item information, a service item, an uninstall registration information, and process information; and the software information corresponding to the target directory includes: a target shortcut, and a target startup item information. , target service item, target uninstall registration information, target process information.
  • the shortcut, the startup item information, the service item, the uninstall registration information, and the process information are scanned respectively, and the software information corresponding to the target directory is obtained, and the software derivative can be comprehensively detected, and the detection feature is efficient and the coverage is wide.
  • the apparatus further includes:
  • a determining unit configured to determine whether the operating system is in an idle state
  • the scanning unit is configured to scan the operating system to obtain the software derivative information when it is determined that the operating system is in the idle state.
  • the operating system When the operating system is in an idle state, the operating system is scanned to obtain software derivative information, which can utilize the resources of the operating system reasonably, thereby avoiding problems such as the card machine caused by scanning the operating system, thereby improving the user experience.
  • the device further includes:
  • a receiving unit configured to receive a deletion instruction after displaying the detected software information of the target software on the terminal
  • Delete the unit set to respond to the delete command, delete the software information of the target software in the operating system.
  • the software information of the target software is deleted in the operating system, and the software information of the target software can be cleared according to the instruction, and the software information of the target software is used to occupy the system resources, thereby ensuring a high clear success rate.
  • the above modules are the same as the examples and application scenarios implemented by the corresponding steps, but are not limited to the contents disclosed in the above embodiment 1. It should be noted that the foregoing module may be implemented in a hardware environment as shown in FIG. 1 as part of the device, and may be implemented by software or by hardware, where the hardware environment includes a network environment.
  • an electronic device for implementing the above-described processing method of software information is also provided.
  • the electronic device may include one or more (only one shown in the figure) processor 1402, memory 1404, transmission device 1406, and input and output device 1408.
  • the memory 1404 can be configured to store a software program and a module, such as a software information processing method and a program instruction/module corresponding to the device in the embodiment of the present application, and the processor 1402 runs the software program and the module stored in the memory 1404. Thereby, various functional applications and data processing are performed, that is, the processing method of the above software information is implemented.
  • Memory 1404 can include high speed random access memory, and can also include non-volatile memory, such as one or more magnetic storage devices, flash memory, or other non-volatile solid state memory.
  • memory 1404 can include memory remotely located relative to processor 1402, which can be connected to the terminal over a network. Examples of such networks include, but are not limited to, the Internet, intranets, local area networks, mobile communication networks, and combinations thereof.
  • the transmission device 1406 described above is arranged to receive or transmit data via a network, and may also be configured as a data transmission between the processor and the memory. Specific examples of the above network may include a wired network and a wireless network.
  • the transmission device 1406 includes a Network Interface Controller (NIC) that can be connected to other network devices and routers via a network cable to communicate with the Internet or a local area network.
  • the transmission device 1406 is a Radio Frequency (RF) module for communicating with the Internet wirelessly.
  • NIC Network Interface Controller
  • RF Radio Frequency
  • the memory 1404 is configured to store an application.
  • the processor 1402 can invoke the application stored in the memory 1404 through the transmission device 1406 to perform the following steps:
  • the software information of the target software corresponding to the target directory in the operating system is detected;
  • the software information of the detected target software is displayed on the terminal.
  • the processor 1402 is further configured to: perform the following steps: obtaining the to-be-detected directory in the operating system installed on the terminal, comprising: acquiring a root directory of each hard disk partition of the operating system; and filtering out, generated from the root directory, the operating system installation The root directory, get the target root directory collection; filter the first-level subdirectories generated by the operating system installation from the default program installation directory of the operating system and all the first-level subdirectories under the default program data directory, to obtain the target sub-directory collection; Use the target root collection and the target subdirectory collection as the directory to be detected.
  • the processor 1402 is further configured to perform the following steps: searching, in the to-be-detected directory, the target directory that matches at least one feature in the pre-acquired feature library comprises: the current directory in the directory to be detected and the current feature in the feature library
  • the software catalog feature is matched, wherein the software catalog feature is used to represent the first regular expression or a pre-set directory name of the software installation directory; in the case that the current directory matches the software catalog feature successfully, the current directory is regarded as a Target directory.
  • the processor 1402 is further configured to perform the step of: matching the current directory in the directory to be detected with the software directory feature in the current feature in the feature library comprises: determining whether the current feature indicates that regular expression matching is required; When the current feature indicates that a regular expression matching is needed, it is determined whether the directory name of the current directory satisfies the first regular expression indicated by the software directory feature; and when the directory name of the current directory satisfies the first regular expression, the current directory is determined. Matches successfully with the software catalog feature.
  • the processor 1402 is further configured to perform the step of: matching the current directory in the directory to be detected with the software directory feature in the current feature in the feature library comprises: determining whether the current feature indicates that regular expression matching is required; The current feature indicates that when the regular expression matching is not required, the directory name of the current directory is compared with the directory name of the software installation directory indicated by the software directory feature; the directory name of the current directory and the directory name of the software installation directory are both If the string is the same, it is determined that the current directory matches the software catalog feature successfully.
  • the processor 1402 is further configured to: determine whether the current feature indicates that a regular expression matching needs to be performed on the file name in the current directory; and when determining that the current feature indicates that the file name in the current directory needs to be matched with a regular expression Determining whether the file name in the current directory has a first target file name, wherein the first target file name satisfies the second regular expression indicated by the file name feature in the current feature; and determining that the file name exists in the current directory In the case of the first target file name, it is determined that the current directory matches the software catalog feature successfully;
  • the processor 1402 is further configured to: determine whether the current feature indicates that a regular expression matching needs to be performed on the file name in the current directory; and determine that the current feature indicates that the regular name matching of the file name in the current directory is not required.
  • determine whether the file name in the current directory has a second target file name, wherein the character string of the second target file name is the same as the character string of the preset file name indicated by the file name feature; If the file name has the second target file name, it is determined that the current directory matches the software directory feature successfully.
  • the processor 1402 is further configured to: perform: detecting software information of the target software corresponding to the target directory in the operating system, including: searching for software information corresponding to the target directory in the software derivative information scanned in advance from the operating system
  • the software information corresponding to the target directory includes a target directory, and/or the directory pointed to by the software information corresponding to the target directory includes a target directory; and the found software information is used as software information of the target software.
  • the processor 1402 is further configured to perform the step of: searching for software information corresponding to the target directory in the software derivative information previously scanned from the operating system, including at least one of the following: a shortcut that is scanned in advance from the operating system. Find the target shortcut, wherein the directory pointed to by the target shortcut includes the target directory; the target startup item information is searched for in the startup item information scanned from the operating system in advance, wherein the directory pointed to by the target startup item information includes the target a directory service; searching for a target service item in a service item scanned from the operating system in advance, wherein the directory pointed to by the target service item includes a target directory; and searching for the target uninstallation registration information in the uninstall registration information scanned in advance from the operating system
  • the directory pointed to by the target uninstallation registration information includes a target directory; the target process information is searched for in the process information scanned from the operating system in advance, wherein the target process information includes the target directory.
  • the processor 1402 is further configured to perform the following steps: before searching for software information corresponding to the target directory in the software derivative information scanned from the operating system in advance, the method further includes: determining whether the operating system is in an idle state; When the system is idle, the operating system is scanned to obtain software derivative information.
  • the processor 1402 is further configured to perform the following steps: after displaying the detected software information of the target software on the terminal, the method further includes: receiving the deletion instruction; and deleting the software information of the target software in the operating system in response to the deletion instruction.
  • a software information detection scheme is provided. Detecting, by using a target directory that matches at least one feature in the pre-acquired feature library in the to-be-detected directory, detecting software information of the target software corresponding to the found target directory in the operating system, and detecting the target software.
  • the software information is displayed on the terminal, and achieves the purpose of comprehensively detecting the software information, thereby realizing the technical effect of improving the accuracy of the software information detection, thereby solving the omission technology when processing the software information of the target software. problem.
  • the terminal can be a smart phone (such as an Android mobile phone, an iOS mobile phone, etc.), a tablet computer, a palm computer, and a mobile Internet device (MID). Terminal equipment such as PAD.
  • Fig. 14 does not limit the structure of the above electronic device.
  • the terminal may also include more or fewer components (such as a network interface, display device, etc.) than shown in FIG. 14, or have a different configuration than that shown in FIG.
  • a storage medium having stored therein a computer program, wherein the computer program is configured to execute the steps of any one of the method embodiments described above.
  • the foregoing storage medium may be located on at least one of the plurality of network devices in the network shown in the foregoing embodiment.
  • the storage medium is arranged to store a computer program for performing the following steps:
  • the storage medium is further arranged to store a computer program for performing the following steps:
  • Obtaining the to-be-detected directory in the operating system installed on the terminal includes:
  • the target root directory set and the target sub-directory set are used as the to-be-detected directory.
  • the storage medium is further arranged to store a computer program for performing the following steps:
  • Finding a target directory in the to-be-detected directory that matches at least one feature in the pre-acquired feature library includes:
  • the storage medium is further arranged to store a computer program for performing the following steps:
  • Matching the current directory in the directory to be detected with the software catalog feature in the current feature in the signature library includes:
  • the storage medium is further arranged to store a computer program for performing the following steps:
  • Matching the current directory in the directory to be detected with the software catalog feature in the current feature in the signature library includes:
  • the storage medium is further arranged to store a computer program for performing the following steps:
  • Determining that the current directory matches the software catalog feature successfully includes:
  • the storage medium is further arranged to store a computer program for performing the following steps:
  • Determining that the current directory matches the software catalog feature successfully includes:
  • the storage medium is further arranged to store a computer program for performing the following steps:
  • the software information of the target software corresponding to the target directory in the operating system is detected:
  • the found software information is used as the software information of the target software.
  • the storage medium is further arranged to store a computer program for performing the following steps:
  • Finding software information corresponding to the target directory in the software derivative information scanned in advance from the operating system includes at least one of the following:
  • the target startup item information is searched for in the startup item information that is previously scanned from the operating system, where the directory pointed to by the target startup item information includes a target directory;
  • the storage medium is further arranged to store a computer program for performing the following steps:
  • the method Before searching for software information corresponding to the target directory in the software derivative information scanned from the operating system in advance, the method further includes:
  • the storage medium is further arranged to store a computer program for performing the following steps:
  • the method further includes:
  • the foregoing storage medium may include, but not limited to, a USB flash drive, a Read-Only Memory (ROM), a Random Access Memory (RAM), a mobile hard disk, and a magnetic memory.
  • ROM Read-Only Memory
  • RAM Random Access Memory
  • mobile hard disk a magnetic memory.
  • magnetic memory a variety of media that can store computer programs, such as a disc or an optical disc.
  • the integrated unit in the above embodiment if implemented in the form of a software functional unit and sold or used as a stand-alone product, may be stored in the above-described computer readable storage medium.
  • the technical solution of the present application may be embodied in the form of a software product, or the whole or part of the technical solution, which is stored in the storage medium, including
  • the instructions are used to cause one or more computer devices (which may be a personal computer, server or network device, etc.) to perform all or part of the steps of the methods described in the various embodiments of the present application.
  • the disclosed client may be implemented in other manners.
  • the device embodiments described above are merely illustrative.
  • the division of the unit is only a logical function division.
  • multiple units or components may be combined or may be Integrate into another system, or some features can be ignored or not executed.
  • the mutual coupling or direct coupling or communication connection shown or discussed may be an indirect coupling or communication connection through some interface, unit or module, and may be electrical or otherwise.
  • the units described as separate components may or may not be physically separated, and the components displayed as units may or may not be physical units, that is, may be located in one place, or may be distributed to multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of the embodiment.
  • each functional unit in each embodiment of the present application may be integrated into one processing unit, or each unit may exist physically separately, or two or more units may be integrated into one unit.
  • the above integrated unit can be implemented in the form of hardware or in the form of a software functional unit.
  • the method for matching the target directory in the directory to be detected in the feature library is detected, and the target directory matching the at least one feature in the feature library acquired in advance is detected in the to-be-detected directory, and the target directory is detected.
  • the software information of the target software corresponding to the found target directory in the operating system, and displaying the detected software information of the target software on the terminal because the features in the feature library are matched with the directories in the directory to be detected, It avoids the problem of missed detection caused by incomplete configuration or new derivatives that do not exist in the configuration list, achieves the purpose of comprehensive detection of software information, and achieves the technical effect of improving the accuracy of software information detection.

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Data Mining & Analysis (AREA)
  • Databases & Information Systems (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Library & Information Science (AREA)
  • Human Computer Interaction (AREA)
  • Stored Programmes (AREA)

Abstract

本申请公开一种软件信息的处理方法和装置及存储介质、电子装置。其中,该方法包括:获取安装在终端上的操作系统中的待检测目录;在所述待检测目录中查找与预先获取到的特征库中的至少一条特征匹配的目标目录;在查找到所述目标目录的情况下,检测所述操作系统中与所述目标目录相对应的目标软件的软件信息;在所述终端上显示检测到的所述目标软件的软件信息。本申请解决了对目标软件的软件信息进行处理时存在遗漏的技术问题。

Description

软件信息的处理方法和装置及存储介质、电子装置
本申请要求于2016年12月30日提交中国专利局、优先权号为2016112605945、发明名称为“软件信息的处理方法及装置”的中国专利申请的优先权,其全部内容通过引用结合在本申请中。
技术领域
本申请涉及计算机领域,具体而言,涉及一种软件信息的处理方法和装置及存储介质、电子装置。
背景技术
由于推广PC(Personal Computer,个人计算机)软件能够获取不菲的商业利益,普通用户使用PC时通过下载或者其他渠道,很容易被诱导或者静默推装上各类软件。部分推装软件通过伤害用户体验的方式(例如,频繁弹窗,静默刷取流量,收集用户隐私信息等)牟利,伤害用户对PC的控制权,对用户构成安全风险。由于推装软件通常采用保护性行为(如,卸载程序交互设计复杂等)保护自身不被用户轻易发现和卸载,导致当用户发现PC机器行为异常时,往往难以发现对应软件源,即使发现,也难以绕开软件设置的卸载障碍,彻底清理软件。
相关技术中,一些安全产品提供了软件卸载功能及插件清理功能。在进行软件卸载或者插件清理的过程中,通过特征库中每条特征配置的各类软件衍生物信息(每条特征信息包含文件,注册表,进程等信息)对文件特征、注册表特征、进程特征以及其他类别特征依次进行匹配的方式,检测用户机器机中的软件衍生物。由于配置列表中需要配置的项非常繁琐,一旦出现配置不完整或者出现的新衍生物尚不存在配置列表,清理时会遗漏相关衍生物在用户机器,无法彻底清理干净整款软件。
针对上述对目标软件的软件信息进行检测时存在遗漏的问题,目前尚未提出有效的解决方案。
发明内容
本申请实施例提供了一种软件信息的处理方法和装置及存储介质、电子装置,以至少解决对目标软件的软件信息进行处理时存在遗漏的技术问题。
根据本申请实施例的一个方面,提供了一种软件信息的处理方法,包括:获取安装在终端上的操作系统中的待检测目录;在所述待检测目录中查找与预先获取到的特征库中的至少一条特征匹配的目标目录;在查找到所述目标目录的情况下,检测所述操作系统中与所述目标目录相对应的目标软件的软件信息;在所述终端上显示检测到的所述目标软件的软件信息。
根据本申请实施例的另一方面,还提供了一种软件信息的处理装置,包括:获取单元,设置为获取安装在终端上的操作系统中的待检测目录;查找单元,设置为在所述待检测目录中查找与预先获取到的特征库中的至少一条特征匹配的目标目录;检测单元,设置为在查找到所述目标目录的情况下,检测所述操作系统中与所述目标目录相对应的目标软件的软件信息;显示单元,设置为在所述终端上显示检测到的所述目标软件的软件信息。
根据本申请实施例的又一方面,还提供了一种存储介质,该存储介质可以存储有执行指令,该执行指令设置为执行上述实施例中的软件信息的处理方法。
根据本申请实施例的又一方面,还提供了一种电子装置,包括存储器、处理器及存储在存储器上并可在处理器上运行的计算机程序,其中,上述处理器通过计算机程序执行上述软件信息的处理方法。
在本申请实施例中,采用特征库中的特征对待检测目录中的目标目录进行匹配的方式,通过在待检测目录中查找与预先获取到的特征库中的至少一条特征匹配的目标目录,检测操作系统中与查找到的目标目录相对应的目标软件的软件信息,并将检测到的目标软件的软件信息在终端上显示,由于采用特征库中的特征与待检测目录中的目录进行匹配,避免了配置不完整或者出现的新衍生物尚不存在配置列表的情况导致的漏检问题,达到了对软件信息的全面检测的目的,从而实现了提高软件信息检测的准确性的技术效果,进而解决了对目标软件的软件信息进行处理时存在遗漏的技术问题。
附图说明
此处所说明的附图用来提供对本申请的理解,构成本申请的一部分,本申请的示意性实施例及其说明用于解释本申请,并不构成对本申请的不当限定。在附图中:
图1是根据本申请实施例的软件信息的处理方法的硬件环境的示意图;
图2是根据本申请实施例的一种可选的软件信息的处理方法的流程图;
图3是根据本申请实施例的一种可选的硬盘分区根目录的示意图;
图4是根据本申请实施例的一种可选的特征库中的单条特征的示意图;
图5是根据本申请实施例的一种可选的推装软件特征库的示意图;
图6是根据本申请实施例的一种可选的用户使用安全产品查杀功能时的流程图;
图7是根据本申请实施例的一种可选的用户使用查杀功能完成时的安全产品提示界面的示意图;
图8是根据本申请实施例的一种可选的安全产品静默扫描时的流程图;
图9是根据本申请实施例的一种可选的产品静默扫描完成时的提示页面的示意图;
图10是根据本申请实施例的一种可选的使用检测功能时检出推装软件的机器量和清理效果的示意图;
图11是根据本申请实施例的一种可选的安全产品主动检测并提示检出推装软件的机器量和清理效果的示意图;
图12是根据本申请实施例的一种可选的安全产品框架的流程示意图;
图13是根据本申请实施例的一种可选的软件信息的检测装置的示意图;以及
图14是根据本申请实施例的一种终端的结构框图。
具体实施方式
为了使本技术领域的人员更好地理解本申请方案,下面将结合本申请实施例中的附图,对本申请实施例中的技术方案进行清楚、完整地描述,显然,所描述的实施例仅仅是本申请一部分的实施例,而不是全部的实施例。基于本申请中的实施例,本领域普通技术人员在没有做出创造性劳动前提下所获得的所有其他实施例,都应当属于本申请保护的范围。
需要说明的是,本申请的说明书和权利要求书及上述附图中的术语“第一”、“第二”等是用于区别类似的对象,而不必用于描述特定的顺序或先后次序。应该理解这样使用的数据在适当情况下可以互换,以便这里描述的本申请的实施例能够以除了在这里图示或描述的那些以外的顺序实施。此外,术语“包括”和“具有”以及他们的任何变形,意图在于覆盖不排他的包含,例如,包含了一系列步骤或单元的过程、方法、系统、产品或设备不必限于清楚地列出的那些步骤或单元,而是可包括没有清楚地列出的或对于这些过程、方法、产品或设备固有的其它步骤或单元。
首先,在对本申请实施例进行描述的过程中出现的部分名词或者术语 适用于如下解释:
硬盘分区,是指对硬盘进行分区后所产生的各个分区,例如,C盘、D盘、E盘等;
硬盘分区的根目录,是指各硬盘分区下的目录,例如,C:\AAA即为即为C盘的根目录);
一级子目录,是指当前目录下的各文件夹或者文件的目录,例如,C:\AAA\BBB,为C:\AAA的一级子目录;
目录的目录名,是指目录所对应的文件夹的文件夹名或者文件的文件名,例如,目录C:\AAA\BBB的目录名为BBB)。
软件衍生物,是指软件安装完成后,在PC机器操作系统中释放的(1)桌面、开始菜单、快速启动栏等位置快捷方式;(2)开机自启动项、软件服务项、软件驱动、软件卸载信息、插件项;(3)安装目录下软件子文件,进程信息等。
根据本申请实施例的一个方面,提供了一种软件信息的处理方法实施例。
可选地,在本实施例中,上述软件信息的处理方法可以应用于如图1所示的由服务器102和终端104所构成的硬件环境中。如图1所示,服务器102通过网络与终端104进行连接,上述网络包括但不限于:广域网、城域网或局域网,终端104并不限定于PC、手机、平板电脑等。本申请实施例的软件信息的处理方法可以由服务器102来执行,也可以由终端104来执行,还可以是由服务器102和终端104共同执行。其中,终端104执行本申请实施例的软件信息的处理方法也可以是由安装在其上的客户端来执行。在由服务器102和终端104共同执行的情况下,由服务器102向终端104下发特征库,终端104根据服务器下发的特征库,对目标软件的软件信息进行处理。
图2是根据本申请实施例的一种可选的软件信息的处理方法的流程图, 如图2所示,该方法可以包括以下步骤:
步骤S202,获取安装在终端上的操作系统中的待检测目录。
在步骤S202提供的技术方案中,可以在检测到用户点击安全产品界面上的预设按键(例如,查杀等)时,也可以是在满足预设条件的情况下,触发安全产品静默扫描时,执行获取待检测目录的操作。这里的预设条件可以是预设时间条件,也可以是预设事件条件。预设时间条件可以是具体的时刻或者时间段,(例如,XXXX年XX月XX日21:00),也可以是周期的时刻或者时间段(例如,每天21:00,每周日21:00)。预设事件条件可以是CPU的占用率低于预定值(例如,30%),具体地获取操作的触发条件,可以根据需要设定,在此不做具体限定。
可选地,在本实施例中,在获取安装在终端上的操作系统中的待检测目录时,可以采用多种方式获取待检测目录。例如,可以获取操作系统的各个硬盘分区中的根目录集合和各级子目录集合,将获取的所有目录集合(根目录集合和各级子目录集合)作为待检测目录。
可选地,在本实施例中,可以获取操作系统的各个硬盘分区的根目录;从根目录中过滤掉操作系统安装时所产生的根目录(例如,C:\WINDOWS),得到目标根目录集合;从操作系统的默认程序安装目录和默认程序数据目录下的所有一级子目录中过滤掉操作系统安装时所产生的一级子目录,得到目标子目录集合;将目标根目录集合和目标子目录集合作为待检测目录。待检测目录为进行软件信息检测的目录。
下面结合具体的示例进行说明。如图3所示,在硬盘分区C盘的根目录中,操作系统安装时所产生的根目录可以包括以下四个:C:\Windows、C:\Windows\Program Files、C:\Windows\Program Files(86)以及C:\Windows\用户,除了上述四个根目录以外的根目录所组成的结合,为目标根目录集合;操作系统的默认程序安装目录包括:C:\Windows\Program Files和C:\Windows\Program Files(86),默认程序数据目录包括:C:\Windows\用户,这三个根目录下的所有一级子目录中过滤掉操作系统安装时所产生的一 级子目录,得到目标子目录集合。
可选地,可以采用枚举的方式枚举出系统中常见安装位置下所有子目录信息,作为待检测目录:
1)枚举硬盘各分区根目录位置下的所有子目录信息,过滤掉操作系统自带目录后记录剩余目录信息。
2)枚举默认程序安装目录(例如,x:\program files),默认程序数据目录(%appdata%)等其它常见软件安装位置下的所有子目录信息,同样过滤操作系统自带目录后记剩余子目录为待检查目录。
将上述1)和2)中确定的所有待核查目录作为待检测目录。
步骤S204,在待检测目录中查找与预先获取到的特征库中的至少一条特征匹配的目标目录。
在步骤S204提供的技术方案中,在待检测目录中查找与预先获取到的特征库中的至少一条特征匹配的目标目录,其中,特征库中包含有至少一个的特征。
特征库中包含的特征用于对目标目录进行匹配,可以采用逐条匹配的方式对待检测目录中的各个目录进行匹配。例如,可以逐条选择待检测目录中的目录,依次与特征库中包含的特征进行比较,确定两者是否匹配。
在进行匹配时,将待检测目录中的当前目录与特征库中的当前特征中的软件目录特征进行匹配。如果当前目录与软件目录特征匹配成功,则将当前目录作为一个目标目录。
软件目录特征用于表示第一正则表达式或预先设置的软件安装目录的目录名(例如,软件安装目录为C:\program files\software install,则软件安装目录的目录名为software install)。在软件目录特征用于表示第一正则表达式时,表示该软件目录特征中可以包含正则表达式类通配符。例如,软件目录特征为“eprjacy+正则表达式类通配符”,该正则表达式类通配符 表示目录中的此处可以为任意字符。如果当前目录的目录名为“eprjacya”,则两者可以匹配成功。
可选地,在本实施例中,预先设置的软件安装目录可以在进行软件信息检测前由用户预先设置。在设置软件安装目录时,可以通过界面交互的方式提示用户进行设置。如果用户未进行设置,可以采用默认值进行设置。
可选地,在本实施例中,可以通过对当前目录下的文件名进行匹配的方式对匹配成功的当前目录进行校验。采用字符串匹配或者正则表达式匹配的方式对当前目录下的文件名进行匹配。例如,可以在当前目录的目录名满足第一正则表达式的情况下,或者,在当前目录的目录名与软件安装目录的目录名两者的字符串相同的情况下,判断当前特征是否指示需要对当前目录下的文件名进行正则表达式匹配。根据不同的判断结果,执行不同的操作:
在判断出当前特征指示需要对当前目录下的文件名进行正则表达式匹配时,判断当前目录下的文件名是否存在第一目标文件名,其中,第一目标文件名满足当前特征中的文件名特征所指示的第二正则表达式;在判断出当前目录下的文件名存在第一目标文件名的情况下,确定当前目录与软件目录特征匹配成功;
在判断出当前特征指示不需要对当前目录下的文件名进行正则表达式匹配时,判断当前目录下的文件名是否存在第二目标文件名,其中,第二目标文件名的字符串与文件名特征表示的预先设置的文件名的字符串相同;在判断出当前目录下的文件名存在第二目标文件名的情况下,确定当前目录与软件目录特征匹配成功。
下面结合具体的示例对如何查找目标目录进行说明。
取步骤S202中所有获取的待检查目录(待检测目录),与最新特征库进行匹配。
1)单条特征形态精简为只需记录目录+文件衍生物(即时软件可有多 个子文件,也可只记录一条为特征),优化后可以为如图4所示的形态。
图4中包含了1条软件特征,其中该条“恶评软件A”的软件特征共包含5个组成部分:
软件名--命中目录特征后展示在安全产品界面上。
软件目录特征--软件安装目录名,与步骤S202中记录的待检测目录进行匹配。可以包含正则表达式类通配符,从而扩展特征覆盖范围。
目录是否需通配--当本条记录为true时,代表“软件目录特征”中包含正则表达式类通配符,单独设立本标记是为了在匹配目录特征前优先判断本标记,如无需正则类匹配时采用完全匹配算法,从而提高特征匹配效率。
目录中文件名特征--当目录特征命中后,再匹配目录下是否存在符合文件名特征的文件。本特征相当于是一种校验规则,保证匹配效果的准确性。可以包含正则表达式类通配符,从而扩展特征覆盖范围。
文件是否需通配--当本条记录为true时,代表“文件名特征”中包含正则表达式类通配符,单独设立本标记是为了在匹配文件特征前优先判断本标记,如无需正则类匹配时采用完全匹配算法,从而提高特征匹配效率。不填时默认为false。
2)多条特征组合后构成推装软件特征库,形态可以如图5所示。
3)取步骤S202中获取的所有待检测目录,依次与每条软件特征进行匹配。
首先,判断“目录是否需通配”,如需要,采用模糊匹配算法匹配“软件目录特征”;如不需要,采用完全匹配算法匹配“软件目录特征”。
然后,匹配时将待检测目录的目录名与“软件目录特征”进行字符串比较,如果字符串不满足相等条件,认为未命中目录特征。此时继续匹配下一条软件特征。如果命中目录特征,进入下一步。
下面结合具体的示例进行说明。对于名称为“C:\eprjacy052411014”的待检测目录,该条待检测目录的目录名为“eprjacy052411014”,特征库中包含如图4所示的“恶评软件A”的一条特征。判断“目录是否需通配”,判断结果为是,则待检测目录的目录名与该条特征匹配成功,将匹配到C:\eprjacy052411014目录符合“恶评软件A”的软件目录名特征。
4)命中目录特征后,枚举该目录下所有子文件并记录(枚举操作较耗时,只有命中目录后再枚举即可节省枚举次数),通用先判定“文件是否需通配”,再判断“目录中文件名特征”是否存在于本步骤中枚举到的子文件列表。如存在,则认为本条软件特征匹配成功,系统中存在该款推广软件。
下面结合具体的示例进行说明。对于如图4所示的“恶评软件A”的特征,枚举根目录C:\eprjacy052411014下的所有子文件,可以得到4个子文件:
C:\eprjacy052411014\static.ini;
C:\eprjacy052411014\eprja_cy05241.exe;
C:\eprjacy052411014\eprja_service.exe;
C:\eprjacy052411014\uninstall.exe。
其中,子文件“C:\eprjacy052411014\eprja_cy05241.exe”的目录名为:“eprja_cy05241.exe”,可命中“文件名特征”,则匹配成功。
通过上述方式,可以在待检测目录中查找与预先获取到的特征库中的至少一条特征匹配的目标目录。
步骤S206,在查找到目标目录的情况下,检测操作系统中与目标目录相对应的目标软件的软件信息。
在步骤S206提供的技术方案中,在查找到目标目录的情况下,检测操作系统中与目标目录相对应的目标软件的软件信息,其中,查找到的目 标目录可以有一个或者多个。
与目标目录相对应的目标软件可能为恶评软件,恶评软件可能被静默安装在用户终端中的推装软件。与目标目录相对应的目标软件的软件信息可以包括目标软件的软件衍生物。
在进行操作系统中与目标目录相对应的目标软件的软件信息检测时,可以在预先从操作系统中扫描得到的软件衍生信息中查找与目标目录相对应的软件信息,将查找到的软件信息作为目标软件的软件信息。其中,与目标目录相对应的软件信息可以包含目标目录,或者,与目标目录相对应的软件信息(例如,快捷方式)所指向的目录包含目标目录,在软件衍生信息为多个的情况下,可以既有包含目标目录的软件信息,又有所指向的目录包含目标目录的与目标目录相对应的软件信息。
可选地,在本实施例中,软件衍生信息可以包括以下至少之一:快捷方式、启动项信息、服务项、卸载注册信息、进程信息;相应地,与目标目录相对应的软件信息可以包括以下至少之一:目标快捷方式、目标启动项信息、目标服务项、目标卸载注册信息、目标进程信息。
可选地,在本实施例中,可以依次从预先从操作系统中扫描得到的快捷方式、预先从操作系统中扫描得到的启动项信息、预先从操作系统中扫描得到的服务项、预先从操作系统中扫描得到的卸载注册信息和预先从操作系统中扫描得到的进程信息中查找与目标目录相对应的软件信息。
在具体实施时,可以分别通过如下步骤进行查找:
1)在预先从操作系统中扫描得到的快捷方式中查找目标快捷方式,其中,目标快捷方式所指向的目录包含目标目录;
2)在预先从操作系统中扫描得到的启动项信息中查找目标启动项信息,其中,目标启动项信息所指向的目录包含目标目录;
3)在预先从操作系统中扫描得到的服务项中查找目标服务项,其中,目标服务项所指向的目录包含目标目录;
4)在预先从操作系统中扫描得到的卸载注册信息中查找目标卸载注册信息,其中,目标卸载注册信息所指向的目录包含目标目录;
5)在预先从操作系统中扫描得到的进程信息中查找目标进程信息,其中,目标进程信息包含目标目录。
上述查找的顺序以及查找的软件衍生信息的种类可以根据需要进行设定,在本实施例中对此不做具体限定。
可选地,在本实施例中,可以在操作系统处于空闲状态时,对操作系统进行扫描,得到软件衍生信息,得到的该软件衍生信息在查找与目标目录相对应的软件信息使使用。例如,可以首先判断操作系统是否处于空闲状态(例如,CPU占用小于或者等于预设CPU占用阈值时,确定操作系统处于空闲状态);在判断出操作系统处于空闲状态时,对操作系统进行扫描,得到软件衍生信息。
下面结合具体的示例对如何检测操作系统中与目标目录相对应的目标软件的软件信息进行说明。
软件特征成功匹配后,通过如下步骤获取所有该款软件对应的所有衍生物,记录后供处理时使用。
1)得到的推广软件安装目录,将记录的所有快捷方式指向目录与该软件安装目录进行对比。如果记录的快捷方式指向信息中包含软件目录特征,则该快捷方式为目标软件的快捷方式衍生物,记录该快捷方式。
2)与步骤1)类似地,比对常规启动项信息,如果记录的启动项指向信息中包含软件目录特征,则该启动项为目标软件的启动项衍生物,记录该启动项。
3)与步骤1)类似地,继续比对服务、卸载注册信息、进程等信息,得到包含软件目录特征的服务项、卸载注册信息和进程,则得到的服务项、卸载注册信息和进程为目标软件的启动项衍生物,记录得到的服务项、卸载注册信息和进程。
下面结合具体的示例对如何获取软件衍生物进行说明。
初始化当前扫描环境,通过如下步骤获取各类软件衍生物信息:
1)获取当前系统环境中各类关键位置的系统路径,如默认程序安装目录(例如,x:\program files),默认系统目录(例如,x:\windows),默认程序数据目录(例如,%appdata%),桌面目录,开始菜单目录,快速启动栏等软件文件衍生物常出现的位置。
2)枚举当前系统桌面、开始菜单、快速启动栏的所有快捷方式文件,并解析其快捷方式指向信息,去除指向信息中参数部分后获取具体指向文件,将快捷方式文件和其指向文件保持一一对应关系后记录。
3)枚举当前系统中所有常规启动项获取启动项衍生物信息(例如,常规启动项信息记录在注册表等位置,注册表的地址可以如下所示:HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersio n\run)。将启动项注册表位置和其指向信息保持一一对应关系后记录。
4)枚举当前系统中所有服务、驱动项(例如,从注册表下子项中提取服务、驱动信息)。将具体服务、驱动项注册表位置和其指向文件信息保持一一对应关系后记录。
其中,注册表目录可以为:
HKEY_LOCAL_MACHINE\SYSTEM\ControlSet001\services。
5)枚举当前系统所有已注册的软件卸载信息(从注册表下子项中提取信息)。将卸载信息注册表位置,软件名称,软件卸载文件路径保持一一对应关系后记录。
注册表的目录可以为:
HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentV ersion\Uninsta。
6)枚举当前系统所有进程信息,将所有进程信息全路径完整记录。
通过上述方式,即可获取到软件衍生物。
步骤S208,在终端上显示检测到的目标软件的软件信息。
在步骤S208提供的技术方案中,在终端上显示检测到的目标软件的软件信息,其中,显示的软件信息可以包括软件名。
可选地,在实施例中,可以在安全产品的界面上向用户展示扫描结果,用户选择处理后,依次处理所有软件衍生物,可以包括:
1)结束进程;
2)停用、删除服务,驱动项;
3)删除软件卸载注册信息;
4)删除软件启动项;
5)删除软件产生的桌面快捷方式;
6)删除软件所有子文件及安装目录;
7)提示用户重启系统,在重启系统过程中再次删除驱动,子文件等关键信息,确保清理成功。
可选地,在本实施例中,待检测目录、目标目录、根目录、一级子目录等中的目录,也可以表述为文件夹或者文件的地址、路径等,本领域技术人员应当理解,上述术语只是表述方式的不同,其具体指代的内容是一致的。
通过上述步骤S202至步骤S208,通过在待检测目录中查找与预先获取到的特征库中的至少一条特征匹配的目标目录,检测操作系统中与查找到的目标目录相对应的目标软件的软件信息,并将检测到的目标软件的软件信息在终端上显示,可以解决了对目标软件的软件信息进行处理时存在遗漏的技术问题,进而达到提高软件信息检测的准确性的技术效果。
作为一种可选的实施例,所述获取安装在终端上的操作系统中的待检 测目录包括:
S1,获取操作系统的各个硬盘分区的根目录;
S2,从根目录中过滤掉操作系统安装时所产生的根目录,得到目标根目录集合;
S3,从操作系统的默认程序安装目录和默认程序数据目录下的所有一级子目录中过滤掉操作系统安装时所产生的一级子目录,得到目标子目录集合;
S4,将目标根目录集合和目标子目录集合作为待检测目录。
通过将操作系统的各个硬盘分区的根目录划分为操作系统安装时所产生的根目录以及不是操作系统安装时所产生的根目录两类,并对两类文件进行不同处理,进而得到待检测目录,在全面对操作系统的各个硬盘分区的目录进行分析的同时,缩小分析范围,提高了待检测目录获取的可靠性和效率。
作为一种可选的实施例,在所述待检测目录中查找与预先获取到的特征库中的至少一条特征匹配的目标目录包括:
S1,将待检测目录中的当前目录与特征库中的当前特征中的软件目录特征进行匹配,其中,软件目录特征用于表示第一正则表达式或预先设置的软件安装目录的目录名;
S2,在当前目录与软件目录特征匹配成功的情况下,将当前目录作为一个目标目录。
通过待检测目录中的当前目录与特征库中的当前特征中的软件目录特征进行匹配的方式确定目标目录,并提供两种不同的软件目录特征,用于表示第一正则表达式或预先设置的软件安装目录的目录名,相比与相关技术中通过具体的单个特征进行检测的方式,目标目录的检测更加简便灵活,提高了检测效率。
可选地,在本实施例中,作为一种可选的实施方式,将待检测目录中的当前目录与特征库中的当前特征中的软件目录特征进行匹配包括:
S11,判断当前特征是否指示需要进行正则表达式匹配;
S12,在判断出当前特征指示需要进行正则表达式匹配时,判断当前目录的目录名是否满足软件目录特征所指示的第一正则表达式;在当前目录的目录名满足第一正则表达式的情况下,确定当前目录与软件目录特征匹配成功。
可选地,在本实施例中,作为另一种可选的实施方式,将待检测目录中的当前目录与特征库中的当前特征中的软件目录特征进行匹配包括:
S13,判断当前特征是否指示需要进行正则表达式匹配;
S14,在判断出当前特征指示不需要进行正则表达式匹配时,将当前目录的目录名与软件目录特征表示的软件安装目录的目录名进行字符串比较;在当前目录的目录名与软件安装目录的目录名两者的字符串相同的情况下,则确定当前目录与软件目录特征匹配成功。
通过对是否需要进行正则表达式匹配进行判断,并根据判断结果执行不同的匹配操作,可以根据需要选择完全匹配算法(特征匹配效率高)还是正则匹配算法(避免漏检)进行匹配,提高匹配的灵活性。
可选地,在本实施例中,作为一种可选地实施例,确定当前目录与软件目录特征匹配成功包括:
S3,判断当前特征是否指示需要对当前目录下的文件名进行正则表达式匹配;
S4,在判断出当前特征指示需要对当前目录下的文件名进行正则表达式匹配时,判断当前目录下的文件名是否存在第一目标文件名,其中,第一目标文件名满足当前特征中的文件名特征所指示的第二正则表达式;
S5,在判断出当前目录下的文件名存在第一目标文件名的情况下,确 定当前目录与软件目录特征匹配成功。
可选地,在本实施例中,作为另一种可选地实施例,确定当前目录与软件目录特征匹配成功包括:
S6,判断当前特征是否指示需要对当前目录下的文件名进行正则表达式匹配;
S7,在判断出当前特征指示不需要对当前目录下的文件名进行正则表达式匹配时,判断当前目录下的文件名是否存在第二目标文件名,其中,第二目标文件名的字符串与文件名特征表示的预先设置的文件名的字符串相同;
S8,在判断出当前目录下的文件名存在第二目标文件名的情况下,确定当前目录与软件目录特征匹配成功。
通过当前目录下的文件名对匹配结果进行校验,避免了匹配错误问题的发生,提高了当前目录与软件目录特征匹配的正确率。
作为一种可选的实施例,检测操作系统中与目标目录相对应的目标软件的软件信息包括:
S1,在预先从操作系统中扫描得到的软件衍生信息中查找与目标目录相对应的软件信息,其中,与目标目录相对应的软件信息包含目标目录,和/或,与目标目录相对应的软件信息所指向的目录包含目标目录;
S2,将查找到的软件信息作为目标软件的软件信息。
根据目标目录对预先从操作系统中扫描得到的软件衍生信息进行查找,获取目标软件的软件信息,由于是根据目标目录而不是具体的特征查找软件衍生信息,可以提高获取目标软件的软件信息的效率。
可选地,在本实施例中,在预先从操作系统中扫描得到的软件衍生信息中查找与目标目录相对应的软件信息包括以下至少之一:
S11,在预先从操作系统中扫描得到的快捷方式中查找目标快捷方式, 其中,目标快捷方式所指向的目录包含目标目录;
S12,在预先从操作系统中扫描得到的启动项信息中查找目标启动项信息,其中,目标启动项信息所指向的目录包含目标目录;
S13,在预先从操作系统中扫描得到的服务项中查找目标服务项,其中,目标服务项所指向的目录包含目标目录;
S14,在预先从操作系统中扫描得到的卸载注册信息中查找目标卸载注册信息,其中,目标卸载注册信息所指向的目录包含目标目录;
S15,在预先从操作系统中扫描得到的进程信息中查找目标进程信息,其中,目标进程信息包含目标目录;
可选地,在本实施例中,软件衍生信息可以包括:快捷方式、启动项信息、服务项、卸载注册信息、进程信息;与目标目录相对应的软件信息可以包括:目标快捷方式、目标启动项信息、目标服务项、目标卸载注册信息、目标进程信息。
分别对快捷方式、启动项信息、服务项、卸载注册信息、进程信息进行扫描,得到与目标目录相对应的软件信息,能够全面检测软件衍生物,检测特征高效且覆盖率广。
可选地,在本实施例中,在预先从所述操作系统中扫描得到的软件衍生信息中查找与所述目标目录相对应的软件信息之前,还包括:
S3,判断所述操作系统是否处于空闲状态;
S4,在判断出所述操作系统处于所述空闲状态时,对所述操作系统进行扫描,得到所述软件衍生信息。
在操作系统处于空闲状态时,对操作系统进行扫描,得到软件衍生信息,可以合理利用操作系统的资源,避免了由于对扫描操作系统导致的卡机等问题,提高了用户体验。
作为一种可选的实施例,在终端上显示检测到的目标软件的软件信息 之后,还包括:
S1,接收到删除指令;
S2,响应删除指令,在操作系统中删除目标软件的软件信息。
根据删除指令在操作系统中删除目标软件的软件信息,能够根据指示清除目标软件的软件信息,解除目标软件的软件信息对系统资源的占用,保证较高的清楚成功率。需要说明的是,对于前述的各方法实施例,为了简单描述,故将其都表述为一系列的动作组合,但是本领域技术人员应该知悉,本申请并不受所描述的动作顺序的限制,因为依据本申请,某些步骤可以采用其他顺序或者同时进行。其次,本领域技术人员也应该知悉,说明书中所描述的实施例均属于可选实施例,所涉及的动作和模块并不一定是本申请所必须的。
通过以上的实施方式的描述,本领域的技术人员可以清楚地了解到根据上述实施例的方法可借助软件加必需的通用硬件平台的方式来实现,当然也可以通过硬件,但很多情况下前者是更佳的实施方式。基于这样的理解,本申请的技术方案本质上或者说对相关技术做出贡献的部分可以以软件产品的形式体现出来,该计算机软件产品存储在一个存储介质(如ROM/RAM、磁碟、光盘)中,包括若干指令用以使得一台终端设备(可以是手机,计算机,服务器,或者网络设备等)执行本申请各个实施例所述的方法。
根据本申请实施例的另一方面,提供了一种可选的实施上述软件信息的处理方法的一种可选的具体应用。本申请实施例的应用环境可以但不限于参照上述实施例中的应用环境,本实施例中对此不再赘述。
本申请实施例中针对相关技术中对目标软件的软件信息进行处理时存在遗漏,在安全产品查杀功能中增加快速检测和清理推装软件的功能。由于互联网环境下会不断出现新的推装软件,因此本申请实施例不仅要考虑检测和清理推装软件的方式,而且也考虑相关技术方案的持续运营成本。 在向用户提供推装软件清理功能的同时,综合考虑特征配置成本,网络带宽,功能占用PC系统资源等因素,不降低产品查杀功能体验的同时,能持续性快速响应新出现的推装软件。
本申请实施例中所提供的安全产品,应用产品功能时,能够全面检测和清理推装软件衍生物,检测特征高效且覆盖广,清理效果彻底,能保证较高的清理成功率,切实降低PC机器安全风险,提升安全产品覆盖和解决安全问题的能力,同时可以主动在机器空闲时机检测系统中是否存在推装软件,如果发现主动向用户提示,优化用户体验。
本实施例中提供了一种用于实施上述软件信息的处理方法的安全产品。该安全产品不受操作系统版本,产品版本等限制,不仅可以在用户触发查杀类功能时,展示特征库与本地插件匹配结果。同时由于解决了原有技术方案效率低,消耗资源大的问题,也适合静默扫描后由产品主动向用户推送扫描结果,不需要用户参与即可主动提示安全风险。
图6是根据本申请实施例的一种可选的用户使用安全产品查杀功能时的流程图,如图6所示,该流程包括如下步骤:
步骤S602,接收使用查杀类功能的指示。
该指示可以由用户通过点击安全产品界面上相应的按钮进行触发。
步骤S604,扫描模块加载。
步骤S606,读取推广软件库。
推广软件库中的每条特征信息只包含文件衍生物。
步骤S608,检测目录特征。
步骤S610,判断所有软件特征是否检测完成,如果完成,执行步骤S612,否则,执行步骤S606。
步骤S612,在安全产品的查杀界面展示结果。
用户使用查杀功能完成时的安全产品提示界面如图7所示。
图8是根据本申请实施例的一种可选的安全产品静默扫描时的流程图,如图8所示,该流程包括如下步骤:
步骤S802,安全产品在机器闲时主动触发检测功能。
这里的机器,也就是安装有该安全产品或者通过云连接等方式与该安全产品相连的机器。
步骤S804,扫描模块加载。
步骤S806,读取推广软件库。
推广软件库中的每条特征信息只包含文件衍生物。
步骤S808,检测目录特征。
步骤S810,判断所有软件特征是否检测完成,如果完成,执行步骤S812,否则,执行步骤S806。
步骤S812,弹窗展示结果。
通过弹窗的方式向用户展示检测结果。
产品静默扫描完成时的提示页面可以如图9所示。
对于上述用户主动使用检测功能时检出推装软件的机器量和清理效果如图10所示。每日检出风险机器量(用户主动触发检测)约10w,处理成功率稳定在97.6%以上,其中,处理不成功主要是由于机器上存在其它推广源反复释放推装软件。
对于上述安全产品主动检测并提示检出推装软件的机器量和清理效果如图11所示。每日通过安全产品主动检测渠道发现存在推装软件的机器量平均超过50w,是用户触发检测场景(图10中所示的数据)的5倍,显示在新场景中的应用明显提升了安全产品推装软件检测效果。针对发现问题的机器主动弹窗的提示窗中,选择处理率平均约45%的,超越绝大部 分安全产品弹窗时用户处理率(安全产品其它类别弹窗中平均处理率约10%,绝大部分用户直接点“关闭”),显示用户对本功能接受度较高。处理成功率与用户主动触发场景同样较高,可以保证较佳的用户体验。
本实施例中所提供的安全产品可以使用快速灵活的脚本语言lua和常规C++语言进行功能开发,其中,C++语言负责开发底层接口代码和调度代码,lua语言负责开发扫描逻辑和清理逻辑代码。
安全产品的框架流程如图12所示,下面对该框架中的各个模块进行说明。
调度模块,设置为用户主动触发查杀功能或者产品自身自动触发时,检测系统环境和当前软件特征库是否最新,调度起数据更新模块和检测模块。
数据更新模块,触发时负责服务器拉取最新数据库,确保本功能运营效果实现按需实时下发最新库。
检测模块和清除模块,主要负责通过软件特征库对比本机安装软件,命中后清理软件及其所有衍生物。
上述安全产品主要体现在数据按需实时更新机制、检测模块和清除模块。其中检测模块逻辑用于执行上述实施例1中的各个方法步骤。
通过本申请实施例的上述安全产品,保证了清理软件效果的彻底性。过往技术依赖运营人员手工配置各类待删的软件衍生物,容易出现配置遗漏或者软件更新导致清理效果不佳。本申请实施例从技术角度能完全发现软件各类衍生物,而不需要依赖繁琐的人工配置。在极大降低了运营人员手工配置工作成本的同时,能确保清理软件功能的彻底性,给用户最佳的产品体验。同时,由于人工工作量的减少,从推装软件发现到响应时长可以直接提升到1分钟级别(提取特征+发布),紧急情况下甚至可以秒级响应,提高了推装软件响应的及时性。
本申请实施例中所提供的软件信息的处理方法,由于优化了匹配特征, 相当于降低了原有匹配技术的时间复杂度,在功能触发情况下减少用户占用的用户PC机器资源(cpu使用率,内存等),因此可以在安全产品中加入静默扫描并提示用户进行相应处理的功能(使用相关技术进行静默扫描用户会发现系统明显卡慢),极大扩展了清理软件功能场景的覆盖度。无需等到用户使用安全产品检测时再进行提醒,从而保证了相比其他安全产品能更早发现和提示用户机器中存在推装软件。
根据本申请实施例的又一方面,还提供了一种用于实施上述软件信息的处理方法的软件信息的检测装置。图13是根据本申请实施例的一种可选的软件信息的检测装置的示意图,如图13所示,该装置可以包括:
获取单元1302,设置为获取安装在终端上的操作系统中的待检测目录;
查找单元1304,设置为在所述待检测目录中查找与预先获取到的特征库中的至少一条特征匹配的目标目录;
检测单元1306,设置为在查找到所述目标目录的情况下,检测所述操作系统中与所述目标目录相对应的目标软件的软件信息;
显示单元1308,设置为在所述终端上显示检测到的所述目标软件的软件信息。
需要说明的是,该实施例中的获取单元1302可以设置为执行本申请实施例1中的步骤S202,该实施例中的查找单元1304可以设置为执行本申请实施例1中的步骤S204,该实施例中的检测单元1306可以设置为执行本申请实施例1中的步骤S206,该实施例中的显示单元1308可以设置为执行本申请实施例1中的步骤S208。
此处需要说明的是,上述模块与对应的步骤所实现的示例和应用场景相同,但不限于上述实施例1所公开的内容。需要说明的是,上述模块作为装置的一部分可以运行在如图1所示的硬件环境中,可以通过软件实现,也可以通过硬件实现。
通过上述模块,可以解决了对目标软件的软件信息进行处理时存在遗 漏的技术问题,进而达到了提高软件信息检测的准确性的技术效果。
可选地,在本实施例中,可以在检测到用户点击安全产品界面上的预设按键(例如,查杀等)时,也可以是在满足预设条件的情况下,触发安全产品静默扫描时,执行获取待检测目录的操作。这里的预设条件可以是预设时间条件,也可以是预设事件条件。预设时间条件可以是具体的时刻或者时间段,(例如,XXXX年XX月XX日21:00),也可以是周期的时刻或者时间段(例如,每天21:00,每周日21:00)。预设事件条件可以是CPU的占用率低于预定值(例如,30%),具体地获取操作的触发条件,可以根据需要设定,在此不做具体限定。
可选地,在本实施例中,在获取安装在终端上的操作系统中的待检测目录时,可以采用多种方式获取待检测目录。例如,可以获取操作系统的各个硬盘分区中的根目录集合和各级子目录集合,将获取的所有目录集合(根目录集合和各级子目录集合)作为待检测目录。
可选地,在本实施例中,可以获取操作系统的各个硬盘分区的根目录;从根目录中过滤掉操作系统安装时所产生的根目录(例如,C:\WINDOWS),得到目标根目录集合;从操作系统的默认程序安装目录和默认程序数据目录下的所有一级子目录中过滤掉操作系统安装时所产生的一级子目录,得到目标子目录集合;将目标根目录集合和目标子目录集合作为待检测目录。待检测目录为进行软件信息检测的目录。
可选地,可以采用枚举的方式枚举出系统中常见安装位置下所有子目录信息,作为待检测目录:
1)枚举硬盘各分区根目录位置下的所有子目录信息,过滤掉操作系统自带目录后记录剩余目录信息。
2)枚举默认程序安装目录(例如,x:\program files),默认程序数据目录(%appdata%)等其它常见软件安装位置下的所有子目录信息,同样过滤操作系统自带目录后记剩余子目录为待检查目录。
将上述1)和2)中确定的所有待核查目录作为待检测目录。
可选地,在本实施例中,特征库中包含有至少一个的特征。特征库中包含的特征用于对目标目录进行匹配,可以采用逐条匹配的方式对待检测目录中的各个目录进行匹配。例如,可以逐条选择待检测目录中的目录,依次与特征库中包含的特征进行比较,确定两者是否匹配。
在进行匹配时,将待检测目录中的当前目录与特征库中的当前特征中的软件目录特征进行匹配。如果当前目录与软件目录特征匹配成功,则将当前目录作为一个目标目录。
软件目录特征用于表示第一正则表达式或预先设置的软件安装目录的目录名(例如,软件安装目录为C:\program files\software install,则软件安装目录的目录名为software install)。在软件目录特征用于表示第一正则表达式时,表示该软件目录特征中可以包含正则表达式类通配符。例如,软件目录特征为“eprjacy+正则表达式类通配符”,该正则表达式类通配符表示目录中的此处可以为任意字符。如果当前目录的目录名为“eprjacya”,则两者可以匹配成功。
可选地,在本实施例中,预先设置的软件安装目录可以在进行软件信息检测前由用户预先设置。在设置软件安装目录时,可以通过界面交互的方式提示用户进行设置。如果用户未进行设置,可以采用默认值进行设置。
可选地,在本实施例中,可以通过对当前目录下的文件名进行匹配的方式对匹配成功的当前目录进行校验。采用字符串匹配或者正则表达式匹配的方式对当前目录下的文件名进行匹配。例如,可以在当前目录的目录名满足第一正则表达式的情况下,或者,在当前目录的目录名与软件安装目录的目录名两者的字符串相同的情况下,判断当前特征是否指示需要对当前目录下的文件名进行正则表达式匹配。根据不同的判断结果,执行不同的操作:
在判断出当前特征指示需要对当前目录下的文件名进行正则表达式 匹配时,判断当前目录下的文件名是否存在第一目标文件名,其中,第一目标文件名满足当前特征中的文件名特征所指示的第二正则表达式;在判断出当前目录下的文件名存在第一目标文件名的情况下,确定当前目录与软件目录特征匹配成功;
在判断出当前特征指示不需要对当前目录下的文件名进行正则表达式匹配时,判断当前目录下的文件名是否存在第二目标文件名,其中,第二目标文件名的字符串与文件名特征表示的预先设置的文件名的字符串相同;在判断出当前目录下的文件名存在第二目标文件名的情况下,确定当前目录与软件目录特征匹配成功。
可选地,在本实施例中,在查找到目标目录的情况下,检测操作系统中与目标目录相对应的目标软件的软件信息,其中,查找到的目标目录可以有一个或者多个。
与目标目录相对应的目标软件可能为恶评软件,恶评软件可能被静默安装在用户终端中的推装软件。与目标目录相对应的目标软件的软件信息可以包括目标软件的软件衍生物。
在进行操作系统中与目标目录相对应的目标软件的软件信息检测时,可以在预先从操作系统中扫描得到的软件衍生信息中查找与目标目录相对应的软件信息,将查找到的软件信息作为目标软件的软件信息。其中,与目标目录相对应的软件信息可以包含目标目录,或者,与目标目录相对应的软件信息(例如,快捷方式)所指向的目录包含目标目录,在软件衍生信息为多个的情况下,可以既有包含目标目录的软件信息,又有所指向的目录包含目标目录的与目标目录相对应的软件信息。
可选地,在本实施例中,软件衍生信息可以包括以下至少之一:快捷方式、启动项信息、服务项、卸载注册信息、进程信息;相应地,与目标目录相对应的软件信息可以包括以下至少之一:目标快捷方式、目标启动项信息、目标服务项、目标卸载注册信息、目标进程信息。
可选地,在本实施例中,可以依次从预先从操作系统中扫描得到的快捷方式、预先从操作系统中扫描得到的启动项信息、预先从操作系统中扫描得到的服务项、预先从操作系统中扫描得到的卸载注册信息和预先从操作系统中扫描得到的进程信息中查找与目标目录相对应的软件信息。
在具体实施时,可以分别通过如下步骤进行查找:
1)在预先从操作系统中扫描得到的快捷方式中查找目标快捷方式,其中,目标快捷方式所指向的目录包含目标目录;
2)在预先从操作系统中扫描得到的启动项信息中查找目标启动项信息,其中,目标启动项信息所指向的目录包含目标目录;
3)在预先从操作系统中扫描得到的服务项中查找目标服务项,其中,目标服务项所指向的目录包含目标目录;
4)在预先从操作系统中扫描得到的卸载注册信息中查找目标卸载注册信息,其中,目标卸载注册信息所指向的目录包含目标目录;
5)在预先从操作系统中扫描得到的进程信息中查找目标进程信息,其中,目标进程信息包含目标目录。
上述查找的顺序以及查找的软件衍生信息的种类可以根据需要进行设定,在本实施例中对此不做具体限定。
可选地,在本实施例中,可以在操作系统处于空闲状态时,对操作系统进行扫描,得到软件衍生信息,得到的该软件衍生信息在查找与目标目录相对应的软件信息使使用。例如,可以首先判断操作系统是否处于空闲状态(例如,CPU占用小于或者等于预设CPU占用阈值时,确定操作系统处于空闲状态);在判断出操作系统处于空闲状态时,对操作系统进行扫描,得到软件衍生信息。
可选地,在本实施例中,在终端上显示检测到的目标软件的软件信息,其中,显示的软件信息可以包括软件名。
可选地,在实施例中,可以在安全产品的界面上向用户展示扫描结果,用户选择处理后,依次处理所有软件衍生物,可以包括:
1)结束进程;
2)停用、删除服务,驱动项;
3)删除软件卸载注册信息;
4)删除软件启动项;
5)删除软件产生的桌面快捷方式;
6)删除软件所有子文件及安装目录;
7)提示用户重启系统,在重启系统过程中再次删除驱动,子文件等关键信息,确保清理成功。
可选地,在本实施例中,待检测目录、目标目录、根目录、一级子目录等中的目录,也可以表述为文件夹或者文件的地址、路径等,本领域技术人员应当理解,上述术语只是表述方式的不同,其具体指代的内容是一致的。
作为一种可选的实施例,所述获取单元1302包括:
获取模块,设置为获取操作系统的各个硬盘分区的根目录;
第一过滤模块,设置为从根目录中过滤掉操作系统安装时所产生的根目录,得到目标根目录集合;
第二过滤模块,设置为从操作系统的默认程序安装目录和默认程序数据目录下的所有一级子目录中过滤掉操作系统安装时所产生的一级子目录,得到目标子目录集合;
获取单元1302,还设置为将目标根目录集合和目标子目录集合作为待检测目录。
通过将操作系统的各个硬盘分区的根目录划分为操作系统安装时所 产生的根目录以及不是操作系统安装时所产生的根目录两类,并对两类文件进行不同处理,进而得到待检测目录,在全面对操作系统的各个硬盘分区的目录进行分析的同时,缩小分析范围,提高了待检测目录获取的可靠性和效率。
作为一种可选的实施例,查找单元1304包括:第一匹配模块,其中,
第一匹配模块,设置为将待检测目录中的当前目录与特征库中的当前特征中的软件目录特征进行匹配,其中,软件目录特征用于表示第一正则表达式或预先设置的软件安装目录的目录名;
查找单元1304,还设置为在当前目录与软件目录特征匹配成功的情况下,将当前目录作为一个目标目录。
通过待检测目录中的当前目录与特征库中的当前特征中的软件目录特征进行匹配的方式确定目标目录,并提供两种不同的软件目录特征,用于表示第一正则表达式或预先设置的软件安装目录的目录名,相比与相关技术中通过具体的单个特征进行检测的方式,目标目录的检测更加简便灵活,提高了检测效率。
可选地,在本实施例中,第一匹配模块,还设置为判断当前特征是否指示需要进行正则表达式匹配;在判断出当前特征指示需要进行正则表达式匹配时,判断当前目录的目录名是否满足软件目录特征所指示的第一正则表达式;在当前目录的目录名满足第一正则表达式的情况下,确定当前目录与软件目录特征匹配成功。
可选地,在本实施例中,第一匹配模块,还设置为判断当前特征是否指示需要进行正则表达式匹配;在判断出当前特征指示需要进行正则表达式匹配时,判断当前目录的目录名是否满足软件目录特征所指示的第一正则表达式;在判断出当前特征指示不需要进行正则表达式匹配时,将当前目录的目录名与软件目录特征表示的软件安装目录的目录名进行字符串比较;在当前目录的目录名与软件安装目录的目录名两者的字符串相同的 情况下,则确定当前目录与软件目录特征匹配成功。
通过对是否需要进行正则表达式匹配进行判断,并根据判断结果执行不同的匹配操作,可以根据需要选择完全匹配算法(特征匹配效率高)还是正则匹配算法(避免漏检)进行匹配,提高匹配的灵活性。
可选地,在本实施例中,作为一种可选的实施方式,第一匹配模块包括:
第一判断子模块,设置为判断当前特征是否指示需要对当前目录下的文件名进行正则表达式匹配;
第二判断子模块,设置为在判断出当前特征指示需要对当前目录下的文件名进行正则表达式匹配时,判断当前目录下的文件名是否存在第一目标文件名,其中,第一目标文件名满足当前特征中的文件名特征所指示的第二正则表达式;
第一确定子模块,设置为在判断出当前目录下的文件名存在第一目标文件名的情况下,确定当前目录与软件目录特征匹配成功。
可选地,在本实施例中,作为另一种可选的实施方式,第一匹配模块包括:
第三判断子模块,设置为判断当前特征是否指示需要对当前目录下的文件名进行正则表达式匹配;
第四判断子模块,设置为在判断出当前特征指示不需要对当前目录下的文件名进行正则表达式匹配时,判断当前目录下的文件名是否存在第二目标文件名,其中,第二目标文件名的字符串与文件名特征表示的预先设置的文件名的字符串相同;
第二确定子模块,设置为在判断出当前目录下的文件名存在第二目标文件名的情况下,确定当前目录与软件目录特征匹配成功。
通过当前目录下的文件名对匹配结果进行校验,避免了匹配错误问题 的发生,提高了当前目录与软件目录特征匹配的正确率。
作为一种可选的实施例,检测单元1306包括:查找模块,其中,
查找模块,设置为在预先从操作系统中扫描得到的软件衍生信息中查找与目标目录相对应的软件信息,其中,与目标目录相对应的软件信息包含目标目录,和/或,与目标目录相对应的软件信息所指向的目录包含目标目录;
检测单元,还设置为将查找到的软件信息作为目标软件的软件信息。
根据目标目录对预先从操作系统中扫描得到的软件衍生信息进行查找,获取目标软件的软件信息,由于是根据目标目录而不是具体的特征查找软件衍生信息,可以提高获取目标软件的软件信息的效率。
可选地,在本实施例中,查找模块包括以下至少之一:
第一查找子模块,设置为在预先从操作系统中扫描得到的快捷方式中查找目标快捷方式,其中,目标快捷方式所指向的目录包含目标目录;
第二查找子模块,设置为在预先从操作系统中扫描得到的启动项信息中查找目标启动项信息,其中,目标启动项信息所指向的目录包含目标目录;
第三查找子模块,设置为在预先从操作系统中扫描得到的服务项中查找目标服务项,其中,目标服务项所指向的目录包含目标目录;
第四查找子模块,设置为在预先从操作系统中扫描得到的卸载注册信息中查找目标卸载注册信息,其中,目标卸载注册信息所指向的目录包含目标目录;
第五查找子模块,设置为在预先从操作系统中扫描得到的进程信息中查找目标进程信息,其中,目标进程信息包含目标目录;
可选地,在本实施例中,软件衍生信息包括:快捷方式、启动项信息、服务项、卸载注册信息、进程信息;与目标目录相对应的软件信息包括: 目标快捷方式、目标启动项信息、目标服务项、目标卸载注册信息、目标进程信息。
分别对快捷方式、启动项信息、服务项、卸载注册信息、进程信息进行扫描,得到与目标目录相对应的软件信息,能够全面检测软件衍生物,检测特征高效且覆盖率广。
可选地,在本实施例中,该装置还包括:
判断单元,设置为判断所述操作系统是否处于空闲状态;
扫描单元,设置为在判断出所述操作系统处于所述空闲状态时,对所述操作系统进行扫描,得到所述软件衍生信息。
在操作系统处于空闲状态时,对操作系统进行扫描,得到软件衍生信息,可以合理利用操作系统的资源,避免了由于对扫描操作系统导致的卡机等问题,提高了用户体验。
作为一种可选的实施例,所述装置还包括:
接收单元,设置为在所述终端上显示检测到的所述目标软件的软件信息之后,接收到删除指令;
删除单元,设置为响应删除指令,在操作系统中删除目标软件的软件信息。
根据删除指令在操作系统中删除目标软件的软件信息,能够根据指示清除目标软件的软件信息,解除目标软件的软件信息对系统资源的占用,保证较高的清楚成功率。
此处需要说明的是,上述模块与对应的步骤所实现的示例和应用场景相同,但不限于上述实施例1所公开的内容。需要说明的是,上述模块作为装置的一部分可以运行在如图1所示的硬件环境中,可以通过软件实现,也可以通过硬件实现,其中,硬件环境包括网络环境。
根据本申请实施例的又一方面,还提供了一种用于实施上述软件信息 的处理方法的电子装置。如图14所示,该电子装置可以包括:一个或多个(图中仅示出一个)处理器1402、存储器1404、传输装置1406以及输入输出设备1408。
其中,存储器1404可设置为存储软件程序以及模块,如本申请实施例中的软件信息的处理方法和装置对应的程序指令/模块,处理器1402通过运行存储在存储器1404内的软件程序以及模块,从而执行各种功能应用以及数据处理,即实现上述的软件信息的处理方法。存储器1404可包括高速随机存储器,还可以包括非易失性存储器,如一个或者多个磁性存储装置、闪存、或者其他非易失性固态存储器。在一些实例中,存储器1404可包括相对于处理器1402远程设置的存储器,这些远程存储器可以通过网络连接至终端。上述网络的实例包括但不限于互联网、企业内部网、局域网、移动通信网及其组合。
上述的传输装置1406设置为经由一个网络接收或者发送数据,还可以设置为处理器与存储器之间的数据传输。上述的网络具体实例可包括有线网络及无线网络。在一个实例中,传输装置1406包括一个网络适配器(Network Interface Controller,NIC),其可通过网线与其他网络设备与路由器相连从而可与互联网或局域网进行通讯。在一个实例中,传输装置1406为射频(Radio Frequency,RF)模块,其用于通过无线方式与互联网进行通讯。
其中,可选地,存储器1404设置为存储应用程序。
处理器1402可以通过传输装置1406调用存储器1404存储的应用程序,以执行下述步骤:
获取安装在终端上的操作系统中的待检测目录;
在待检测目录中查找与预先获取到的特征库中的至少一条特征匹配的目标目录;
在查找到目标目录的情况下,检测操作系统中与目标目录相对应的目 标软件的软件信息;
在终端上显示检测到的目标软件的软件信息。
处理器1402还设置为执行下述步骤:获取安装在终端上的操作系统中的待检测目录包括:获取操作系统的各个硬盘分区的根目录;从根目录中过滤掉操作系统安装时所产生的根目录,得到目标根目录集合;从操作系统的默认程序安装目录和默认程序数据目录下的所有一级子目录中过滤掉操作系统安装时所产生的一级子目录,得到目标子目录集合;将目标根目录集合和目标子目录集合作为待检测目录。
处理器1402还设置为执行下述步骤:在待检测目录中查找与预先获取到的特征库中的至少一条特征匹配的目标目录包括:将待检测目录中的当前目录与特征库中的当前特征中的软件目录特征进行匹配,其中,软件目录特征用于表示第一正则表达式或预先设置的软件安装目录的目录名;在当前目录与软件目录特征匹配成功的情况下,将当前目录作为一个目标目录。
处理器1402还设置为执行下述步骤:将待检测目录中的当前目录与特征库中的当前特征中的软件目录特征进行匹配包括:判断当前特征是否指示需要进行正则表达式匹配;在判断出当前特征指示需要进行正则表达式匹配时,判断当前目录的目录名是否满足软件目录特征所指示的第一正则表达式;在当前目录的目录名满足第一正则表达式的情况下,确定当前目录与软件目录特征匹配成功。
处理器1402还设置为执行下述步骤:将待检测目录中的当前目录与特征库中的当前特征中的软件目录特征进行匹配包括:判断当前特征是否指示需要进行正则表达式匹配;在判断出当前特征指示不需要进行正则表达式匹配时,将当前目录的目录名与软件目录特征表示的软件安装目录的目录名进行字符串比较;在当前目录的目录名与软件安装目录的目录名两者的字符串相同的情况下,则确定当前目录与软件目录特征匹配成功。
处理器1402还设置为执行下述步骤:判断当前特征是否指示需要对当前目录下的文件名进行正则表达式匹配;在判断出当前特征指示需要对当前目录下的文件名进行正则表达式匹配时,判断当前目录下的文件名是否存在第一目标文件名,其中,第一目标文件名满足当前特征中的文件名特征所指示的第二正则表达式;在判断出当前目录下的文件名存在第一目标文件名的情况下,确定当前目录与软件目录特征匹配成功;
处理器1402还设置为执行下述步骤:判断当前特征是否指示需要对当前目录下的文件名进行正则表达式匹配;在判断出当前特征指示不需要对当前目录下的文件名进行正则表达式匹配时,判断当前目录下的文件名是否存在第二目标文件名,其中,第二目标文件名的字符串与文件名特征表示的预先设置的文件名的字符串相同;在判断出当前目录下的文件名存在第二目标文件名的情况下,确定当前目录与软件目录特征匹配成功。
处理器1402还设置为执行下述步骤:检测操作系统中与目标目录相对应的目标软件的软件信息包括:在预先从操作系统中扫描得到的软件衍生信息中查找与目标目录相对应的软件信息,其中,与目标目录相对应的软件信息包含目标目录,和/或,与目标目录相对应的软件信息所指向的目录包含目标目录;将查找到的软件信息作为目标软件的软件信息。
处理器1402还设置为执行下述步骤:在预先从操作系统中扫描得到的软件衍生信息中查找与目标目录相对应的软件信息包括以下至少之一:在预先从操作系统中扫描得到的快捷方式中查找目标快捷方式,其中,目标快捷方式所指向的目录包含目标目录;在预先从操作系统中扫描得到的启动项信息中查找目标启动项信息,其中,目标启动项信息所指向的目录包含目标目录;在预先从操作系统中扫描得到的服务项中查找目标服务项,其中,目标服务项所指向的目录包含目标目录;在预先从操作系统中扫描得到的卸载注册信息中查找目标卸载注册信息,其中,目标卸载注册信息所指向的目录包含目标目录;在预先从操作系统中扫描得到的进程信息中查找目标进程信息,其中,目标进程信息包含目标目录。
处理器1402还设置为执行下述步骤:在预先从操作系统中扫描得到的软件衍生信息中查找与目标目录相对应的软件信息之前,还包括:判断操作系统是否处于空闲状态;在判断出操作系统处于空闲状态时,对操作系统进行扫描,得到软件衍生信息。
处理器1402还设置为执行下述步骤:在终端上显示检测到的目标软件的软件信息之后,还包括:接收到删除指令;响应删除指令,在操作系统中删除目标软件的软件信息。
采用本申请实施例,提供了一种软件信息的检测方案。通过在待检测目录中查找与预先获取到的特征库中的至少一条特征匹配的目标目录,检测操作系统中与查找到的目标目录相对应的目标软件的软件信息,并将检测到的目标软件的软件信息在终端上显示,,达到了对软件信息的全面检测的目的,从而实现了提高软件信息检测的准确性的技术效果,进而解决了对目标软件的软件信息进行处理时存在遗漏的技术问题。
可选地,本实施例中的具体示例可以参考上述实施例1和实施例2中所描述的示例,本实施例在此不再赘述。
本领域普通技术人员可以理解,图14所示的结构仅为示意,终端可以是智能手机(如Android手机、iOS手机等)、平板电脑、掌上电脑以及移动互联网设备(Mobile Internet Devices,MID)、PAD等终端设备。图14其并不对上述电子装置的结构造成限定。例如,终端还可包括比图14中所示更多或者更少的组件(如网络接口、显示装置等),或者具有与图14所示不同的配置。
本领域普通技术人员可以理解上述实施例的各种方法中的全部或部分步骤是可以通过程序来指令终端设备相关的硬件来完成,该程序可以存储于一计算机可读存储介质中,存储介质可以包括:闪存盘、只读存储器(Read-Only Memory,ROM)、随机存取器(Random Access Memory,RAM)、磁盘或光盘等。
根据本申请的实施例的又一方面,还提供了一种存储介质,该存储介质中存储有计算机程序,其中,该计算机程序被设置为运行时执行上述任一项方法实施例中的步骤。
可选地,在本实施例中,上述存储介质可以位于上述实施例所示的网络中的多个网络设备中的至少一个网络设备上。
可选地,在本实施例中,存储介质被设置为存储用于执行以下步骤的计算机程序:
S1,获取安装在终端上的操作系统中的待检测目录;
S2,在待检测目录中查找与预先获取到的特征库中的至少一条特征匹配的目标目录;
S3,在查找到目标目录的情况下,检测操作系统中与目标目录相对应的目标软件的软件信息;
S4,在终端上显示检测到的目标软件的软件信息。
可选地,存储介质还被设置为存储用于执行以下步骤的计算机程序:
获取安装在终端上的操作系统中的待检测目录包括:
S1,获取操作系统的各个硬盘分区的根目录;
S2,从根目录中过滤掉操作系统安装时所产生的根目录,得到目标根目录集合;
S3,从操作系统的默认程序安装目录和默认程序数据目录下的所有一级子目录中过滤掉操作系统安装时所产生的一级子目录,得到目标子目录集合;
S4,将目标根目录集合和目标子目录集合作为待检测目录。
可选地,存储介质还被设置为存储用于执行以下步骤的计算机程序:
在待检测目录中查找与预先获取到的特征库中的至少一条特征匹配 的目标目录包括:
S1,将待检测目录中的当前目录与特征库中的当前特征中的软件目录特征进行匹配,其中,软件目录特征用于表示第一正则表达式或预先设置的软件安装目录的目录名;
S2,在当前目录与软件目录特征匹配成功的情况下,将当前目录作为一个目标目录。
可选地,存储介质还被设置为存储用于执行以下步骤的计算机程序:
将待检测目录中的当前目录与特征库中的当前特征中的软件目录特征进行匹配包括:
S1,判断当前特征是否指示需要进行正则表达式匹配;
S2,在判断出当前特征指示需要进行正则表达式匹配时,判断当前目录的目录名是否满足软件目录特征所指示的第一正则表达式;在当前目录的目录名满足第一正则表达式的情况下,确定当前目录与软件目录特征匹配成功。
可选地,存储介质还被设置为存储用于执行以下步骤的计算机程序:
将待检测目录中的当前目录与特征库中的当前特征中的软件目录特征进行匹配包括:
S1,判断当前特征是否指示需要进行正则表达式匹配;
S2,在判断出当前特征指示不需要进行正则表达式匹配时,将当前目录的目录名与软件目录特征表示的软件安装目录的目录名进行字符串比较;
S3,在当前目录的目录名与软件安装目录的目录名两者的字符串相同的情况下,则确定当前目录与软件目录特征匹配成功。
可选地,存储介质还被设置为存储用于执行以下步骤的计算机程序:
确定当前目录与软件目录特征匹配成功包括:
S1,判断当前特征是否指示需要对当前目录下的文件名进行正则表达式匹配;
S2,在判断出当前特征指示需要对当前目录下的文件名进行正则表达式匹配时,判断当前目录下的文件名是否存在第一目标文件名,其中,第一目标文件名满足当前特征中的文件名特征所指示的第二正则表达式;
S3,在判断出当前目录下的文件名存在第一目标文件名的情况下,确定当前目录与软件目录特征匹配成功。
可选地,存储介质还被设置为存储用于执行以下步骤的计算机程序:
确定当前目录与软件目录特征匹配成功包括:
S1,判断当前特征是否指示需要对当前目录下的文件名进行正则表达式匹配;
S2,在判断出当前特征指示不需要对当前目录下的文件名进行正则表达式匹配时,判断当前目录下的文件名是否存在第二目标文件名,其中,第二目标文件名的字符串与文件名特征表示的预先设置的文件名的字符串相同;
S3,在判断出当前目录下的文件名存在第二目标文件名的情况下,确定当前目录与软件目录特征匹配成功。
可选地,存储介质还被设置为存储用于执行以下步骤的计算机程序:
检测操作系统中与目标目录相对应的目标软件的软件信息包括:
S1,在预先从操作系统中扫描得到的软件衍生信息中查找与目标目录相对应的软件信息,其中,与目标目录相对应的软件信息包含目标目录,和/或,与目标目录相对应的软件信息所指向的目录包含目标目录;
S2,将查找到的软件信息作为目标软件的软件信息。
可选地,存储介质还被设置为存储用于执行以下步骤的计算机程序:
在预先从操作系统中扫描得到的软件衍生信息中查找与目标目录相对应的软件信息包括以下至少之一:
S1,在预先从操作系统中扫描得到的快捷方式中查找目标快捷方式,其中,目标快捷方式所指向的目录包含目标目录;
S2,在预先从操作系统中扫描得到的启动项信息中查找目标启动项信息,其中,目标启动项信息所指向的目录包含目标目录;
S3,在预先从操作系统中扫描得到的服务项中查找目标服务项,其中,目标服务项所指向的目录包含目标目录;
S4,在预先从操作系统中扫描得到的卸载注册信息中查找目标卸载注册信息,其中,目标卸载注册信息所指向的目录包含目标目录;
S5,在预先从操作系统中扫描得到的进程信息中查找目标进程信息,其中,目标进程信息包含目标目录。
可选地,存储介质还被设置为存储用于执行以下步骤的计算机程序:
在预先从操作系统中扫描得到的软件衍生信息中查找与目标目录相对应的软件信息之前,还包括:
S1,判断操作系统是否处于空闲状态;
S2,在判断出操作系统处于空闲状态时,对操作系统进行扫描,得到软件衍生信息。
可选地,存储介质还被设置为存储用于执行以下步骤的计算机程序:
在终端上显示检测到的目标软件的软件信息之后,还包括:
S1,接收到删除指令;
S2,响应删除指令,在操作系统中删除目标软件的软件信息。
可选地,本实施例中的具体示例可以参考上述实施例1和实施例2中所描述的示例,本实施例在此不再赘述。
可选地,在本实施例中,上述存储介质可以包括但不限于:U盘、只读存储器(ROM,Read-Only Memory)、随机存取存储器(RAM,Random Access Memory)、移动硬盘、磁碟或者光盘等各种可以存储计算机程序的介质。
上述本申请实施例序号仅仅为了描述,不代表实施例的优劣。
上述实施例中的集成的单元如果以软件功能单元的形式实现并作为独立的产品销售或使用时,可以存储在上述计算机可读取的存储介质中。基于这样的理解,本申请的技术方案本质上或者说对相关技术做出贡献的部分或者该技术方案的全部或部分可以以软件产品的形式体现出来,该计算机软件产品存储在存储介质中,包括若干指令用以使得一台或多台计算机设备(可为个人计算机、服务器或者网络设备等)执行本申请各个实施例所述方法的全部或部分步骤。
在本申请的上述实施例中,对各个实施例的描述都各有侧重,某个实施例中没有详述的部分,可以参见其他实施例的相关描述。
在本申请所提供的几个实施例中,应该理解到,所揭露的客户端,可通过其它的方式实现。其中,以上所描述的装置实施例仅仅是示意性的,例如所述单元的划分,仅仅为一种逻辑功能划分,实际实现时可以有另外的划分方式,例如多个单元或组件可以结合或者可以集成到另一个系统,或一些特征可以忽略,或不执行。另一点,所显示或讨论的相互之间的耦合或直接耦合或通信连接可以是通过一些接口,单元或模块的间接耦合或通信连接,可以是电性或其它的形式。
所述作为分离部件说明的单元可以是或者也可以不是物理上分开的,作为单元显示的部件可以是或者也可以不是物理单元,即可以位于一个地方,或者也可以分布到多个网络单元上。可以根据实际的需要选择其中的 部分或者全部单元来实现本实施例方案的目的。
另外,在本申请各个实施例中的各功能单元可以集成在一个处理单元中,也可以是各个单元单独物理存在,也可以两个或两个以上单元集成在一个单元中。上述集成的单元既可以采用硬件的形式实现,也可以采用软件功能单元的形式实现。
以上所述仅是本申请的可选实施方式,应当指出,对于本技术领域的普通技术人员来说,在不脱离本申请原理的前提下,还可以做出若干改进和润饰,这些改进和润饰也应视为本申请的保护范围。
工业实用性
在本申请实施例中,采用特征库中的特征对待检测目录中的目标目录进行匹配的方式,通过在待检测目录中查找与预先获取到的特征库中的至少一条特征匹配的目标目录,检测操作系统中与查找到的目标目录相对应的目标软件的软件信息,并将检测到的目标软件的软件信息在终端上显示,由于采用特征库中的特征与待检测目录中的目录进行匹配,避免了配置不完整或者出现的新衍生物尚不存在配置列表的情况导致的漏检问题,达到了对软件信息的全面检测的目的,实现了提高软件信息检测的准确性的技术效果。

Claims (24)

  1. 一种软件信息的处理方法,包括:
    获取安装在终端上的操作系统中的待检测目录;
    在所述待检测目录中查找与预先获取到的特征库中的至少一条特征匹配的目标目录;
    在查找到所述目标目录的情况下,检测所述操作系统中与所述目标目录相对应的目标软件的软件信息;
    在所述终端上显示检测到的所述目标软件的软件信息。
  2. 根据权利要求1所述的方法,其中,所述获取安装在终端上的操作系统中的待检测目录包括:
    获取所述操作系统的各个硬盘分区的根目录;
    从所述根目录中过滤掉所述操作系统安装时所产生的根目录,得到目标根目录集合;
    从所述操作系统的默认程序安装目录和默认程序数据目录下的所有一级子目录中过滤掉所述操作系统安装时所产生的一级子目录,得到目标子目录集合;
    将所述目标根目录集合和所述目标子目录集合作为所述待检测目录。
  3. 根据权利要求1所述的方法,其中,在所述待检测目录中查找与预先获取到的特征库中的至少一条特征匹配的目标目录包括:
    将所述待检测目录中的当前目录与所述特征库中的当前特征中的软件目录特征进行匹配,其中,所述软件目录特征用于表示第一正则表达式或预先设置的软件安装目录的目录名;
    在所述当前目录与所述软件目录特征匹配成功的情况下,将所述当前目录作为一个所述目标目录。
  4. 根据权利要求3所述的方法,其中,所述将所述待检测目录中的当前 目录与所述特征库中的当前特征中的软件目录特征进行匹配包括:
    判断所述当前特征是否指示需要进行正则表达式匹配;
    在判断出所述当前特征指示需要进行正则表达式匹配时,判断所述当前目录的目录名是否满足所述软件目录特征所指示的所述第一正则表达式;
    在所述当前目录的目录名满足所述第一正则表达式的情况下,确定所述当前目录与所述软件目录特征匹配成功。
  5. 根据权利要求3所述的方法,其中,所述将所述待检测目录中的当前目录与所述特征库中的当前特征中的软件目录特征进行匹配包括:
    判断所述当前特征是否指示需要进行正则表达式匹配;
    在判断出所述当前特征指示不需要进行正则表达式匹配时,将所述当前目录的目录名与所述软件目录特征表示的所述软件安装目录的目录名进行字符串比较;
    在所述当前目录的目录名与所述软件安装目录的目录名两者的字符串相同的情况下,则确定所述当前目录与所述软件目录特征匹配成功。
  6. 根据权利要求4或5所述的方法,其中,确定所述当前目录与所述软件目录特征匹配成功包括:
    判断所述当前特征是否指示需要对所述当前目录下的文件名进行正则表达式匹配;
    在判断出所述当前特征指示需要对所述当前目录下的文件名进行正则表达式匹配时,判断所述当前目录下的文件名是否存在第一目标文件名,其中,所述第一目标文件名满足所述当前特征中的文件名特征所指示的第二正则表达式;
    在判断出所述当前目录下的文件名存在所述第一目标文件名的情况下,确定所述当前目录与所述软件目录特征匹配成功。
  7. 根据权利要求4或5所述的方法,其中,确定所述当前目录与所述软 件目录特征匹配成功包括:
    判断所述当前特征是否指示需要对所述当前目录下的文件名进行正则表达式匹配;
    在判断出所述当前特征指示不需要对所述当前目录下的文件名进行正则表达式匹配时,判断所述当前目录下的文件名是否存在第二目标文件名,其中,所述第二目标文件名的字符串与所述文件名特征表示的所述预先设置的文件名的字符串相同;
    在判断出所述当前目录下的文件名存在所述第二目标文件名的情况下,确定所述当前目录与所述软件目录特征匹配成功。
  8. 根据权利要求1所述的方法,其中,所述检测所述操作系统中与所述目标目录相对应的目标软件的软件信息包括:
    在预先从所述操作系统中扫描得到的软件衍生信息中查找与所述目标目录相对应的软件信息,其中,所述与所述目标目录相对应的软件信息包含所述目标目录,和/或,所述与所述目标目录相对应的软件信息所指向的目录包含所述目标目录;
    将查找到的软件信息作为所述目标软件的软件信息。
  9. 根据权利要求8所述的方法,其中,在预先从所述操作系统中扫描得到的软件衍生信息中查找与所述目标目录相对应的软件信息包括以下至少之一:
    在预先从所述操作系统中扫描得到的快捷方式中查找目标快捷方式,其中,所述目标快捷方式所指向的目录包含所述目标目录;
    在预先从所述操作系统中扫描得到的启动项信息中查找目标启动项信息,其中,所述目标启动项信息所指向的目录包含所述目标目录;
    在预先从所述操作系统中扫描得到的服务项中查找目标服务项,其中,所述目标服务项所指向的目录包含所述目标目录;
    在预先从所述操作系统中扫描得到的卸载注册信息中查找目标 卸载注册信息,其中,所述目标卸载注册信息所指向的目录包含所述目标目录;
    在预先从所述操作系统中扫描得到的进程信息中查找目标进程信息,其中,所述目标进程信息包含所述目标目录。
  10. 根据权利要求8所述的方法,其中,在预先从所述操作系统中扫描得到的软件衍生信息中查找与所述目标目录相对应的软件信息之前,还包括:
    判断所述操作系统是否处于空闲状态;
    在判断出所述操作系统处于所述空闲状态时,对所述操作系统进行扫描,得到所述软件衍生信息。
  11. 根据权利要求1至5中任一项所述的方法,其中,在所述终端上显示检测到的所述目标软件的软件信息之后,还包括:
    接收到删除指令;
    响应所述删除指令,在所述操作系统中删除所述目标软件的软件信息。
  12. 一种软件信息的处理装置,包括:
    获取单元,设置为获取安装在终端上的操作系统中的待检测目录;
    查找单元,设置为在所述待检测目录中查找与预先获取到的特征库中的至少一条特征匹配的目标目录;
    检测单元,设置为在查找到所述目标目录的情况下,检测所述操作系统中与所述目标目录相对应的目标软件的软件信息;
    显示单元,设置为在所述终端上显示检测到的所述目标软件的软件信息。
  13. 根据权利要求12所述的装置,其中,所述获取单元包括:
    获取模块,设置为获取所述操作系统的各个硬盘分区的根目录;
    第一过滤模块,设置为从所述根目录中过滤掉所述操作系统安装 时所产生的根目录,得到目标根目录集合;
    第二过滤模块,设置为从所述操作系统的默认程序安装目录和默认程序数据目录下的所有一级子目录中过滤掉所述操作系统安装时所产生的一级子目录,得到目标子目录集合;
    所述获取单元,还设置为将所述目标根目录集合和所述目标子目录集合作为所述待检测目录。
  14. 根据权利要求12所述的装置,其中,所述查找单元包括:第一匹配模块,其中,
    第一匹配模块,设置为将所述待检测目录中的当前目录与所述特征库中的当前特征中的软件目录特征进行匹配,其中,所述软件目录特征用于表示第一正则表达式或预先设置的软件安装目录的目录名;
    所述查找单元,还设置为在所述当前目录与所述软件目录特征匹配成功的情况下,将所述当前目录作为一个所述目标目录。
  15. 根据权利要求14所述的装置,其中,所述第一匹配模块,还设置为判断所述当前特征是否指示需要进行正则表达式匹配;在判断出所述当前特征指示需要进行正则表达式匹配时,判断所述当前目录的目录名是否满足所述软件目录特征所指示的所述第一正则表达式;在所述当前目录的目录名满足所述第一正则表达式的情况下,确定所述当前目录与所述软件目录特征匹配成功。
  16. 根据权利要求14所述的装置,其中,所述第一匹配模块,还设置为判断所述当前特征是否指示需要进行正则表达式匹配;在判断出所述当前特征指示需要进行正则表达式匹配时,判断所述当前目录的目录名是否满足所述软件目录特征所指示的所述第一正则表达式;在判断出所述当前特征指示不需要进行正则表达式匹配时,将所述当前目录的目录名与所述软件目录特征表示的所述软件安装目录的目录名进行字符串比较;在所述当前目录的目录名与所述软件安装目录的目录名两者的字符串相同的情况下,则确定所述当前目录与所述软件目录 特征匹配成功。
  17. 根据权利要求15或者16所述的装置,其中,所述第一匹配模块包括:
    第一判断子模块,设置为判断所述当前特征是否指示需要对所述当前目录下的文件名进行正则表达式匹配;
    第二判断子模块,设置为在判断出所述当前特征指示需要对所述当前目录下的文件名进行正则表达式匹配时,判断所述当前目录下的文件名是否存在第一目标文件名,其中,所述第一目标文件名满足所述当前特征中的文件名特征所指示的第二正则表达式;
    第一确定子模块,设置为在判断出所述当前目录下的文件名存在所述第一目标文件名的情况下,确定所述当前目录与所述软件目录特征匹配成功。
  18. 根据权利要求15或者16所述的装置,其中,所述第一匹配模块包括:
    第三判断子模块,设置为判断所述当前特征是否指示需要对所述当前目录下的文件名进行正则表达式匹配;
    第四判断子模块,设置为在判断出所述当前特征指示不需要对所述当前目录下的文件名进行正则表达式匹配时,判断所述当前目录下的文件名是否存在第二目标文件名,其中,所述第二目标文件名的字符串与所述文件名特征表示的所述预先设置的文件名的字符串相同;
    第二确定子模块,设置为在判断出所述当前目录下的文件名存在所述第二目标文件名的情况下,确定所述当前目录与所述软件目录特征匹配成功。
  19. 根据权利要求12所述的装置,其中,所述检测单元包括:
    查找模块,设置为在预先从所述操作系统中扫描得到的软件衍生信息中查找与所述目标目录相对应的软件信息,其中,所述与所述目标目录相对应的软件信息包含所述目标目录,和/或,所述与所述目标目录相对应的软件信息所指向的目录包含所述目标目录;
    所述检测单元,还设置为将查找到的软件信息作为所述目标软件 的软件信息。
  20. 根据权利要求19所述的装置,其中,所述查找模块包括以下至少之一:
    第一查找子模块,设置为在预先从所述操作系统中扫描得到的快捷方式中查找目标快捷方式,其中,所述目标快捷方式所指向的目录包含所述目标目录;
    第二查找子模块,设置为在预先从所述操作系统中扫描得到的启动项信息中查找目标启动项信息,其中,所述目标启动项信息所指向的目录包含所述目标目录;
    第三查找子模块,设置为在预先从所述操作系统中扫描得到的服务项中查找目标服务项,其中,所述目标服务项所指向的目录包含所述目标目录;
    第四查找子模块,设置为在预先从所述操作系统中扫描得到的卸载注册信息中查找目标卸载注册信息,其中,所述目标卸载注册信息所指向的目录包含所述目标目录;
    第五查找子模块,设置为在预先从所述操作系统中扫描得到的进程信息中查找目标进程信息,其中,所述目标进程信息包含所述目标目录。
  21. 根据权利要求19所述的装置,其中,所述装置还包括:
    判断单元,设置为在预先从所述操作系统中扫描得到的软件衍生信息中查找与所述目标目录相对应的软件信息之前,判断所述操作系统是否处于空闲状态;
    扫描单元,设置为在判断出所述操作系统处于所述空闲状态时,对所述操作系统进行扫描,得到所述软件衍生信息。
  22. 根据权利要求12至16中任一项所述的装置,其中,所述装置还包括:
    接收单元,设置为在所述终端上显示检测到的所述目标软件的软件信息之后,接收到删除指令;
    删除单元,设置为响应所述删除指令,在所述操作系统中删除所述目标软件的软件信息。
  23. 一种存储介质,所述存储介质中存储有计算机程序,其中,所述计算机程序被设置为运行时执行所述权利要求1至11任一项中所述的方法。
  24. 一种电子装置,包括存储器和处理器,其中,所述存储器中存储有计算机程序,所述处理器被设置为通过所述计算机程序执行所述权利要求1至11任一项中所述的方法。
PCT/CN2017/118035 2016-12-30 2017-12-22 软件信息的处理方法和装置及存储介质、电子装置 WO2018121442A1 (zh)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201611260594.5 2016-12-30
CN201611260594.5A CN106874366B (zh) 2016-12-30 2016-12-30 软件信息的处理方法及装置

Publications (1)

Publication Number Publication Date
WO2018121442A1 true WO2018121442A1 (zh) 2018-07-05

Family

ID=59164178

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2017/118035 WO2018121442A1 (zh) 2016-12-30 2017-12-22 软件信息的处理方法和装置及存储介质、电子装置

Country Status (2)

Country Link
CN (1) CN106874366B (zh)
WO (1) WO2018121442A1 (zh)

Cited By (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109800131A (zh) * 2018-12-18 2019-05-24 平安健康保险股份有限公司 Linux服务器的监控处理方法、装置、计算机设备和存储介质
CN110764789A (zh) * 2019-10-09 2020-02-07 Oppo(重庆)智能科技有限公司 工序管控方法、装置、存储介质及电子设备
CN111078481A (zh) * 2019-12-19 2020-04-28 哈尔滨安天科技集团股份有限公司 获取配置检查清单的方法、装置、电子设备及存储介质
CN111695113A (zh) * 2020-06-01 2020-09-22 南方电网数字电网研究院有限公司 终端软件安装合规性检测方法、装置和计算机设备
CN111722974A (zh) * 2019-03-21 2020-09-29 阿里巴巴集团控股有限公司 日志信息的采集方法及装置、计算机设备
CN117077207A (zh) * 2023-09-01 2023-11-17 广州世安智慧科技有限公司 一种敏感信息检测方法及系统
CN117234945A (zh) * 2023-11-10 2023-12-15 英诺达(成都)电子科技有限公司 测试思维导图的展示方法、装置、电子设备和存储介质

Families Citing this family (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN106874366B (zh) * 2016-12-30 2020-06-02 腾讯科技(深圳)有限公司 软件信息的处理方法及装置
CN108664609B (zh) * 2018-05-10 2021-04-30 中国银行股份有限公司 一种数据共享的方法、网络设备及终端
CN114679410B (zh) * 2020-12-24 2024-04-12 奇安信网神信息技术(北京)股份有限公司 降低对外网资源占用的方法、装置、电子设备和存储介质

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20140324788A1 (en) * 2013-04-24 2014-10-30 Piriform Ltd. Cleaner with browser monitoring
CN104156414A (zh) * 2014-07-30 2014-11-19 珠海市君天电子科技有限公司 一种垃圾文件的清理方法、装置及终端
CN104317840A (zh) * 2014-10-10 2015-01-28 北京金山安全软件有限公司 一种文件清理方法、装置及终端
CN106874366A (zh) * 2016-12-30 2017-06-20 腾讯科技(深圳)有限公司 软件信息的处理方法及装置

Family Cites Families (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7725727B2 (en) * 2005-06-01 2010-05-25 International Business Machines Corporation Automatic signature generation for content recognition
CN102880713B (zh) * 2012-09-29 2016-08-03 北京奇虎科技有限公司 文件清理方法及装置
CN103831049B (zh) * 2014-01-10 2016-01-20 黑龙江省畜牧机械化研究所 异型搅龙鼓式混合机
CN104881495B (zh) * 2015-06-15 2019-03-26 北京金山安全软件有限公司 一种文件夹路径识别及文件夹清理方法及装置

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20140324788A1 (en) * 2013-04-24 2014-10-30 Piriform Ltd. Cleaner with browser monitoring
CN104156414A (zh) * 2014-07-30 2014-11-19 珠海市君天电子科技有限公司 一种垃圾文件的清理方法、装置及终端
CN104317840A (zh) * 2014-10-10 2015-01-28 北京金山安全软件有限公司 一种文件清理方法、装置及终端
CN106874366A (zh) * 2016-12-30 2017-06-20 腾讯科技(深圳)有限公司 软件信息的处理方法及装置

Cited By (11)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109800131A (zh) * 2018-12-18 2019-05-24 平安健康保险股份有限公司 Linux服务器的监控处理方法、装置、计算机设备和存储介质
CN109800131B (zh) * 2018-12-18 2024-04-05 平安健康保险股份有限公司 Linux服务器的监控处理方法、装置、计算机设备和存储介质
CN111722974A (zh) * 2019-03-21 2020-09-29 阿里巴巴集团控股有限公司 日志信息的采集方法及装置、计算机设备
CN110764789A (zh) * 2019-10-09 2020-02-07 Oppo(重庆)智能科技有限公司 工序管控方法、装置、存储介质及电子设备
CN111078481A (zh) * 2019-12-19 2020-04-28 哈尔滨安天科技集团股份有限公司 获取配置检查清单的方法、装置、电子设备及存储介质
CN111078481B (zh) * 2019-12-19 2023-12-26 安天科技集团股份有限公司 获取配置检查清单的方法、装置、电子设备及存储介质
CN111695113A (zh) * 2020-06-01 2020-09-22 南方电网数字电网研究院有限公司 终端软件安装合规性检测方法、装置和计算机设备
CN111695113B (zh) * 2020-06-01 2023-12-05 南方电网数字平台科技(广东)有限公司 终端软件安装合规性检测方法、装置和计算机设备
CN117077207A (zh) * 2023-09-01 2023-11-17 广州世安智慧科技有限公司 一种敏感信息检测方法及系统
CN117234945A (zh) * 2023-11-10 2023-12-15 英诺达(成都)电子科技有限公司 测试思维导图的展示方法、装置、电子设备和存储介质
CN117234945B (zh) * 2023-11-10 2024-01-30 英诺达(成都)电子科技有限公司 测试思维导图的展示方法、装置、电子设备和存储介质

Also Published As

Publication number Publication date
CN106874366B (zh) 2020-06-02
CN106874366A (zh) 2017-06-20

Similar Documents

Publication Publication Date Title
WO2018121442A1 (zh) 软件信息的处理方法和装置及存储介质、电子装置
CN106708557B (zh) 一种针对终端应用的更新处理方法及装置
US10303773B2 (en) Chatbot system and method
US10192053B2 (en) Method, apparatus, system, device and computer storage medium for treating virus
US20150331882A1 (en) Redundant file deletion method, apparatus and storage medium
US9690562B2 (en) Detecting computing processes requiring reinitialization after a software package update
Moser et al. Hunting in the enterprise: Forensic triage and incident response
CN106709341B (zh) 一种针对文件包的病毒处理方法及装置
CN103631628B (zh) 软件清理方法和系统
SG182486A1 (en) Method, system and server for collecting version of software
CN107992429B (zh) 一种内存对象引用关系确定方法及装置
US20200175165A1 (en) Endpoint detection and response attack process tree auto-play
EP3113060B1 (en) Method and apparatus for determining behaviour information corresponding to dangerous file
CN112099757A (zh) 一种应用保活的方法以及装置
US9910662B2 (en) Selectively migrating applications during an operating system upgrade
US20160277477A1 (en) Information processing apparatus, terminal device, information processing method, and non-transitory computer readable recording medium
CN107766068B (zh) 应用系统补丁安装方法、装置、计算机设备和存储介质
CN113094248A (zh) 用户行为数据分析方法、装置、电子设备及介质
CN106156210B (zh) 一种确定应用标识匹配列表的方法和装置
WO2014161328A1 (zh) 一种应用程序显示方法、装置及一种终端
CN108121545B (zh) 应用程序的卸载反馈方法及装置
US9910667B2 (en) Segregating a monolithic computing system into multiple attachable application containers based on application boundaries
US20210049274A1 (en) Analysis device, analysis method, and recording medium
US20180060052A1 (en) Using machine learning to optimize minimal sets of an application
CN112148545A (zh) 嵌入式系统的安全基线检测方法以及安全基线检测系统

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 17886932

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 17886932

Country of ref document: EP

Kind code of ref document: A1