CN103220352B - Terminal, server, file storage system and file storage method - Google Patents
Terminal, server, file storage system and file storage method Download PDFInfo
- Publication number
- CN103220352B CN103220352B CN201310130998.2A CN201310130998A CN103220352B CN 103220352 B CN103220352 B CN 103220352B CN 201310130998 A CN201310130998 A CN 201310130998A CN 103220352 B CN103220352 B CN 103220352B
- Authority
- CN
- China
- Prior art keywords
- file
- type
- server
- character information
- upper transmitting
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Active
Links
Landscapes
- Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
- Information Transfer Between Computers (AREA)
- Storage Device Security (AREA)
Abstract
The invention provides a terminal. The terminal comprises a transmitting unit, a terminal side storage unit, a terminal side type determining unit, a terminal side judging unit and a terminal side processing unit. The transmitting unit is used for transmitting a request for acquiring file information. The terminal side storage unit is used for receiving the file information transmitted by a server and extracting and storing a list of types of files which are prohibited from being uploaded, and the format feature information of files of various types. The terminal side type determining unit is used for reading the content of the uploaded file when the uploaded file is received, and comparing the content of the upload file with the feature information of the files of the various types so as to determine the file type of the upload file. The terminal side judging unit is used for reading the stored the list of the types of the files which are prohibited from being uploaded, and judging whether the file type of the upload file can be found in the list. The terminal side processing unit is used for prohibiting the upload file from being uploaded to the server if a detected judging result shows that the file type of the upload file can be found in the list, and is used for allowing the upload file to be uploaded to the server if the detected judging result shows that the file type of the upload file cannot be found in the list. The invention further provides the server, a file storage system and a file storage method. Through the terminal, the server, the file storage system and the file storage method, the formats of files uploaded by a user can be limited, and storage space can be saved.
Description
Technical field
The present invention relates to field of terminal technology, in particular to a kind of terminal, a kind of server, a kind of storage of file
System and a kind of file memory method.
Background technology
With the fast development of information technology, user can generate substantial amounts of data file, enterprises and institutions in routine duties
Unit information manager often purchases storage server and provides the user storage, backup, shared service.But in this process
In, often some and the unrelated data file that works, such as music, film, game etc. upload to storage clothes to a lot of users
On business device, cause that a large amount of garbage files are existed on storage server, space availability ratio is low.The waste of memory space is exactly cost
Waste, each unit generally require spend substantial contribution purchase more storage servers.
In the prior art, mainly there is following several method saving memory space:1st, data compression technique, deposits to data
Storage and reading are compressed/decompression operation, reduce the space hold amount of data;2nd, user's space limits, and limits each user
The gross space of the data that can upload;3rd, forbid uploading the file of some suffix name.
The defect of prior art is:Scheme 1, data compression can cause the bottleneck on server performance, and impact is using upper
Fluency;Scheme 2 is although limit the use space of unique user, but user still can upload garbage files, and manager is normal
The space that each user of Chang Wufa accurate assurance needs;Scheme 3, user pass through change file suffix name just can easily around
Open.
Accordingly, it would be desirable to a kind of new file storage technology, the form of the file of user's upload can be limited, thus save depositing
Storage space, reaches cost-effective purpose.
Content of the invention
The present invention is based on the problems referred to above it is proposed that a kind of new file storage technology, can limit user's upload
The form of file, thus saving memory space, reaches cost-effective purpose.
In view of this, the present invention proposes a kind of terminal, including:Transmitting element, sends to server and obtains fileinfo
Request, so that described server sends described fileinfo to described terminal according to described request, wherein, described fileinfo
Including the format character information forbidding upload file type list and each type file;End side memory element, receives described
The described fileinfo that server sends, extract described in forbid uploading the lattice of file type list and each type file described
Formula characteristic information, and stored;End side type determining units, when receiving upper transmitting file, read described upper transmitting file
File content, by the format character of described file content and each type file described in the storage of described end side memory element
Information is contrasted, to determine the file type of described upper transmitting file;End side judging unit, reads the storage of described end side single
Forbid uploading file type list described in unit's storage, and judge to forbid whether searching in upload file type list described
File type to described upper transmitting file;End side processing unit, if detect the judged result of described end side judging unit
It is yes, then forbids described upload files passe to described server, if the judgement knot of described end side judging unit is detected
Fruit is no, then allow described upload files passe to described server, so that described server is carried out to described upper transmitting file
Process.
In this technical scheme, the format character of the file content of upper transmitting file and each type file is compared,
So by being identified to the form of upper transmitting file, the file type of transmitting file in determination, thus it is specific to forbid that user uploads
The file of the type such as the file type of form, such as music, film, game, has so reached the rubbish reducing storage on server
Rubbish file, improves the utilization rate in space, the purpose of investment reduction cost.
It is preferable that described transmitting element is additionally operable in technique scheme:When detecting from described server
When list update notifies, send, to described server, the request that forbidding upload file type list obtaining after updating, for institute
State server and file type list is uploaded to described terminal according to forbidding after the described renewal of described request transmission;And described end
Side memory element is additionally operable to:Receive and store forbidding after the described renewal that described server sends and upload file type row
Table.
In this technical scheme, when management personnel are on the server to forbidding that uploading file type list modifies or more
When new, terminal also can keep the synchronization of server, update and forbid uploading file type list, thus effectively forbidding certain kinds
The files passe of type is to server.
It is preferable that described end side type determining units also include in technique scheme:It is single that son is searched in end side
Unit, starts to read file content from the beginning of described upper transmitting file, reads a byte every time, and reading a byte
When, the format character information of the byte of reading and each type file described is compared, searched whether with described on
The consistent format character information of transmitting file, if finding, determines file type according to described format character information, if not searching
Arrive, then continue to read file content, until finding the format information consistent with described upper transmitting file or determining described upload literary composition
Till part is all inconsistent with the format character information of each type file;And end side notifies subelement, described detecting
When end side is searched subelement and had determined that the format character information of described upper transmitting file and each type file is all inconsistent, notify
Described end side processing unit allows described upload files passe to described server, so that described server is to described upload
File is processed.
In this technical scheme, the format character information byte-by-byte of upper transmitting file and each type file is compared
Right, so that it is determined that the corresponding file type of upper transmitting file, so file type is determined by file format, it is to avoid user is permissible
File is modified and gets around the problem of the restriction of upper transmitting file, thus effectively forbidding the upload of particular type file, section
The memory space of about server, improves the space availability ratio of server.
The invention allows for a kind of server, including:Server side memory element, storage file information, and receiving
During the acquisition request of arrival self terminal, send described fileinfo to described terminal, wherein, described fileinfo includes forbidding
Transmitting file list of types and the format character information of each type file;File reception unit, receives upper from described terminal
Transmitting file;Server side type determining units, read the file content in described upper transmitting file, by described file content and storage
Described format character information contrasted, to determine the file type of described upper transmitting file;Server side judging unit, reads
Forbid described in storage uploading file type list, and judge to forbid whether finding in upload file type list described
The file type of described upper transmitting file;Server side processing unit, if detect the judgement knot of described server side judging unit
Fruit is yes, then delete described upper transmitting file, if the judged result described server side judging unit is detected is no, stores institute
State transmitting file.
In this technical scheme, in order to prevent terminal from getting around the inspection of file type after artificially being cracked, and lead to service
The file forbidding uploading is stored by device, and therefore server end also can carry out the two of file type to the upper transmitting file receiving
Secondary identification checks, thus thoroughly avoiding the problem forbidding that the file uploading stores in the server.
It is preferable that also including in technique scheme:Information generating unit, analyzes the file of multiple same types, from
In extract the type file format character, and generate the format character information of type file, to be stored.
In this technical scheme, because its concrete form of different types of file is different, and the file of same type
General character all can be existed on form, therefore, by being identified to file format can determine the files classes belonging to certain file
Type, wherein format character information can server the file of a large amount of same types is analyzed after generate, and after storing
As the standard judging file type.
It is preferable that described server side type determining units also include in technique scheme:Server side searches son
Unit, starts to read file content from the beginning of described upper transmitting file, reads a byte every time, and reading a byte
When, the format character information of the byte of reading and each type file described is compared, searched whether with described on
The consistent format character information of transmitting file, if finding, determines file type according to described format character information, if not searching
Arrive, then continue to read file content, until determining that described upper transmitting file is all differed with the format character information of each type file
Till cause;Server side notifies subelement, detect described server side search subelement have determined that on described transmitting file with
When the format character information of each type file is all inconsistent, notify that described server side processing unit storage is described to upload literary composition
Part.
In this technical scheme, the format character information byte-by-byte of upper transmitting file and each type file is compared
Right, so that it is determined that the corresponding file type of upper transmitting file, so file type is determined by file format, it is to avoid user is permissible
File is modified and gets around the problem of the restriction of upper transmitting file, thus effectively forbidding the storage of particular type file, section
The memory space of about server, improves the space availability ratio of server.
It is preferable that also including in technique scheme:Arranging unit, according to the setting instruction receiving, setting is forbidden
The file type list uploading;List update unit, when the file type list forbidding described in detecting uploading has renewal, obtains
Forbidding after renewal is taken to upload file type list, to be stored by described server side memory element, and to described terminal
Transmission list update notification, so that described terminal forbids uploading file type list according to the renewal of described notice.
In this technical scheme, management personnel can arrange the file type forbidding uploading as needed on the server,
And renewal of can modifying at any time, terminal meeting server holding synchronization, so facilitate the operation of user, user only needs to
Simply it is configured just can effectively forbidding certain types of files passe, save the cost of investment of user.
The invention allows for a kind of document storage system, including terminal server recited above.
According to a further aspect in the invention it is also proposed that a kind of file memory method, including:Step 402, described terminal to
Server sends the request obtaining fileinfo, so that described server is extremely described according to the described request described fileinfo of transmission
Terminal, wherein, described fileinfo includes the format character information forbidding uploading file type list and each type file;Step
Rapid 404, receive the described fileinfo that described server sends, extract described in forbid uploading file type list and described each
The format character information of individual type file, and stored;Step 406, when receiving upper transmitting file, reads described upload literary composition
The file content of part, the described format character information of described file content and storage is contrasted, to determine described upload literary composition
The file type of part;Step 408, reads and forbids described in storage uploading file type list, and judges to forbid uploading described
The file type of described upper transmitting file whether can be found, if the determination result is YES, then forbidding will be described in file type list
Upload files passe to described server, if judged result is no, allow described upload files passe to described server,
To be processed to described upper transmitting file by described server.
In this technical scheme, the format character of the file content of upper transmitting file and each type file is compared,
So by being identified to the form of upper transmitting file, the file type of transmitting file in determination, thus it is specific to forbid that user uploads
The file of the type such as the file type of form, such as music, film, game, has so reached the rubbish reducing storage on server
Rubbish file, improves the utilization rate in space, the purpose of investment reduction cost.
It is preferable that described step 402 also includes in technique scheme:When detecting from described server
When list update notifies, send, to described server, the request that forbidding upload file type list obtaining after updating, for institute
State server and file type list is uploaded to described terminal according to forbidding after the described renewal of described request transmission;And described step
Rapid 404 also include:Receive and store forbidding after the described renewal that described server sends and upload file type list.
In this technical scheme, when management personnel are on the server to forbidding that uploading file type list modifies or more
When new, terminal also can keep the synchronization of server, update and forbid uploading file type list, thus effectively forbidding certain kinds
The files passe of type is to server.
It is preferable that described step 406 also includes in technique scheme:Start to read from the beginning of described upper transmitting file
Take file content, read a byte every time, and when having read a byte, by the byte of reading and each type described
The format character information of file is compared, and searches whether the format character information consistent with described upper transmitting file, if searching
Arriving, then file type is determined according to described format character information, if not finding, continuing to read file content, until determining
Till described upper transmitting file is all inconsistent with the format character information of each type file;And have determined that on described detecting
It is allowed to by described upload files passe to described service when the format character information of transmitting file and each type file is all inconsistent
Device, so that described server is processed to described upper transmitting file.
In this technical scheme, the format character information byte-by-byte of upper transmitting file and each type file is compared
Right, so that it is determined that the corresponding file type of upper transmitting file, so file type is determined by file format, it is to avoid user is permissible
File is modified and gets around the problem of the restriction of upper transmitting file, thus effectively forbidding the upload of particular type file, section
The memory space of about server, improves the space availability ratio of server.
The invention allows for a kind of file memory method, including:Step 502, storage file information, and arrive receiving
During the acquisition request of self terminal, send described fileinfo to described terminal, wherein, described fileinfo includes forbidding uploading literary composition
Part list of types and the format character information of each type file;Step 504, receives the upper transmitting file from described terminal;Step
Rapid 506, read the file content in described upper transmitting file, the described format character information of described file content and storage is carried out
Contrast, to determine the file type of described upper transmitting file;Step 508, reads and forbids described in storage uploading file type list,
And judge to forbid uploading the file type that whether can find transmitting file on described in file type list described;Step 510,
If it is yes for judged result is detected, delete described upper transmitting file, if it is no for judged result is detected, store described upload literary composition
Part.
In this technical scheme, in order to prevent terminal from getting around the inspection of file type after artificially being cracked, and lead to service
The file forbidding uploading is stored by device, and therefore server end also can carry out the two of file type to the upper transmitting file receiving
Secondary identification checks, thus thoroughly avoiding the problem forbidding that the file uploading stores in the server.
It is preferable that described step 502 also includes in technique scheme:Analyze the file of multiple same types, therefrom
Extract the format character of the file of the type, and generate the format character information of type file, so that described server is carried out
Storage.
In this technical scheme, because its concrete form of different types of file is different, and the file of same type
General character all can be existed on form, therefore, by being identified to file format can determine the files classes belonging to certain file
Type, wherein format character information can server the file of a large amount of same types is analyzed after generate, and after storing
As the standard judging file type.
It is preferable that described step 506 also includes in technique scheme:Start to read from the beginning of described upper transmitting file
Take file content, read a byte every time, and when having read a byte, by the byte of reading and each type described
The format character information of file is compared, and searches whether the format character information consistent with described upper transmitting file, if searching
Arriving, then file type is determined according to described format character information, if not finding, continuing to read file content, until determining
Till described upper transmitting file is all inconsistent with the format character information of each type file;Have determined that described upload literary composition detecting
When the format character information of part and each type file is all inconsistent, store described upper transmitting file.
In this technical scheme, the format character information byte-by-byte of upper transmitting file and each type file is compared
Right, so that it is determined that the corresponding file type of upper transmitting file, so file type is determined by file format, it is to avoid user is permissible
File is modified and gets around the problem of the restriction of upper transmitting file, thus effectively forbidding the storage of particular type file, section
The memory space of about server, improves the space availability ratio of server.
It is preferable that described step 502 also includes in technique scheme:According to the setting instruction receiving, setting is prohibited
The file type list only uploading;And when detect forbid upload file type list have renewal when, obtain update after
Forbid uploading file type list, to be stored, and to described terminal transmission list update notification, for described terminal according to
The renewal of described notice is forbidden uploading file type list.
In this technical scheme, management personnel can arrange the file type forbidding uploading as needed on the server,
And renewal of can modifying at any time, terminal meeting server holding synchronization, so facilitate the operation of user, user only needs to
Simply it is configured just can effectively forbidding certain types of files passe, save the cost of investment of user.
The invention allows for a kind of file memory method, including:Step 602, terminal to server sends and obtains file
The request of information, wherein, described fileinfo includes the format character forbidding uploading file type list and each type file
Information;Step 604, fileinfo described in described server storage, and when receiving from the acquisition request of described terminal, send out
Send described fileinfo to described terminal;Step 606, described terminal receives the described fileinfo that described server sends, and carries
Forbid described in taking-up uploading the format character information of file type list and each type file described, and stored;Step
608, receive transmitting file in described terminal, read the file content in described upper transmitting file, by described file content and institute
State format character information to be contrasted, to determine the file type of described upper transmitting file;Step 610, described terminal reads storage
Forbid upload file type list, and judge described forbid upload file type list in whether can find described upload
The file type of file, if the determination result is YES, then forbids described upload files passe to described server, if judged result
It is no, then allow described upload files passe to described server;Step 612, described server receives and is derived from described terminal
Described upper transmitting file, read out the file content in described upper transmitting file, by described file content with storage described form
Characteristic information is contrasted, to determine the file type of described upper transmitting file;Step 614, described server reads the taboo of storage
Only upload file type list, and judge to forbid uploading in file type list whether can find transmitting file on described described
File type, if the determination result is YES, then delete described upper transmitting file, if judged result is no, store described upload literary composition
Part.
In this technical scheme, the format character of the file content of upper transmitting file and each type file is compared,
So by being identified to the form of upper transmitting file, determine the file type of transmitting file in terminal, thus forbidding uploading specific
The file type of form(The file of the such as type such as music, film, game)To server.Meanwhile, in order to prevent terminal by people
For getting around the inspection of file type after cracking, and server is led to be stored the file forbidding uploading, therefore server end
Also the upper transmitting file receiving can be carried out with the secondary identification inspection of file type, thus thoroughly avoiding the file forbidding uploading
The problem storing in the server, has reached the garbage files reducing storage on server, improves the utilization rate in space, saves and throws
The purpose of money cost.
It is preferable that described step 604 also includes in technique scheme:The multiple same type of described server analysis
File, therefrom extract the format character of the file of the type, and generate the format character information of type file, to be deposited
Storage.
In this technical scheme, because its concrete form of different types of file is different, and the file of same type
General character all can be existed on form, therefore, by being identified to file format can determine the files classes belonging to certain file
Type, wherein format character information can server the file of a large amount of same types is analyzed after generate, and after storing
As the standard judging file type.
It is preferable that described step 608 also includes in technique scheme:Start to read from the beginning of described upper transmitting file
Take file content, read a byte every time, and when having read a byte, by the byte of reading and each type described
The format character information of file is compared, and searches whether the format character information consistent with described upper transmitting file, if searching
Arriving, then file type is determined according to described format character information, if not finding, continuing to read file content, until determining
Till described upper transmitting file is all inconsistent with the format character information of each type file;And have determined that on described detecting
It is allowed to by described upload files passe to described service when the format character information of transmitting file and each type file is all inconsistent
Device, so that described server is processed to described upper transmitting file;Described step 612 also includes:From opening of described upper transmitting file
Head starts to read file content, every time reads a byte, and when having read a byte, by the byte of reading with described
The format character information of each type file is compared, and searches whether the format character letter consistent with described upper transmitting file
Breath, if finding, determines file type according to described format character information, if not finding, continues to read file content,
Till determining that described upper transmitting file is all inconsistent with the format character information of each type file;And it is true detecting
When the format character information of fixed described upper transmitting file and each type file is all inconsistent, store described upper transmitting file.
In this technical scheme, the format character information byte-by-byte of upper transmitting file and each type file is compared
Right, so that it is determined that the corresponding file type of upper transmitting file, so file type is determined by file format, it is to avoid user is permissible
File is modified and gets around the problem of the restriction of upper transmitting file, thus effectively forbidding the storage of particular type file, section
The memory space of about server, improves the space availability ratio of server.
It is preferable that described step 604 also includes in technique scheme:Described server is according to the setting receiving
Instruction, the file type list uploading is forbidden in setting;And when described server detects the file type list forbidding uploading
When having renewal, obtain forbidding after updating and upload file type list, to be stored, and update to described terminal transmission list
Notify;Described step 602 also includes:When detecting from the list update notice of described server, described terminal is to institute
State server and send the request that forbidding upload file type list obtaining after updating, so that described server is according to described request
Send forbidding after described renewal and upload file type list to described terminal;Described step 606 also includes:Described terminal receives
And store forbidding after the described renewal that described server sends and upload file type list.
In this technical scheme, management personnel can arrange the file type forbidding uploading as needed on the server,
And renewal of can modifying at any time, terminal meeting server holding synchronization, so facilitate the operation of user, user only needs to
Simply it is configured just can effectively forbidding certain types of files passe, save the cost of investment of user.
By above technical scheme, the form of the file of user's upload can be limited, thus effectively reducing storage service
The garbage files of storage on device, improve the space availability ratio of storage server, save the cost of investment of user.
Brief description
Fig. 1 shows the block diagram of terminal according to an embodiment of the invention;
Fig. 2 shows the block diagram of server according to an embodiment of the invention;
Fig. 3 shows the block diagram of document storage system according to an embodiment of the invention;
The flow chart that Fig. 4 shows file memory method according to an embodiment of the invention;
The flow chart that Fig. 5 shows file memory method according to an embodiment of the invention;
The flow chart that Fig. 6 shows file memory method according to an embodiment of the invention;
The flow chart that Fig. 7 shows file type identification according to an embodiment of the invention;
Fig. 8 shows the structure chart of document storage system according to an embodiment of the invention;
Fig. 9 shows the particular flow sheet of file memory method according to an embodiment of the invention.
Specific embodiment
In order to be more clearly understood that the above objects, features and advantages of the present invention, below in conjunction with the accompanying drawings and specifically real
Mode of applying is further described in detail to the present invention.It should be noted that in the case of not conflicting, the enforcement of the application
Feature in example and embodiment can be mutually combined.
Elaborate a lot of details in the following description in order to fully understand the present invention, but, the present invention also may be used
To be implemented different from other modes described here using other, therefore, protection scope of the present invention is not described below
Specific embodiment restriction.
Fig. 1 shows the block diagram of terminal according to an embodiment of the invention.
As shown in figure 1, terminal 100 according to an embodiment of the invention, including:Transmitting element 102, sends to server and obtains
Take the request of fileinfo, so that described server sends described fileinfo to described terminal, wherein, institute according to described request
State the format character information that fileinfo includes forbidding uploading file type list and each type file;End side memory element
104, receive the described fileinfo that described server sends, extract described in forbid uploading file type list and described each
The format character information of type file, and stored;End side type determining units 106, when receiving upper transmitting file, read
Take the file content of described upper transmitting file, by described file content and each type described in the storage of described end side memory element
The format character information of file is contrasted, to determine the file type of described upper transmitting file;End side judging unit 108, reads
Take and forbid uploading file type list described in the memory element storage of described end side, and judge to forbid uploading files classes described
The file type of described upper transmitting file whether can be found in type list;End side processing unit 110, if detect described terminal
The judged result of side judging unit is yes, then forbid described upload files passe to described server, if described end is detected
The judged result of side judging unit is no, then allow described upload files passe to described server, for described service
Device is processed to described upper transmitting file.
In this technical scheme, the format character of the file content of upper transmitting file and each type file is compared,
So by being identified to the form of upper transmitting file, the file type of transmitting file in determination, thus it is specific to forbid that user uploads
The file of the type such as the file type of form, such as music, film, game, has so reached the rubbish reducing storage on server
Rubbish file, improves the utilization rate in space, the purpose of investment reduction cost.
It is preferable that described transmitting element 102 is additionally operable in technique scheme:When having detected from described service
When the list update of device notifies, send the request that forbidding upload file type list obtaining after updating to described server, with
For described server, forbidding after described renewal is sent according to described request and upload file type list to described terminal;And institute
State end side memory element 104 to be additionally operable to:Receive and store and forbid upper transmitting file after the described renewal that described server sends
List of types.
In this technical scheme, when management personnel are on the server to forbidding that uploading file type list modifies or more
When new, terminal also can keep the synchronization of server, update and forbid uploading file type list, thus effectively forbidding certain kinds
The files passe of type is to server.
It is preferable that described end side type determining units 106 also include in technique scheme:Son is searched in end side
Unit 1062, starts to read file content from the beginning of described upper transmitting file, reads a byte every time, and reading one
During byte, the format character information of the byte of reading and each type file described is compared, has searched whether and institute
Stating the consistent format character information of transmitting file, if finding, file type being determined according to described format character information, if not
Find, then continue to read file content, until finding the format information consistent with described upper transmitting file or determining on described
Till transmitting file is all inconsistent with the format character information of each type file;And end side notifies subelement 1064, in inspection
Measure described end side and search subelement 1062 and have determined that the format character information of described upper transmitting file and each type file all
When inconsistent, described end side processing unit 110 is notified to allow described upload files passe to described server, for described
Server is processed to described upper transmitting file.
In this technical scheme, the format character information byte-by-byte of upper transmitting file and each type file is compared
Right, so that it is determined that the corresponding file type of upper transmitting file, so file type is determined by file format, it is to avoid user is permissible
File is modified and gets around the problem of the restriction of upper transmitting file, thus effectively forbidding the upload of particular type file, section
The memory space of about server, improves the space availability ratio of server.
Fig. 2 shows the block diagram of server according to an embodiment of the invention.
As shown in Fig. 2 server 200 according to an embodiment of the invention, including:Server side memory element 202, storage
Fileinfo, and when the acquisition receiving self terminal is asked, send described fileinfo to described terminal, wherein, described
Fileinfo includes the format character information forbidding uploading file type list and each type file;File reception unit 204,
Receive the upper transmitting file from described terminal;Server side type determining units 206, read in the file in described upper transmitting file
Hold, the described format character information of described file content and storage is contrasted, to determine the files classes of described upper transmitting file
Type;Server side judging unit 208, reads and forbids described in storage uploading file type list, and judge on described forbidding
The file type of described upper transmitting file whether can be found in transmitting file list of types;Server side processing unit 210, if detection
Judged result to described server side judging unit is yes, then delete described upper transmitting file, if described server side is detected
The judged result of judging unit is no, then store described upper transmitting file.
In this technical scheme, in order to prevent terminal from getting around the inspection of file type after artificially being cracked, and lead to service
The file forbidding uploading is stored by device, and therefore server end also can carry out the two of file type to the upper transmitting file receiving
Secondary identification checks, thus thoroughly avoiding the problem forbidding that the file uploading stores in the server.
It is preferable that also including in technique scheme:Information generating unit 212, analyzes the literary composition of multiple same types
Part, therefrom extracts the format character of the file of the type, and generates the format character information of type file, to be stored.
In this technical scheme, because its concrete form of different types of file is different, and the file of same type
General character all can be existed on form, therefore, by being identified to file format can determine the files classes belonging to certain file
Type, wherein format character information can server the file of a large amount of same types is analyzed after generate, and after storing
As the standard judging file type.
It is preferable that described server side type determining units 206 also include in technique scheme:Server side is looked into
Look for subelement 2062, start to read file content from the beginning of described upper transmitting file, read a byte every time, and reading
During one byte, the format character information of the byte of reading and each type file described is compared, has searched whether
The format character information consistent with described upper transmitting file, if finding, determines file type according to described format character information,
If not finding, continue to read file content, until determining the format character letter of described upper transmitting file and each type file
Till breath is all inconsistent;Server side notifies subelement 2064, and detecting, described server side lookup subelement 2062 is true
When the format character information of fixed described upper transmitting file and each type file is all inconsistent, notify described server side processing unit
Store described upper transmitting file.
In this technical scheme, the format character information byte-by-byte of upper transmitting file and each type file is compared
Right, so that it is determined that the corresponding file type of upper transmitting file, so file type is determined by file format, it is to avoid user is permissible
File is modified and gets around the problem of the restriction of upper transmitting file, thus effectively forbidding the storage of particular type file, section
The memory space of about server, improves the space availability ratio of server.
It is preferable that also including in technique scheme:Arranging unit 214, according to the setting instruction receiving, setting
Forbid the file type list uploading;List update unit 216, forbids that the file type list uploading has more described in detect
When new, obtain forbidding after updating and upload file type list, to be stored by described server side memory element, and to institute
State terminal transmission list update notification, so that described terminal forbids uploading file type list according to the renewal of described notice.
In this technical scheme, management personnel can arrange the file type forbidding uploading as needed on the server,
And renewal of can modifying at any time, terminal meeting server holding synchronization, so facilitate the operation of user, user only needs to
Simply it is configured just can effectively forbidding certain types of files passe, save the cost of investment of user.
Fig. 3 shows the block diagram of document storage system according to an embodiment of the invention.
As shown in figure 3, document storage system 300 according to an embodiment of the invention, including terminal 100 He recited above
Server 200.
The flow chart that Fig. 4 shows file memory method according to an embodiment of the invention.
As shown in figure 4, file memory method according to an embodiment of the invention, including:Step 402, described terminal
Send the request obtaining fileinfo to server, so that described server sends described fileinfo to institute according to described request
State terminal, wherein, described fileinfo includes the format character information forbidding uploading file type list and each type file;
Step 404, receives the described fileinfo that described server sends, extract described in forbid uploading file type list and described
The format character information of each type file, and stored;Step 406, when receiving upper transmitting file, reads described upload
The file content of file, the described format character information of described file content and storage is contrasted, to determine described upload
The file type of file;Step 408, reads and forbids described in storage uploading file type list, and judge on described forbidding
The file type of described upper transmitting file whether can be found in transmitting file list of types, if the determination result is YES, then forbid institute
State upload files passe to described server, if judged result is no, allow described upload files passe to described service
Device, to be processed to described upper transmitting file by described server.
In this technical scheme, the format character of the file content of upper transmitting file and each type file is compared,
So by being identified to the form of upper transmitting file, the file type of transmitting file in determination, thus it is specific to forbid that user uploads
The file of the type such as the file type of form, such as music, film, game, has so reached the rubbish reducing storage on server
Rubbish file, improves the utilization rate in space, the purpose of investment reduction cost.
It is preferable that described step 402 also includes in technique scheme:When detecting from described server
When list update notifies, send, to described server, the request that forbidding upload file type list obtaining after updating, for institute
State server and file type list is uploaded to described terminal according to forbidding after the described renewal of described request transmission;And described step
Rapid 404 also include:Receive and store forbidding after the described renewal that described server sends and upload file type list.
In this technical scheme, when management personnel are on the server to forbidding that uploading file type list modifies or more
When new, terminal also can keep the synchronization of server, update and forbid uploading file type list, thus effectively forbidding certain kinds
The files passe of type is to server.
It is preferable that described step 406 also includes in technique scheme:Start to read from the beginning of described upper transmitting file
Take file content, read a byte every time, and when having read a byte, by the byte of reading and each type described
The format character information of file is compared, and searches whether the format character information consistent with described upper transmitting file, if searching
Arriving, then file type is determined according to described format character information, if not finding, continuing to read file content, until determining
Till described upper transmitting file is all inconsistent with the format character information of each type file;And have determined that on described detecting
It is allowed to by described upload files passe to described service when the format character information of transmitting file and each type file is all inconsistent
Device, so that described server is processed to described upper transmitting file.
In this technical scheme, the format character information byte-by-byte of upper transmitting file and each type file is compared
Right, so that it is determined that the corresponding file type of upper transmitting file, so file type is determined by file format, it is to avoid user is permissible
File is modified and gets around the problem of the restriction of upper transmitting file, thus effectively forbidding the upload of particular type file, section
The memory space of about server, improves the space availability ratio of server.
The flow chart that Fig. 5 shows file memory method according to an embodiment of the invention.
As shown in figure 5, file memory method according to an embodiment of the invention, including:Step 502, storage file information,
And when the acquisition receiving self terminal is asked, send described fileinfo to described terminal, wherein, described fileinfo bag
Include the format character information forbidding uploading file type list and each type file;Step 504, receives from described terminal
Upper transmitting file;Step 506, reads the file content in described upper transmitting file, by the described form of described file content and storage
Characteristic information is contrasted, to determine the file type of described upper transmitting file;Step 508, reads and forbids described in storage uploading
File type list, and judge to forbid uploading the file that whether can find transmitting file on described in file type list described
Type;Step 510, if it is yes for judged result is detected, deletes described upper transmitting file, if it is no for judged result is detected,
Store described upper transmitting file.
In this technical scheme, in order to prevent terminal from getting around the inspection of file type after artificially being cracked, and lead to service
The file forbidding uploading is stored by device, and therefore server end also can carry out the two of file type to the upper transmitting file receiving
Secondary identification checks, thus thoroughly avoiding the problem forbidding that the file uploading stores in the server.
It is preferable that described step 502 also includes in technique scheme:Analyze the file of multiple same types, therefrom
Extract the format character of the file of the type, and generate the format character information of type file, so that described server is carried out
Storage.
In this technical scheme, because its concrete form of different types of file is different, and the file of same type
General character all can be existed on form, therefore, by being identified to file format can determine the files classes belonging to certain file
Type, wherein format character information can server the file of a large amount of same types is analyzed after generate, and after storing
As the standard judging file type.
It is preferable that described step 506 also includes in technique scheme:Start to read from the beginning of described upper transmitting file
Take file content, read a byte every time, and when having read a byte, by the byte of reading and each type described
The format character information of file is compared, and searches whether the format character information consistent with described upper transmitting file, if searching
Arriving, then file type is determined according to described format character information, if not finding, continuing to read file content, until determining
Till described upper transmitting file is all inconsistent with the format character information of each type file;Have determined that described upload literary composition detecting
When the format character information of part and each type file is all inconsistent, store described upper transmitting file.
In this technical scheme, the format character information byte-by-byte of upper transmitting file and each type file is compared
Right, so that it is determined that the corresponding file type of upper transmitting file, so file type is determined by file format, it is to avoid user is permissible
File is modified and gets around the problem of the restriction of upper transmitting file, thus effectively forbidding the storage of particular type file, section
The memory space of about server, improves the space availability ratio of server.
It is preferable that described step 502 also includes in technique scheme:According to the setting instruction receiving, setting is prohibited
The file type list only uploading;And when detect forbid upload file type list have renewal when, obtain update after
Forbid uploading file type list, to be stored, and to described terminal transmission list update notification, for described terminal according to
The renewal of described notice is forbidden uploading file type list.
In this technical scheme, management personnel can arrange the file type forbidding uploading as needed on the server,
And renewal of can modifying at any time, terminal meeting server holding synchronization, so facilitate the operation of user, user only needs to
Simply it is configured just can effectively forbidding certain types of files passe, save the cost of investment of user.
The flow chart that Fig. 6 shows file memory method according to an embodiment of the invention.
As shown in fig. 6, file memory method according to an embodiment of the invention, including:Step 602, terminal to server
Send the request obtaining fileinfo, wherein, described fileinfo includes forbidding uploading file type list and each type literary composition
The format character information of part;Step 604, fileinfo described in described server storage, and receiving from described terminal
When obtaining request, send described fileinfo to described terminal;Step 606, described terminal receives the institute that described server sends
State fileinfo, extract described in forbid uploading the format character information of file type list and each type file described, and
Stored;Step 608, receives transmitting file in described terminal, reads the file content in described upper transmitting file, will be described
File content is contrasted with described format character information, to determine the file type of described upper transmitting file;Step 610, described
What terminal reading stored forbids uploading file type list, and judges to forbid whether looking in upload file type list described
Find the file type of described upper transmitting file, if the determination result is YES, then forbid described upload files passe to described service
Device, if judged result is no, allows described upload files passe to described server;Step 612, described server receives
From the described upper transmitting file of described terminal, read out the file content in described upper transmitting file, by described file content with deposit
The described format character information of storage is contrasted, to determine the file type of described upper transmitting file;Step 614, described server
That reads storage forbids upload file type list, and judges to forbid whether finding in upload file type list described
The file type of described upper transmitting file, if the determination result is YES, then deletes described upper transmitting file, if judged result is no, deposits
Store up described upper transmitting file.
In this technical scheme, the format character of the file content of upper transmitting file and each type file is compared,
So by being identified to the form of upper transmitting file, determine the file type of transmitting file in terminal, thus forbidding uploading specific
The file type of form(The file of the such as type such as music, film, game)To server.Meanwhile, in order to prevent terminal by people
For getting around the inspection of file type after cracking, and server is led to be stored the file forbidding uploading, therefore server end
Also the upper transmitting file receiving can be carried out with the secondary identification inspection of file type, thus thoroughly avoiding the file forbidding uploading
The problem storing in the server, has reached the garbage files reducing storage on server, improves the utilization rate in space, saves and throws
The purpose of money cost.
It is preferable that described step 604 also includes in technique scheme:The multiple same type of described server analysis
File, therefrom extract the format character of the file of the type, and generate the format character information of type file, to be deposited
Storage.
In this technical scheme, because its concrete form of different types of file is different, and the file of same type
General character all can be existed on form, therefore, by being identified to file format can determine the files classes belonging to certain file
Type, wherein format character information can server the file of a large amount of same types is analyzed after generate, and after storing
As the standard judging file type.
It is preferable that described step 608 also includes in technique scheme:Start to read from the beginning of described upper transmitting file
Take file content, read a byte every time, and when having read a byte, by the byte of reading and each type described
The format character information of file is compared, and searches whether the format character information consistent with described upper transmitting file, if searching
Arriving, then file type is determined according to described format character information, if not finding, continuing to read file content, until determining
Till described upper transmitting file is all inconsistent with the format character information of each type file;And have determined that on described detecting
It is allowed to by described upload files passe to described service when the format character information of transmitting file and each type file is all inconsistent
Device, so that described server is processed to described upper transmitting file;Described step 612 also includes:From opening of described upper transmitting file
Head starts to read file content, every time reads a byte, and when having read a byte, by the byte of reading with described
The format character information of each type file is compared, and searches whether the format character letter consistent with described upper transmitting file
Breath, if finding, determines file type according to described format character information, if not finding, continues to read file content,
Till determining that described upper transmitting file is all inconsistent with the format character information of each type file;And it is true detecting
When the format character information of fixed described upper transmitting file and each type file is all inconsistent, store described upper transmitting file.
In this technical scheme, the format character information byte-by-byte of upper transmitting file and each type file is compared
Right, so that it is determined that the corresponding file type of upper transmitting file, so file type is determined by file format, it is to avoid user is permissible
File is modified and gets around the problem of the restriction of upper transmitting file, thus effectively forbidding the storage of particular type file, section
The memory space of about server, improves the space availability ratio of server.
It is preferable that described step 604 also includes in technique scheme:Described server is according to the setting receiving
Instruction, the file type list uploading is forbidden in setting;And when described server detects the file type list forbidding uploading
When having renewal, obtain forbidding after updating and upload file type list, to be stored, and update to described terminal transmission list
Notify;Described step 602 also includes:When detecting from the list update notice of described server, described terminal is to institute
State server and send the request that forbidding upload file type list obtaining after updating, so that described server is according to described request
Send forbidding after described renewal and upload file type list to described terminal;Described step 606 also includes:Described terminal receives
And store forbidding after the described renewal that described server sends and upload file type list.
In this technical scheme, management personnel can arrange the file type forbidding uploading as needed on the server,
And renewal of can modifying at any time, terminal meeting server holding synchronization, so facilitate the operation of user, user only needs to
Simply it is configured just can effectively forbidding certain types of files passe, save the cost of investment of user.
The flow chart that Fig. 7 shows file type identification according to an embodiment of the invention.
As shown in fig. 7, file type identification process is as follows according to an embodiment of the invention:
Step 702, by the beginning of the file in upload for the needle locating.
Step 704, reads a byte of this document.
Step 706, judges the file type whether having this document to meet in fingerprint base.Wherein, store in fingerprint base respectively
The format character of individual type file, these format character be by analyze a large amount of same type files general character, extract such
The format character of type file., beginning foremost 32 byte of document is all D0CF11E0A1B11A taking Word2003 document as a example
(16 enter E1000000000000000000000000000000003E000300FE FF09000600000000000000
System), and last 480 bytes of file are all started with Microsoft Office Word, here it is the form of Word document is special
Levy.
Step 708, if not finding the file type of this document, exits file type recognizer.
Step 710, if the file type being met by this document in fingerprint base, judges whether the file type meeting has many
Individual, if the determination result is YES, enter step 714, if judged result is no, enter step 712.
Step 712, judges whether the fingerprint characteristic of file has arrived last position, if the determination result is YES, enters step
718, if judged result is no, enter step 714.
Step 714, obtains next fingerprint point.
Step 716, needle locating to fingerprint point continues to read byte.
Step 718, if the file type only one of which meeting or fingerprint characteristic have arrived last position, obtains this document class
Type, this document type is exactly the file type of upper transmitting file.
Fig. 8 shows the structure chart of document storage system according to an embodiment of the invention.
As shown in figure 8, document storage system 800 according to an embodiment of the invention includes storage server 802 He
Client 804.
Storage server 802 mainly comprises following components:
File fingerprint manages library module 8022, is responsible for generating the finger print information of each type file, and is stored to literary composition
In part type fingerprint base;
File type identification module 8024, by being contrasted file content with the information in file type fingerprint base, is obtained
File type;
Document management module 8026, the upload of responsible file and download;
File type fingerprint base 8028, stores the finger print information of each type file;
Communication module 80210, is responsible for the network communication with client;
File type management module 80212, the file being responsible for which type is forbidden uploading.
Client 804 mainly comprises following components:
File type fingerprint base 8042, the finger print information of storage all kinds file, refer to storage server file type
Stricture of vagina storehouse is synchronous;
File type identification module 8044, file content is contrasted with the information in file type fingerprint base, obtains file
Type;
Document management module 8046, the upload of responsible file and download;
Communication module 8048, is responsible for the network communication with server.
With reference to Fig. 8 and Fig. 9, the file memory method of the present invention is described in detail.
Fig. 9 shows the particular flow sheet of file memory method according to an embodiment of the invention.
As shown in figure 9, the idiographic flow of file memory method is as follows according to an embodiment of the invention:
Step 902, client 804 logs in storage server 802;
Step 904, client 804 obtains from the file type management module 80212 of storage server 802 forbids upload
File type;
Step 906, client 804 is from the file fingerprint database management module 8022 synchronous documents type of storage server 802
Fingerprint base 8028 arrives the PC of user;
Step 908, client 804 selects the file needing to upload, and client 804 passes through file type identification module
8044, fileinfo is contrasted with file type fingerprint base 8042, is obtained file type.
Step 910, client 804 judges this document type whether in the file type list forbidding uploading, if sentenced
Disconnected result is yes, enters step 912, if it is judged that being no, enters step 914.
Step 912, forbids uploading, files passe failure.
Step 914, after the completion of client 804 type checking, client's file management module 8046 is by files passe to clothes
Business device 802;
Step 916, the document management module 8026 of server 802, after the completion of files passe, calls file type to identify
Module 8024, identifies file type.
Step 918, checks this document type whether in the file type list forbidding uploading, if the determination result is YES,
Enter step 920, if judged result is no, enter step 922.
Step 920, deletes file, uploads unsuccessfully.
Step 922, upload completes.
So, before passing on the client, server is identified inspection twice to file type after the completion of receiving file,
Certain types of file being forbidden upload, thus reducing the garbage files of server, improving space availability ratio.
Technical scheme is described in detail above in association with accompanying drawing, by technical scheme, can limit
The form of the file that user uploads, thus effectively reducing the garbage files of storage in storage server, improves storage server
Space availability ratio, save user cost of investment.
The foregoing is only the preferred embodiments of the present invention, be not limited to the present invention, for the skill of this area
For art personnel, the present invention can have various modifications and variations.All within the spirit and principles in the present invention, made any repair
Change, equivalent, improvement etc., should be included within the scope of the present invention.
Claims (19)
1. a kind of terminal, is applied to document storage system it is characterised in that including:
Transmitting element, sends the request obtaining fileinfo to server, so that described server sends institute according to described request
State fileinfo to described terminal, wherein, described fileinfo includes forbidding uploading file type list and each type file
Format character information;
End side memory element, receives the described fileinfo that described server sends, extract described in forbid uploading files classes
The format character information of type list and each type file described, and stored;
End side type determining units, when receiving upper transmitting file, read the file content of described upper transmitting file, by described literary composition
The format character information of each type file described that part content is stored with described end side memory element is contrasted, to determine
The file type of described upper transmitting file;
End side judging unit, reads and forbids uploading file type list described in the memory element storage of described end side, and sentence
Break and forbid uploading the file type that whether can find transmitting file on described in file type list described;
End side processing unit, if the judged result described end side judging unit is detected is yes, forbids described upload
Files passe to described server, if the judged result described end side judging unit is detected be no, permission will be described on
Transmitting file is uploaded to described server, so that described server is processed to described upper transmitting file;
Described end side type determining units also include:
Subelement is searched in end side, starts to read file content from the beginning of described upper transmitting file, reads a byte every time, and
When having read a byte, the format character information of the byte of reading and each type file described is compared, looks into
Looking for and whether have the format character information consistent with described upper transmitting file, if finding, being determined according to described format character information
File type, if not finding, continues to read file content, until finding the format information consistent with described upper transmitting file
Or till determining that described upper transmitting file is all inconsistent with the format character information of each type file.
2. terminal according to claim 1 is it is characterised in that described transmitting element is additionally operable to:
When detecting from the list update notice of described server, send to described server and obtain forbidding after updating
Upload file type list request, for described server according to described request send described update after forbid upper transmitting file
List of types is to described terminal;And
Described end side memory element is additionally operable to:
Receive and store forbidding after the described renewal that described server sends and upload file type list.
3. terminal according to claim 1 and 2 is it is characterised in that described end side type determining units also include:
End side notifies subelement, has determined that transmitting file and each type on described described end side lookup subelement is detected
When the format character information of file is all inconsistent, described end side processing unit is notified to allow described upload files passe to institute
State server, so that described server is processed to described upper transmitting file.
4. a kind of server, is applied to document storage system it is characterised in that including:
Server side memory element, storage file information, and when the acquisition receiving self terminal is asked, send described file
To described terminal, wherein, described fileinfo includes the form forbidding uploading file type list and each type file to information
Characteristic information;
File reception unit, receives the upper transmitting file from described terminal;
Server side type determining units, read the file content in described upper transmitting file, by described file content and storage
Described format character information is contrasted, to determine the file type of described upper transmitting file;
Server side judging unit, reads and forbids described in storage uploading file type list, and judges to forbid uploading described
The file type of described upper transmitting file whether can be found in file type list;
Server side processing unit, if the judged result described server side judging unit is detected is yes, deletes on described
Transmitting file, if the judged result described server side judging unit is detected is no, stores described upper transmitting file.
5. server according to claim 4 is it is characterised in that also include:
Information generating unit, analyzes the file of multiple same types, therefrom extracts the format character of the file of the type, and raw
Become the format character information of type file, to be stored.
6. server according to claim 4 is it is characterised in that described server side type determining units also include:
Server side searches subelement, starts to read file content from the beginning of described upper transmitting file, reads a byte every time,
And when having read a byte, the format character information of the byte of reading and each type file described is compared,
Search whether the format character information consistent with described upper transmitting file, if finding, true according to described format character information
Determining file type, if not finding, continuing to read file content, until determining described upper transmitting file and each type file
Till format character information is all inconsistent;
Server side notifies subelement, detect described server side search subelement have determined that on described transmitting file and each
When the format character information of type file is all inconsistent, described server side processing unit is notified to store described upper transmitting file.
7. the server according to any one of claim 4 to 6 is it is characterised in that also include:
Arranging unit, according to the setting instruction receiving, the file type list uploading is forbidden in setting;
List update unit, when the file type list forbidding described in detecting uploading has renewal, obtains forbidding after updating
Upload file type list, to be stored by described server side memory element, and update to described terminal transmission list logical
Know, so that described terminal notifies renewal to forbid uploading file type list according to described list update.
8. a kind of document storage system is it is characterised in that the terminal any one of inclusion claims 1 to 3 and right will
Seek the server any one of 4 to 7.
9. a kind of file memory method, is applied to document storage system it is characterised in that including:
Step 402, terminal to server sends the request obtaining fileinfo, so that described server sends according to described request
To described terminal, wherein, described fileinfo includes forbidding uploading file type list and each type literary composition described fileinfo
The format character information of part;
Step 404, receives the described fileinfo that described server sends, extract described in forbid uploading file type list and
The format character information of each type file described, and stored;
Step 406, when receiving upper transmitting file, read described upper transmitting file file content, by described file content with deposit
The described format character information of storage is contrasted, to determine the file type of described upper transmitting file;
Step 408, reads and forbids described in storage uploading file type list, and judges to forbid uploading file type row described
The file type of described upper transmitting file whether can be found in table,
If the determination result is YES, then forbid described upload files passe to described server, if judged result is no, allow
By described upload files passe to described server, to be processed to described upper transmitting file by described server;
Described step 406 also includes:
Start to read file content from the beginning of described upper transmitting file, read a byte every time, and reading a byte
When, the format character information of the byte of reading and each type file described is compared, searched whether with described on
The consistent format character information of transmitting file, if finding, determines file type according to described format character information, if not searching
Arrive, then continue to read file content, until determining that described upper transmitting file is all differed with the format character information of each type file
Till cause.
10. file memory method according to claim 9 is it is characterised in that described step 402 also includes:
When detecting from the list update notice of described server, send to described server and obtain forbidding after updating
Upload file type list request, for described server according to described request send described update after forbid upper transmitting file
List of types is to described terminal;And
Described step 404 also includes:
Receive and store forbidding after the described renewal that described server sends and upload file type list.
11. file memory methods according to claim 9 or 10 are it is characterised in that described step 406 also includes:
Detect the format character information having determined that transmitting file and each type file on described all inconsistent when it is allowed to by institute
State upload files passe to described server, so that described server is processed to described upper transmitting file.
A kind of 12. file memory methods, are applied to document storage system it is characterised in that including:
Step 502, storage file information, and when the acquisition receiving self terminal is asked, send described fileinfo to institute
State terminal, wherein, described fileinfo includes the format character information forbidding uploading file type list and each type file;
Step 504, receives the upper transmitting file from described terminal;
Step 506, reads the file content in described upper transmitting file, by the described format character letter of described file content and storage
Breath is contrasted, to determine the file type of described upper transmitting file;
Step 508, reads and forbids described in storage uploading file type list, and judges to forbid uploading file type row described
The file type of described upper transmitting file whether can be found in table;
Step 510, if it is yes for judged result is detected, deletes described upper transmitting file, if it is no for judged result is detected, deposits
Store up described upper transmitting file.
13. file memory methods according to claim 12 are it is characterised in that described step 502 also includes:
Analyze the file of multiple same types, therefrom extract the format character of the file of the type, and generate type file
Format character information, so that server is stored.
14. file memory methods according to claim 12 are it is characterised in that described step 506 also includes:
Start to read file content from the beginning of described upper transmitting file, read a byte every time, and reading a byte
When, the format character information of the byte of reading and each type file described is compared, searched whether with described on
The consistent format character information of transmitting file, if finding, determines file type according to described format character information, if not searching
Arrive, then continue to read file content, until determining that described upper transmitting file is all differed with the format character information of each type file
Till cause;
Detect the format character information having determined that transmitting file and each type file on described all inconsistent when, storage is described
Upper transmitting file.
15. the file memory method according to any one of claim 12 to 14 is it is characterised in that described step 502 is gone back
Including:
According to the setting instruction receiving, the file type list uploading is forbidden in setting;And
When detect forbid upload file type list have renewal when, obtain update after forbidding upload file type list,
To be stored, and to described terminal transmission list update notification, so that described terminal forbids uploading according to the renewal of described notice
File type list.
A kind of 16. file memory methods, are applied to document storage system it is characterised in that including:
Step 602, terminal to server sends the request obtaining fileinfo, and wherein, described fileinfo includes forbidding uploading
File type list and the format character information of each type file;
Step 604, fileinfo described in described server storage, and when receiving from the acquisition request of described terminal, send out
Send described fileinfo to described terminal;
Step 606, described terminal receives the described fileinfo that described server sends, extract described in forbid uploading files classes
The format character information of type list and each type file described, and stored;
Step 608, when described terminal receives transmitting file, reads the file content in described upper transmitting file, by described literary composition
Part content is contrasted with described format character information, to determine the file type of described upper transmitting file;
Step 610, what described terminal reading stored forbids uploading file type list, and judges to forbid uploading files classes described
The file type of described upper transmitting file whether can be found in type list,
If the determination result is YES, then forbid described upload files passe to described server, if judged result is no, allow
By described upload files passe to described server;
Step 612, described server receives the described upper transmitting file from described terminal, reads out the literary composition in described upper transmitting file
Part content, the described format character information of described file content and storage is contrasted, to determine the literary composition of described upper transmitting file
Part type;
Step 614, what described server reading stored forbids uploading file type list, and judges transmitting file on described forbidding
The file type of described upper transmitting file whether can be found in list of types,
If the determination result is YES, then delete described upper transmitting file, if judged result is no, store described upper transmitting file.
17. file memory methods according to claim 16 are it is characterised in that described step 604 also includes:
The file of the multiple same type of described server analysis, therefrom extracts the format character of the file of the type, and generates
The format character information of type file, to be stored.
18. file memory methods according to claim 16 are it is characterised in that described step 608 also includes:
Start to read file content from the beginning of described upper transmitting file, read a byte every time, and reading a byte
When, the format character information of the byte of reading and each type file described is compared, searched whether with described on
The consistent format character information of transmitting file, if finding, determines file type according to described format character information, if not searching
Arrive, then continue to read file content, until determining that described upper transmitting file is all differed with the format character information of each type file
Till cause;And
Detect the format character information having determined that transmitting file and each type file on described all inconsistent when it is allowed to by institute
State upload files passe to described server, so that described server is processed to described upper transmitting file;
Described step 612 also includes:
Start to read file content from the beginning of described upper transmitting file, read a byte every time, and reading a byte
When, the format character information of the byte of reading and each type file described is compared, searched whether with described on
The consistent format character information of transmitting file, if finding, determines file type according to described format character information, if not searching
Arrive, then continue to read file content, until determining that described upper transmitting file is all differed with the format character information of each type file
Till cause;And
Detect the format character information having determined that transmitting file and each type file on described all inconsistent when, storage is described
Upper transmitting file.
19. file memory methods according to any one of claim 16 to 18 it is characterised in that
Described step 604 also includes:
Described server forbids, according to the setting instruction receiving, setting, the file type list uploading;And
When described server detect forbid upload file type list have renewal when, obtain update after forbid upper transmitting file
List of types, to be stored, and to described terminal transmission list update notification;
Described step 602 also includes:
When detecting from the list update notice of described server, described terminal sends to obtain to described server and updates
The request forbidding upload file type list afterwards, so that described server sends forbidding after described renewal according to described request
Upload file type list to described terminal;
Described step 606 also includes:
Described terminal receives and stores forbidding after the described renewal that described server sends and uploads file type list.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201310130998.2A CN103220352B (en) | 2013-04-15 | 2013-04-15 | Terminal, server, file storage system and file storage method |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201310130998.2A CN103220352B (en) | 2013-04-15 | 2013-04-15 | Terminal, server, file storage system and file storage method |
Publications (2)
Publication Number | Publication Date |
---|---|
CN103220352A CN103220352A (en) | 2013-07-24 |
CN103220352B true CN103220352B (en) | 2017-02-08 |
Family
ID=48817803
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201310130998.2A Active CN103220352B (en) | 2013-04-15 | 2013-04-15 | Terminal, server, file storage system and file storage method |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN103220352B (en) |
Families Citing this family (11)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN104572038A (en) * | 2013-10-15 | 2015-04-29 | 镇江金软计算机科技有限责任公司 | Excel data reading and storage method based on POI technique |
CN104978341A (en) * | 2014-04-08 | 2015-10-14 | 北京奇虎科技有限公司 | File processing method and equipment, and network system |
CN104539611B (en) * | 2014-12-26 | 2016-09-07 | 深圳市奇付通科技有限公司 | Share the method for file management, Apparatus and system |
CN105897685A (en) * | 2015-12-15 | 2016-08-24 | 乐视网信息技术(北京)股份有限公司 | File validity determining method and system |
CN106131200A (en) * | 2016-07-20 | 2016-11-16 | 深圳市瑞云科技有限公司 | The file transfer means of cloud rendering system |
CN108023955B (en) * | 2017-12-06 | 2020-10-30 | 华强方特(深圳)动漫有限公司 | Processing method and device for three-dimensional animation production process |
CN109361731A (en) * | 2018-09-03 | 2019-02-19 | 中国平安人寿保险股份有限公司 | A kind of method, storage medium and server that file uploads |
CN112835864B (en) * | 2021-02-03 | 2024-02-20 | 北京联创信安科技股份有限公司 | File storage method, device, equipment and storage medium |
CN114006895A (en) * | 2021-09-23 | 2022-02-01 | 银盛通信有限公司 | Method for uploading file with high security |
CN114390039A (en) * | 2021-11-30 | 2022-04-22 | 航天信息股份有限公司 | File uploading and downloading method and system |
CN114780896B (en) * | 2022-06-20 | 2022-09-09 | 深圳市快印客电子商务有限公司 | Webpage content generation method and device and computer readable storage medium |
Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101055576A (en) * | 2006-04-14 | 2007-10-17 | 英保达股份有限公司 | System and method for automatically uploading and classifying file |
CN102169453A (en) * | 2011-03-08 | 2011-08-31 | 杭州电子科技大学 | File online backup method |
CN102821119A (en) * | 2011-06-10 | 2012-12-12 | 北大方正集团有限公司 | Client end, method, system and equipment for uploading files |
CN102868765A (en) * | 2012-10-09 | 2013-01-09 | 乐视网信息技术(北京)股份有限公司 | Method and system for uploading files |
-
2013
- 2013-04-15 CN CN201310130998.2A patent/CN103220352B/en active Active
Patent Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN101055576A (en) * | 2006-04-14 | 2007-10-17 | 英保达股份有限公司 | System and method for automatically uploading and classifying file |
CN102169453A (en) * | 2011-03-08 | 2011-08-31 | 杭州电子科技大学 | File online backup method |
CN102821119A (en) * | 2011-06-10 | 2012-12-12 | 北大方正集团有限公司 | Client end, method, system and equipment for uploading files |
CN102868765A (en) * | 2012-10-09 | 2013-01-09 | 乐视网信息技术(北京)股份有限公司 | Method and system for uploading files |
Also Published As
Publication number | Publication date |
---|---|
CN103220352A (en) | 2013-07-24 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN103220352B (en) | Terminal, server, file storage system and file storage method | |
US10237295B2 (en) | Automated event ID field analysis on heterogeneous logs | |
CN104750469B (en) | Source code statistical analysis technique and system | |
CN109492378A (en) | A kind of auth method based on EIC equipment identification code, server and medium | |
US20100106784A1 (en) | Electronic device with automatic software update function and method thereof | |
CN104484407B (en) | A kind of method and system for identifying fraud information | |
RU2007141754A (en) | METHOD AND ELEMENT FOR SERVICE MANAGEMENT | |
CN107688531A (en) | Geo-database integration method of testing, device, computer equipment and storage medium | |
CN109561085A (en) | A kind of auth method based on EIC equipment identification code, server and medium | |
CN107844409A (en) | Test example executing method and device | |
CN109727027A (en) | Account recognition methods, device, equipment and storage medium | |
CN103490978A (en) | Terminal, server and message monitoring method | |
CN110929110B (en) | Electronic document detection method, device, equipment and storage medium | |
CN107454205A (en) | A kind of method and apparatus of connection server | |
CN108388672A (en) | Lookup method, device and the computer readable storage medium of video | |
CN105930313A (en) | Method and device for processing notification message | |
CN102083093A (en) | Method and device for extracting test data | |
CN111382051B (en) | API automatic test method and test device | |
CN110059491A (en) | Data import monitoring method, device, equipment and readable storage medium storing program for executing | |
JP4807364B2 (en) | Information management device | |
US20030162559A1 (en) | Mobile communications terminal, information transmitting system and information receiving method | |
CN109977423A (en) | A kind of unknown word processing method, apparatus, electronic equipment and readable storage medium storing program for executing | |
US7784091B2 (en) | Data processing system | |
CN105282091A (en) | Security application server detection method and system thereof | |
CN109344130A (en) | A kind of blog management method and device |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
C06 | Publication | ||
PB01 | Publication | ||
C10 | Entry into substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
C14 | Grant of patent or utility model | ||
GR01 | Patent grant | ||
PP01 | Preservation of patent right | ||
PP01 | Preservation of patent right |
Effective date of registration: 20220816 Granted publication date: 20170208 |