Looking for breakthrough ideas for innovation challenges? Try Patsnap Eureka!

File encryption and decryption method and system

A technology for encryption and decryption and file, which is applied in the direction of instruments, electrical digital data processing, digital data protection, etc., and can solve problems such as difficult to realize file encryption and decryption

Active Publication Date: 2017-02-01
GUANGZHOU SHIYUAN ELECTRONICS CO LTD
View PDF2 Cites 2 Cited by
  • Summary
  • Abstract
  • Description
  • Claims
  • Application Information

AI Technical Summary

Problems solved by technology

[0003] Based on this, it is necessary to provide a method and system for file encryption and decryption for the problem that it is difficult to implement file encryption and decryption on devices with small memory

Method used

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
View more

Image

Smart Image Click on the blue labels to locate them in the text.
Viewing Examples
Smart Image
  • File encryption and decryption method and system
  • File encryption and decryption method and system
  • File encryption and decryption method and system

Examples

Experimental program
Comparison scheme
Effect test

Embodiment Construction

[0010] In order to further illustrate the technical means adopted by the present invention and the achieved effects, the technical solutions of the present invention will be clearly and completely described below in conjunction with the accompanying drawings and preferred embodiments.

[0011] figure 1 It is a schematic flowchart of a method for encrypting and decrypting a file in an embodiment.

[0012] Such as figure 1 As shown, a method for file encryption and decryption includes:

[0013] S101. Create a secret key array and a jump function; the secret key array includes multiple secret keys.

[0014] As a preferred implementation, create an array of secret keys as follows:

[0015] K[n]={K 1 , K 2 , K 3 ...K N}

[0016] Among them, n∈[1,N], N is the length of the secret key array, that is, the total number of secret keys in the secret key array; the secret key array is free to set, and can be a non-zero random number (all zeros will not achieve the encryption effec...

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to View More

PUM

No PUM Login to View More

Abstract

The invention relates to a file encryption and decryption method and system. The method comprises the following steps of: creating a secret key array and a jump function; reading data elements of an original file; respectively taking the data elements of the original file as dependent variables of the jump function, calculating a value corresponding to the jump function, and taking the corresponding value as an index to query the secret key array so as to obtain secret keys corresponding to the data elements; carrying out XOR on the data elements of the original file and the corresponding secret keys to obtain an encrypted file; and carrying out XOR restoration on the data elements of the encrypted file and the corresponding secret keys to obtain the original file. According to the method and system provided by the invention, the jump function is created on the basis of reversibility of XOR, so that the secret keys corresponding to the data elements of the original file are indexed in a jump manner, XOR is carried out on the data elements of the original file and the corresponding secret keys to obtain the encrypted file, and XOR restoration is carried out on the data elements of the encrypted file and the corresponding secret keys to obtain the original file, thereby well realizing the encryption and decryption of the file on embedded devices with small memories.

Description

technical field [0001] The invention relates to the field of file security, in particular to a method and system for file encryption and decryption. Background technique [0002] During the production of embedded devices, the program files must be distributed to the factory, and the program files are easily obtained by competitors; when the remote files are upgraded, the upgrade files are easily intercepted. Therefore, a file encryption algorithm is usually used for encryption protection when the program file distribution factory or remote file upgrade. Some existing encryption algorithms are too complex and have a large amount of code, resulting in large memory usage, which cannot be implemented on embedded devices with small memory. Contents of the invention [0003] Based on this, it is necessary to provide a method and system for file encryption and decryption to address the problem that it is difficult to implement file encryption and decryption on devices with small...

Claims

the structure of the environmentally friendly knitted fabric provided by the present invention; figure 2 Flow chart of the yarn wrapping machine for environmentally friendly knitted fabrics and storage devices; image 3 Is the parameter map of the yarn covering machine
Login to View More

Application Information

Patent Timeline
no application Login to View More
IPC IPC(8): G06F21/62
CPCG06F21/6209G06F2221/2107
Inventor 高平东郑洪涛李艳峰
Owner GUANGZHOU SHIYUAN ELECTRONICS CO LTD
Who we serve
  • R&D Engineer
  • R&D Manager
  • IP Professional
Why Patsnap Eureka
  • Industry Leading Data Capabilities
  • Powerful AI technology
  • Patent DNA Extraction
Social media
Patsnap Eureka Blog
Learn More
PatSnap group products