JPH0820847B2 - Blocking method for remainder calculation - Google Patents
Blocking method for remainder calculationInfo
- Publication number
- JPH0820847B2 JPH0820847B2 JP62336045A JP33604587A JPH0820847B2 JP H0820847 B2 JPH0820847 B2 JP H0820847B2 JP 62336045 A JP62336045 A JP 62336045A JP 33604587 A JP33604587 A JP 33604587A JP H0820847 B2 JPH0820847 B2 JP H0820847B2
- Authority
- JP
- Japan
- Prior art keywords
- data
- block
- flag
- remainder
- result
- 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.)
- Expired - Lifetime
Links
- 238000000034 method Methods 0.000 title description 16
- 230000000903 blocking effect Effects 0.000 title description 4
- 230000005540 biological transmission Effects 0.000 description 1
- 238000007796 conventional method Methods 0.000 description 1
- 238000010586 diagram Methods 0.000 description 1
- 230000000694 effects Effects 0.000 description 1
Description
【発明の詳細な説明】 (産業上の利用分野) 本発明は剰余演算処理により符号化する入力ビット列
をブロック化する方法およびその復号化に関する。Description: TECHNICAL FIELD The present invention relates to a method of dividing an input bit string to be encoded by a residue arithmetic process into blocks and its decoding.
(従来の技術) 入力されたビット列をブロック化し、おのおののブロ
ックに関してある正整数Nを法とした剰余演算を行う場
合、Nのビット数よりも小さいビット数でブロック化を
行う方法が知られている。例えば、コンピュータ(Comp
uter)誌1986年9月号に掲載された論文「ア・プロポー
ズド・スタンダード・フォーマット・フォア・アール・
エス・エー・クリプトシステムズ(A Proposed Standar
d Format foe RSA Cryptosystems)」では、入力された
バイト列をNのバイト数よりも1少ないバイト数でブロ
ック化する方法が提案されている。(Prior Art) When the input bit string is divided into blocks and a remainder operation is performed on each block using a certain positive integer N as a modulus, a method is known in which the number of bits is smaller than N. There is. For example, a computer (Comp
The paper "A Proposed Standard Format for R.
S Crypto Systems (A Proposed Standar
d Format foe RSA Cryptosystems) ”, a method of blocking an input byte string with one byte less than N bytes is proposed.
(発明が解決しようとする問題点) 従来の方式において、1ビット少なくブロッキングす
るとバイト単位の処理が難しくなり、また、1バイト少
なくブロッキングすると、剰余演算後の出力はNと同じ
バイト数になるのでこの処理により1ブロックに付き1
バイト長さが増えるという欠点を持つ。(Problems to be Solved by the Invention) In the conventional method, if the data is blocked by 1 bit less, it becomes difficult to process in byte units, and if it is blocked by 1 byte less, the output after the remainder operation has the same number of bytes as N. 1 per block by this process
It has the drawback of increasing the byte length.
(問題点を解決するため手段) 上記問題点を解決するため、 本発明の剰余演算用ブロック化方法は、kビットで表
現される正整数Nを法とした剰余演算処理を用いてデー
タを送受信する時に用いる剰余演算用ブロック化方法で
あって、 データ送信側は、送信すべき入力データをkビット長
でブロッキングし、前記ブロック化された各ブロックデ
ータを数値化し、数値化されたブロックデータがNより
大きいか否かを判定し、判定の結果Nより大きい場合に
はフラグをたて、前記数値化されたブロックデータに対
して剰余演算処理を行い、剰余演算処理の結果と前記フ
ラグを送信し、 データ受信側は、受信データからフラグを切り出し、
フラグを除いた受信データをkビット長で再ブロッキン
グし、再ブロッキングされた各ブロックデータを数値化
し、数値化されたブロックデータに対して剰余演算処理
を行い、前記フラグのたっているブロックには剰余演算
処理の行われた結果にNを加算することを特徴とする。(Means for Solving the Problems) In order to solve the above problems, the residue calculation blocking method of the present invention transmits and receives data using a residue calculation process modulo a positive integer N represented by k bits. A block method for remainder calculation used when the data transmission side blocks input data to be transmitted with a k-bit length, digitizes each of the blocked block data, and digitizes the block data. It is determined whether or not it is greater than N. If the result of the determination is greater than N, a flag is set, a remainder operation process is performed on the digitized block data, and the result of the remainder operation process and the flag are transmitted. Then, the data receiving side cuts out the flag from the received data,
The received data excluding the flag is reblocked with a k-bit length, each reblocked block data is converted into a numerical value, and the remainder operation processing is performed on the converted block data. It is characterized in that N is added to the result of the arithmetic processing.
更に本発明の剰余演算用ブロック化方法は、前記デー
タ送信側で、各ブロックの前記演算処理の結果送信した
後に各ブロックのフラグを送信するか、あるいは各ブロ
ックのフラグを送信した後に各ブロックの剰余演算処理
の結果を送信することを特徴とする。Further, in the modular calculation blocking method of the present invention, the data transmitting side transmits the flag of each block after transmitting the result of the arithmetic processing of each block, or transmits the flag of each block and then transmits each block of each block. It is characterized in that the result of the remainder calculation process is transmitted.
(実施例) 本発明をRSA暗号に実施した例を与える。(Example) An example in which the present invention is applied to RSA encryption will be given.
RSA暗号を簡単に説明する。暗号化したメッセージM
(ただし0≦M<N)を暗号化鍵Eを用いてC=MEmodN
を計算し、Cを暗号文とする。これを復号化鍵Dを用い
てCDmodNを計算すればMが復号できるという暗号方式で
ある。詳細は前記の文献に載っている。The RSA encryption will be briefly explained. Encrypted message M
(Where 0 ≦ M <N) using the encryption key E, C = M E modN
Is calculated and C is a ciphertext. This is an encryption method in which M can be decrypted by calculating C D mod N using the decryption key D. Details are given in the above-mentioned document.
いま、Nを64バイトの数とする。 Now, let N be a 64-byte number.
まず、第一の発明の実施例を示す。第1図は実施例を
示すフローチャートである。First, an embodiment of the first invention will be shown. FIG. 1 is a flow chart showing an embodiment.
暗号化したいテキストをバイト単位で読み込み、64バ
イトを1ブロックとする。64バイトに満たないときは、
例えば零詰めにする。i番目のブロックの値をMiとする
とMi≧Nのとき、i番目のフラグFiをたてる。暗号化は
Mi EmodN或は(Mi-N)EmodNを計算して64バイトの暗号文Ci
を得る。暗号文Ci(i=0,1,2,…)とフラグFi(i=0,
1,2,…)を送信、或はファイルに格納する。Read the text to be encrypted byte by byte and make 64 bytes one block. If it is less than 64 bytes,
For example, zero padding. If the value of the i-th block is M i , and M i ≧ N, the i-th flag F i is set. Encryption is
M i E modN or (M i -N) E mod N is calculated and ciphertext of 64 bytes C i
Get. Ciphertext C i (i = 0,1,2, ...) and flag F i (i = 0,
1,2, ...) or store it in a file.
暗号文とフラグは、例えば別々のデータとしてもよい
し、暗号文の最初か最後にフラグを付けてもよい。第2
図は、この一例のフォーマットを示す図で、暗号文の最
後にフラグを付けている。フラグは8個で1バイトにパ
ックする。The ciphertext and the flag may be, for example, separate data, or the ciphertext may be flagged at the beginning or the end. Second
The figure shows the format of this example, and a flag is attached to the end of the ciphertext. Eight flags are packed in 1 byte.
次に第二の発明の実施例を示す。 Next, an embodiment of the second invention will be shown.
第三図は第2の実施例を示すフローチャートである。 FIG. 3 is a flow chart showing the second embodiment.
上記のように暗号化された暗号文Ciとそれに対応する
フラグFiを用いて復号する。例えば第二図のようにフオ
ーマットされたファイルを受け取ったとする。このと
き、ファイルの大きさが分かれば、暗号文64バイトに対
してフラグが1ビット付いているので、フラグと暗号文
の配分は一意に分かる。Decryption is performed using the ciphertext C i encrypted as described above and the corresponding flag F i . For example, suppose that a formatted file is received as shown in FIG. At this time, if the file size is known, the flag is attached to 1 bit for 64 bytes of the ciphertext, so that the distribution of the flag and the ciphertext can be uniquely known.
復号鍵Dを用いて、Mi′=Ci DmodNを計算する。もし
フラグFiがたっていればこれにNをくわえたものをMi′
とする。このときすべてのiに対してMi′=Miが成り立
っている。Using the decryption key D, calculate M i ′ = C i D modN. If the flag F i is set, add N to this flag M i ′
And At this time, M i ′ = M i holds for all i.
(発明の効果) 以上詳細に説明したように、本発明ブロック方式を用
いれば、テキストの長さをそれほど増やすことなく剰余
演算によるバイト単位の処理が行えるので、暗号などに
適用して効果が大きい。(Effects of the Invention) As described in detail above, if the block method of the present invention is used, it is possible to perform byte-by-byte processing by the remainder calculation without increasing the length of the text so much, and it is very effective when applied to encryption or the like. .
第1図は本発明の実施例における暗号化のフローチャー
ト、第2図は暗号文とフラグのフォーマットの一例を示
す図、第3図は本第二発明の実施例における復号化のフ
ローチャートである。FIG. 1 is a flowchart of encryption in an embodiment of the present invention, FIG. 2 is a diagram showing an example of a ciphertext and flag format, and FIG. 3 is a flowchart of decryption in an embodiment of the second invention.
フロントページの続き (56)参考文献 特開 昭62−118642(JP,A) Computer September 1986P.21−34「Proposed S tandard Format for RSA Chptodydtems」Ph ilip ZimmermannContinuation of the front page (56) References JP 62-118642 (JP, A) Computer September 1986P. 21-34 "Proposed Standard Format for RSA Chptodydtems" Ph ilip Zimmermann
Claims (2)
剰余演算処理を用いてデータを送受信する時に用いる剰
余演算用ブロック化方法であって、 データ送信側は、送信すべき入力データをkビット長で
ブロッキングし、前記ブロック化された各ブロックデー
タを数値化し、数値化されたブロックデータがNより大
きいか否かを判定し、判定の結果Nより大きい場合には
フラグをたて、前記数値化されたブロックデータに対し
て剰余演算処理を行い、剰余演算処理の結果と前記フラ
グを送信し、 データ受信側は、受信データからフラグを切り出し、フ
ラグを除いた受信データをkビット長で再ブロッキング
し、再ブロッキングされた各ブロックデータを数値化
し、数値化されたブロックデータに対して剰余演算処理
を行い、前記フラグのたっているブロックには剰余演算
処理の行われた結果にNを加算することを特徴とした剰
余演算用ブロック化方法。1. A remainder calculation blocking method used when transmitting and receiving data by using a remainder calculation process modulo a positive integer N represented by k bits, wherein a data transmission side inputs data to be transmitted. Is blocked with a k-bit length, each of the blocked block data is digitized, it is determined whether the digitized block data is larger than N, and if the result of the determination is larger than N, a flag is set. , Performing remainder calculation processing on the digitized block data, transmitting the result of the remainder calculation processing and the flag, and the data receiving side cuts a flag from the reception data and removes the flag from the reception data by k bits. Reblocking is performed for a long time, each reblocked block data is converted into a numerical value, and the remainder operation processing is performed on the converted numerical block data. Remainder operation for blocking method characterized by adding N to the result made a remainder operation process is linked blocks.
算処理の結果送信した後に各ブロックのフラグを送信す
るか、あるいは各ブロックのフラグを送信した後に各ブ
ロックの剰余演算処理の結果を送信することを特徴とす
る特許請求の範囲第1項に記載の剰余演算用ブロック化
方法。2. The data transmitting side transmits the flag of each block after transmitting the result of the arithmetic processing of each block, or transmits the result of the remainder arithmetic processing of each block after transmitting the flag of each block. The modularization blocking method according to claim 1, wherein:
Priority Applications (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| JP62336045A JPH0820847B2 (en) | 1987-12-29 | 1987-12-29 | Blocking method for remainder calculation |
Applications Claiming Priority (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| JP62336045A JPH0820847B2 (en) | 1987-12-29 | 1987-12-29 | Blocking method for remainder calculation |
Publications (2)
| Publication Number | Publication Date |
|---|---|
| JPH01175629A JPH01175629A (en) | 1989-07-12 |
| JPH0820847B2 true JPH0820847B2 (en) | 1996-03-04 |
Family
ID=18295130
Family Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| JP62336045A Expired - Lifetime JPH0820847B2 (en) | 1987-12-29 | 1987-12-29 | Blocking method for remainder calculation |
Country Status (1)
| Country | Link |
|---|---|
| JP (1) | JPH0820847B2 (en) |
Families Citing this family (1)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| JPH0740339Y2 (en) * | 1988-11-24 | 1995-09-20 | タイガー魔法瓶株式会社 | Electric hot water storage container |
Family Cites Families (1)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| JPH07105730B2 (en) * | 1985-11-19 | 1995-11-13 | キヤノン株式会社 | Encoder |
-
1987
- 1987-12-29 JP JP62336045A patent/JPH0820847B2/en not_active Expired - Lifetime
Non-Patent Citations (1)
| Title |
|---|
| ComputerSeptember1986P.21−34「ProposedStandardFormatforRSAChptodydtems」PhilipZimmermann |
Also Published As
| Publication number | Publication date |
|---|---|
| JPH01175629A (en) | 1989-07-12 |
Similar Documents
| Publication | Publication Date | Title |
|---|---|---|
| EP0792041B1 (en) | Method and apparatus for block encryption | |
| US7231040B1 (en) | Multiprime RSA public key cryptosystem | |
| US7603560B2 (en) | Method and apparatus for digital signature authentication | |
| KR100362458B1 (en) | Cryptographic processing apparatus, cryptographic processing method, and recording medium recording cryptographic processing program for realizing high-speed crypographic processing without impairing security | |
| EP1031204B1 (en) | Cryptographic system and method with fast decryption | |
| US6477254B1 (en) | Network system using a threshold secret sharing method | |
| JP3917679B2 (en) | High bandwidth cryptographic system with low bandwidth cryptographic module | |
| CN109039640A (en) | A kind of encryption and decryption hardware system and method based on rsa cryptosystem algorithm | |
| EP0673134B1 (en) | Pseudo-random number generator, and communication method and apparatus using encrypted text based upon pseudo-random numbers generated by said generator | |
| JPH09230786A (en) | Data encryption method and device | |
| JPH11510036A (en) | Decryption of retransmitted data in encrypted communication systems | |
| JPH0380645A (en) | Enciphering method and deciphering method | |
| WO2003084077A1 (en) | Variable/fixed length data conversion method and device | |
| JP3204317B2 (en) | Electronic bidding system | |
| US5761310A (en) | Communication system for messages enciphered according to an RSA-type procedure | |
| JPH06282227A (en) | Public key encryption device and public key decryption device | |
| JPH0777933A (en) | Network data encryption device | |
| JPH01175629A (en) | Blocking system for remainder operation | |
| JP3464771B2 (en) | Electronic signature creation method by partial partial decryption, electronic signature creation device, and program recording medium for creating electronic signature | |
| CN115378593B (en) | Processing system and corresponding operating methods | |
| JPH1155244A (en) | Key recovery method and device | |
| JP2004184516A (en) | Digital data transmission terminal | |
| JPH06138820A (en) | Encryption device and encryption / decryption device | |
| JPH09200195A (en) | Encryption communication method | |
| JP2753269B2 (en) | Asymmetric key cryptography |
Legal Events
| Date | Code | Title | Description |
|---|---|---|---|
| EXPY | Cancellation because of completion of term |