CN115276990B - Safety storage method for research and development information of ocean engineering equipment - Google Patents

Safety storage method for research and development information of ocean engineering equipment Download PDF

Info

Publication number
CN115276990B
CN115276990B CN202211186457.7A CN202211186457A CN115276990B CN 115276990 B CN115276990 B CN 115276990B CN 202211186457 A CN202211186457 A CN 202211186457A CN 115276990 B CN115276990 B CN 115276990B
Authority
CN
China
Prior art keywords
data
plaintext
decimal
magic cube
sequence
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
CN202211186457.7A
Other languages
Chinese (zh)
Other versions
CN115276990A (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.)
Nantong Senmiao Ship Technology Co ltd
Original Assignee
Nantong Senmiao Ship Technology 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 Nantong Senmiao Ship Technology Co ltd filed Critical Nantong Senmiao Ship Technology Co ltd
Priority to CN202211186457.7A priority Critical patent/CN115276990B/en
Publication of CN115276990A publication Critical patent/CN115276990A/en
Application granted granted Critical
Publication of CN115276990B publication Critical patent/CN115276990B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L9/00Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols
    • H04L9/08Key distribution or management, e.g. generation, sharing or updating, of cryptographic keys or passwords
    • H04L9/0816Key establishment, i.e. cryptographic processes or cryptographic protocols whereby a shared secret becomes available to two or more parties, for subsequent use
    • H04L9/0819Key transport or distribution, i.e. key establishment techniques where one party creates or otherwise obtains a secret value, and securely transfers it to the other(s)
    • H04L9/0825Key transport or distribution, i.e. key establishment techniques where one party creates or otherwise obtains a secret value, and securely transfers it to the other(s) using asymmetric-key encryption or public key infrastructure [PKI], e.g. key signature or public key certificates
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F21/00Security arrangements for protecting computers, components thereof, programs or data against unauthorised activity
    • G06F21/60Protecting data
    • G06F21/602Providing cryptographic facilities or services
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L9/00Cryptographic mechanisms or cryptographic arrangements for secret or secure communications; Network security protocols
    • H04L9/08Key distribution or management, e.g. generation, sharing or updating, of cryptographic keys or passwords
    • H04L9/0861Generation of secret information including derivation or calculation of cryptographic keys or passwords

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Security & Cryptography (AREA)
  • Signal Processing (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Theoretical Computer Science (AREA)
  • Software Systems (AREA)
  • Health & Medical Sciences (AREA)
  • Physics & Mathematics (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Computer Hardware Design (AREA)
  • General Health & Medical Sciences (AREA)
  • Bioethics (AREA)
  • Management, Administration, Business Operations System, And Electronic Commerce (AREA)
  • Compression, Expansion, Code Conversion, And Decoders (AREA)

Abstract

The application relates to the technical field of digital data processing, in particular to a safe storage method of research and development information of ocean engineering equipment, which uniformly codes the research and development information of the ocean engineering equipment of different types to obtain a data sequence; segmenting the data sequence, converting each segment of subsequence into decimal data, performing six-equal division on all decimal data, and respectively generating square matrixes to form a plaintext magic cube model; acquiring the discreteness of each line or each column of data in each face of the plaintext magic cube model, and calculating the average value of all discreteness corresponding to each layer to be used as the public key of the data of the layer; the public key is utilized to acquire the rotation angle and the rotation sequence as the corresponding private key; encrypting the plaintext magic cube model based on the public key and the private key to obtain a ciphertext magic cube model; and disassembling the ciphertext magic square model to obtain an encrypted binary sequence and storing the encrypted binary sequence. The application avoids the problem of key management and improves the storage safety of the research and development information of the ocean engineering equipment.

Description

Safety storage method for research and development information of ocean engineering equipment
Technical Field
The application relates to the technical field of digital data processing, in particular to a safe storage method of research and development information of ocean engineering equipment.
Background
In order to meet the needs of various ocean exploration, ocean engineering equipment needs to be used and developed, so the emphasis in the ocean engineering industry is on the development of the ocean engineering equipment. In order to avoid malicious competition and leakage of research and development information of marine engineering equipment, the research and development information of the marine engineering equipment needs to be stored safely, wherein the most common means is to encrypt the information.
The research and development information of ocean engineering is very complex information data, and the magic cube encryption algorithm has good encryption effect on relatively complex information. However, when the conventional magic cube encryption algorithm is used for encrypting and storing ocean engineering equipment research and development information, the conventional magic cube encryption algorithm is used for encrypting and storing the ocean engineering equipment research and development information, more keys are needed for information encryption because the data size is large, the keys are determined in advance, the security is extremely threatening under the condition that the number of the key holders is large, the keys are needed to be replaced frequently to ensure the security of the ocean engineering equipment research and development information, and inconvenience is caused to the storage and management of the keys.
Disclosure of Invention
In order to solve the problem of insufficient safety of a symmetrical magic cube encryption algorithm, the application provides a safe storage method of research and development information of ocean engineering equipment, and the adopted technical scheme is as follows:
an embodiment of the application provides a safe storage method of ocean engineering equipment research and development information, which comprises the following steps:
uniformly coding research and development information of different types of ocean engineering equipment to obtain a data sequence consisting of binary coded data;
screening out the optimal length by calculating the redundancy of binary codes with different lengths, segmenting the data sequence with the optimal length, wherein the length of each segment of sub-sequence is the optimal length; converting each segment of subsequence into decimal data, performing hexagonal division on all decimal data, respectively generating square matrixes, and forming a plaintext magic cube model by taking each square matrix as a surface;
acquiring a corresponding weight based on the occurrence probability of each decimal data in the plaintext magic cube model, acquiring the discreteness of each line or each column of data in each surface of the plaintext magic cube model according to the weight and the probability, taking the data of the same line or the same column of all surfaces as one layer of the plaintext magic cube model, and calculating the average value of all discreteness corresponding to each layer as the public key of the data of the layer; the public key is utilized to acquire the rotation angle and the rotation sequence as the corresponding private key;
rotating the plaintext magic cube data according to the rotation sequence and rotation angle of the private key of each layer of plaintext magic cube data, and obtaining an encrypted ciphertext magic cube model after all layers are rotated; and disassembling the ciphertext magic square model to obtain an encrypted binary sequence, and storing the encrypted binary sequence.
Preferably, the redundancy obtaining method includes:
starting from the length of 8, segmenting the data sequence by taking each length as a segmentation unit, obtaining the segmented data length of each segment of data which is equally divided into 6 sections, and subtracting the data length from the number obtained by rounding up the data length to obtain the redundancy.
Preferably, the probability obtaining method includes:
taking the ratio of the total number of occurrences of each decimal data in the plaintext magic cube model to the total number of occurrences of all decimal data in the plaintext magic cube model as a first probability;
taking the ratio of the total number of occurrences of each decimal data on any one face in the plaintext magic cube model to the total number of occurrences of all decimal data in the face as a second probability;
the probability of occurrence of each decimal data includes the first probability and the second probability.
Preferably, the weight obtaining method includes:
calculating the variance of the second probability of any decimal data in six faces, and multiplying the square of the variance by the first probability of the decimal data to obtain the weight.
Preferably, the method for acquiring the discreteness comprises the following steps:
taking the product result of multiplying each decimal data by the corresponding weight value as the weight value of the decimal data, then obtaining the joint value of the weight value corresponding to the decimal data of the decimal data and two adjacent positions of the same row or the same column, calculating the joint value probability of the joint value in the corresponding row or the corresponding column, and taking the sum of the information entropy of all the joint value probabilities in the row or the column as the discreteness of the corresponding row or the corresponding column.
Preferably, the method for obtaining the rotation angle comprises the following steps:
and calculating a remainder obtained by dividing the public key by 4, and taking the product of the remainder and 90 degrees as the rotation angle.
Preferably, the method for acquiring the rotation sequence comprises the following steps:
all public keys are ordered in descending order from big to small, and the ordering order is the rotation order of the private keys.
Preferably, the method further comprises the steps of:
and generating a ciphertext magic cube model by the encrypted binary sequence, rotating the ciphertext magic cube model by using a private key to obtain a restored plaintext Wen Mofang model, disassembling the restored plaintext magic cube model to obtain a decimal plaintext matrix, generating a decimal plaintext sequence by the decimal plaintext matrix, and converting the decimal plaintext sequence into binary ocean engineering equipment research and development information to finish decryption.
The embodiment of the application has at least the following beneficial effects:
the optimal length of the generated data sequence after the ocean engineering equipment research and development information is encoded is screened out for segmentation, so that the zero padding quantity is minimum and the redundancy quantity is minimum when the data sequence is used for constructing a Wen Mofang model; and then, the discrete property of the constructed plaintext magic cube model is calculated in a layering manner to be used as a public key, and the private key is calculated based on the public key, so that the plaintext magic cube model is encrypted, the research and development information of the ocean engineering equipment can be encrypted according to the characteristic combination algorithm of the data, instead of taking a predetermined secret key as an encryption basis, the problem of secret key management is avoided, and the storage safety of the research and development information of the ocean engineering equipment is improved.
Drawings
In order to more clearly illustrate the embodiments of the application or the technical solutions and advantages of the prior art, the following description will briefly explain the drawings used in the embodiments or the description of the prior art, and it is obvious that the drawings in the following description are only some embodiments of the application, and other drawings can be obtained according to the drawings without inventive effort for a person skilled in the art.
Fig. 1 is a flowchart of a method for securely storing development information of marine engineering equipment according to an embodiment of the present application.
Detailed Description
In order to further describe the technical means and effects adopted by the application to achieve the preset aim, the following is a specific implementation, structure, characteristics and effects of the method for safely storing development information of ocean engineering equipment according to the application, which are described in detail below with reference to the accompanying drawings and preferred embodiments. In the following description, different "one embodiment" or "another embodiment" means that the embodiments are not necessarily the same. Furthermore, the particular features, structures, or characteristics of one or more embodiments may be combined in any suitable manner.
Unless defined otherwise, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the art to which this application belongs.
The application provides a specific scheme of a safe storage method for ocean engineering equipment research and development information, which is specifically described below with reference to the accompanying drawings.
Referring to fig. 1, a flowchart of a method for securely storing development information of marine engineering equipment according to an embodiment of the application is shown, the method includes the following steps:
and S001, uniformly encoding the research and development information of the ocean engineering equipment of different types to obtain a data sequence consisting of binary coded data.
The method comprises the following specific steps of:
all information of the ocean engineering equipment is structured, so that the situation that the encryption effect is affected due to the fact that feature extraction is different due to the fact that compression coding technologies adopted for different types of data are different when encryption is carried out later is avoided. The structuring process is specifically to uniformly encode all the development information of the ocean engineering equipment of different types by using the same compression encoding technology, so that uniform binary encoded data are obtained.
Different types of marine engineering equipment development information include text information and image information.
There are many existing compression coding techniques, e.g. usingThe compression coding technique can perform compression coding on the whole information to enable the whole information to have binary compression coding with the same characteristic structure.
The length of the research and development information of all ocean engineering equipment obtained through unified coding isA data sequence consisting of binary coded data +.>Wherein->For the +.>And (3) binary coding.
Step S002, screening out the optimal length by calculating the redundancy of binary codes with different lengths, segmenting the data sequence with the optimal length, wherein the length of each segment of sub-sequence is the optimal length; and converting each segment of subsequence into decimal data, performing hexagonal division on all decimal data, respectively generating square matrixes, and forming a plaintext magic cube model by taking each square matrix as a surface.
The method comprises the following specific steps of:
1. the optimal length is selected by calculating the redundancy of binary codes with different lengths.
When the plaintext magic cube model is built, 6 data matrix matrixes with the same size are needed to be used as 6 faces of the plaintext magic cube model, so that data are required to be partitioned, and when the data are partitioned by the conventional data method, zero padding is needed to be carried out on the data, so that the whole data 6 are equally divided, and then the matrix matrixes can be generated, and a certain data redundancy is contained. The data redundancy has uncertainty, and the redundancy quantity cannot be determined.
Binary codes of a certain length correspond to a certain decimal value range, for example, 8 bits of length correspond to 8 binary codes of length, and the value range after conversion to decimal codes is 0,255]. On the basis of converting binary system into decimal system, the data sequence is equidistantly divided by utilizing the decimal value range. Calculating redundancy of each decimal value rangeWherein b represents the binary code length, and the optimal decimal code range is selected through redundancy, so that the zero padding quantity is minimum when the plaintext magic cube model is built, and the redundancy quantity is minimum.
Starting from the length of 8, segmenting the data sequence by taking each length as a segmentation unit, obtaining the data length of each segmented data which is equally divided into 6 sections, and subtracting the data length from the number obtained by rounding up the data length to obtain redundancy.
Starting with 8 binary codes, i.e.Its redundancy calculation->The mode is as follows:
wherein,representing redundancy at length 8, A represents the length of the data sequence, < >>Representing the total length of decimal data after decimal conversion of binary code in 8 bits as a unit,/->Representing the data length equally divided into 6 intervals for decimal encoding,/->Representing the side length of the square matrix generated by the square matrix over the interval length, namely the square matrix isSize, or->Representing rounding up symbols.
When the plain magic cube model is built, based on the physical model of the magic cube, each surface is square, so that the data of each partition is required to generate a square matrix, and when the data cannot generate the square matrix, the operation of end zero padding is generally required, the more the number of zero padding is, the redundancy of the data is increasedThe application uses mathematical rule to divide decimal data equally by 6 minutes, then uses evolution operation to make binary conversion under the length into decimal code to construct redundancy calculation of plaintext magic cube model, so as to select binary-decimal characteristic amplification method with minimum redundancy length. When (when)The closer to zero, the lower the redundancy is when the generation of the square matrix is performed after the binary length is converted into the decimal length.
For example:there is->;/>The method has the advantages that the number of zero padding needed when the plaintext magic cube model is built when binary data is converted into decimal by 8-bit binary codes is smaller, and the redundancy degree is smaller.
From subscriptsStarting to calculate redundancy until a certain length +.>When it corresponds to redundancy +.>The corresponding binary length B is the optimal length.
Because the gray value or single-channel value of each pixel point in the image information in the ocean engineering equipment research and development information is in the decimal range of [0,255], and the corresponding binary code is 8 bits, in order to ensure the undistorted data, the calculation is started from b=8
2. And segmenting the data sequence based on the optimal length, and constructing a plaintext magic cube model.
Segmenting the data sequence with the optimal length, wherein the length of each segment of sub-sequence is the optimal length; and converting each segment of subsequence into decimal data, performing hexagonal division on all decimal data, respectively generating square matrixes, and forming a plaintext magic cube model by taking each square matrix as a surface.
The binary coding of all ocean engineering equipment research and development information takes a group of continuous B binary codes as a subsequence, each subsequence is converted into decimal data, then all the decimal data after conversion are subjected to 6-equal division and square matrixes are generated, and then each square matrix is taken as each surface of a magic cube to form a plaintext magic cube model, wherein the size of each surface is thatI.e. there is a common +.>Go->Column>For convenience, the rows and columns are distinguished and represented by different parameters.
Step S003, obtaining a corresponding weight based on the occurrence probability of each decimal data in the plaintext magic cube model, obtaining the discreteness of each line or each column of data in each surface of the plaintext magic cube model according to the weight and the probability, taking the data in the same line or the same column of all surfaces as one layer of the plaintext magic cube model, and calculating the average value of all discreteness corresponding to each layer as the public key of the data of the layer; and acquiring the rotation angle and the rotation sequence by using the public key as a corresponding private key.
The conventional magic cube encryption algorithm is a symmetric encryption algorithm, when the data are encrypted, although the encryption effect on the complex data of the research and development information of marine equipment is better, the same has the corresponding defects of the symmetric encryption algorithm, such as key preservation problem, key replacement problem, key quantity problem and the like, and the specific defects are that a large number of keys are needed to rotate the magic cube model on the magic cube encryption algorithm, and the manual definition of the keys (namely, which layer rotates and the rotation times) is too troublesome, and the storage and the replacement are not facilitated, so the security is correspondingly insufficient in the encryption process. According to the application, on the basis of a symmetrical magic cube encryption algorithm, the corresponding public key and private key are generated by utilizing the characteristics of research and development information of marine equipment, and in the encryption process, the public key and the private key are correspondingly different due to the different encrypted data, so that the encrypted data is safer.
The method comprises the following specific steps of:
1. and obtaining the occurrence probability of each decimal data in the plaintext magic cube model.
Taking the ratio of the total number of occurrences of each decimal data in the plaintext magic cube model to the total number of occurrences of all decimal data in the plaintext magic cube model as a first probability; taking the ratio of the total number of occurrences of each decimal data on any one face in the plaintext magic cube model to the total number of occurrences of all decimal data in the face as a second probability; the probability of occurrence of each decimal data includes a first probability and a second probability.
In the first placePersonal decimal data->For example, calculate the first probability of its occurrence in the whole plaintext magic cube model +.>Wherein->Expressed as decimal data +>Total number of occurrences in the whole plaintext magic cube model, +.>The total number of all decimal data in the plaintext magic cube model.
And then calculateProbability of each face in the plaintext magic cube by +.>Face is exemplified by->,/>In->Second probability of face->Wherein->Expressed as decimal data +>In plaintext magic cube model +.>The total number of occurrences of a facet,is a plaintext magic cube model->The total number of all decimal data.
2. And acquiring a corresponding weight value based on the occurrence probability of each decimal data in the plaintext magic cube model.
The variance of the second probability of any decimal data in six faces is calculated, and the square of the variance is multiplied by the first probability of the decimal data to obtain a weight.
Using decimal dataThe decimal corresponding weight is carried out on the probability of occurrence in the whole plaintext magic cube model and the probability of occurrence of each face>The specific calculation process is as follows:
in the plaintext magic cube model, the number of decimal data is equal under the condition of larger probability, and the discrete representation is not obvious when the discrete calculation of the data of each row or each column is carried out later, so the probability is utilized to calculate the weight value of each decimal data, and the difference of the discrete property of each decimal data is amplified through the weight value.
First, thePersonal decimal data->The probability in the whole plaintext magic cube is fixed, but the probability in each face is different due to the different number of occurrences of each face in the plaintext magic cube model, so for +.>The variance of the probability of occurrence at each face is calculated, the larger the variance thereof, the more random the occurrence in the six faces of the plaintext magic cube model thereof, i.e. ≡>The greater the number of occurrences at 6 faces, and the amplification thereof by square is performed so that +.>The distribution difference of six faces of the plain magic cube model is more obvious. Finally use decimal data->The product of the probability of occurrence in the whole plaintext magic cube model and the amplified differences of the six faces is taken as +.>Weight of (2) which can represent data +.>Distribution in the whole magic cube: />The larger the explanatory data +.>The more times that appear, and the irregularities in which they are distributed in the six faces of the plaintext cube; and has lower repeatability: because the decimal data may have the same probability in the whole plaintext magic cube model, but the corresponding weight will be different if the probability of occurrence of any one of the six faces of the plaintext magic cube model is different, and the probability of occurrence of the decimal data at each face is particularly low relative to the large amount of data at each face, the corresponding repeatability is lower, and the data amount of the plaintext imitation model can be solvedThere are more problems with the same probability of decimal data in larger cases. So that even if the probability of decimal data is the same in the subsequent discrete calculation of each row or each column of data, the difference is more obvious.
By the method, the weights of all decimal data in the plaintext magic cube model are calculated, and the weights corresponding to all decimal data can be obtained.
3. And acquiring the discreteness of each row or each column of data in each face of the plaintext magic cube model according to the weight and the probability. And taking the data of the same row or the same column of all the surfaces as one layer of the plaintext magic cube model, and calculating the average value of all the discreteness corresponding to each layer as the public key of the data of the layer.
Taking the product result of multiplying each decimal data by the corresponding weight value as the weight value of the decimal data, then obtaining the joint value of the weight value corresponding to the decimal data of the decimal data and two adjacent positions of the same row or the same column, calculating the joint value probability of the joint value in the corresponding row or the corresponding column, and taking the sum of the information entropy of all the joint value probabilities in the row or the column as the discreteness of the corresponding row or the corresponding column.
Since the plain-text magic cube model is a cube, the six faces are the same in size, and the discrete calculation is the same in units of rows or columns, the discrete calculation of each row or each column of data is possible.
In the first placeFace data are taken as an example, calculate +.>Discretization of line data->When first for->Face->All binary data of the line are weighted to obtain corresponding weighted values for +.>Face->Line->Personal decimal data->For example, its weight value +.>The method comprises the following steps: />,/>Representing decimal data +>Corresponding weights.
Then calculate the firstWeighting values of individual decimal data ++>The joint value of the weighting values of two decimal data adjacent thereto ++>Wherein->Indicate->Face->Line->Weighting value of the decimal data, +.>Indicate->Face->Line->Weighting values of the decimal data.
Calculate the joint value at the firstJoint value probability of row:
wherein,representation->Is>Is indicated at +.>Face->All weights of the line +.>The number of occurrences>Indicate->Face->The total number of all weighted values of a row.
In the first placeThe sum of the information entropy of all joint value probabilities in a row as +.>
Line discreteness
The information entropy formula is a known formula.
In the first placeFace->All decimal data of the rowThe calculation of the row of discreteness is performed in an information entropy mode, and is characterized in that the larger the weighted value of each decimal data is, the stronger the discreteness of the data is, and then the data is connected with surrounding adjacent positions by averaging the weighted values of two data at adjacent positions, so that the data is characterized by spatial distribution of the decimal data, namely, the decimal data and the data at the adjacent two positions are spatially distributed as a whole. And then, carrying out discrete calculation on the data through information entropy, wherein the larger the information entropy is, the more discrete is the distribution of single data or the distribution of the spatial structures of the single data and two adjacent data in the periphery in the row, and the opposite is the opposite.
In the same way for each side firstDiscrete values of the decimal data of the row are calculated. By the->Discrete values of decimal data of rows as ++th of plaintext magic cube model>Layer, by->Average value of all the discreteness of layer correspondence +.>As a public key for the layer data.
First face of each face in plain magic cube modelThe data of the row is +.>Layers, so using six facesFirst->Average value of discrete values of decimal data of row as +.>Discrete values of the overall data of the layer, +.>The larger the data that describes the layer, the more discrete the data, i.e. the more irregular the distribution of the data. />The smaller the data that describes the layer, the less discrete the data, i.e. the more regular the distribution of data.
4. A private key for each layer is generated based on the public key.
The remainder of the public key divided by 4 is calculated, and the product of the remainder and 90 ° is taken as the rotation angle.
Taking the m layer as an example, the rotation angle of the private keyThe method comprises the following steps:
wherein,representing the remainder operation on the function in brackets.
Because the rotation of the magic cube is at least 90 degrees per layer, the multiple public keys are divided by four to make a remainder, and the division by four is because the magic cubes are rotated towards the same directionAfter 90 ° the device returns to its original position, so that the device is first excluded and only the remainder is left as a calculation parameter for the rotation angle.
All public keys are ordered in descending order from big to small, and the ordering order is the rotation order of the private keys.
Step S004, rotating the plaintext magic cube data according to the rotation sequence and rotation angle of the private key of each layer of plaintext magic cube data, and obtaining an encrypted ciphertext magic cube model after all layers are rotated; and disassembling the ciphertext magic square model to obtain an encrypted binary sequence, and storing the encrypted binary sequence.
And encrypting the plaintext magic cube data by using the public key and the private key.
And rotating the plaintext magic cube data according to the rotation sequence and rotation angle of each layer of plaintext magic cube data in the private key, and obtaining the encrypted ciphertext magic cube model after all layers are rotated. And disassembling the ciphertext magic square model to obtain an encrypted binary sequence of ocean engineering research and development information, and then storing to finish the safe storage of ocean equipment information.
The application further comprises a decryption step:
and generating a ciphertext magic cube model by using the encrypted binary sequence, rotating the ciphertext magic cube model by using a private key to obtain a restored plaintext Wen Mofang model, disassembling the restored plaintext magic cube model to obtain a decimal plaintext matrix, generating a decimal plaintext sequence by using the decimal plaintext matrix, and converting the decimal plaintext sequence into binary ocean engineering equipment research and development information to finish decryption.
It should be noted that, when the decryption rotation is performed, the rotation sequence of the private key is completely opposite to that when the encryption is performed, that is, the last private key is used for first performing the decryption rotation, and the first private key is used for last performing the decryption rotation, so that the corresponding rotation angle is unchanged.
The method for utilizing ocean engineering equipment research and development information by converting decimal plaintext sequence into binary is modulo-binary division.
In summary, the embodiment of the application uniformly encodes development information of different types of ocean engineering equipment to obtain a data sequence composed of binary coded data; selecting the optimal length by calculating the redundancy of binary codes with different lengths, segmenting the data sequence with the optimal length, wherein the length of each segment of sub-sequence is the optimal length; converting each segment of subsequence into decimal data, performing hexagonal division on all decimal data, respectively generating square matrixes, and forming a plaintext magic cube model by taking each square matrix as a surface; acquiring a corresponding weight based on the occurrence probability of each decimal data in the plaintext magic cube model, acquiring the discreteness of each line or each column of data in each surface of the plaintext magic cube model according to the weight and the probability, taking the data of the same line or the same column of all surfaces as one layer of the plaintext magic cube model, and calculating the average value of all the discreteness corresponding to each layer as the public key of the data of the layer; the public key is utilized to acquire the rotation angle and the rotation sequence as the corresponding private key; rotating the plaintext magic cube data according to the rotation sequence and rotation angle of the private key of each layer of plaintext magic cube data, and obtaining an encrypted ciphertext magic cube model after all layers are rotated; and disassembling the ciphertext magic square model to obtain an encrypted binary sequence, and storing the encrypted binary sequence. The embodiment of the application avoids the problem of key management and improves the storage safety of the research and development information of the ocean engineering equipment.
It should be noted that: the sequence of the embodiments of the present application is only for description, and does not represent the advantages and disadvantages of the embodiments. And the foregoing description has been directed to specific embodiments of this specification. In addition, the processes depicted in the accompanying figures do not necessarily require the particular order shown, or sequential order, to achieve desirable results. In some embodiments, multitasking and parallel processing are also possible or may be advantageous.
In this specification, each embodiment is described in a progressive manner, and the same or similar parts of each embodiment are referred to each other, and each embodiment mainly describes differences from other embodiments.
The above embodiments are only for illustrating the technical solution of the present application, and not for limiting the same; the technical solutions described in the foregoing embodiments are modified or some of the technical features are replaced equivalently, so that the essence of the corresponding technical solutions does not deviate from the scope of the technical solutions of the embodiments of the present application, and all the technical solutions are included in the protection scope of the present application.

Claims (1)

1. The safe storage method of the development information of the ocean engineering equipment is characterized by comprising the following steps of:
uniformly coding research and development information of different types of ocean engineering equipment to obtain a data sequence consisting of binary coded data; the development information of the marine engineering equipment of different types comprises text information and image information; the decimal range of the gray value or the single channel value of each pixel point in the image information in the ocean engineering equipment research and development information is [0,255], and the corresponding binary code is 8 bits;
screening out the optimal length by calculating the redundancy of binary codes with different lengths, segmenting the data sequence with the optimal length, wherein the length of each segment of sub-sequence is the optimal length; converting each segment of subsequence into decimal data, performing hexagonal division on all decimal data, respectively generating square matrixes, and forming a plaintext magic cube model by taking each square matrix as a surface;
acquiring a corresponding weight based on the occurrence probability of each decimal data in the plaintext magic cube model, acquiring the discreteness of each line or each column of data in each surface of the plaintext magic cube model according to the weight and the probability, taking the data of the same line or the same column of all surfaces as one layer of the plaintext magic cube model, and calculating the average value of all discreteness corresponding to each layer as the public key of the data of the layer; the public key is utilized to acquire the rotation angle and the rotation sequence as the corresponding private key;
rotating the plaintext magic cube data according to the rotation sequence and rotation angle of the private key of each layer of plaintext magic cube data, and obtaining an encrypted ciphertext magic cube model after all layers are rotated; disassembling the ciphertext magic square model to obtain an encrypted binary sequence, and storing the encrypted binary sequence;
the method further comprises the steps of:
generating a ciphertext magic cube model by the encrypted binary sequence, rotating the ciphertext magic cube model by using a private key to obtain a restored plaintext Wen Mofang model, disassembling the restored plaintext magic cube model to obtain a decimal plaintext matrix, generating a decimal plaintext sequence by the decimal plaintext matrix, and converting the decimal plaintext sequence into binary ocean engineering equipment research and development information to finish decryption;
the redundancy obtaining method comprises the following steps:
starting from the length of 8, segmenting the data sequence by taking each length as a segmentation unit, obtaining the segmented data length of each segment of data which is equally divided into 6 intervals, and subtracting the data length from the number obtained by rounding the data length upwards to obtain the redundancy;
the probability obtaining method comprises the following steps:
taking the ratio of the total number of occurrences of each decimal data in the plaintext magic cube model to the total number of occurrences of all decimal data in the plaintext magic cube model as a first probability;
taking the ratio of the total number of occurrences of each decimal data on any one face in the plaintext magic cube model to the total number of occurrences of all decimal data in the face as a second probability;
the probability of occurrence of each decimal data includes the first probability and the second probability;
the weight obtaining method comprises the following steps:
calculating the variance of the second probability of any decimal data in six faces, and multiplying the square of the variance by the first probability of the decimal data to obtain the weight;
the method for acquiring the discreteness comprises the following steps:
taking the product result of multiplying each decimal data by the corresponding weight value as the weight value of the decimal data, then obtaining the joint value of the weight value corresponding to the decimal data of the decimal data and the adjacent two positions of the same row or the same column, calculating the joint value probability of the joint value in the corresponding row or the corresponding column, and taking the sum of the information entropy of all the joint value probabilities in the row or the column as the discreteness of the corresponding row or the corresponding column;
the method for acquiring the rotation angle comprises the following steps:
calculating a remainder obtained by dividing the public key by 4, and taking the product of the remainder and 90 degrees as the rotation angle;
the method for acquiring the rotation sequence comprises the following steps:
all public keys are ordered in descending order from big to small, and the ordering order is the rotation order of the private keys.
CN202211186457.7A 2022-09-28 2022-09-28 Safety storage method for research and development information of ocean engineering equipment Active CN115276990B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202211186457.7A CN115276990B (en) 2022-09-28 2022-09-28 Safety storage method for research and development information of ocean engineering equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202211186457.7A CN115276990B (en) 2022-09-28 2022-09-28 Safety storage method for research and development information of ocean engineering equipment

Publications (2)

Publication Number Publication Date
CN115276990A CN115276990A (en) 2022-11-01
CN115276990B true CN115276990B (en) 2023-12-05

Family

ID=83756419

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202211186457.7A Active CN115276990B (en) 2022-09-28 2022-09-28 Safety storage method for research and development information of ocean engineering equipment

Country Status (1)

Country Link
CN (1) CN115276990B (en)

Families Citing this family (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115879137B (en) * 2023-02-22 2023-07-14 浙江天航咨询监理有限公司 Data encryption-based supervision project information management system and method
CN116010996B (en) * 2023-03-01 2023-06-13 上海伯镭智能科技有限公司 Unmanned system development data safety management method
CN116405293B (en) * 2023-04-07 2023-09-01 光谷技术有限公司 Data encryption storage method of safe operation and maintenance system

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113129195A (en) * 2021-04-07 2021-07-16 中国人民解放军海军工程大学 Image encryption method based on improved magic cube transformation and memristive chaos
CN113518079A (en) * 2021-06-17 2021-10-19 西安空间无线电技术研究所 Data feature-based segmented information embedding method and system

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN113129195A (en) * 2021-04-07 2021-07-16 中国人民解放军海军工程大学 Image encryption method based on improved magic cube transformation and memristive chaos
CN113518079A (en) * 2021-06-17 2021-10-19 西安空间无线电技术研究所 Data feature-based segmented information embedding method and system

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
RUBICRYPT: IMAGE SCRAMBLING ENCRYPTION SYSTEM BASED ON RUBIK’S CUBE CONFIGURATION;Joffin Joy et al.;《International Conference on Systems Computation Automation and Networking》;20191231;全文 *

Also Published As

Publication number Publication date
CN115276990A (en) 2022-11-01

Similar Documents

Publication Publication Date Title
CN115276990B (en) Safety storage method for research and development information of ocean engineering equipment
CN111614455B (en) Color image compression and encryption method
Zhang et al. A novel method for lossless image compression and encryption based on LWT, SPIHT and cellular automata
CN109903212B (en) Image encryption method based on H geometric fractal and Hilbert curve
CN115694784B (en) Data security storage method
CN111294481B (en) Image encryption method based on self-updating transformation, double random three-dimensional matrix scrambling and DNA calculation
CN106980791B (en) Secret sharing method for extended weighting threshold ocean remote sensing image in cloud environment
CN113297606A (en) Color quantum image encryption and decryption method based on multiple chaos and DNA operation
CN115314600B (en) Chemical fertilizer production monitoring data management method
CN116150795A (en) Homomorphic encryption-based data processing method, system and related equipment
CN112261240B (en) Hyperchaotic system image encryption method based on spiral scrambling
CN112116672B (en) Color image preservation thumbnail encryption algorithm based on genetic algorithm
CN112838922B (en) DICOM image asymmetric encryption method based on chaotic mapping and selective Signcryption
CN112887509A (en) Fusion encryption method based on multiple chaotic systems
CN106934755B (en) A kind of image encrypting and decrypting method based on m-sequence
CN112182610A (en) Image encryption method, device, equipment and storage medium
CN115190216B (en) Encrypted image reversible data hiding and decrypting method based on prediction error map
CN114697671B (en) Building engineering quality management system
CN111210378A (en) Recoverability method based on image data on industrial cloud
CN115134471A (en) Image encryption and decryption method and related equipment
Rakhunde et al. New Approach for Reversible Data Hiding Using Visual Cryptography
CN115103081B (en) Encrypted image reversible data hiding method based on mixed prediction and Huffman coding
CN112528303B (en) Multi-user privacy recommendation method based on NTRU encryption algorithm
CN113268707B (en) Ciphertext covariance matrix calculation method based on row coding
Jirjees et al. IMGTXT: Image to Text Encryption Based on Encoding Pixel Contrasts.

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant