Method for detecting improper rewriting of stored data

Abstract: It is aimed to determine whether or not the rewrite of a stored data has been made by a person other than the regular creator. Therefore, in storing the data, a first code is generated by converting the password and a predetermined portion of the stored data (e.g., data itself or time stamp) in a predetermined procedure, and stored in correspondence to the stored data. Thereafter, in reading the stored data, a second code is generated by converting the password and the predetermined portion of the stored data in the predetermined procedure, and the comparison is made between the generated second code and the first code stored in correspondence to the stored data to determine that the rewrite has been made if unmatched.

Description: The present invention relates to a method in a data processing system for creating, registering and managing documents or programs, wherein the method includes determining whether or not the content of stored data is valid data which remains as created and stored by the authorized user and detecting the fact that the improper rewrite has been made, if any. It is conventionally common practice that a document is created on a computer, and stored as a file. When this document file is used in the joint work by a plurality of users, a method has been adopted in which under the operating system, the file is shared among the plurality of users and other users are inhibited from making the access to the file. For example, in a UNIX operating system (UNIX is a trademark of Bell laboratories), the permission for the write, the reference (read), and the execution can be given to the owner of the file, the group of joint work, and other users for each file. In such a system, when a certain file is shared within a group, and the users outside of the group are inhibited from changing the file, a method is taken in which the users within the group are permitted to write into the file, but the users outside of the group are inhibited from writing, so that the file can be shared only within the group. However, with the conventional example, the permission for writing or reading a certain file is only given to the owner of the file, the group and other users. Also, the justification (validity) of the document is assured by inhibiting the unauthorized user from writing or reading. Accordingly, there were following problems. 1. It is not possible to meet a requirement of recognizing the rewrite if any, although the rewrite by others is permitted. 2. When the group for dealing with each file is different, a number of groups are created, in which the memhers of each group are registered, and the group corresponding to which each file belongs must be registered, so that the management becomes very complicated. 3. When the rewrite by the super user (user having all rights for any file) or the false rewrite by the authorized user is made, there is no indication for the alteration. A system for restricting access to information stored in the memory of a data processing system is disclosed in US 3920976. This system generates a code from part of the data to be stored and from the user security ID that authorises the user to have access to that data. The generated code is stored when the data is stored. When the next user attempts to access the data, a new code is generated from this user's security ID. The newly generated code is compared with the stored code. If the two codes differ the user is denied access to the stored data. SUMMARY OF THE INVENTION An aim of the present invention is to provide a method for determining whether or not the content of stored data is valid data which remains as created and stored by the authorized user, and detecting the fact that the improper rewrite, if any, has been made. The present invention provides a method for determining on the basis of user information whether an improper rewrite of stored data has occurred in a file storage system, the file storage system being such that plural users having different user information may have rewritten the stored data, the method comprising the steps of: (a) when data is to be stored: generating a first code in accordance with a pre-determined procedure by inputting the user information; and generating a code by converting the inputted user information and a predetermined portion of the data; storing said data; and storing said first code in correspondence with said stored data; (b) when reading out stored data: generating a second code on the basis of inputted user information and said predetermined portion of the read out data in accordance with said predetermined procedure; comparing said second code with the code stored in correspondence with said stored data; and determining whether said stored data has been rewritten by a user having different user information based upon the result of said comparison. Other aims and advantages besides those discussed above shall be apparent to those skilled in the art from the description of preferred embodiments of the invention which follows. In the description, reference is made to accompanying drawings, which form a part thereof, and which illustrate examples of the invention. Such examples, however, are not exhaustive of the various embodiments of the invention, and therefore reference is made to the claims which follow the description for determining the scope of the invention. BRIEF DESCRIPTION OF THE DRAWINGS Fig. 1 is a system configuration diagram in the first example. Fig. 2 is a flowchart for a document creating and registering process in the first example. Fig. 3 is a flowchart for a code generating process in the first exmaple. Fig. 4 is a flowchart for a justification identification process in the first example. Fig. 5 is a system configuration diagram in the second example. Fig. 6 is a flowchart for a code generating process in the second example. Fig. 7 is a system configuration diagram in the third example. Fig. 8 is a flowchart for a correspondence process in the third example. Fig. 9 is a view showing an example of document data with a justification identification code appended. Fig. 10 is a flowchart for a code generating process in the third example. Fig. 11 is a flowchart for a comparison process in the third example. Fig. 12 is a system configuration diagram in the fourth example. Fig. 13 is a flowchart for a correspondence process in the fourth example. Fig. 14 is a diagram showing the transition of time stamp in the fourth example. Fig. 15 is a system configuration diagram in the fifth example. Fig. 16 is a flowchart for a code generating process in the fifth example. Fig. 17 is flowchart for a correspondence process in the fifth example. Fig. 18 is a diagram showing the transition of time stamp in the fifth example. Fig. 19 is a system configuration diagram in the sixth example. Fig. 20 is a flowchart for a document creating and registering process in the sixth example. Fig. 21 is a flowchart for a code generating process in the sixth example. Fig. 22 is a flowchart for a justification identification process in the sixth example. Fig. 23 is a system configuration diagram in the seventh example. Fig. 24 is a flowchart for a document creating and registering process in the seventh example. Fig. 25 is a flowchart for a code generating process in the seventh example. Fig. 26 is a flowchart for a justification identification process in the seventh example. Fig. 27 is a flowchart for a log-in directory fetching process. Fig. 28 is a flowchart from the justification identification process to the print process in the eighth example. DETAILED DESCRIPTION OF THE PREFERRED EMBODIMENTS [First example] An example of the present invention will be described with reference to the drawings. Fig. 1 is a diagram showing a system configuration of this example. 1 is a console having a device for the input to a computer (e.g., keyboard) and a device for the display of a response from the computer (e.g., CRT). 2 is a CPU for controlling each device via a bus 4 and executing various processes with processing programs stored in a program memory 10, and 3 is an output device for the print-out or the display on to a screen. 20 is a data memory such as FD or HD for storing a document data or a justification identification code file 23 as hereinafter described in the file format. 30 is a main memory composed of RAM or the like, in which an input password 31, a justification identification code 32 as hereinafter described, a determined result 33, time stamp + password 34, and a comparison code 35 are stored, and comprising various work areas for use in editing the document, for example. 10 is a main memory composed of ROM or the like for storing various processing procedures including the processing procedures corresponding to the flowcharts as shown in Fig. 2 to Fig. 4, herein referred to as a program memory. Note that it is unnecessary for these memories 10, 20, 30 to the physically separate. Note that in the above and below, the content of data and the area on the memory for storing its data are not distinguished on the identification and the reference number, as long as particularly there is no trouble. Next, the processing flow of this example will be described. The processing is largely divided into two parts of creating and registering the document and identifying the justification for the content. Fig. 2 is a flowchart showing the flow of a document creating and registering process. First, al step S21, the document creator creates and edits a document using a console 1, and stores it into the document data 21 as a file. This is generally performed with a document creating/editing device called an editor. With the above operations, the document data 21 stored in the memory 20 has a time stamp (final update time) at the time of creating the file appended. This is automatically performed by the operating system such as unix. Next, at step S22, a password of the document creator is obtained. Here, the document creator is requested to input the password through the console 1, and the password input therethrough is stored in the password 31 in the memory 30. Next, at step S23, the time stamp appended to the file and the password are encoded to generate a justification identification code. This time stamp and the password may be only a byte train, rather than a character train. This code generating process will be described using the flowchart of Fig. 3. First, at step S31, the time stamp of the document data 21 and the password 31 are stored in time stamp + password 34 as a series of character train. At step S32, the time stamp + password is encoded. This encoding means can be implemented with the same algorithm as in the encoding of password in unix, for example. This is to convert a character train into another character train with a method virtually not allowing the inverse conversion. If this method only accepts the fixed-length character train (e.g., eight bytes), and the time stamp + password contains a character train exceeding that fixed-length, that character train needs to be made the fixed-length in the following way. First, the time stamp + password is separated into each eight bytes. Next, the exclusive OR (exclusive OR: EX-OR) thereof is taken sequentially. (The EX-OR of the first eight bytes and the next eight bytes is taken, and then the EX-OR of its result and the next eight bytes is taken. The following is continued in the same way.) If the remainder separated lastly is less than eight bytes, a measure for filling up the deficient bytes with blanks, for example, is taken. With such a measure, the eight byte code can be eventually obtained. This is converted into a printable character code. In doing do, the inappropriate code (e.g., a line feed code) is appropriately converted. Encoding this character code allows an encoded character train specific to the document to be obtained. Note that this encoding is not to limit the input or output to the character train, but may be handled only as the byte train. The code generated therein is called a justification identification code, and stored in the justification identification code 32 of the memory 30. At this time, the justification identification code 32 may be displayed on the console 1. With the above operation, the code generating process is completed. Next, at step S24 in Fig. 2, a correspondence process of the created document to the justification identification code is performed. In this example, the justification identification code is stored in a file having an expander appended after the document name. That is, if the created document is a file identified as "text", the justification identification code is stored in the justification identification code file 23 with a file name of "text.code". Thereby, the created document data file and the justification identification code file, in the mutually corresponding form, are stored in the memory 20. The above operation is a process for creating and registering the document. Subsequently, a justification identification process for confirming that the document thus registered is the same as at the time of creation will be described using the flowchart of Fig. 4. In the memory 20, the document data file 21 and the file containing the justification identification code or the justification identification code file 23 are already stored. First, at step S41, the file name for the identification is specified from the console 1. Next, at step S42, the password is input from the console 1 and stored in the password 31 of the memory 30. Next, at step S43, the justification identification code is generated from the time stamp of the file of interest and the input password in the same procedure as at step S23 in Fig. 2, and stored in the justification identification code 32 of the memory 30. This justification identification code 32 is newly generated, and is different from the justification identification code 32 generated in the document creating and registering process. Next, at step S44, the content (character train) of the justification identification code file 23 corresponding to the specified document data is read into the comparison code 35, for the comparison between the code 35 and the content (character train) of the justification identification code 32 generated herein. Its result is identified as yes if they are equal, or otherwise no, for example, and stored in the decision result 33. At step S45, it is displayed as the character train of "yes" or "no" on the console 1 or a screen of the output device 3. Of course, this display may be arbitrarily made if the decision result can be distinguished. Also, this comparison result may be used as an input into a certain process. Thereby, if the time stamp at the time of creation and the current time stamp as last updated are coincident, and the password input at the time of creation and the current password are coincident, the document is determined as a valid (unaltered) one. Accordingly, even if the update of the document is made undetectable with the change of the time stamp, and the content (code) of the justification identification code file 23 is rewritten with the time stamp at that time in some way in updating the document, the alteration of the document can be detected unless the same password as at the creation is used in generating the code (i.e., the password is not known). The above operation is the justification identification process. With the above-described operation, it is possible to create and register the document in the form of allowing for the justification identification in later time, and confirm whether or not the document data is rewritten after the creation. In this example, if the document is altered (or the time stamp is changed) after its registration even once, the document is decided as "invalid". [Second example] A second example of the present invention will be described. In the first example, the justification identification code was generated from the time stamp appended to the document data file and the password input by the user, while in the second example, the justification identification code is generated from the character train which is a content of the document data file and the password input by the user. Thereby, there is the advantage that the file can be decided as "valid" if the content of the document itself is not altered even though the file is updated (for example, the time stamp is changed as the file has been copied to another directory). Fig. 5 is a diagram showing the system configuration in the second example. The hardware constitution is not changed from that of Fig. 1, but the content of the memory is different in part. Specifically, the program memory 10 stores a processing procedure as shown in Fig. 6, instead of that of Fig. 3, and the main memory 30 is provided with text content + password 36, instead of time stamp + password 34 in Fig. 1. Next, the processing flow of this example will be described. This example is also divided into two sections of a document creating/registering process and a justification identification process. The processing flow of document creating/registering process is in accordance with Fig. 2. The flow from step S21 to step S22 is the same as in the first example. As the code generating process at step S23 is different from the first example, the flow of the code generating process in this example will be described with reference to Fig. 6. First, at step S61, the document content of the text data 21 and the password 31 are stored as a series of character train into text content + password 36. Note that the password and the text content may not be the character train but only the byte train. Next, at step S62, the text content + password 36 is encoded. This encoding procedure is the same as in the first example. The generated code (justification identification code) is stored in the justification identification code 32 of the memory 30. The above operation is the code generating process. Next, at step S24, the correspondence process of the justification identification code 32 to the text data 21 is executed, in the same way as in the first example. The above operation is the document creating/generating process. Subsequently, the justification identification process, for confirming that the document thus registered is the same as created, follows. This process is basically the same as in the example 1, and in accordance with Fig. 4. However, the processing at step S43 is different in that the justification identification code is generated from the text content of the file of interest and the password input at step S42, in the same procedure as at step S61 and S62. In this example, there is the effect that even if the created document file is rewritten by someone after the registration, it can be decided as valid if the content is restored eventually. This is effective when it is only necessary that the document content is the same. This is also effective because it can be confirmed that the document content is the same as original even if the owner or the file updating data is changed. [Third example] In the first and second examples as above described, the justification identification code is provided as a file independent of the corresponding document file, while in the third example, the document data and the justification identification code thereof are stored in the same file. Fig. 7 is a system configuration diagram in the third example. The hardware constitution is not changed from that of Figs. 1 and 5, but the content of the memory is different in part. Specifically, the program memory 10 stores a processing procedure as shown in Figs. 2, 4, 8, 10 and 11, and the main memory 30 is the same in Fig. 5, but the data memory 20 does not have the justification identification code file. Next, the processing flow of this example will be described. In this example, the process is also divided into two sections of a document creating/registering process and a justification identification process. The processing flow of document creating/registering process is in accordance with Fig. 2, like the previous examples. In this example, like the second example, the justification identification code 32 is generated from the text content and the input password. The feature of this example is a correspondence process as at step S24. The correspondence process of the created document to the justification identification code will be described with reference to Fig. 8. By the time of this step, the document data and justification identification code are stored in the text data 21 and the justification identification code 32, respectively. In this example, the text data and the justification identification code are stored in one file in the form of being distinguishable form each other (for example, a punctuation symbol is interposed therebetween as shown in Fig. 9). At step S81, a specific text punctuation symbol, for example, a line only consisting of a character train of <*code*>, is appended to the file end of the text data. Here, if the character train of <*code*> is used in the document, rather than as the text punctuation symbol, care must be taken out to have the line only consisting of the character train of <*code*>. At step S82, the justification identification code 32 is further appended to the file end of the text data 21. With the above operation, in the text data 21, the content of original document, and the justification identification code thereof exist in one file so as to be distinguishable with the text punctuation symbol of <*code*>. Thus, step S24 is finished. The above operation is the document creating/registering process. Subsequently, the process for confirming that the document is the same as created will be described. This process is in accordance with Fig. 4, like the previous examples. In this example, the text data file (including the justification identification code for that text) is already stored in the memory, when starting this process. First, the steps S41 and S42 are the same as in the previous examples. Next, in the code generation at step S43, the justification identification code is generated from the text data file 21 of interest and the password 31, with the encoding, and stored in the justification identification code 32. This code generating process will be described with reference to Fig. 10. This process is slightly different from the code generating process performed at the time of creating and registering the document. First, at step S101, the character train just before the punctuation symbol <*code*> in the text data 21 and the character train stored in the password 31 are stored in text content + password 36 as a series of character train. Next, at step S102, the text content + password 36 is encoded, and stored in the justification identification code 32. Here, the encoding method for the character train may be the same as in the previous examples. Thus, the code generating process at step S43 has been described. Next, at step S44, the comparison between the content (character train) of the justification identification code created beforehand and stored in the same file as the text data and the content (character train) of the justification identification code 32 created at step S43 is made. This process will be described with reference to Fig. 11. At step S111, the text data in the text data file from immediately after the text punctuation symbol until the file end is read and stored in the comparison code 36 of the memory 30. At step S112, the comparison between the content of the comparison code 36 and the content of the justification identification code 32 is made, in which yes if equal and no if otherwise is stored in the decision result 33. The above operation is the comparison decision process at step S44. Next, at step S45, the content of the decision result 33 is displayed on the console 1 or the screen of the output device 3, for example, as the character train of "yes". Also, this may be used as the input into a certain process. Thus, the justification identification process is completed. In this example, there is the same effect as in the second example because the text content is used for the generation of the justification identification code, and there is a further effect that the file management can be facilitated by making the text data and the justification identification code in one file. With the present invention, there is provided the effect that it can be confirmed whether or not the text content has been rewritten for a text file, as above described. [Fourth example] When the code is created from the input password and the last updated lime of the text, as in the first example, the addition of the code is an update of the text data if the justification identification code including the time and the text data are stored in the same text data, as in the third example, so that the time information (last update time at the code generation) in the justification identification code and the time stamp (update time of appending the generated code) in the text data are inconsistent, whereby there is the problem that even if the confirmation is made in this state, the rewrite is always determined, and it can not be decided whether or not the improper rewrite has been made. In this example, the justification identification code and the text are stored in the same text in the form of being distinguishable from each other, in which the time stamp of the created document is made coincident with the time in the code, so that the consistency with the time information contained in the code is retained to allow the code for confirming the alteration of the text content to be stored in the same file as the text. Fig. 12 is a system configuration diagram in this example. It is different from Fig. 1 in the content of the program memory 10 and in that a regular time stamp 37 as will be described later is provided in the main memory 30. Next, the processing flow of this example will be described. The process is also divided into two sections of a document creating/registering process and a justification identification process for the text content. The processing flow of document creating/registering process is in accordance with the flowchart of Fig. 2, like the previous examples. In the flow, the process up to the code generation is the same as in the first example, and the explanation will be described. Next, at step S24, the process of creating the text data 21 including the justification identification code 32 by appending the justification identification code 32 to the document data 21 is performed. The correspondence process will be described with reference to Fig. 13. Before the step S24, the document data 21 and justification identification code 32 are stored. In this example, the text data followed by the justification identification code is stored in one file in the form of being distinguishable from each other (for example, a punctuation symbol is interposed therebetween) (Fig. 9). At step S131, the time stamp of the text data 21 is fetched and stored as the regular time stamp 37 of the text data 21. At step S132, a specific text punctuation symbol, for example, a line only consisting of a character train of <*code*>, is appended to the file end of the text data. Accordingly, if the character train of <*code*>, is used as the text content, rather than the text punctuation symbol, care must be taken not to produce the line only consisting of the character train of <*code*>. At step S133, the justification identification code 32 is further appended to the file end of the text data 21. With the above operation, in the text data 21, the content of original document, and the justification identification code thereof exist in one file in the form of being distinguishable with the text punctuation symbol of <*code*>. However, the time stamp of the text data 21 has been updated with the process of appending the punctuation symbol and the justification identification code at steps S132 and S133, and is different from the time stamp at the time of generating the justification identification code 32, so that the time stamp written in the justification identification code 32 and that of the text data 21 are inconsistent. Thus, at step S134, the time stamp of the text data 21 is replaced with the regular time stamp 37, so that the time stamp used for the generation of the justification identification code 32 and that of the text data 21 are held consistent. This time stamp replacement process can be implemented, for example, by using "utime" (a system call for altering the time stamp of the file) which is one of the system calls in the UNIX operating system. Fig. 14 shows the transition state for the text data and the time stamp in each step of Fig. 13 in the correspondence process of the text data to the justification identification code, as described in Fig. 13. The above operation is the document creating and registering process. The process for identifying the justification for the registered text can be performed in the same way as in the third example , using the text data 21 (including the justification identification code for that text). With this example, there is the effect that the management is facilitated because the identification code generated using the time information can be stored in the same one file as the original text, using the time information appended to the text data for the identification of text justification. [Fifth example] In the previous examples, the time stamp used in generating the justification identification code was the time stamp of the text data 21 originally created. This example is characterized in that arbitrary time can be set as the time stamp in generating the justification identification code. Fig. 15 is a system configuration diagram of this example. The hardware constitution is the same as in Fig. 1, except that the user can input an arbitrary time information for the time stamp from the console 1, and the processing procedure for appending the time stamp based on the input information is provided in the memory 10, and therefore the detailed explanation for other portions will be omitted. The processing flow of this example is substantially the same as in the fourth example, but different from the previous examples in the justification identification code generating process and the correspondence process of the text data to the justification identification code, which is a feature of this example. The justification identification code generating process will be described with reference to Fig. 16. First, at step S161, an arbitrary time is input from the console 1, and its result is stored in the regular time stamp 37. For example, the current time may be used as the regular time stamp, by inputting "now", or the free time (year/month/date/minute/second) may be set. Then, like the fourth example, at steps S162 and S163, the regular time stamp 37 and the password 31 are stored in time stamp + password 34, and encoded to generate the justification identification code, which is then stored in the justification identification code 32 of the memory 30. With the above operation, the justification identification code generating process is completed. Next, the correspondence process will be described with reference to Fig. 17. It is also supposed, like the previous examples, that the text data 21 and the justification identification code 32 have been already stored at the time of performing the correspondence process. Also, in this example, the justification identification code is stored after the text data in one file in the form of being distinguishable from each other (for example, a punctuation symbol is interposed therebetween) (Fig. 9), like the fourth example. At step S171, a specific text punctuation symbol, for example, a line only consisting of a character train of <*code*>, is appended to the file end of the text data 21. If the character train of <*code*> is used as the text content, rather than the punctuation symbol, care must be taken not to produce the line only consisting of the character train of <*code*>. At step S172, the justification identification code 32 generated at step S163 is further appended to the file end of the text data 21. With the above operation, in the text data 21, the content of original document, and the justification identification code thereof exist in one file in the form of being distinguishable with the text punctuation symbol of <*code*>. However, the time stamp of the text data 21 has been updated with the process of appending the punctuation symbol and the justification identification code in the same procedure as at steps S132 and S133 of the fourth example, and is different from the time stamp at the time of generating the justification identification code 32. Accordingly, the time stamp written in the justification identification code 32 and that in the text data 21 are inconsistent. Thus, using the time stamp replacement process at step S173, the time stamp of the text data 21 is replaced with the regular time stamp 37, so that the time stamp written in the justification identification code 32 and that of the text data 21 are held consistent. With the above operation, the correspondence process is completed. Here, the regular time stamp 37 is one as set with the time stamp input at step S161. This time stamp replacement process can be implemented, like the previous example, by using the system call "utime". Fig. 18 shows the transition state for the text data and the time stamp in each step of Fig. 17 in the correspondence process of the text data to the justification identification code, as described in Fig. 17. With this example, there is the effect that the time stamp of the text data which constitutes a part of the justification identification code can be freely set irrespective of the current time. [Sixth example] With the previous examples there is a problem that when a plurality of documents are required to be sequentially confirmed, the input operation for the password is complex. In this example, the identification code is generated using the information of identifying the user not dependent on the text, instead of the password for each text. Fig. 19 is a system configuration diagram of this example. This system is only different from Fig. 5 in the content of the program memory 10, and in that the main memory 30 is provided with a user name 38 as will be described later and a text content + user name 39, instead of the password 31 and the text content + password 36. The processing flow of this example is largely divided into two sections of a document creating and registering process and a justification identification process for the content. Fig. 20 is a flowchart showing the document creating and registering process. First, at step S201, the text is created and edited, and stored in the text data 21 as a file, like the previous examples. Next, at step S202, the user name of the text creator is obtained, and stored in the user name 38. This is obtained with a whoami command in the unix, C-shell, for example. At step S203, the justification identification code is generated by encoding the content of the text data 21 and the character train stored in the user name 38. This code generating process can be executed with a procedure of storing the content of the text data 21 and the user name 38 into the text content + user name 39 as a series of character train (step S211), and encoding the text content + user name 39 (step S212), as shown in Fig. 21. This is fundamentally the same as in Fig. 3, and the detailed explanation will be omitted. The generated code is stored as the justification identification code 32, and the code generating process is completed. At step S204, the correspondence process of the created text to the justification identification code is executed. This can be performed like the first example, and the correspondence of the text data to the justification identification code can be done by storing the justification identification code into the file having the file name of the text file name followed by the expander (extension). Thus, the created text data 21 file and the justification identification code file 23 have been stored in the memory 20 in the mutual corresponding form. The above operation is the text creating and registering process. Subsequently, the process of confirming whether or not the text thus registered is the same as created will be described with reference to Fig. 22. This process is fundamentally the same as in Fig. 4, except that the user name is obtained (step S222), instead of the password input (step S42) of Fig. 4, and therefore the step S222 will be only described. In this step, a user name of the user to perform the identification process is obtained and stored in the user name 38 of the memory 30. This is the same as at step S202 of Fig. 20. Then, the justification identification code is generated from the content of specified text data 21 and the user name 38, and compared with the content of justification identification code file 23 corresponding to the specified text data, in which yes if they are equal, or no if otherwise is displayed on the screen of the console 1. This result may be also used as the input into a certain process. With this example, the registration and identification operation for a plurality of texts can be simplified, because the input of the password is unnecessary for each text as above described. [Seventh example] Fig. 23 is a system configuration diagram of this example. The hardware constitution is not different from Fig. 19, but the memory is different in part. Specifically, the program memory 10 stores a processing procedure of this example, the main memory 30 has a log-in directory 40, and a text content + log-in directory 41, instead of the text content + user name 34 as shown in Fig. 19, and the data memory 20 has a correspondence table 24 as will be described later. The processing flow of this example is largely divided into two sections of a text creating/registering process and a justification identification process for the content. Fig. 24 shows a processing flow for the text creating/registering process. First, at step S241, the text is created and edited, and at step S242, a user name of the text creator is obtained. This portion is the same as steps S201 and S202. Next, at step S243, the log-in directory of the text creator is obtained from the user name obtained at step S242 and the correspondence table 24, and stored in the log-in directory 40. The correspondence table 24 is a correspondence table between the user name and the log-in a directory, and equivalent to a /etc/passwd file in the unix system. In the /etc/passwd/ file, the first field indicates the user name and the sixth field indicates the log-in directory. The step of fetching the log-in directory will be described with reference to Fig. 27. First, at step S271, the log-in name of the user is stored in the user name 38. The log-in name can be obtained by using a whoami command of C-shell in the unix system. Next, at step S272, the log-in directory corresponding to the user name 38 obtained at step S271 is obtained using the correspondence table 24 describing the correspondence relation between the user name and the log-in directory, and stored in the log-in directory 40. At step S244, the content of the text data 21 and the character train stored in the log-in directory 40 are encoded to generate the justification identification code. This code generating process is to store the content of the text data 21 and the log-in directory 40 into the text content + log-in directory 36 as a series of character train at step S251, and encode the character train stored in the text content + log-in directory 41 at step S252, as shown in Fig. 25. The generated code is stored as the justification identification code 32, and the code generating process is completed. At step S204, the correspondence process of the created text to the justification identification code is executed. In this example, like the first example, the created text data 21 file and the justification identification code file 23 can be stored in the memory 20 in the mutually corresponding form by storing the justification identification code into the file having the file name of the text file name followed by the expander. Thus, the created text data 21 file and the justification identification code file 23 have been stored in the memory 20 in the mutual corresponding form. The above operation is the text creating and registering process. Subsequently, the process of confirming whether or not the text thus registered is the same as created will be described with reference to Fig. 26. This process is fundamentally the same as in Fig. 4, except that the log-in directory is fetched (step S262), instead of the password input (step S42) of Fig. 4, and therefore the step S262 only will be described. In this step, a log-in directory of the user to perform the identification is obtained and stored in the log-in directory 40 of the memory 30. This is the same as at steps S242 and S243 of Fig. 24. Then, the justification identification code is generated from the content of specified text data 21 and the log-in directory 40, and compared with the content of justification identification code file 23 corresponding to the specified text data, in which yes if they are equal, or no if otherwise is displayed on the screen of the console 1. This result may be also used as the input into a certain process. With this example, the management can be simplified by providing a plurality of users having the same log-in directory, because the log-in directory referenced indirectly from the user name is used as the password for the text registration and the text identification. [Eighth example] In this example, depending on the result of justification identification, the text data is processed if the justification is identified, and excluded from the processing if not. The system configuration of this example is the same as in Fig. 1. However, the program memory 10 further includes a processing procedure corresponding to the flowchart of Fig. 28. Next, the processing flow of this example will be described. The process is largely divided into two sections of a text creating/registering process and a process of identifying the justification of the text data for a requested processing and switching the process depending on its result (or executing if it is justified, or not executing if not). The processing flow for the text creating/registering process is the same as described in connection with the flowchart of Fig. 2 in the first example. When some processing is taken for such a registered text, the process of switching the requested processing depending on the result of justification identification will be described. As an example of the requested processing, a process of printing the text registered in the previous process (Zprint) will be described. This processing will be described with reference to Fig. 28. This process consists of a justification identification processing portion for identifying the justification of the text data and a portion for switching the execution or refusal of the print depending on the result of the previous process. First, at step S281, the file name of interest, as well as the processing command (Zprint), are input from the console 1. Next, at step S282, the justification identification process for identifying the justification of the text data is executed. The detail of this process is omitted as it is the same as in the first example. As a result of this process, the decision result of valid or invalid is stored in the decision result 33, like the previous example. At step S283, the processing is performed depending on the content of the decision result 33. That is, the print output of the specified text data is performed if the content of the decision result 33 is "yes", and a message that the print output can not be made as a result of justification identification is displayed on the console 1 (for example, displayed as "print output disabled") if the content of the decision result 33 is "no" (the password or the text content is different from that at the creation). With the above process, it is possible to confirm whether the text data created and registered has been rewritten after the creation or not, and execute or refuse the requested process depending on the result. With the method of this example, it is possible to execute or refuse the requested process by confirming whether or not the request is from the authorized user, rather than the justification of the text. Accordingly, when a plurality of persons jointly participate in the creation of one text by dividing the text into respective portions of the text on the computer, it is possible to avoid the possibility that one's portion in charge is processed (e.g., printed) as a part of the text by others when it is not completed. While in this example the justification identification code was derived from the time stamp appended to the text data file and the password input by the user, it will be appreciated that whcn the code is generated with other methods as described in the previous examples, the switching of the processing like this example is also permitted. In this example, the print processing (Zprint) was adopted as an example of the text processing, and the switching between the execution and the pending (non-execution) was performed. Here. a further processing, for example, issuing an electronic mail for the disabled print to the specific destination, may be provided to output the print if the result is "yes", , or the electronic mail is issued if it is "no". That is, a plurality of executable text processings are prepared, and the processing for execution is switched depending on the decision result. With this example, there is the effect that for a text file, it is possible to confirm whether or not the content of the text has been rewritten, and control the execution of the requested process for the text data depending on its result, so that anyone can freely read or write the text data, but the processing by the unauthorized user or the processing for the rewritten text data can be made invalid, as above described. Note that in the above examples, the data of interest for deciding the presence or absence of the alteration of the content was text data, but could also be program data. The present invention can be implemented by a system consisting of one or more devices. Further, it will be appreciated that the present invention is also applicable when accomplished by supplying a program to the system.

Claims: A method for determining on the basis of user information whether an improper rewrite of stored data has occurred in a file storage system, the file storage system being such that plural users having different user information may have rewritten the stored data, the method comprising the steps of: (a) when data (21) is to be stored: generating a first code (32) in accordance with a pre-determined procedure by inputting the user information and generating a code by converting the inputted user information and a predetermined portion of the data (21); storing said data (21); and storing said first code (32) in correspondence with said stored data; and (b) when reading out stored data (21): generating a second code (35) on the basis of inputted user information and said predetermined portion of the read out data in accordance with said predetermined procedure; comparing said second code (35) with the code (32) stored in correspondence with said stored data (21); and determining whether said stored data (21) has been rewritten by a user having different user information, based upon the result of said comparison. A method according to claim 1, wherein the predetermined portion of the data comprises the data (21) itself. A method according to claim 1, wherein when data (21) is to be stored, said data is stored with a first storage time (T1) appended distinguishably and said predetermined portion of the data (21) comprises said first storage time (T1) appended to the data. A method according to claim 3, further comprising the steps of: when data (21) is to be stored: storing said data (21) with a second storage time (T3) appended distinguishably; and changing said appended second storing time (T3) to said first storing time (T1). A method according to claim 1, further comprising the step of: when data is to be stored, inputting time information (Tx) as a storage time; wherein when data (21) is to be stored, said data is stored with said storage time (Tx) appended distinguishably and said predetermined portion of the data (21) comprises said storage time (Tx) appended to the data. A method according to any of the preceding claims, further comprising the step of when reading out stored data (21), executing a first process if said first code (32) and said second code (35) are determined to be equal. A method according to claim 6, further comprising the step of when reading out stored data (21), executing a second process if said first code (32) and said second code (35) are determined to be not equal. A method according to any of the preceding claims, wherein said user information is a password (31). A method according to any of claims 1 to 7, wherein said user information is a user name (38). A method according to any of claims 1 to 7, wherein said user information is a log-in directory (40) corresponding to a plurality of users. A method according to any of the preceding claims, wherein said data (21) comprises text. A method according to any of claims 1 to 10, wherein said data (21) comprises a program. A method according to any of the preceding claims, wherein said data (21) to be stored and said first code (32) corresponding thereto are stored in the same file, distinguished from each other. A method according to any of claims 1 to 12, wherein said first code (32) is stored in a file having a file name comprising file name for said data (21) corresponding to the first code (32) followed by an extension.

Inventors: NAGASHIMA MASAAKI, OKUNO YASUHIRO, SASAKI TAKAYUKI, YAMAKAWA TADASHI, NAGASHIMA, MASAAKI, OKUNO, YASUHIRO, SASAKI, TAKAYUKI, YAMAKAWA, TADASHI, NAGASHIMA, MASAAKI, C/O CANON KABUSHIKI KAISHA, Okuno, Yasuhiro, c/o Canon Kabushiki Kaisha, Sasaki, Takayuki, c/o Canon Kabushiki Kaisha, YAMAKAWA, TADASHI, C/O CANON KABUSHIKI KAISHA
Applicants: CANON KK, CANON KABUSHIKI KAISHA
Application year: 1992
Main classification: G06F12
IPC codes: G06F21