Encryption system, encryption device, encryption method, and program
The encryption system addresses the need for range-indicating information in log data encryption by controlling acquisition, encryption, and storage to reduce computing load and ensure confidentiality through partial encryption.
Patent Information
- Application Number
- JP2024505796
- Authority / Receiving Office
- JP · JP
- Patent Type
- Patents
- Current Assignee / Owner
- Filing Date
- 2022-03-11
- Publication Date
- 2025-11-26
- Estimated Expiration
- 2042-03-11
Smart Images

Figure 0007776175000001 
Figure 0007776175000002 
Figure 0007776175000003
Abstract
Description
[Technical Field]
[0001] The present disclosure relates to an encryption system, an encryption device, an encryption method, and a program. [Background technology]
[0002] The amount of log data is increasing due to the recent advances in functionality in various types of devices. In addition, depending on the type of device and the information handled, it is necessary to maintain confidentiality when collecting log data.
[0003] For example, Patent Document 1 describes a log collection system that aims to collect log information without using dedicated tools or a dedicated user interface, while preventing information leakage to third parties. The log collection system includes a formatting unit, a log acquisition unit, an encryption unit, and a log writing unit. The formatting unit formats external media from and to which information can be read and written, by including a public key in the volume label. The log acquisition unit acquires log information when the external media is connected. The encryption unit encrypts the acquired log information with the public key included in the volume label. The log writing unit writes the encrypted log information to the external media.
[0004] Furthermore, in order to collect log data while maintaining confidentiality, it is also possible to employ a method of encrypting the data on a file-by-file basis, unlike the technology described in Patent Document 1. However, such a method poses the risk of monopolizing the computing resources of the device and increasing the load on the device during operation. For this reason, a method has been proposed that reduces the load on computing resources by encrypting the data partially.
[0005] Furthermore, Patent Document 2 describes a packet communication method that is adapted to high-speed lines by eliminating the need for processing using a complex encryption algorithm, suppresses deterioration in transmission efficiency due to redundant bits, and enables data confidentiality using a simple method. The packet communication method is a packet communication method for preventing eavesdropping and tampering of data during bit-synchronized data communication, and includes an inserting step, a reception disabling step, and a reception enabling step. The inserting step artificially inserts a synchronization flag sequence indicating the start and end of a frame, which is a unit of transmitted data, so that the frame length in packet communication is equal to or shorter than a minimum frame length. The reception disabling step causes an unauthorized receiving side to discard frames shorter than the minimum frame length as short frames, thereby disabling reception by unauthorized parties attempting to eavesdrop or tamper. The reception enabling step allows an authorized receiving side to delete the artificially inserted synchronization flag sequence and receive frames shorter than the minimum frame length as regular frames.
[0006] Patent Document 3 describes a data encryption method that does not require adding encryption functions to existing WWW (World Wide Web) servers or WWW browsers. The data encryption method performs data processing, including encryption processing, on encryption target data, in accordance with an instruction that specifies a data processing method, including an encryption processing method. The data encryption method encrypts the range specified by the encryption range specification instruction for encryption target data, in which an encryption range specification instruction that specifies the range to be encrypted is specified.
[0007] Patent Document 4 describes a log recording device that aims to achieve both confidentiality of user data and fault analysis. The log recording device includes a CDB (Command Description Block) determination means, a first encryption means, and a log output means. The CDB determination means determines whether a SCSI request in the input SCSI (Small Computer System Interface) log data is related to user data or not based on CDB determination information. The first encryption means encrypts, based on an encryption key, a portion of the SCSI request that the CDB determination means determines is a SCSI request related to user data. The log output means formats the SCSI request that the CDB determination means determines is not related to user data and the SCSI request with the encrypted portion including the user data from the first encryption means, and outputs the resulting format as an analytical log file. [Prior art documents] [Patent documents]
[0008] [Patent Document 1] Japanese Patent Application Laid-Open No. 2017-215853 [Patent Document 2] Japanese Patent Application Publication No. 11-215190 [Patent Document 3] Japanese Patent Application Publication No. 11-215122 [Patent Document 4] Japanese Patent Application Publication No. 2019-097028 Summary of the Invention [Problem to be solved by the invention]
[0009] However, in the technology described in Patent Document 2, in order to ensure data confidentiality, it is necessary to insert a synchronization flag sequence even when all of the log data of the device is encrypted.
[0010] Furthermore, in the technology described in Patent Document 3, not only when the data to be encrypted includes both encrypted and unencrypted portions, but also when it includes only encrypted portions, the data is output as a single encrypted data with a decryption range designation command embedded. Therefore, even if the technology described in Patent Document 3 is applied to the encryption of device log data, a single encrypted file with a decryption range designation command embedded will be output even when all of the log data is encrypted.
[0011] Furthermore, the technology described in Patent Document 4 also outputs a file that contains both encrypted and unencrypted parts as a single file, so in order to decrypt it, information indicating that it has been encrypted is required, even if the file is completely encrypted.
[0012] The present disclosure has been made to solve the above-mentioned problems, and aims to provide an encryption system etc. that, when specifying the range to be encrypted and encrypting the log data of a device, can avoid the need for information indicating the range even when encrypting the entire range. [Means for solving the problem]
[0013] In a first aspect, the encryption system includes an acquisition unit that acquires log data, an encryption unit that encrypts the log data, a reception unit that receives an instruction to specify the range of encryption to be performed by the encryption unit before starting to acquire the log data, a memory unit that stores the log data, and a control unit that controls, based on the range, the timing of the acquisition of log data by the acquisition unit, the start and end positions of encryption by the encryption unit, and the storage of log data by the memory unit, wherein the control unit controls the encryption unit to perform encryption by inserting a start flag that indicates the start position and an end flag that indicates the end position, respectively, at the start and end positions indicated by the range, and when the entire range of log data is specified as the range, controls the encryption unit to perform encryption without controlling to insert the start flag and the end flag, and stores the encrypted data for the portion of log data that falls within the range and the plain text data for the portion of log data that does not fall within the range in the memory unit, each as separate files.
[0014] In a second aspect, an encryption device includes an acquisition unit that acquires log data, an encryption unit that encrypts the log data, an acceptance unit that accepts an instruction to specify the range of encryption to be performed by the encryption unit before starting to acquire the log data, a memory unit that stores the log data, and a control unit that controls, based on the range, the timing of acquisition of log data by the acquisition unit, the start and end positions of encryption by the encryption unit, and the storage of log data by the memory unit, wherein the control unit controls the encryption unit to perform encryption by inserting a start flag that indicates the start position and an end flag that indicates the end position, respectively, at the start and end positions indicated by the range, and when the entire range of log data is specified as the range, controls the encryption unit to perform encryption without controlling to insert the start flag and the end flag, and stores the encrypted data for the part of log data that falls within the range and the plain text data for the part of log data that does not fall within the range in the memory unit, each as separate files.
[0015] In a third aspect, an encryption method includes acquiring log data, encrypting the log data, accepting an instruction specifying a range for encryption before starting to acquire the log data, storing the log data, and controlling, based on the range, the timing of acquiring the log data, the start and end positions of encryption, and storing the log data, wherein the controlling includes inserting a start flag that indicates the start position and an end flag that indicates the end position at the start and end positions indicated by the range, respectively, to perform encryption, and when the entire range of the log data is specified as the range, performing encryption without inserting the start flag and the end flag, and storing, as separate files, the encrypted data for the portion of the log data that falls within the range and the plaintext data for the portion of the log data that does not fall within the range.
[0016] In a fourth aspect, the program is a program for causing a computer to execute encryption processing, and the computer-readable medium stores the program. The encryption processing includes acquiring log data, encrypting the log data, accepting an instruction specifying a range for encryption before starting acquisition of the log data, storing the log data, and controlling, based on the range, the timing of log data acquisition, the start and end positions of encryption, and storing the log data, wherein the controlling includes inserting a start flag that indicates the start position and an end flag that indicates the end position at the start and end positions indicated by the range, respectively, to execute encryption, and, when the entire range of log data is specified as the range, executing encryption without inserting the start flag and the end flag, and storing, as separate files, the encrypted data for the portion of log data that falls within the range and the plaintext data for the portion of log data that does not fall within the range. [Effects of the Invention]
[0017] The present disclosure makes it possible to provide an encryption system, etc., which, when encrypting log data of a device by specifying the range to be encrypted, can avoid the need for information indicating the range even when encrypting the entire range. [Brief explanation of the drawings]
[0018] [Figure 1] 1 is a block diagram showing an example of the configuration of an encryption system according to a first embodiment. [Figure 2] 2 is a block diagram showing an encryption device as an example of the configuration of the encryption system of FIG. 1. FIG. [Figure 3] 3 is a flow diagram for explaining an example of an encryption method in the encryption system of FIG. 1 or the encryption device of FIG. 2. FIG. [Figure 4] FIG. 10 is a block diagram showing an example of the configuration of an encryption system according to a second embodiment. [Figure 5] FIG. 5 is a diagram showing an example of a log acquisition command that is accepted as an instruction in the encryption system of FIG. [Figure 6] 5 is a flow diagram for explaining an example of processing in a target device in the encryption system of FIG. 4. FIG. [Figure 7] This is a flow chart continuing from FIG. [Figure 8] FIG. 5 is a sequence diagram showing an example of the overall processing in the encryption system of FIG. [Figure 9] This is a sequence diagram continuing from FIG. 8. [Figure 10] FIG. 11 is a flowchart illustrating an example of processing in a target device in an encryption system according to a third embodiment. [Figure 11] FIG. 2 illustrates an example of a hardware configuration of the apparatus. DETAILED DESCRIPTION OF THE INVENTION
[0019] Hereinafter, embodiments will be described with reference to the drawings. In the embodiments, identical or equivalent elements are given the same reference numerals, and duplicated explanations may be omitted. In the following drawings, identical and similar elements are given the same reference numerals, and duplicated explanations may be omitted as necessary.
[0020] <Embodiment 1> FIG. 1 is a block diagram showing an example of the configuration of an encryption system according to the first embodiment. As shown in Fig. 1, an encryption system 1 according to this embodiment may include an acquisition unit 1a, an encryption unit 1b, a reception unit 1c, a storage unit 1d, and a control unit 1e. The encryption system 1 includes a device from which log data is to be collected (hereinafter referred to as a target device) and a log collection device that collects logs from the target device, and collects various log data from the target device. Therefore, the encryption system 1 may be referred to as a log collection system.
[0021] The type of target device does not matter as long as it is a device that can record logs. The log collection device can be installed in the same location as the target device and directly connected, or it can be installed in a remote location from the target device and connected via a network.
[0022] In the encryption system 1, the target device can be provided with an acquisition unit 1a, an encryption unit 1b, a reception unit 1c, a storage unit 1d, and a control unit 1e, but is not limited to this; for example, a recording medium as one element of the storage unit 1d can be provided in an external device connected to the target device. The storage unit 1d and the recording medium will be described later.
[0023] Furthermore, the target device may have its functions distributed among multiple devices, and in this case, the method of distributing the acquisition unit 1a, encryption unit 1b, reception unit 1c, storage unit 1d, and control unit 1e is not limited. For example, each device may have the functions of the encryption unit 1b and storage unit 1d, and one of the devices may have the acquisition unit 1a, reception unit 1c, and control unit 1e.
[0024] The acquisition unit 1a acquires log data from the target device. The method for acquiring the log data does not matter, and it can acquire log data of a type and period that is predetermined or included in an instruction described below, for example. The encryption unit 1b encrypts the log data acquired by the acquisition unit 1a. However, as described below, the encryption unit 1b encrypts a specified range of the log data and does not encrypt log data outside that range. Furthermore, the encryption method used by the encryption unit 1b does not matter, as long as the encrypted data can be decrypted.
[0025] Before the acquisition unit 1a starts acquiring log data, the reception unit 1c receives an instruction specifying the scope of encryption to be performed by the encryption unit 1b. This instruction may be transmitted from a log collection device connected to the target device via a network, P2P, or the like. Therefore, the reception unit 1c may include a communication unit (not shown) that communicates with the log collection device. This communication unit may include an interface for communicating with the outside world wirelessly or via a wired connection. However, the functions of the log collection device may also be provided in the target device. In this case, the encryption system 1 is configured in the target device, and the above instruction is also received from an operation unit or the like provided in the target device.
[0026] The storage unit 1d stores encrypted log data and plaintext log data. The storage unit 1d can be a storage device that includes a recording medium and a writing unit that writes data to the recording medium. The type of recording medium is not important.
[0027] Based on the range, the control unit 1e controls the timing of acquisition of log data by the acquisition unit 1a, the start and end positions of encryption by the encryption unit 1b, and the storage of log data by the storage unit 1d.
[0028] The control unit 1e controls the encryption unit 1b to insert a start flag indicating the start position and an end flag indicating the end position into the start position and end position indicated by the range accepted by the acceptance unit 1c, respectively, and perform encryption. At this time, the control unit 1e also controls the acquisition unit 1a to acquire log data based on the above range. In this way, the encryption system 1 can perform partial encryption of log data.
[0029] Then, the control unit 1e stores the encrypted data for the log data that falls within the above range, and the plain text data for the log data that does not fall within the above range, in the memory unit 1d, each as a separate file (separate log file).
[0030] In particular, in this embodiment, when the entire range of log data is specified as the range, the control unit 1e controls the encryption unit 1b to perform encryption without inserting a start flag and an end flag. As a result, when the entire range of log data is encrypted, a start flag and an end flag are not inserted, and a log file that does not include a start flag and an end flag is stored in the storage unit 1d.
[0031] The control unit 1e can be realized by, for example, a CPU (Central Processing Unit), a working memory, and a non-volatile storage device storing a program. This program can be a program that causes the CPU to execute the processes of the acquisition unit 1a, the encryption unit 1b, the reception unit 1c, and the writing unit of the storage unit 1d. Furthermore, the recording medium of the storage device provided in the control unit 1e can also be used as the recording medium of the storage unit 1d.
[0032] The target device may also include a transmitter that, in response to an instruction received by the receiver 1c, transmits a file (log file) stored in the memory 1d to the log collecting device, which is the instructing device that sent the instruction. This transmitter may utilize a communication unit provided in the receiver 1c. In this way, the target device includes the encryption unit 1b, the receiver 1c, the memory 1d, and a transmitter that transmits the log file stored in the memory 1d to the log collecting device, and may be a device from which log data is collected.
[0033] In this example, the log collection device is a device that transmits instructions received by the reception unit 1c to the reception unit 1c. Although not shown, the log collection device may include a control unit that controls the entire device and a communication unit that communicates with the target device. This communication unit may include an interface for wireless or wired communication with the outside. The log collection device may also be configured to receive log files stored in the memory unit 1d via the communication unit. The control unit of the log collection device may be realized, for example, by a CPU, working memory, and a non-volatile storage device that stores a program. This program may be a program that causes the CPU to execute a process of generating instructions to be sent to the reception unit 1c and a process of sending the instructions to the target device via the communication unit. Note that the recording medium of the storage device provided in the control unit of the log collection device may also be used as a recording medium for storing the log files received in this manner.
[0034] Furthermore, as exemplified by the log collection device and the target device, the encryption system 1 can also be configured as multiple devices with distributed functions, and the functions of each unit exemplified as the target device can also be configured by distributing them across multiple devices, and the method of distribution does not matter. When constructing the encryption system 1 with distributed functions across multiple devices, each device should be equipped with a control unit, a communication unit, and, if necessary, a memory unit, etc., and the multiple devices should be connected via wireless or wired communication as necessary to cooperate and realize the functions of the encryption system 1.
[0035] Furthermore, as shown in FIG. 2, the encryption system 1 can also be constructed as a single encryption device 2 including an acquisition unit 1a, an encryption unit 1b, a reception unit 1c, a storage unit 1d, and a control unit 1e. FIG. 2 is a block diagram showing the encryption device 2, which is an example configuration of the encryption system 1 of FIG. 1. The encryption device 2 can be a device having the functions of the target device described above, or a device having the functions of the target device and the functions of a log collection device. The encryption device 2 can be configured to include a computer device including hardware including, for example, one or more processors and one or more memories. At least a portion of the functions of each unit in the encryption device 2 can be realized by one or more processors operating in accordance with a program read from one or more memories.
[0036] Next, an example of processing by the encryption system 1 or the encryption device 2 will be described with reference to Fig. 3. Fig. 3 is a flow diagram for explaining an example of an encryption method in the encryption system 1 or the encryption device 2. The encryption method in the encryption system 1 will be described below, but the encryption method in the encryption device 2 is also similar.
[0037] First, before starting to acquire log data, the encryption system 1 receives an instruction specifying the range to be encrypted (step S1). Based on this instruction, the encryption system 1 acquires the log data (step S2). Next, the encryption system 1 determines whether the instruction indicates that the entire range should be encrypted (step S3).
[0038] If the answer is YES in step S3, the encryption system 1 performs encryption on the entire range of log data without inserting a start flag or an end flag, i.e., without going through step S5 (described later) (step S6), and stores the encrypted log data as a single log file (step S7).
[0039] On the other hand, if the result of step S3 is NO, the log data acquired in step S2 is determined to be within the above range (step S4). Then, for the log data determined to be YES in step S4, i.e., the log data that falls within the above range, the encryption system 1 inserts a start flag and an end flag at the start position and end position, respectively, of the log data within the above range (step S5). Thereafter, the encryption system 1 executes encryption (step S6). Thereafter, the process similarly proceeds to step S7, where the encrypted log data is stored as a single log file.
[0040] On the other hand, for log data determined as NO in step S4, that is, log data that does not fall within the above range, the encryption system 1 stores the data in plain text as one file (step S8).
[0041] The timing of acquiring the log data in step S2 does not matter in the order shown in the figure, as long as it is before encryption if the data is to be encrypted, or before storing the log file (step S8) if the data is in plain text.
[0042] The encryptable log collection process according to this embodiment has been described. In this embodiment, the decryption method for the encrypted log file is not important. The encrypted log file stored in this embodiment can be viewed by employing a decryption method corresponding to the encryption method. Furthermore, in this embodiment, the log file that is completely encrypted does not have a start flag or an end flag, but this log file can be viewed by employing a general-purpose decryption method. Furthermore, the plaintext log file stored in this embodiment is a separate file from the encrypted log file, and therefore can be viewed as is.
[0043] As described above, according to this embodiment, when collecting logs from a target device, instead of encrypting all of the log data, partial encryption is used to hide only confidential information, and only the information that can be provided can be made public by storing it in a plaintext log file. For example, partial encryption makes it possible to immediately identify publicly available information in the log, such as time information, making it possible to quickly check the log when a problem occurs. Furthermore, since this embodiment is configured so that it is possible to select whether or not to encrypt the data, it is possible to collect logs without the hassle of decryption even when encryption is not required, such as during in-house testing or debugging.
[0044] Furthermore, according to this embodiment, when collecting logs from the target device, the log data can be partially encrypted, thereby reducing the time that CPU resources are occupied by encryption and the load on the target device.
[0045] For example, if a failure occurs in a target device making it difficult to obtain log data remotely, the log data must be collected on-site, and this work may be outsourced to a third party. Even in such a case, according to this embodiment, confidentiality can be ensured only for the necessary parts while reducing the load on the target device, making it impossible for third parties to read the log file and eliminating the risk of information leakage. In this way, according to this embodiment, when collecting logs on-site or remotely from a target device, the contents of the log file can be collected safely without being viewed by third parties.
[0046] In particular, according to this embodiment, when encrypting device log data by specifying the range to be encrypted, it is possible to avoid the need for information indicating the range even when encrypting the entire range. In other words, according to this embodiment, when encrypting the entire range, encryption is possible without a start flag and an end flag, and the encrypted and unencrypted portions can be saved in separate files. Therefore, according to this embodiment, the amount of data can be reduced by not inserting a flag when encrypting the entire range, and the necessary confidentiality can be ensured by encrypting the necessary portions even when viewing the file.
[0047] <Embodiment 2> The second embodiment will be described with reference to Figures 4 to 9, focusing on the differences from the first embodiment, but the various examples described in the first embodiment can also be applied. First, an example of the configuration of an encryption system according to this embodiment will be described with reference to Figures 4 and 5. Figure 4 is a block diagram showing an example of the configuration of an encryption system according to the second embodiment, and Figure 5 is a diagram showing an example of a log acquisition command accepted as an instruction in this encryption system.
[0048] 4 (hereinafter referred to as the present system) can include a target device 10 that functions as the encryption device according to the present embodiment, and a log collection device 20 that collects log files from the target device 10. As described in the first embodiment, the log collection device 20 may encrypt and collect log files at the installation location of the target device 10, or may perform the encryption and collection from a target device 10 that is remotely connected.
[0049] For simplicity of explanation, an example will be given in which the system includes one target device 10. However, the system can also be configured to include multiple target devices 10 for one log collection device 20, with the log collection device 20 sending instructions to each of the multiple target devices 10 and collecting log files from each of them.
[0050] The log collection device 20 can include a control unit 21, an operation unit 22, a storage unit 23, and a communication unit 24. The log collection device 20 can be configured as a single device or a distributed device.
[0051] The control unit 21 is a control unit that controls the entire log collection device 20. The control unit 21 can be realized by, for example, a CPU, a working memory, and a non-volatile storage device that stores a program. This program can include a program that causes the CPU to execute processing for log acquisition. The storage device provided in the control unit 21 can also be used as the storage unit 23, which will be described later.
[0052] The operation unit 22 accepts an operation to request a log file from the target device 10 that is the target of log collection, and passes the operation content to the control unit 21, which can then request the log file in accordance with the operation content. This request is a command that requests (instructs) the target device 10 to acquire a log, and will hereinafter be referred to as a log acquisition command.
[0053] The log acquisition command can include information indicating the type of log to be collected, information indicating whether encryption is required, and information indicating the specified encryption range (in the case of partial encryption), as exemplified in Fig. 5. These pieces of information, i.e., parameters, that can be included in the log acquisition command can be specified, for example, from the operation unit 22.
[0054] The information indicating the log type described above can be information indicating the type of log to be collected, such as a log of an application incorporated in the target device 10 or a log of a device provided in the target device 10. In the example of Fig. 5, for simplicity, the information indicating the log type is described as being expressed by a log acquisition command name. However, each log acquisition command includes information indicating the log type, or the target device 10 is configured to be able to determine the log type from the log acquisition command name.
[0055] Note that, in the case where all data is encrypted or where no encryption is performed, the following description is given on the assumption that the log data to be collected can be identified based on the log type alone in the target device 10. However, as will be described later, in these cases, it is also possible to include information indicating the log acquisition range in the log acquisition command, and configure the target device 10 to identify the log data to be collected based on the log type and the log acquisition range.
[0056] The information indicating whether encryption is required can be information indicating full encryption, partial encryption, or no encryption. The information indicating the encryption range is information that specifies the encryption range for a log acquisition command that specifies partial encryption, and is an invalid parameter for anything other than partial encryption. The information indicating the encryption range can be information indicating a range specified by the processing content, such as from process α to process β, for the log type indicated by the log acquisition command, or information indicating a processing period, such as from a first date and time to a second date and time. Alternatively, the information indicating the encryption range can be a combination of these. Furthermore, the range specified by the processing content can be multiple ranges, such as from process α to process β and from process γ to process δ, or multiple processing periods, such as from the first date and time to the second date and time and from the third date and time to a fourth date and time.
[0057] The operations accepted by the operation unit 22 can include an operation of inputting information indicating the target device 10 from which logs are to be collected. The operations accepted by the operation unit 22 can include an operation of inputting information included in a log acquisition command. Therefore, the operations accepted can include an operation of inputting information indicating the log data to be acquired or the type of the log data, information indicating whether encryption is to be performed, and, if encryption is to be performed, information indicating whether encryption is to be performed on all or part of the target. Furthermore, the operations accepted can include an operation of inputting information indicating the encryption range if encryption is to be performed on part of the log data to be acquired.
[0058] Alternatively, the operation unit 22 may simply accept an operation to input information indicating the target device 10. In this case, the control unit 21 can read or generate a log acquisition command based on predetermined content regarding whether encryption is required and the encryption range designation (in the case of partial encryption).
[0059] The storage unit 23 is a storage device that stores a log file received from the target device 10 via the communication unit 24 as a response to the request. The communication unit 24 transmits the request to the target device 10 under the control of the control unit 21, and receives the log file as a response. The communication unit 24 can be equipped with a wired or wireless communication interface.
[0060] The target device 10 is an example of the encryption device 2 in Fig. 2. The target device 10 may include a main control unit 11 that controls the entire device, and a communication unit 12 that communicates with the outside. Under the control of the main control unit 11, a functional unit (not shown) that realizes the original function of the target device 10 can be made to function.
[0061] Furthermore, the target device 10 can include the following components to function as an encryption device. That is, the target device 10 can include a log acquisition unit 15 and a buffer unit 16, an encryption unit 17, a writing unit 18 and a recording medium 19, and a generation control unit 14, which are examples of the acquisition unit 1a, encryption unit 1b, storage unit 1d, and control unit 1e in FIG. 2, respectively. Furthermore, the communication unit 12 has the function of the reception unit 1c in FIG. 2 as well as the function of transferring log files to the log collection device 20. The log acquisition unit 15 and the buffer unit 16, the encryption unit 17, the writing unit 18 and a recording medium 19, and the generation control unit 14 can function as a log generation unit 13 that generates logs in cooperation with each other. The target device 10 can be configured as a single device or a distributed device.
[0062] The main control unit 11 is a control unit that controls the entire target device 10. The main control unit 11 can be realized by, for example, a CPU, a working memory, and a non-volatile storage device that stores a program. This program can be a program that causes the CPU to execute processing in the above-mentioned functional units and processing that instructs the generation control unit 14 of the log generation unit 13 to perform processing related to log acquisition for functioning as an encryption device. The storage device provided in the main control unit 11 can also be used as a recording medium 19. The communication unit 12 receives a log acquisition command from the log collection device 20 and transmits a log file in response. The communication unit 12 can be provided with a wired or wireless communication interface.
[0063] Log generation unit 13 generates a log file under control of main control unit 11. Specifically, log generation unit 13 receives a log acquisition command received by communication unit 12 from main control unit 11, and thereby links the components included in log generation unit 13, such as generation control unit 14. Then, through this linkage, log generation unit 13 generates a log file and transmits the log file via communication unit 12, as described below.
[0064] The generation control unit 14 is a control unit that controls the entire log generation unit 13 under control of the main control unit 11. Upon receiving a log acquisition command from the main control unit 11, which is received by the communication unit 12, the generation control unit 14 generates a log file in accordance with the log acquisition command and transmits the log file via the communication unit 12. As described above, this log acquisition command can include whether encryption is required and the specified encryption range if partial encryption is required. Of course, if the log acquisition command includes only the encryption range, it implicitly includes whether encryption is required, and therefore it can be said that the generation control unit 14 can know whether encryption is required and whether full encryption or partial encryption is required.
[0065] Based on the log acquisition command, the generation control unit 14 controls the timing of log data acquisition by the log acquisition unit 15, the start and end positions of encryption by the encryption unit 17, and the writing of the log data to the recording medium 19 by the writing unit 18.
[0066] That is, in accordance with the log acquisition command received from the main control unit 11, the generation control unit 14 controls the start of log collection in accordance with the contents of the log acquisition command. This control includes control over the log acquisition unit 15, encryption unit 17, and writing unit 18, and causes them to respectively acquire log data, encrypt the log data, file the log data, and write the file. Furthermore, the generation control unit 14 returns the written file, that is, the log file, to the log collection device 20 that sent the log acquisition command via the communication unit 12.
[0067] As the encryption process, the generation control unit 14 controls the encryption unit 17 to insert an encryption start flag indicating the start position and an encryption end flag indicating the end position at the start position and end position indicated by the encryption range, respectively, and perform encryption.
[0068] However, when the entire range of log data is specified as the encryption range, the generation control unit 14 controls the encryption unit 17 to perform encryption without inserting the encryption start flag and encryption end flag. As a result, when the entire range of log data is encrypted, the encryption start flag and encryption end flag are not inserted, and a log file that does not include the encryption start flag and encryption end flag is stored on the recording medium 19.
[0069] For the log data filing and file writing process, the generation control unit 14 performs the following control: That is, the generation control unit 14 controls the writing unit 18 to store, as separate log files, the encrypted data for the log data portion that falls within the encryption range, and the plaintext data for the log data portion that does not fall within the encryption range.
[0070] In particular, in this embodiment, when a partial range of log data is specified as the encryption range in a log acquisition command, the log acquisition command is configured to include an instruction to specify a partial encryption log acquisition range that includes the encryption range but is larger than the encryption range. In other words, the operation unit 22 of the log collection device 20 also accepts an operation to specify information indicating the partial encryption log acquisition range, and the control unit 21 controls the log acquisition command to include this information and transmit it to the target device 10 via the communication unit 24. This makes it possible for the target device 10 to know the range of log data to be acquired in plaintext from the partial encryption log acquisition range and the encryption range.
[0071] Then, generation control unit 14 controls writing unit 18 to collect and store the encrypted data obtained in the partial encryption log acquisition range as one log file 19a. Furthermore, generation control unit 14 controls writing unit 18 to collect and store the plaintext data obtained in a portion (range) of the partial encryption log acquisition range excluding the encryption range as one log file 19b. With this control, even if the partial encryption log acquisition range includes multiple encryption ranges, all of the encrypted data for these encryption ranges is collected into one log file 19a, and all of the plaintext data for the remaining ranges is collected into one log file 19b.
[0072] For example, if a certain log acquisition command specifies that the encryption range is from process α to process β and from process γ to process δ within the partial encrypted log acquisition range, one encrypted log file 19a and one plaintext log file 19b will be stored.
[0073] The same concept can be applied when the encryption range is specified for multiple processing periods, such as from the first date and time to the second date and time and from the third date and time to the fourth date and time. Here, the first date and time, the second date and time, the third date and time, and the fourth date and time are described in order as being closest to the present. In this case, the encrypted log data from the first date and time to the second date and time and the encrypted log data from the third date and time to the fourth date and time are stored as a single log file. The plaintext log data from the second date and time to the third date and time, the plaintext log data from the start date and time of the partial encryption log acquisition range to the first date and time, and the plaintext log data from the fourth date and time to the end date and time of the partial encryption log acquisition range are stored as a single log file. However, if the start date and time of the partial encryption log acquisition range is the same as the first date and time, no corresponding plaintext log data exists, and if the end date and time of the partial encryption log acquisition range is the same as the fourth date and time, no corresponding plaintext log data exists.
[0074] Log acquisition unit 15, under the control of generation control unit 14, acquires log data in target device 10 instructed by the log acquisition command and temporarily stores it in buffer unit 16. Buffer unit 16 is a temporary storage buffer for the log data acquired by log acquisition unit 15, and the temporarily stored log data is used when encryption unit 17 encrypts it or when writing unit 18 writes it.
[0075] The encryption unit 17 encrypts the log data acquired by the log acquisition unit 15 within a range (encryption range) specified in the log acquisition command. The encryption method used by the encryption unit 17 does not matter as long as the encrypted data can be decrypted. The encryption unit 17 also sets an encryption start flag at the start point indicated by the encryption range, and an encryption end flag at the encryption end point indicated by the encryption range. The encryption start flag and encryption end flag can be set by inserting an encryption start flag and an encryption end flag, respectively.
[0076] Furthermore, the encryption unit 17 encrypts the plaintext log data to be encrypted, temporarily stored in the buffer unit 16, using, for example, a byte array and a set encryption method and password. The encryption unit 17 is also configurable, and the encryption method can be set by receiving it from an operation unit (not shown) of the target device 10 or according to the contents described in the log acquisition command. The password can be set according to the contents described in the log acquisition command, but is not limited to this. Furthermore, any encryption method can be used in the encryption unit 17, such as public key encryption, Transport Layer Security (TLS), or Secure Socket Layer (SSL) instead of a password. The encryption unit 17 can temporarily store the encrypted log data in the buffer unit 16. However, the encrypted log data can also be temporarily stored in a buffer unit provided within the encryption unit 17.
[0077] The writing unit 18 controls the file writing of the encrypted log data and plaintext log data temporarily stored in the buffer unit 16 to the recording medium 19. As a result, the recording medium 19 stores at least one of a log file for encrypted flagged log data, a log file for encrypted ungated log data, and a log file for plaintext log data.
[0078] The recording medium 19 may be of any type, such as a hard disk drive, a solid state drive, or a portable recording medium. The recording medium 19 may also be a storage device used by the target device 10 to perform its original functions.
[0079] Furthermore, the generation control unit 14 and the log acquisition unit 15 can be configured as subprograms that cause the CPU of the main control unit 11 to execute processes for generating logs and returning log files via the communication unit 12, and for acquiring log data, respectively. The encryption unit 17 and the writing unit 18 can be configured as subprograms that cause the CPU of the main control unit 11 to execute processes for encrypting log data and for filing and writing log data, respectively. However, these components are not limited to being configured as subprograms; for example, the encryption unit 17 can also be configured as hardware that performs encryption.
[0080] Next, an example of processing in the target device 10 in this system will be described with reference to Figures 6 and 7. Figure 6 is a flow diagram for explaining an example of processing in the log generation unit 13 of the target device 10 in this system, and Figure 7 is a flow diagram continuing from Figure 6.
[0081] 6 and 7, an example of processing for a certain log acquisition command will be described as an example, but if there are multiple log acquisition commands for the target device 10, the following processing will be executed for each log acquisition command.
[0082] In the log generating unit 13, first, when the generation control unit 14 receives a log acquisition command from the log collecting device 20, it checks the information (parameters) described in the log acquisition command (step S11). Next, the generation control unit 14 determines whether encryption is necessary based on the check result (step S12).
[0083] If encryption is not required, that is, if the answer is NO in step S12, the generation control unit 14 causes the log acquisition unit 15 to acquire (collect) log data and temporarily store the collected log data in plain text in the buffer unit 16 (step S13). Next, the generation control unit 14 controls the writing unit 18 to file the plain text log data temporarily stored in the buffer unit 16 and write it to the recording medium 19 (step S14), and the process ends.
[0084] If encryption is required, i.e., if the answer is YES in step S12, the generation control unit 14 determines whether or not partial encryption is required (whether the entire data is encrypted) based on the check result in step S11 (step S15). If the entire data is to be encrypted, i.e., if the answer is NO in step S15, the generation control unit 14 causes the log acquisition unit 15 to acquire (collect) log data and temporarily stores the collected log data in plain text in the buffer unit 16 (step S16).
[0085] Thereafter, the generation control unit 14 causes the encryption unit 17 to encrypt the log data temporarily stored in the buffer unit 16, and causes the encrypted log data to be temporarily stored in the buffer unit 16 (step S17). The encryption unit 17 stores, for example, plaintext log data in a byte array, specifies an encryption method and a password, and performs encryption. The encryption method and password may be specified in the log acquisition command or may be predetermined.
[0086] Next, the generation control unit 14 controls the writing unit 18 to file the encrypted log data temporarily stored in the buffer unit 16 and write it to the recording medium 19 (step S18), and then ends the process.
[0087] If partial encryption is to be performed, that is, if the answer is YES in step S15, the generation control unit 14 executes a loop process from the loop start (step S21s) to the loop end (step S21e) until the log acquisition command is completed.
[0088] When partial encryption is performed, the encryption start position is specified by the encryption range in one of the partial encryption log acquisition ranges. Therefore, the generation control unit 14 first determines whether the encryption start position indicated by the check result in step S11 is the encryption start position based on the current acquisition status of the log data (step S22). Note that at the beginning of the loop processing, if the start position of the partial encryption log acquisition range and the encryption start position match, the answer is YES in step S22, and otherwise, that is, if there is an unencrypted range at the beginning, the answer is NO in step S22.
[0089] If the result of step S22 is NO, the generation control unit 14 causes the log acquisition unit 15 to acquire (collect) log data and temporarily stores the collected log data in plain text in the buffer unit 16 (step S23). Next, similar to step S22, the generation control unit 14 determines whether or not the current acquisition status of the log data indicates the encryption start position (step S24). If the result of step S24 is NO, the process of step S23 continues.
[0090] The generation control unit 14 continues the process of step S23 until the sequence advances to the encryption start position (until step S24 returns YES). When the sequence advances to the encryption start position, that is, when step S24 returns YES, the generation control unit 14 controls the writing unit 18 to write the plaintext log data that has been temporarily stored in the buffer unit 16 up to that point into the first file, which is a plaintext file (step S25).
[0091] In step S25, in the first loop in which the first file is not yet generated, the generation control unit 14 controls the writing unit 18 to generate a first file by converting the temporarily stored plaintext log data into a file and write the file to the recording medium 19. In the next and subsequent loop processes, in step S25, the generation control unit 14 causes the writing unit 18 to append the temporarily stored plaintext log data to the first file stored in the recording medium 19. After step S25 is completed, the process moves to the next loop process.
[0092] On the other hand, if the answer is YES in step S22, the generation control unit 14 causes the encryption unit 17 to insert an encryption start flag (step S26). At this stage, log data containing only the encryption start flag for the encryption section may be temporarily stored in the buffer unit 16. Following step S26, the generation control unit 14 causes the log acquisition unit 15 to acquire (collect) log data, and causes the collected log data to be temporarily stored in plain text in the buffer unit 16 (step S27), and determines whether the process has proceeded to the encryption end position (step S28). If the answer is NO in step S28, the process of step S27 continues.
[0093] When the encryption end position is reached, i.e., when the answer is YES in step S28, the generation control unit 14 controls the encryption unit 17 to insert an encryption end flag at the end of the temporarily stored log data, and causes the encryption unit 17 to perform the insertion (step S29).
[0094] Next, the generation control unit 14 causes the encryption unit 17 to encrypt the flagged log data temporarily stored in the buffer unit 16, and causes the encrypted log data to be temporarily stored in the buffer unit 16 (step S30). Here too, the encryption unit 17 stores, for example, plaintext log data in a byte array, specifies an encryption method and a password, and performs encryption. The encryption method and password may be specified in the log acquisition command or may be predetermined.
[0095] The generation control unit 14 controls the writing unit 18 to write the encrypted log data that has been temporarily stored in the buffer unit 16 into a second file that is a file for encryption (step S31).
[0096] In step S31, in the first loop in which the second file has not yet been generated, the generation control unit 14 controls the writing unit 18 to generate a second file by converting the temporarily stored encrypted log data into a file and write the file to the recording medium 19. In the next and subsequent loop processes, in step S31, the generation control unit 14 causes the writing unit 18 to add the temporarily stored encrypted log data to the second file stored in the recording medium 19. After step S31 ends, the process proceeds to the next loop process.
[0097] Next, an example of processing by the log collection device 20 and the target device 10 will be described with reference to Fig. 8 and Fig. 9. Fig. 8 is a sequence diagram showing an example of the overall processing in this system, and Fig. 9 is a sequence diagram following Fig. 8.
[0098] First, the log collecting device 20 transmits a log acquisition request, which is a log acquisition command, to the target device 10, and the log acquisition request is received by the generation control unit 14 (step S100). Although it has been explained that the log acquisition command can be specified from the operation unit 22 of the log collecting device 20 or the like, the contents set by the log acquisition command can be determined in advance, that is, the contents can be set so that they cannot be changed by the user of the log collecting device 20.
[0099] Next, the generation control unit 14 checks the parameters set in the received log acquisition command (step S101). A loop process is executed for each received log acquisition command. In this loop process, one of the following processes is executed depending on the check result for the target log acquisition command: no encryption process, full encryption process, or partial encryption process.
[0100] If the log acquisition command is an unencrypted log acquisition command, the generation control unit 14 executes the log acquisition command, thereby starting temporary storage (buffering) of the log data in the buffer unit 16 (step S102). Next, the generation control unit 14 requests the writing unit 18 to file the log data (step S103), and the writing unit 18 executes the file creation and stores the plaintext log file on the recording medium 19 (step S104). Next, in response to the request, the writing unit 18 notifies the generation control unit 14 that the file creation has been completed (step S105). In response to this notification, the generation control unit 14 transmits (transfers) the plaintext log file stored on the recording medium 19 to the log collection device 20 via the communication unit 12 (step S106), and the process ends.
[0101] If the log acquisition command is to encrypt all data, the generation control unit 14 executes the log acquisition command, thereby starting temporary storage of the log data in the buffer unit 16 (step S107). Next, the generation control unit 14 transmits an encryption request to the encryption unit 17 (step S108), and the encryption unit 17 responds to the request, encrypts the temporarily stored log data (step S109), and notifies the generation control unit 14 of the completion of encryption (step S110).
[0102] Upon receiving this notification, the generation control unit 14 requests the writing unit 18 to file the log data (step S111), and the writing unit 18 executes the file creation and stores the encrypted log file on the recording medium 19 (step S112). Next, the writing unit 18 notifies the generation control unit 14 that the file creation has been completed in response to the request (step S113). Next, the generation control unit 14 transmits (transfers) the encrypted log file stored on the recording medium 19 to the log collection device 20 via the communication unit 12 (step S114), and the process ends.
[0103] If the log acquisition command is partially encrypted, a loop process is executed in which one of the following processes is executed until the log acquisition command ends: processing at the encryption start position, processing at the encryption end position, or processing in the non-encrypted section.
[0104] The encryption start position is not necessarily the beginning of the log data. Therefore, by executing a log acquisition command, the generation control unit 14 temporarily stores the log data in the buffer unit 16 as processing in a non-encryption zone until the encryption start position is reached (step S126). Thereafter, the generation control unit 14 requests the writing unit 18 to file the log data (step S127), and the writing unit 18 executes the file creation and stores the plaintext log file on the recording medium 19 (step S128). Next, in response to the request, the writing unit 18 notifies the generation control unit 14 that the file creation in this non-encryption range has been completed (step S129). If there is a next non-encryption range, it is preferable to append plaintext log data to the plaintext log file stored on the recording medium 19 in step S127.
[0105] An example of processing at the encryption start position will be described. When the encryption start position is reached, generation control unit 14 executes a log acquisition command, thereby starting temporary storage of log data in buffer unit 16 (step S115). Next, generation control unit 14 transmits an encryption start request to encryption unit 17 (step S116). Upon receiving the encryption start request, encryption unit 17 inserts an encryption start flag at the encryption start position of the unencrypted log data temporarily stored in step S115 (step S117), and returns an encryption start response to generation control unit 14 (step S118).
[0106] An example of processing at the encryption end position will be described. When the processing proceeds to the encryption end position, the generation control unit 14 transmits an encryption end request to the encryption unit 17 (step S119). The encryption unit 17 inserts an encryption end flag at the end of the log data that has been continuously and temporarily stored in step S115 (step S120), and performs encryption of the section delimited by the encryption start flag and encryption end flag (step S121). Thereafter, the encryption unit 17 returns an encryption end response to the generation control unit 14 (step S122).
[0107] Thereafter, the generation control unit 14 requests the writing unit 18 to file the encrypted log data for that section (step S123). Upon receiving this request, the writing unit 18 executes the file creation and stores the encrypted log file on the recording medium 19 (step S124). Next, in response to the request, the writing unit 18 notifies the generation control unit 14 that the file creation for this encryption range has been completed (step S125). If there is a next encryption range, the encrypted log data may be added to the encrypted log file stored on the recording medium 19 in step S124.
[0108] As described above, when the log data is acquired by the target log acquisition command, partially encrypted, and filed, the loop process for partial encryption ends. After that, the generation control unit 14 transmits (transfers) one plaintext log file and one encrypted log file stored in the recording medium 19 to the log collection device 20 via the communication unit 12 (step S130), and the process ends.
[0109] As described above, according to this embodiment, in addition to the effects of embodiment 1, even when a log acquisition command includes multiple encryption ranges, the multiple encryption ranges can be collected together and obtained as a single encrypted log file. Furthermore, according to this embodiment, even when a log acquisition command includes one or more encryption ranges, and as a result includes multiple non-encrypted ranges, the multiple non-encrypted ranges can be collected together and obtained as a single plaintext log file.
[0110] In addition, in the present embodiment, it has been described that the log acquisition command that encrypts part of the data includes information indicating the partial encryption log acquisition range. However, it is also possible to include information indicating the log acquisition range in both the log acquisition command that encrypts all the data and the log acquisition command that does not encrypt the data. This allows the target device 10 to identify the log data to be collected for both of these types of log acquisition commands based on the log type and log acquisition range included in the log acquisition command.
[0111] 8 and 9, the generation control unit 14 in this embodiment has a function of determining the insertion positions of the encryption start flag and the encryption end flag during execution of the log acquisition command, and switching between non-encryption, partial encryption (partial encryption), and full encryption. By having such a function, it is possible to switch processing in response to any of these three types of requests from the log collection device 20, generate a log file, and transfer the log file to the log collection device 20.
[0112] Finally, we will briefly explain how to use the encryption start flag and encryption end flag when viewing (decrypting) a log file when partial encryption is performed. In this case, the encryption start flag and encryption end flag are not used; decryption of the encrypted log file is possible by ignoring these flags. However, these flags can be used when viewing log files for one log acquisition command in sequence. For example, the decryption of the encrypted log file can be performed first, and the encrypted range and non-encrypted range can be presented in order. Which of the encrypted range or non-encrypted range comes first is known after the log acquisition command is generated by the log collection device 20, and can be determined by referring to the log acquisition command. For example, after the encryption end flag, the next non-encrypted range in the plaintext log file can be read and presented, and once the presentation of the non-encrypted range in the plaintext log file has finished, the next encrypted range indicated by the next encryption start flag can be read and presented.
[0113] <Embodiment 3> The third embodiment will be described with reference to Fig. 10 etc., focusing on the differences from the second embodiment, but the various application examples described in the first and second embodiments are also applicable to the third embodiment. As the configuration example of the encryption system in Fig. 4 can be applied to the third embodiment as well, with the exception of some processes, the description will be based on the configuration example in Fig. 4.
[0114] In embodiment 2, when a log acquisition command includes multiple encryption ranges, the multiple encryption ranges are collected together and obtained as a single encrypted log file, and the multiple non-encrypted ranges are collected together and obtained as a single plaintext log file.
[0115] In contrast to this, the generation control unit 14 in this embodiment stores the encrypted log data as one file in the recording medium 19 each time the encryption range is separated by the start position and end position, and stores the plaintext log data as one file in the recording medium 19. In other words, in this embodiment, when the encryption range is separated into multiple parts, it is possible to store a log file each time the encryption range is separated in processing order, and to transmit each stored log file to the log collection device 20.
[0116] A specific example of a file storage method will be described. If the log acquisition command specifies processes α to β and processes γ to δ as the encryption range, the following two encrypted log files will be stored as the encrypted log file. That is, an encrypted log file for processes α to β and an encrypted log file for processes γ to δ will be stored. Furthermore, consecutive log data other than these processes can be stored as plaintext log files. For example, log data for a series of processes from after process β to before process γ will be stored as a single plaintext log file. Furthermore, if there is a series of processes before process α, the log data for that series of processes will be stored as a single plaintext log file, and if there is a series of processes after process δ, the log data for that series of processes will be stored as a single plaintext log file. In this example, there will be a maximum of three plaintext log files.
[0117] The same concept can be applied when the encryption range is specified for multiple processing periods, such as from the first date and time to the second date and time and from the third date and time to the fourth date and time. Here, the first date and time, the second date and time, the third date and time, and the fourth date and time are described as being closer to the present in that order. In this case, an encrypted log file from the first date and time to the second date and time and an encrypted log file from the third date and time to the fourth date and time are stored. Also, a plaintext log file from the second date and time to the third date and time, a plaintext log file from the start date and time of the partial encryption log acquisition range to the first date and time, and a plaintext log file from the fourth date and time to the end date and time of the partial encryption log acquisition range are stored. However, if the start date and time of the partial encryption log acquisition range is the same as the first date and time, no corresponding plaintext log file exists. Also, if the end date and time of the partial encryption log acquisition range is the same as the fourth date and time, no corresponding plaintext log file exists.
[0118] Note that, here too, it is assumed that a partial encryption log acquisition range is specified, as in embodiment 2. Also, in this embodiment, the log acquisition command for full encryption and the log acquisition command for no encryption may include information indicating the log acquisition range.
[0119] Next, an example of processing in the log generation unit 13 of the target device 10 in this embodiment will be described with reference to Fig. 10. Fig. 10 is a flow diagram for explaining an example of processing in the log generation unit 13 of the target device 10 in the encryption system according to the third embodiment, and is a flow diagram for explaining another example of processing following Fig. 6.
[0120] 6 and 10 also explain an example of processing for a certain log acquisition command as an example, but if there are multiple log acquisition commands for the target device 10, the following processing is executed for each log acquisition command. Note that explanation using sequence diagrams such as those shown in FIGS. 8 and 9 will be omitted.
[0121] In this embodiment, the processing is similar when there is no encryption or when all is encrypted, and the processing example in Fig. 6 can be applied. In this embodiment, as shown in Fig. 10, when a log acquisition command is partially encrypted, a loop processing is executed in which one of processing at the encryption start position, processing at the encryption end position, and processing in the non-encryption section is executed until the log acquisition command ends. In this loop processing, in this embodiment, the processing of steps S25 and S31 in Fig. 7 is changed to processing of steps S25a and S31a, respectively.
[0122] In step S25a, if the result of step S24 is YES, the generation control unit 14 controls the writing unit 18 to write the plaintext log data that is the target of the loop processing at that time and that is temporarily stored in the buffer unit 16 to the first file, which is a file for plaintext.
[0123] In step S25a, the generation control unit 14 controls the writing unit 18 to file the temporarily stored plaintext log data to generate a first file, which is then written to the recording medium 19. The first file here is a first file for each target section. Therefore, the first file is stored as a first file for each target section for the number of loop processes for which step S24 returned a YES answer. After step S25a is completed, the process moves to the next loop process.
[0124] In step S31a, the generation control unit 14 controls the writing unit 18 to write the encrypted log data temporarily stored in the buffer unit 16, i.e., the encrypted log data that has not been filed, to a second file, which is a file for encryption.
[0125] In step S31a, the generation control unit 14 controls the writing unit 18 to file the temporarily stored encrypted log data, i.e., the encrypted log data that has not been filed, to generate a second file and write it to the recording medium 19. The second file here is a second file for each target section. Therefore, the second file is stored as a second file for each target section for the number of loop processes for which step S28 has returned YES. After step S31a is completed, the process proceeds to the next loop process.
[0126] As described above, according to this embodiment, in addition to the effects of embodiment 1, even if the log acquisition command includes multiple encryption ranges, one encrypted log file can be obtained for each encryption range, and one plaintext log file can be obtained for each non-encryption range.
[0127] Here, we briefly explain how to use the encryption start flag and encryption end flag when viewing (decrypting) a log file when partial encryption is performed. In this case, the encryption start flag and encryption end flag are not used; decryption of the encrypted log file is possible by ignoring these flags. However, these flags can be used when viewing encrypted log files for a single log acquisition command in sequence. For example, the decryption of the encrypted log file can be performed first, and the encrypted and non-encrypted ranges can be presented in order. This order is known after the log acquisition command is generated by the log collection device 20, so it can be obtained by referring to the log acquisition command. Alternatively, this order can be determined by the date and time the log file was last saved. For example, after the encryption end flag is set, the next non-encrypted range in the plaintext log file can be read and presented, and once the presentation of the non-encrypted range in the plaintext log file has finished, the next encrypted range indicated by the next encryption start flag can be read and presented.
[0128] In addition, the target device 10 may be provided with a function for switching between the processing of embodiment 2 and embodiment 3, and the log acquisition command sent by the log collection device 20 may include information indicating which processing to apply.
[0129] <Other embodiments> [a] In each embodiment, the functions of the encryption system, encryption device, target device, log collection device, and devices that can be included in the encryption system have been described, but each device is not limited to the configuration example shown in the figure, and it is sufficient if each device can realize these functions.
[0130] [b] Each of the devices described in the first to third embodiments may have the following hardware configuration. Fig. 11 is a diagram showing an example of the hardware configuration of the device. The same applies to the other embodiment [a] above.
[0131] The device 100 shown in FIG. 11 may include a processor 101, a memory 102, and a communication interface (I / F) 103. The processor 101 may be, for example, a microprocessor, an MPU (Micro Processor Unit), or a CPU. The processor 101 may include multiple processors. The memory 102 is configured, for example, by a combination of a volatile memory and a non-volatile memory. The functions of each device described in the first to third embodiments are realized by the processor 101 reading and executing a program stored in the memory 102. In this case, information can be sent and received with other devices via the communication interface 103 or an input / output interface (not shown).
[0132] In the above examples, the program includes instructions (or software code) that, when loaded into a computer, cause the computer to perform one or more functions described in the embodiments. The program may be stored on a non-transitory computer-readable medium or a tangible storage medium. By way of example and not limitation, computer-readable medium or tangible storage medium includes random-access memory (RAM), read-only memory (ROM), flash memory, solid-state drive (SSD) or other memory technology, CD-ROM, digital versatile disc (DVD), Blu-ray® disc or other optical disk storage, magnetic cassette, magnetic tape, magnetic disk storage or other magnetic storage device. The program may also be transmitted on a transitory computer-readable medium or communication medium. By way of example and not limitation, transitory computer-readable medium or communication medium includes electrical, optical, acoustic, or other forms of propagated signals.
[0133] The present disclosure is not limited to the above-described embodiments, and may be modified as appropriate without departing from the spirit and scope of the present disclosure. In addition, the present disclosure may be implemented by appropriately combining the respective embodiments.
[0134] A part or all of the above-described embodiments can be described as, but not limited to, the following supplementary notes.
[0135] (Appendix 1) an acquisition unit that acquires log data; an encryption unit that encrypts the log data; a reception unit that receives an instruction to specify a range to be encrypted by the encryption unit before starting acquisition of log data; a storage unit that stores log data; a control unit that controls, based on the range, the timing of acquisition of log data by the acquisition unit, the start and end positions of encryption by the encryption unit, and storage of log data by the storage unit; Equipped with The control unit controlling the encryption unit to insert a start flag indicating the start position and an end flag indicating the end position into the start position and the end position indicated by the range, respectively, and then perform encryption; When the entire range of the log data is designated as the range, the encryption unit is controlled to perform encryption without inserting the start flag and the end flag; The encrypted data for the log data corresponding to the range and the plaintext data for the log data not corresponding to the range are stored in the storage unit as separate files. Encryption system. (Appendix 2) when a partial range of log data is specified as the range, the reception unit receives an instruction to specify a partial encrypted log acquisition range that is a log acquisition range that includes the range and is larger than the range; the control unit collectively stores the encrypted data obtained in the partial encryption log acquisition range as a single file in the storage unit, and collectively stores the plaintext data obtained in the portion of the partial encryption log acquisition range excluding the range as a single file in the storage unit. 1. The encryption system described in Appendix 1. (Appendix 3) when a partial range of log data is specified as the range, the reception unit receives an instruction to specify a partial encrypted log acquisition range that is a log acquisition range that includes the range and is larger than the range; the control unit causes the storage unit to store the encrypted data as one file and the plaintext data as one file each time the range is delimited by a start position and an end position indicated by the range. 1. The encryption system described in Appendix 1. (Appendix 4) an instruction device that transmits an instruction to the reception unit to be received by the reception unit; a target device that is a target for collecting log data, the target device including the encryption unit, the reception unit, the storage unit, and a transmission unit that transmits the file stored in the storage unit to the instruction device; Equipped with An encryption system according to any one of appendices 1 to 3. (Appendix 5) an acquisition unit that acquires log data; an encryption unit that encrypts the log data; a reception unit that receives an instruction to specify a range to be encrypted by the encryption unit before starting acquisition of log data; a storage unit that stores log data; a control unit that controls, based on the range, the timing of acquisition of log data by the acquisition unit, the start and end positions of encryption by the encryption unit, and storage of log data by the storage unit; Equipped with The control unit controlling the encryption unit to insert a start flag indicating the start position and an end flag indicating the end position into the start position and the end position indicated by the range, respectively, and then perform encryption; When the entire range of the log data is designated as the range, the encryption unit is controlled to perform encryption without inserting the start flag and the end flag; The encrypted data for the log data corresponding to the range and the plaintext data for the log data not corresponding to the range are stored in the storage unit as separate files. Encryption device. (Appendix 6) when a partial range of log data is specified as the range, the reception unit receives an instruction to specify a partial encrypted log acquisition range that is a log acquisition range that includes the range and is larger than the range; the control unit collectively stores the encrypted data obtained in the partial encryption log acquisition range as a single file in the storage unit, and collectively stores the plaintext data obtained in the portion of the partial encryption log acquisition range excluding the range as a single file in the storage unit. 6. The encryption device of claim 5. (Appendix 7) when a partial range of log data is specified as the range, the reception unit receives an instruction to specify a partial encrypted log acquisition range that is a log acquisition range that includes the range and is larger than the range; the control unit causes the storage unit to store the encrypted data as one file and the plaintext data as one file each time the range is delimited by a start position and an end position indicated by the range. 6. The encryption device of claim 5. (Appendix 8) a transmitting unit that, in response to the instruction received by the receiving unit, transmits the file stored in the storage unit to an instruction device that transmitted the instruction; 8. The encryption device according to any one of Supplementary notes 5 to 7. (Appendix 9) Obtaining log data; Encrypting log data; receiving an instruction to specify a range to be encrypted before starting acquisition of log data; storing the log data; and Controlling the timing of acquiring log data, the start and end positions of encryption, and storage of log data based on the range; Equipped with The controlling comprises: inserting a start flag indicating the start position and an end flag indicating the end position into the start position and the end position indicated by the range, respectively, and then performing encryption; When the entire range of the log data is designated as the range, encryption is performed without inserting the start flag and the end flag; and storing the encrypted data for the log data that falls within the range and the plaintext data for the log data that does not fall within the range in separate files; encryption methods, including (Appendix 10) When a partial range of log data is specified as the range, the receiving includes receiving an instruction to specify a partial encrypted log acquisition range that is a log acquisition range that includes the range and is larger than the range; The controlling includes collectively storing the encrypted data obtained in the partial encryption log acquisition range as one file, and collectively storing the plaintext data obtained in the part excluding the partial encryption log acquisition range as one file. 10. The encryption method described in Appendix 9. (Appendix 11) When a partial range of log data is specified as the range, the receiving includes receiving an instruction to specify a partial encrypted log acquisition range that is a log acquisition range that includes the range and is larger than the range; The controlling includes storing the encrypted data as one file and storing the plaintext data as one file each time the range is delimited by a start position and an end position indicated by the range. 10. The encryption method described in Appendix 9. (Appendix 12) In response to the instruction received by said receiving, transmitting the stored file to the instruction device that transmitted said instruction. The encryption method according to any one of Supplementary Notes 9 to 11, comprising: (Appendix 13) Obtaining log data; Encrypting log data; receiving an instruction to specify a range to be encrypted before starting acquisition of log data; storing the log data; and Controlling the timing of acquiring log data, the start and end positions of encryption, and storage of log data based on the range; Including, The controlling comprises: inserting a start flag indicating the start position and an end flag indicating the end position into the start position and the end position indicated by the range, respectively, and then performing encryption; When the entire range of the log data is designated as the range, encryption is performed without inserting the start flag and the end flag; and storing the encrypted data for the log data that falls within the range and the plaintext data for the log data that does not fall within the range in separate files; Including, A computer-readable medium that stores a program for causing a computer to execute an encryption process. (Appendix 14) When a partial range of log data is specified as the range, the receiving includes receiving an instruction to specify a partial encrypted log acquisition range that is a log acquisition range that includes the range and is larger than the range; The controlling includes collectively storing the encrypted data obtained in the partial encryption log acquisition range as one file, and collectively storing the plaintext data obtained in the part excluding the partial encryption log acquisition range as one file. 14. The computer-readable medium of claim 13. (Appendix 15) When a partial range of log data is specified as the range, the receiving includes receiving an instruction to specify a partial encrypted log acquisition range that is a log acquisition range that includes the range and is larger than the range; The controlling includes storing the encrypted data as one file and storing the plaintext data as one file each time the range is delimited by a start position and an end position indicated by the range. 14. The computer-readable medium of claim 13. (Appendix 16) the encryption process includes, in response to the instruction received by the receiving, transmitting the stored file to a device that sent the instruction. 16. The computer-readable medium of any one of appendices 13 to 15.
[0136] Although the present invention has been described above with reference to the embodiments, the present invention is not limited to the above. Various modifications that can be understood by those skilled in the art can be made to the configuration and details of the present invention within the scope of the invention. [Explanation of symbols]
[0137] 1. Encryption System 1a Acquisition part 1b Encryption part 1c Reception 1d storage section 1e Control unit 2 Encryption device 10 Target Device 11 Main control unit 12 Communications Department 13 Log Generation Unit 14 Generation control section 15 Log acquisition section 16 Buffer section 17 Encryption section 18 Writing section 19 Recording media 19a Encrypted log files 19b Plaintext log files 20 Log collection device 21 Control Unit 22 Control section 23 Memory section 24 Communications Department 100 devices 101 processors 102 memory 103 Communication Interface
Claims
1. an acquisition unit that acquires log data; an encryption unit that encrypts the log data; a reception unit that receives an instruction to specify a range to be encrypted by the encryption unit before starting acquisition of log data; a storage unit that stores log data; a control unit that controls, based on the range, the timing of acquisition of log data by the acquisition unit, the start and end positions of encryption by the encryption unit, and storage of log data by the storage unit; Equipped with The control unit controlling the encryption unit to insert a start flag indicating the start position and an end flag indicating the end position into the start position and the end position indicated by the range, respectively, and then perform encryption; When the entire range of the log data is designated as the range, the encryption unit is controlled to perform encryption without inserting the start flag and the end flag; The encrypted data for the log data corresponding to the range and the plaintext data for the log data not corresponding to the range are stored in the storage unit as separate files. Encryption system.
2. when a partial range of log data is specified as the range, the reception unit receives an instruction to specify a partial encrypted log acquisition range that is a log acquisition range that includes the range and is larger than the range; the control unit collectively stores the encrypted data obtained in the partial encryption log acquisition range as a single file in the storage unit, and collectively stores the plaintext data obtained in the portion of the partial encryption log acquisition range excluding the range as a single file in the storage unit. The encryption system of claim 1 .
3. when a partial range of log data is specified as the range, the reception unit receives an instruction to specify a partial encrypted log acquisition range that is a log acquisition range that includes the range and is larger than the range; the control unit stores the encrypted data as one file in the storage unit and stores the plaintext data as one file in the storage unit each time the range is delimited by a start position and an end position indicated by the range. The encryption system of claim 1 .
4. an instruction device that transmits an instruction to the reception unit to be received by the reception unit; a target device that is a target for collecting log data, the target device including the encryption unit, the reception unit, the storage unit, and a transmission unit that transmits the file stored in the storage unit to the instruction device; Equipped with The encryption system according to any one of claims 1 to 3.
5. an acquisition unit that acquires log data; an encryption unit that encrypts the log data; a reception unit that receives an instruction to specify a range to be encrypted by the encryption unit before starting acquisition of log data; a storage unit that stores log data; a control unit that controls, based on the range, the timing of acquisition of log data by the acquisition unit, the start and end positions of encryption by the encryption unit, and storage of log data by the storage unit; Equipped with The control unit controlling the encryption unit to insert a start flag indicating the start position and an end flag indicating the end position into the start position and the end position indicated by the range, respectively, and then perform encryption; When the entire range of the log data is designated as the range, the encryption unit is controlled to perform encryption without inserting the start flag and the end flag; The encrypted data for the log data corresponding to the range and the plaintext data for the log data not corresponding to the range are stored in the storage unit as separate files. Encryption device.
6. when a partial range of log data is specified as the range, the reception unit receives an instruction to specify a partial encrypted log acquisition range that is a log acquisition range that includes the range and is larger than the range; the control unit collectively stores the encrypted data obtained in the partial encryption log acquisition range as a single file in the storage unit, and collectively stores the plaintext data obtained in the portion of the partial encryption log acquisition range excluding the range as a single file in the storage unit. The encryption device according to claim 5 .
7. when a partial range of log data is specified as the range, the reception unit receives an instruction to specify a partial encrypted log acquisition range that is a log acquisition range that includes the range and is larger than the range; the control unit stores the encrypted data as one file in the storage unit and stores the plaintext data as one file in the storage unit each time the range is delimited by a start position and an end position indicated by the range. The encryption device according to claim 5 .
8. a transmitting unit that, in response to the instruction received by the receiving unit, transmits the file stored in the storage unit to an instruction device that transmitted the instruction; The encryption device according to any one of claims 5 to 7.
9. A computer comprising: Obtaining log data; Encrypting log data; receiving an instruction to specify a range to be encrypted before starting acquisition of log data; storing the log data; and Controlling the timing of acquiring log data, the start and end positions of encryption, and storage of log data based on the range; performs an encryption process including The controlling comprises: inserting a start flag indicating the start position and an end flag indicating the end position into the start position and the end position indicated by the range, respectively, and then performing encryption; When the entire range of the log data is designated as the range, encryption is performed without inserting the start flag and the end flag; and storing the encrypted data for the log data that falls within the range and the plaintext data for the log data that does not fall within the range in separate files; encryption methods, including
10. Obtaining log data; Encrypting log data; receiving an instruction to specify a range to be encrypted before starting acquisition of log data; storing the log data; and Controlling the timing of acquiring log data, the start and end positions of encryption, and storage of log data based on the range; Including, The controlling comprises: inserting a start flag indicating the start position and an end flag indicating the end position into the start position and the end position indicated by the range, respectively, and then performing encryption; When the entire range of the log data is designated as the range, encryption is performed without inserting the start flag and the end flag; and storing the encrypted data for the log data that falls within the range and the plaintext data for the log data that does not fall within the range in separate files; Including, A program that causes a computer to perform encryption processing.
Citation Information
Patent Citations
Method, device, and system for enciphering data
JP1999215122A
Packet communication method
JP1999215190A
Information processing system
JP2011237975A
Information processing device, information processing method, information processing system and information processing program
JP2017097703A
Log collection system, log output apparatus, log collection method, and log collection program
JP2017215853A