CN102055722B - Implementation method for ensuring secure storage of electronic mails - Google Patents

Implementation method for ensuring secure storage of electronic mails Download PDF

Info

Publication number
CN102055722B
CN102055722B CN200910181093.1A CN200910181093A CN102055722B CN 102055722 B CN102055722 B CN 102055722B CN 200910181093 A CN200910181093 A CN 200910181093A CN 102055722 B CN102055722 B CN 102055722B
Authority
CN
China
Prior art keywords
mail
encryption
user
implementation method
storage
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
Application number
CN200910181093.1A
Other languages
Chinese (zh)
Other versions
CN102055722A (en
Inventor
魏达
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
China Standard Software Co Ltd
Original Assignee
China Standard Software Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by China Standard Software Co Ltd filed Critical China Standard Software Co Ltd
Priority to CN200910181093.1A priority Critical patent/CN102055722B/en
Publication of CN102055722A publication Critical patent/CN102055722A/en
Application granted granted Critical
Publication of CN102055722B publication Critical patent/CN102055722B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Abstract

The invention provides an implementation method for ensuring secure storage of electronic mails, which comprises the following steps of: (1) when a mailbox is registered, generating a unique random string r for a user, and storing the random string r; (2) when the user receives the mails, accessing the random string r, generating symmetric keys K by using a key generating algorithm H, then encrypting mail plaintexts by using a symmetric algorithm F to generate encrypted mail texts, and storing the encrypted mail texts; and (3) when the user reads the mails of the mailbox, accessing the random string r, generating symmetric keys k by using the same key generating algorithm H, and finally decrypting the encrypted mail texts by using the symmetric algorithm F. The server-based mail encryption and storage technology has a trigger occasion of an encryption mechanism after the mails reach the server and before the mails are stored in a local hard disk. High-strength symmetric encryption algorithms are adopted in the technology, different users encrypt and decrypt the mails in the mailbox by using different randomly-generated keys, and a high flexible encryption control scheme is formed by means of encryption of the mails.

Description

A kind of implementation method that guarantees safety of electronic mail storage
Technical field
The present invention relates to safety of electronic mail, especially a kind of implementation method of the mail security memory technology based on server end.
Background technology
The transmission of Email is now undertaken by mail delivery proxy server, mail delivery agency provides local delivery agency on the one hand, by email storage on disk, IMAP/POP3 protocol server is provided on the other hand, be used for reading mail, send the Client Agent of mail to, one envelope mail is transferred to after destination server by mail transport agent, will start local delivery agency, by email storage on server, until user collects mail by POP agreement, or by IMAP agreement, mail is managed.Because mail is that form with file is stored on server, a system user (for example keeper) of obtaining mail document read right can read arbitrarily the mail in mail user inbox, thereby the safety of mail during being stored in mail server can not get ensureing.
Summary of the invention
For addressing the above problem, the object of the present invention is to provide a kind of mail that can make between storage life, is the form with ciphertext on server, reaches the method for secret effect.
Another object of the present invention is to provide a kind of mail index speed that do not affect, to obtain the balance in fail safe and efficiency, the email encryption storage means less to the increase of the performance overhead of mailing system.
For reaching above-mentioned purpose, the technical solution used in the present invention is: a kind of implementation method that guarantees safety of electronic mail storage, and it comprises the steps: that (1), when registration mailbox, for user generates its unique random train r, and preserve this random train r; (2) when described user gets the mail, get this random train r, with a kind of key schedule H, produce symmetric key k, then with a kind of symmetry algorithm F privacy enhanced mail, expressly generate mail ciphertext, and this mail ciphertext is preserved; (3) when user reads the mail of described mailbox, first get this random train r, with same key schedule H, produce symmetric key k, finally with symmetry algorithm F, decipher this mail ciphertext.
Useful technique effect of the present invention is:
1, the encrypt and decrypt of mail all completes at server end, irrelevant with client, both stop the leakage of information hidden danger that mail adopts stored in clear to bring in server, and can not produce any impact to the existing operating habit of user again, well taken into account Information Security and ease for use.
2, different users uses different keys, and these keys are all random generations, guarantees the privacy in individual mail data space.
3, can freely customize high-intensity cryptographic algorithm, the user of can take encrypts the open and close of memory function as unit controls flexibly.
4, only mail body is encrypted itself, do not change the original mail index of mail server, memory mechanism, do not affect mail index speed, obtained the balance in fail safe and efficiency, through measuring, open encrypt memory function to the performance overhead of mailing system in 4%.
Utilize the present invention, can make mail between storage life, is the form with ciphertext on server, reaches secret effect.
Accompanying drawing explanation
Fig. 1 is method frame figure of the present invention;
Fig. 2 is encryption pretreatment process figure of the present invention;
Fig. 3 is encryption Main Process figure of the present invention;
Fig. 4 a, Fig. 4 b are decrypting process flow chart of the present invention.
Embodiment
For object of the present invention, technical scheme and advantage are better understood, now with specific embodiment also by reference to the accompanying drawings, be described as follows:
Referring to Fig. 1, be method frame figure of the present invention, the invention provides a kind of email encryption memory technology based on server end, the trigger timing of encryption mechanism is after mail arrives server, before being kept at local hard drive.Present technique adopts high-intensity symmetric encipherment algorithm, and different users uses the different key of random generation that the mail in own mailbox is encrypted and is deciphered, and utilizes and only mail body to be encrypted, and height of formation is encrypted control program flexibly.
Method of the present invention is that it is operated on mail delivery proxy server software, mail delivery agency provides local delivery to act on behalf of s101 on the one hand, by email storage s104 on disk, provide on the other hand IMAP/POP3 protocol server s107, for reading mail, send the Client Agent s108 of mail to, therefore the present invention includes two parts, before email storage, be encrypted, when reading, be decrypted, in addition, before encrypting, also can carry out a preliminary treatment.Owing to need to guaranteeing the flexibility of whole process, a situation that is Maildir for the storage format of mail.
Whole process comprises encrypts preliminary treatment s102, encrypts main procedure s103, and decrypting process s106, can be referring to Fig. 1.In order to distinguish mail and the unencrypted mail of encrypting, need to add a sign mail head, exist the mail of sign be considered to add overstocked or will be encrypted, this is operated in local delivery main program s101 and completes at once, and bestly after getting the mail, carries out at once.Final step before mail proceeds to storage, encrypt main procedure s103 and start working, scan after mail head's encryption indicator, mail body is cut apart to encryption and (mail body is regarded as to an integral body, do not go to distinguish the situation of MIME form or annex), and storage.User, by IMAP or POP3 agreement, read in the process s107 of mail, decrypting process s106 just follows wherein always, opens mailbox, find corresponding mail, check mail head's encryption indicator, mail body is cut apart to deciphering, finally by IMAP/POP3 agreement, allow user can obtain mail.
Wherein, the algorithm of encrypting can be any one symmetric encipherment algorithm, the key of encryption and decryption generates by generating key, generating key (rawkey) is stored in database s105, same encryption opening switch (enablecrypt) also, takies two fields of subscriber's meter (mail_user) together.The process of encrypting and decrypting all needs these two fields of reading database, in order to reduce the loss in the performance of decrypting process reading database s105, interim being stored in a file under subscriber mailbox master catalogue of key will be generated, because reading out data is than a lot of soon with SQL statement data query in database from file.Encryption and decryption all can be carried out by piecemeal, 1024 bytes of each piece (last piece is less than this value) for example, and each piece is all used identical key encryption and decryption, finally a synthetic integral body.
Below in conjunction with concrete steps, be elaborated:
One, first, when registration mailbox, proxy server generates its unique random train r for user, and this random train r is preserved, and the Email being preferably in random train r and mailbox is to store respectively, the storage security rank of those random trains r should be higher, { how to preserve? in the present embodiment, be to be stored in a database s104, this database s104 comprises user name, whether opens the field of encryption function and this random train r.
Two, when this proxy server is received described user's mail, enter encryption flow, according to subscriber mailbox (user name), get this random train r, with a kind of key schedule H, produce symmetric key k, then with a kind of symmetry algorithm F privacy enhanced mail, expressly obtain mail ciphertext, and preserve this mail ciphertext.
Wherein, the Symmetric key generation algorithm H of employing, can be any existing pseudo random sequence generating algorithm, individual event hashing algorithm, and their mixing or distortion, and symmetry algorithm F can be any symmetric encipherment algorithm.
And can in mail head, write sign to adding overstocked mail, in order to distinguish unencrypted mail.
In the present embodiment, in email storage process, can comprise an encryption preprocessor s102 flow process and encrypt main procedure s103 flow process.
1. encrypt preprocessor flow process
Referring to Fig. 2, for encryption pretreatment process figure of the present invention, when the local delivery s101 of server program is received the client's mail transmitting, enter the beginning step s201 that encrypts preliminary treatment s102 flow process, in encrypting preliminary treatment s102, first need the once operation to database s105, carry out inquiring user table step s202, and according to user name, inquire this user and whether open storage encryption function s203, if opened, carry out step s204, obtain generation key, be kept in a file under home directory, for encrypting main procedure, then perform step s205 to writing encryption indicator to mail head, finish this encryption pretreatment process s206, if do not open, directly enter ending step s206, and enter and encrypt Main Process s103.
To mail head, writing when sign, because the character stream of mail transmits by pipeline, can not write, so need to create a temporary file, the data of pipeline stream be copied in file, then write sign, finally delete this temporary file, a document retaining descriptor.
2. encrypt Main Process
Referring to Fig. 3, for encryption Main Process figure of the present invention, when entering into the beginning step 301 of encrypting Main Process s103, before privacy enhanced mail, guarantee that delivery program all completes all operations of mail, otherwise by the result leading to errors, so will first perform step s302, obtain the descriptor of mail document, and new descriptor of dup, treat that normal mail preservation process s303 completes, then by new descriptor operation file, be encrypted, finally will close this new descriptor.
After step s302 has carried out, enter normal mail and preserve process s303.
Then enter the encryption indicator that step s304 checks mail, while judging existence sign by step s305, enter step s306, otherwise directly enter step s310, finish.
By step s306, read to such an extent that generate after key, through step, s307 is converted to encryption key, block encryption mail body in step s308, and then close file descriptor in step s309, enters ending step s310.
Owing to encrypting preliminary treatment s102 and encrypting main procedure s102 and separate, so encrypt preliminary treatment, to the production key of encrypting main procedure transmission, be to be undertaken by file, another kind of method is to read database one time again, this will cause hydraulic performance decline.Encrypting main procedure s102 is reading to such an extent that generate after key, be converted to encryption key, then generation key file is deleted, otherwise will cause a potential safety hazard, if this file is by wrong modification, to cause the failure of deciphering mail, another hidden danger is that he can read the mail that others encrypted if having people another user's mail and generate the inbox that key file copies oneself to.
In addition, in ciphering process, can only for mail body, be encrypted, mail header is divided and is remained unchanged so that mail server to received mail search for, the operation such as index; And, in above step, for the encryption of mail body, be that sectional independently carries out, 1024 bytes of each piece (last piece is less than this value) for example, each piece is all used identical secret key encryption, a last synthetic integral body, thereby can the storage of encryption limit, limit; Ciphering process can be also once to encrypt a file (mail body), then global storage.
Three, when user collects mail by POP agreement, or when mail is managed by IMAP agreement, enter decrypting process flow process
When if user need to read the mail of described mailbox, need to get random train r, with same key schedule H, produce symmetric key k, finally by symmetry algorithm F deciphering mail ciphertext.
In order to reduce taking server resource, deciphering for mail body is that sectional independently carries out, decrypting process is only deciphered Yi Ge buffering area (if deciphering the position that whole file may not deposited) at every turn, therefore in the present embodiment, adopt and read the how many strategy of how many deciphering, be similar to and kidnap a system call of reading, it can only decipher corresponding fragment according to user's demand, reduces the demand to system.This has just related to the problem of a piece alignment, from the first character of mail body, calculate the skew of the relative mail body of original position of reading file, if the centre of the original position of reading file in a piece needs front half block and rear half block to decipher respectively.Piece alignment problem comprises alignment forward and alignment backward, guarantees that each decryption block is corresponding with corresponding cryptographic block.Piece alignment problem is a significant problem, if block alignment errors, and the data that decrypt so will be a pile mess codes.
In addition, the present invention also can dispose flexibly in existing mailing system, and at this moment, decrypting process is divided into two parts: the one, rewrite the inlet flow structure of deciphering, and the 2nd, check encryption indicator, replace inlet flow structure.Original inlet flow construction packages some system calls, read, seek etc., rewrite inlet flow structure and only need to rewrite original read, and preserve encryption key, mail head's size.
Referring to Fig. 4, for deciphering flow chart of the present invention, this flow chart is the example that is deployed as being attached in existing mailing system, it comprises reads decrypting process (referring to Fig. 4 a) and replace input stream procedure (referring to accompanying drawing 4b), now in conjunction with Fig. 4 a and Fig. 4 b, illustrate job step, when entering decrypting process s106, first enter step s411, start to carry out replacement input stream procedure, when execution step s412, open mailbox and obtain mail inlet flow structure, and check mail head's encryption indicator S413, at step S414, judge, if do not finish to replace input stream procedure if do not exist sign directly to perform step S417, if exist sign to perform step S415, obtain generation key, and enter and replace inlet flow structure S416, be finished, finish to replace input stream procedure S417, enter subsequently step S401 and start to read decrypting process, first perform step S402, the relation of document location and piece is read in calculating, by step S403, is judged whether at block boundary, is directly to enter step S405 read data to buffering area, perform step if not S404, reading location is aligned to forward integer piece, then enters step S405 read data to buffering area, and by step, S406 deciphers and copies away, complete laggard ending step S407, the mail that completes client reads process.
Certainly the method also can be applicable to service system newly developed, and at this moment step s412 and s416 just can omit.
The present invention has realized the encryption storage of mail on server technically, each user is with its storage encryption key separately, can effectively prevent that server attack person or unique keeper from checking private mail, improved the fail safe of mail server.And user can control whether open encryption voluntarily, also can be in existing mailing system subordinate's this method flexibly.
Utilize the present invention, can make mail between storage life, be the form storage with ciphertext, thereby reach secret effect on server.

Claims (8)

1. an implementation method that guarantees safety of electronic mail storage, is characterized in that, comprises the steps:
(1), in registration during mailbox, mail delivery proxy server generates its unique random train r for user, and this random train r is preserved;
(2) when this mail delivery proxy server is received described user's mail, this mail delivery proxy server is got this random train r, with a kind of key schedule H, produce symmetric key k, then with a kind of symmetry algorithm F privacy enhanced mail, expressly generate mail ciphertext, and this mail ciphertext is preserved;
(3) when user reads the mail of described mailbox by IMAP or POP3 agreement, first mail delivery proxy server gets this random train r, with same key schedule H, produce symmetric key k, finally with symmetry algorithm F, decipher this mail ciphertext, and allow user can obtain mail by IMAP/POP3 agreement;
Wherein, in step (2) and step (3), be the method for random train r of getting according to subscriber mailbox, and the Email in this random train r and mailbox store respectively, the level of security of this random train r is higher;
Wherein, the encrypt and decrypt of mail all completes at server end, irrelevant with client, and is to be encrypted before email storage, when reading, is decrypted, and in addition, before encrypting, also carries out a preliminary treatment;
And this mail ciphertext of deciphering is that segmentation is independently carried out in step (3), decrypting process is only deciphered Yi Ge buffering area at every turn, adopts and reads the how many strategy of how many deciphering, kidnaps a system call of reading, only to decipher corresponding fragment according to user's demand.
2. the implementation method that assurance safety of electronic mail as claimed in claim 1 is stored, it is characterized in that, the Symmetric key generation algorithm H that step (2) and step (3) adopt, for existing pseudo random sequence generating algorithm or individual event hashing algorithm, or those existing pseudo random sequence generating algorithms or the mixing of individual event hashing algorithm or distortion.
3. the implementation method of assurance safety of electronic mail as claimed in claim 1 storage, is characterized in that, only for mail body, is encrypted, and mail header is divided and remained unchanged.
4. the implementation method of the assurance safety of electronic mail as described in claim 1 or 3 storage, is characterized in that, for the encryption of mail body, is that segmentation is independently carried out.
5. the implementation method of assurance safety of electronic mail storage as claimed in claim 1, is characterized in that, to adding overstocked mail, writes sign in mail head, in order to distinguish unencrypted mail.
6. the implementation method of assurance safety of electronic mail storage as claimed in claim 1, is characterized in that, user controls whether open encryption voluntarily.
7. the implementation method that assurance safety of electronic mail as claimed in claim 6 is stored, it is characterized in that, in step (2), first inquire this user and whether open storage encryption function, if opened, obtain generation key, and be kept in a file under home directory, for encrypting step subsequently.
8. the implementation method that assurance safety of electronic mail as claimed in claim 6 is stored, it is characterized in that, the method is deployed in existing mailing system of not having an encryption flow, the method also comprises replacement input stream procedure, this replacement input stream procedure is when customer selecting is encrypted, to replace unencryption flow process with encrypting or decipher flow process.
CN200910181093.1A 2009-10-28 2009-10-28 Implementation method for ensuring secure storage of electronic mails Active CN102055722B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN200910181093.1A CN102055722B (en) 2009-10-28 2009-10-28 Implementation method for ensuring secure storage of electronic mails

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN200910181093.1A CN102055722B (en) 2009-10-28 2009-10-28 Implementation method for ensuring secure storage of electronic mails

Publications (2)

Publication Number Publication Date
CN102055722A CN102055722A (en) 2011-05-11
CN102055722B true CN102055722B (en) 2014-01-15

Family

ID=43959657

Family Applications (1)

Application Number Title Priority Date Filing Date
CN200910181093.1A Active CN102055722B (en) 2009-10-28 2009-10-28 Implementation method for ensuring secure storage of electronic mails

Country Status (1)

Country Link
CN (1) CN102055722B (en)

Families Citing this family (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2013097326A1 (en) * 2011-12-29 2013-07-04 盈世信息科技(北京)有限公司 Electronic mail encryption method, mail server, and system
CN103023655B (en) * 2012-12-13 2016-06-29 曙光云计算技术有限公司 Network safety system
CN103188271A (en) * 2013-04-19 2013-07-03 国家电网公司 Secure mail client local data storage and identification methods and devices
CN104410564B (en) * 2014-11-26 2018-09-25 论客科技(广州)有限公司 A kind of important email judgment method
CN110971394A (en) * 2019-12-09 2020-04-07 紫光云(南京)数字技术有限公司 Mechanism for realizing safety of mobile mailbox

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1558580A (en) * 2004-02-03 2004-12-29 胡祥义 A network data safety protection method based on cryptography
CN101123495A (en) * 2007-09-07 2008-02-13 农革 A data encryption, decryption system and method
CN101309278A (en) * 2008-06-27 2008-11-19 腾讯科技(深圳)有限公司 Method and system for storing encrypt data on customer
CN101335627A (en) * 2008-07-31 2008-12-31 中兴通讯股份有限公司 Network facsimile system and using method thereof
CN100477647C (en) * 2004-10-28 2009-04-08 杭州华三通信技术有限公司 E-mail management system and method

Family Cites Families (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
GB2368756A (en) * 2000-11-02 2002-05-08 Roke Manor Research Email encryption system in which messages are sent via an encryption server which stores the public keys of intended recipients
AU2002256965A1 (en) * 2002-05-06 2003-12-02 Rhandeev Singh A method of processing electronic mail
CN1885762A (en) * 2005-06-24 2006-12-27 网际威信控股公司 E-mail encryption/decryption method and its storage media and module
JP4728902B2 (en) * 2006-07-28 2011-07-20 Necビッグローブ株式会社 Secure mail distribution system, secure mail distribution apparatus, secure mail distribution method, and program
JP2009118202A (en) * 2007-11-07 2009-05-28 Hitachi Ltd Electronic mail distribution method

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN1558580A (en) * 2004-02-03 2004-12-29 胡祥义 A network data safety protection method based on cryptography
CN100477647C (en) * 2004-10-28 2009-04-08 杭州华三通信技术有限公司 E-mail management system and method
CN101123495A (en) * 2007-09-07 2008-02-13 农革 A data encryption, decryption system and method
CN101309278A (en) * 2008-06-27 2008-11-19 腾讯科技(深圳)有限公司 Method and system for storing encrypt data on customer
CN101335627A (en) * 2008-07-31 2008-12-31 中兴通讯股份有限公司 Network facsimile system and using method thereof

Non-Patent Citations (2)

* Cited by examiner, † Cited by third party
Title
JP特开2008-35145A 2008.02.14
JP特开2009-118202A 2009.05.28

Also Published As

Publication number Publication date
CN102055722A (en) 2011-05-11

Similar Documents

Publication Publication Date Title
US20190334878A1 (en) System and method for enhanced data protection
JP3640331B2 (en) Two-phase encryption key recovery system
CN107086915B (en) Data transmission method, data sending end and data receiving end
CN1729647B (en) Methods, apparatus and computer programs for generating and/or using conditional electronic signatures for reporting status changes
CN100431295C (en) Method and device for data encipher/deciphering
CN107070879B (en) Data guard method and system
CN103684794A (en) Communication data encryption and decryption method based on DES (Data Encryption Standard), RSA and SHA-1 (Secure Hash Algorithm) encryption algorithms
CN102055722B (en) Implementation method for ensuring secure storage of electronic mails
CN109543434B (en) Block chain information encryption method, decryption method, storage method and device
US10567357B2 (en) Secure transmission system with upgraded encryption strength
CN101753311A (en) Information privacy and identity authentication method and digital signature program
CN110138795B (en) Multi-step mixed encryption and decryption method in communication process
CN101345624B (en) Document access system and method
CN102355352A (en) Data confidentiality and integrity protection method
RU2008122777A (en) Encapsulating Address Components
CN103117850B (en) A kind of method for building up of the cryptographic system based on random sequence database
CN103532709B (en) A kind of IBE encryption apparatus and data encryption/decryption method
CN102572750A (en) Method and terminal for protecting short messages
JP2002185443A (en) Secret key managing system
JP2003204323A (en) Secret communication method
CN105471657B (en) inter-domain communication log management method, device and system for virtual machine
US20170365193A1 (en) Mutable secure communication
US20160080327A1 (en) Terminal apparatus, gateway apparatus, and relay apparatus connected to content-centric network, and communication method
CN101369887B (en) E-mail enciphered transmission method
CN106453300A (en) Data encryption and decryption method and device, and data transmission system

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
ASS Succession or assignment of patent right

Owner name: CHINA STANDARD SOFTWARE CO., LTD.

Free format text: FORMER OWNER: SHANGHAI ZHONGBIAO SOFTWARE CO. LTD.

Effective date: 20120305

C41 Transfer of patent application or patent right or utility model
COR Change of bibliographic data

Free format text: CORRECT: ADDRESS; FROM: 200233 XUHUI, SHANGHAI TO: 200030 XUHUI, SHANGHAI

TA01 Transfer of patent application right

Effective date of registration: 20120305

Address after: 200030 room 1006-1010, Panyu Road, Shanghai, 1028

Applicant after: China Standard Software Co., Ltd.

Address before: 200233 No. 418, Shanghai, Guilin Road

Applicant before: Shanghai Zhongbiao Software Co., Ltd.

C14 Grant of patent or utility model
GR01 Patent grant