CN114599032A - Short message transmission method, device, equipment and medium based on salt value encryption - Google Patents

Short message transmission method, device, equipment and medium based on salt value encryption Download PDF

Info

Publication number
CN114599032A
CN114599032A CN202210255011.9A CN202210255011A CN114599032A CN 114599032 A CN114599032 A CN 114599032A CN 202210255011 A CN202210255011 A CN 202210255011A CN 114599032 A CN114599032 A CN 114599032A
Authority
CN
China
Prior art keywords
salt value
short message
salt
effective
message service
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.)
Pending
Application number
CN202210255011.9A
Other languages
Chinese (zh)
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.)
Ping An Technology Shenzhen Co Ltd
Original Assignee
Ping An Technology Shenzhen 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 Ping An Technology Shenzhen Co Ltd filed Critical Ping An Technology Shenzhen Co Ltd
Priority to CN202210255011.9A priority Critical patent/CN114599032A/en
Publication of CN114599032A publication Critical patent/CN114599032A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W12/00Security arrangements; Authentication; Protecting privacy or anonymity
    • H04W12/03Protecting confidentiality, e.g. by encryption
    • H04W12/033Protecting confidentiality, e.g. by encryption of the user plane, e.g. user's traffic
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W12/00Security arrangements; Authentication; Protecting privacy or anonymity
    • H04W12/60Context-dependent security
    • H04W12/61Time-dependent
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W4/00Services specially adapted for wireless communication networks; Facilities therefor
    • H04W4/12Messaging; Mailboxes; Announcements
    • H04W4/14Short messaging services, e.g. short message services [SMS] or unstructured supplementary service data [USSD]

Abstract

The application relates to the technical field of data security encryption, and provides a short message transmission method and device based on salt value encryption, wherein the method comprises the following steps: the short message service terminal encrypts a short message to be sent by using the effective salt value, wherein the effective salt value information comprises the effective salt value and a salt value identifier, and the effective salt value is effective within a preset effective period; the short message service side sends the client communication identification, the encrypted short message and the salt value identification to a short message service provider; and the short message service provider acquires the salt value for decrypting the encrypted short message through the salt value identifier to obtain the content of the short message. According to the scheme, the salt value has the valid period, once the salt value exceeds the valid period, the salt value can be invalid and cannot be used for encryption, so that the information encryption safety is improved, the difficulty of packet capturing of sensitive information of a client in a link transmission process is improved, and once the information is not decrypted timely, decryption is difficult, and the security of private data of the client is protected.

Description

Short message transmission method, device, equipment and medium based on salt value encryption
Technical Field
The present application relates to the field of data security encryption technologies, and in particular, to a short message transmission method and apparatus based on salt value encryption, an electronic device, and a computer-readable storage medium.
Background
When an enterprise short message service end provides short message service for a customer, the short message service end often needs to be inter-modulated with an interface of an external short message service provider to transmit short message content, and the short message content often carries some sensitive information, such as: short message verification codes and the like of the clients are easy to capture and acquire when the information is transmitted in an https mode, privacy of the clients is further leaked, and security of private data of the clients is damaged.
Therefore, a short message transmission method capable of preventing the private data of the client from being easily acquired is required.
Disclosure of Invention
The embodiment of the application mainly aims to provide a short message transmission method and device based on salt value encryption, electronic equipment and a computer readable storage medium, so as to solve the problem that private data of a client is easily leaked in a short message transmission process between a short message service end and an external short message service provider, and improve the security of the private data of the client.
In order to achieve the above object, a first aspect of the embodiments of the present application provides a short message transmission method based on salt value encryption, where the method is applied to a short message transmission system, where the short message transmission system includes a short message service end and a short message service provider, and the method includes:
the short message service side judges whether effective salt value information corresponding to a client communication identifier is stored locally at the short message service side according to the client communication identifier corresponding to a short message to be sent, wherein the effective salt value information comprises an effective salt value and a salt value identifier, the effective salt value and the salt value identifier have a unique corresponding relation, and the effective salt value is effective within a preset effective period;
when the short message service end locally stores effective salt value information corresponding to the client communication identifier, the short message service end encrypts the short message to be sent by using the effective salt value in the effective salt value information to obtain an encrypted short message;
the short message service end sends the client communication identification, the encrypted short message and the salt value identification in the effective salt value information to a short message service provider;
and the short message service provider receives the encrypted short message and the salt value identification from the short message service end, acquires a salt value for decrypting the encrypted short message according to the salt value identification, and decrypts the encrypted short message according to the acquired salt value to obtain the decrypted short message content.
According to the short message transmission method based on salt value encryption provided by some embodiments of the present application, the short message transmission system further includes a salt value generation server, and the method further includes:
when the short message service side does not locally store effective salt value information corresponding to the client communication identification, the short message service side sends a first salt value request to the salt value generation service side, wherein the first salt value request carries the client communication identification;
after receiving the first salt value request, the salt value generation service end generates salt value information corresponding to the client communication identifier according to the client communication identifier in the first salt value request, and returns the salt value information to the short message service end, wherein the salt value information comprises a salt value and a salt value identifier, and the salt value identifier have a unique corresponding relation;
and the short message service end stores the salt value information returned by the salt value generation service end locally, and determines the valid period of the salt value information according to the storage time, wherein the salt value information is valid salt value information within the valid period.
According to some embodiments of the present application, after generating the salt information corresponding to the client communication identifier according to the client communication identifier in the first salt request, the method for transmitting a short message based on salt encryption further includes:
and the salt value generation server adds the salt values and the salt value identifications in the salt value information to a preset salt value list, wherein the salt value list is used for recording the salt values corresponding to the salt value identifications.
According to a short message transmission method based on salt value encryption provided by some embodiments of the present application, the obtaining a salt value for decrypting the encrypted short message according to the salt value identifier includes:
judging whether the short message service provider locally stores a salt value corresponding to the salt value identification;
when the salt value is locally stored in the short message service provider, the short message service provider acquires the salt value from the local.
According to the short message transmission method based on salt value encryption provided by some embodiments of the present application, after the determining whether the short message service provider locally stores the salt value corresponding to the salt value identifier, the method further includes:
when the salt value is not locally stored in the short message service provider, the short message service provider sends a second salt value request to the salt value generation service end, where the second salt value request includes the salt value identifier;
after receiving the second salinity request, the salinity generating service end searches the salinity corresponding to the salinity identifier from the salinity list according to the salinity identifier in the second salinity request, and returns the searched salinity to the short message service provider.
According to the short message transmission method based on salt value encryption provided by some embodiments of the present application, encrypting the short message to be transmitted by using the effective salt value in the effective salt value information to obtain an encrypted short message includes:
acquiring a fixed key corresponding to the client communication identifier, and processing the fixed key according to the effective salt value in the effective salt value information to obtain a derivative key;
and encrypting the short message to be sent according to a preset symmetric encryption algorithm and the derived key to obtain an encrypted short message.
According to the short message transmission method based on salt value encryption provided by some embodiments of the present application, the decrypting the encrypted short message by the obtained salt value to obtain the decrypted short message content includes:
acquiring a fixed key corresponding to the client communication identifier, and processing the fixed key according to the acquired salt value to obtain a derivative key;
and decrypting the encrypted short message according to a preset symmetric encryption algorithm and the derived key to obtain the decrypted short message content.
In order to achieve the above object, a second aspect of the embodiments of the present application provides a short message transmission system based on salt value encryption, the system including a short message service end and a short message service provider, wherein,
the short message service end comprises:
the system comprises a first judging module, a second judging module and a third judging module, wherein the first judging module is used for judging whether effective salt value information corresponding to a client communication identifier is stored locally at a short message service end according to the client communication identifier corresponding to a short message to be sent, the effective salt value information comprises an effective salt value and a salt value identifier, the effective salt value and the salt value identifier have a unique corresponding relation, and the effective salt value is effective within a preset effective period;
the encryption module is used for encrypting the short message to be sent by utilizing the effective salt value in the effective salt value information to obtain an encrypted short message when the effective salt value information corresponding to the client communication identifier is locally stored in the short message service end;
a first sending module, configured to send the client communication identifier, the encrypted short message, and the salt identifier in the valid salt information to a short message service provider;
the short message service provider comprises:
the first receiving module is used for receiving the encrypted short message and the salt value identifier from the short message service end;
and the decryption module is used for acquiring the salt value for decrypting the encrypted short message according to the salt value identification, and decrypting the encrypted short message according to the acquired salt value to obtain the decrypted short message content.
To achieve the above object, a third aspect of an embodiment of the present application provides an electronic apparatus, including:
at least one processor; and the number of the first and second groups,
a memory communicatively coupled to the at least one processor; wherein, the first and the second end of the pipe are connected with each other,
the memory stores a computer program that, when executed by the at least one processor, causes the at least one processor to perform the method for transmitting short messages based on salt value encryption as described in any of the embodiments of the first aspect above.
In order to achieve the above object, a fourth aspect of the embodiments of the present application provides a computer-readable storage medium, which stores a computer program, and when the computer program is executed by a processor, the method for transmitting a short message based on salt value encryption according to any one of the embodiments of the first aspect is implemented.
The embodiment of the application provides a short message transmission method, a short message transmission device, electronic equipment and a computer readable storage medium based on salt value encryption, wherein a short message service end judges whether effective salt value information corresponding to a client communication identifier is stored locally at the short message service end according to the client communication identifier corresponding to a short message to be sent, the effective salt value information comprises an effective salt value and a salt value identifier, the effective salt value and the salt value identifier have a unique corresponding relation, and the effective salt value is effective within a preset effective period; when the short message service end locally stores effective salt value information corresponding to the client communication identifier, the short message service end encrypts the short message to be sent by using the effective salt value in the effective salt value information to obtain an encrypted short message; the short message service end sends the client communication identification, the encrypted short message and the salt value identification in the effective salt value information to a short message service provider; and the short message service provider receives the encrypted short message and the salt value identification from the short message service end, acquires a salt value for decrypting the encrypted short message according to the salt value identification, and decrypts the encrypted short message according to the acquired salt value to obtain the decrypted short message content. According to the scheme of the embodiment of the application, the short message server encrypts the short message to be sent by using the effective salt value, the salt value has the valid period, and once the salt value exceeds the valid period, the salt value can be invalid and can not be used for encryption any more, so that the safety of information encryption is improved, the difficulty of packet capturing of sensitive information of a client in a link transmission process is improved, and once the information is not decrypted timely, decryption is difficult due to the existence of a timing refreshing mechanism of the salt value, and the safety of private data of the client is protected.
Drawings
Fig. 1 is a schematic diagram illustrating an interaction process between a short message service side of a short message transmission system and a short message service provider in the related art;
fig. 2 is a schematic flowchart of a short message transmission method based on salt value encryption according to an embodiment of the present application;
fig. 3 is a schematic flowchart of a short message transmission method based on salt value encryption according to another embodiment of the present application;
FIG. 4 is a schematic diagram of the substeps of step S110 in FIG. 2;
FIG. 5 is a schematic diagram of the substeps of step S120 in FIG. 2;
FIG. 6 is a schematic diagram of the substeps of step S140 in FIG. 2;
FIG. 7 is a schematic diagram of the substeps of step S140 in FIG. 2;
fig. 8 is a schematic structural diagram of a short message transmission system based on salt value encryption according to an embodiment of the present application.
Detailed Description
In order to make the objects, technical solutions and advantages of the present application more apparent, the present application is described in further detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative of the present application and are not intended to limit the present application.
It is to be noted that, 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 terminology used herein is for the purpose of describing embodiments of the present application only and is not intended to be limiting of the application.
For the convenience of understanding, the technical terms and application scenarios related to the embodiments of the present application will be briefly described here:
HTTPS: the method is a transmission protocol for carrying out safe communication through a computer network, carries out communication through HTTP, establishes a full channel by utilizing SSL/TLS and encrypts a data packet. The primary purpose of HTTPS use is to provide authentication of the web server while protecting the privacy and integrity of the exchanged data. It is widely used for security sensitive communications on the world wide web, such as transaction payments.
Symmetric encryption algorithm: in the symmetric encryption algorithm, a data sender processes a plaintext (original data) and an encryption key together through a special encryption algorithm, and then the plaintext and the encryption key are changed into a complex encryption ciphertext to be sent out. After the receiver receives the ciphertext, if the receiver wants to decode the original text, the receiver needs to decrypt the ciphertext by using the key used for encryption and the inverse algorithm of the same algorithm so as to recover the ciphertext into readable plaintext. In the symmetric encryption algorithm, only one key is used, and both the sender and the receiver use the key to encrypt and decrypt data, so that the encryption key must be known by a secret party in advance.
Salt value: belonging to random values. When a user registers, the system combines the user password to generate a random number, which is called salt value, and is commonly called salting value.
The embodiment of the application provides a short message transmission method based on salt value encryption, which is applied to a short message transmission system, wherein the short message transmission system comprises a short message service end, a short message service provider and a client, and an HTTPS channel is established between the short message service end and the short message service provider. The short message service end is accessed to the enterprise application layer, and the short message service requirement is determined according to the instruction from the enterprise application layer. The short message service provider is a short message service provider platform of a third party and can provide an interface for calling the short message service for the short message service terminal. Here, the short message service may include, but is not limited to, a verification code short message, a notification short message, a service promotion short message, and the like.
Referring to fig. 1, the following describes an interaction process between a short message service side and a short message service provider by taking sending a verification code short message as an example, and the specific process is as follows:
1, a short message service end receives a verification code request initiated by a user on a client app/webpage (belonging to an enterprise application layer);
2, the SMS terminal calls the interface of the SMS provider to generate the verification code
3, sending the verification code short message to a client of the user through a short message service provider;
4, the short message service end receives verification code information returned by the enterprise application layer;
5, the SMS server terminal calls the interface of the SMS provider to verify the verification code,
and 6, the short message service provider returns the verification result to the short message service end.
In the process, the short message service side and the short message service provider perform information interaction through the HTTPS channel, however, when verification code information is transmitted through the HTTPS channel, the verification code information is easily acquired by packet capturing, privacy of a client is further leaked, and security of private data of the client is damaged. Therefore, a short message transmission method capable of preventing the private data of the client from being easily acquired is required.
It should be understood that the short message service side and the short message service provider may be configured as independent physical servers, may also be configured as a server cluster or a distributed system formed by a plurality of physical servers, and may also be configured as a cloud server providing basic cloud computing services such as cloud service, a cloud database, cloud computing, a cloud function, cloud storage, network service, cloud communication, middleware service, domain name service, security service, CDN, and a big data and artificial intelligence platform, but are not limited to the above forms.
Method embodiments provided herein may be described in the general context of computer-executable instructions, such as program modules, being executed by a computer. Generally, program modules include routines, programs, objects, components, data structures, etc. that perform particular tasks or implement particular abstract data types. The application may also be practiced in distributed computing environments where tasks are performed by remote processing devices that are linked through a communications network. In a distributed computing environment, program modules may be located in both local and remote computer storage media including memory storage devices.
The embodiment of the application mainly aims to provide a short message transmission method and device based on salt value encryption, electronic equipment and a computer readable storage medium, and aims to solve the problem that private data of a client is easily leaked in a short message transmission process between a short message service end and an external short message service provider, and improve the security of the private data of the client.
Referring to fig. 2, fig. 2 is a schematic flow chart illustrating a short message transmission method based on salt value encryption according to an embodiment of the present application. As shown in fig. 2, the short message transmission method provided in the embodiment of the present application includes, but is not limited to, the following steps:
step S110, the short message service end judges whether the short message service end locally stores effective salt value information corresponding to the customer communication identification according to the customer communication identification corresponding to the short message to be sent.
The effective salt value information comprises an effective salt value and a salt value identification, the effective salt value and the salt value identification have a unique corresponding relation, and the effective salt value is effective within a preset effective period.
It can be understood that the short message service end determines the short message service requirement according to the instruction of the enterprise application layer, and generates the short message to be sent. The instruction of the enterprise application layer is initiated by a client at a client app/webpage, for example, a client user logs in an account on a client in a short message verification code mode, the client user initiates an instruction for requesting the verification code, and after receiving the instruction for requesting the verification code, the short message service end generates a short message to be sent corresponding to a client communication identifier of the client user.
Illustratively, the customer communication identifier may be a mobile phone number of the customer, an account number of the customer, and the like.
After the short message service end generates a short message to be sent, whether effective salt value information corresponding to a client communication identifier is stored locally or not is judged according to the client communication identifier corresponding to the current short message to be sent. It can be understood that the short message service side locally stores the salt value information corresponding to the plurality of client communication identifiers, each salt value information has an effective period, the salt value information is valid within the effective period, and if the effective period is exceeded, the salt value information is invalid.
Referring to fig. 3, when the short message service end does not locally store the effective salt value information corresponding to the client communication identifier, the embodiment of the present application further includes the following steps S201 to S203:
step S201, the short message service end sends a first salt value request to the salt value generation service end, and the first salt value request carries the client communication identifier.
Here, the salt value generation server is a server for generating a random salt value.
Step S202, after receiving the first salt request, the salt generation service end generates salt information corresponding to the client communication identifier according to the client communication identifier in the first salt request, and returns the salt information to the short message service end, wherein the salt information comprises a salt and a salt identifier, and the salt identifier have a unique corresponding relation.
Here, each time the salt value generation server generates a salt value, that is, a unique salt value identifier is configured for the salt value, and the salt value identifier is used for marking the currently generated identifier.
It can be understood that, after the salt value generation server in step S202 generates salt value information corresponding to the client communication identifier according to the client communication identifier in the first salt value request, the method in this embodiment of the present application further includes:
step S301, the salt value generation server adds the salt value and the salt value identifier in the salt value information to a preset salt value list, where the salt value list is used to record the salt value corresponding to each salt value identifier.
Step S203, the short message service end stores the salt value information returned by the salt value generation service end locally, and determines the valid period of the salt value information according to the storage time, wherein the salt value information is valid salt value information within the valid period.
After receiving the salt value information returned by the salt value generation server, the short message service end stores the salt value information locally, and then determines the valid period of the salt value information according to the storage time. The length of the validity period is set in advance, for example, to 2 minutes, 5 minutes, or the like. The expiration date corresponding to each salt value may be recorded by a local list.
Referring to fig. 4, the step S110 of determining whether the short message service side locally stores the effective salt value information corresponding to the client communication identifier may specifically include the following steps S111 to S112:
step S111, the short message service side judges whether the local salinity information corresponding to the client communication identification is stored, if so, step S112 is executed; if not, determining that the effective salt value information corresponding to the client communication identification is not stored locally.
Step S112, acquiring the valid period of the salt value information corresponding to the client communication identifier from the local, and if the valid period indicates that the salt value information is within the valid period, determining that the valid salt value information corresponding to the client communication identifier is stored locally; and if the valid period indicates that the salt value information exceeds the valid period, determining that valid salt value information corresponding to the client communication identifier is not stored locally.
It can be understood that the short message service end encrypts the current short message to be sent by using the effective salt value information corresponding to the client communication identifier.
Step S120, when the short message service end locally stores the effective salt value information corresponding to the client communication identifier, the short message service end encrypts the short message to be sent by using the effective salt value in the effective salt value information to obtain an encrypted short message.
The short message is encrypted based on a symmetric encryption algorithm and a salt value. For example, referring to fig. 5, encrypting the short message to be sent by using the effective salt value in the effective salt value information in step S120 to obtain an encrypted short message may specifically include the following steps S121 to S122:
step S121, obtaining a fixed key corresponding to the client communication identifier, and processing the fixed key according to the effective salt value in the effective salt value information to obtain a derivative key;
and S122, encrypting the short message to be sent according to a preset symmetric encryption algorithm and the derived key to obtain an encrypted short message.
It is understood that in the embodiment of the present application, each client communication identifier has a corresponding fixed key, and then the fixed key is processed by a salt value with an expiration date to obtain a derivative key. And then encrypting the short message to be sent according to a preset symmetric encryption algorithm and the derived key to obtain an encrypted short message. Because the salt value has a valid period, after the valid period is exceeded, the salt value is invalid and can not be used, and only a new salt value can be requested from the salt value generation server again, so that derivative keys obtained at different times are different, and the key security of the encrypted short message is greatly improved.
Step S130, the short message service end sends the client communication identification, the encrypted short message and the salt value identification in the effective salt value information to a short message service provider.
It can be understood that, after the short message service end completes the encryption of the short message, the encrypted short message, the corresponding customer communication identifier and the salt identifier corresponding to the salt used in the encryption of the short message are sent to the short message service provider together.
Step S140, the short message service provider receives the encrypted short message and the salt value identification from the short message service end, obtains a salt value for decrypting the encrypted short message according to the salt value identification, and decrypts the encrypted short message according to the obtained salt value to obtain the decrypted short message content.
Referring to fig. 6, the obtaining of the salt value for decrypting the encrypted short message according to the salt value identifier in step S140 may specifically include the following steps S401 to S404:
step S401, the short message service provider judges whether a salt value corresponding to the salt value identification is stored locally.
When the sms service provider locally stores the salt value, the following step S402 is executed:
step S402, the short message service provider obtains the salt value from local.
When the short message service provider does not locally store the salt value, the following steps S403-S404 are executed:
step S403, the sms provider sends a second salt request to the salt generation service end, where the second salt request includes the salt identifier;
s404, after receiving the second salinity request, the salt generation service end searches for a salt corresponding to the salt identifier from the salt list according to the salt identifier in the second salinity request, and returns the found salt to the short message service provider.
It can be understood that the salt value generation server is locally provided with a salt value list, and each time a salt value is generated by the salt value generation server, a unique salt value identifier is configured for the salt value, and then the salt value and the salt value identifier corresponding to the salt value are added to the salt value list, so that the salt value corresponding to each salt value identifier can be found through the salt value list.
Referring to fig. 7, the decrypting the encrypted short message by the obtained salt value in step S140 to obtain the decrypted short message content includes the following steps S501 to S502:
step S501, acquiring a fixed key corresponding to the client communication identifier, and processing the fixed key according to the acquired salt value to obtain a derivative key;
step S502, the encrypted short message is decrypted according to a preset symmetric encryption algorithm and the derived key, and the decrypted short message content is obtained.
It can be understood that, in the embodiment of the present application, the short message is encrypted by using a symmetric encryption algorithm, so that the keys used in the encryption process and the decryption process are consistent.
According to the scheme of the embodiment of the application, the short message server encrypts the short message to be sent by using the effective salt value, and the salt value has the valid period, so that the salt value is invalid and cannot be used for encryption once exceeding the valid period, the information encryption safety is improved, the difficulty of packet capturing of sensitive information of a client in the link transmission process is improved, and the decryption is difficult once the information is not decrypted in time due to the existence of a timing refreshing mechanism of the salt value. The security of the private data of the client is protected.
The following describes in detail a short message transmission method according to an embodiment of the present application by using a specific example.
Step S601, the short message service end judges whether the short message service end locally stores effective salt value information corresponding to a customer communication identifier according to the customer communication identifier corresponding to a short message to be sent, if so, the step S606 is executed; if not, executing steps S602-S605; the effective salt value information comprises an effective salt value and a salt value identification, the effective salt value and the salt value identification have a unique corresponding relation, and the effective salt value is effective within a preset effective period.
Step S602, the short message service end sends a first salt value request to the salt value generation service end, and the first salt value request carries the client communication identification.
Step S603, after receiving the first salt request, the salt generation service end generates salt information corresponding to the client communication identifier according to the client communication identifier in the first salt request, and returns the salt information to the short message service end, where the salt information includes a salt and a salt identifier, and the salt identifier have a unique correspondence relationship.
Step S604, the salt value generation server adds the salt value and the salt value identifier in the salt value information to a preset salt value list, where the salt value list is used to record the salt value corresponding to each salt value identifier.
Step S605, the short message service end stores the salt value information returned by the salt value generation service end locally, and determines the valid period of the salt value information according to the storage time, wherein the salt value information is valid salt value information within the valid period.
Step S606, the short message service end encrypts the short message to be sent by using the effective salt value in the effective salt value information to obtain an encrypted short message; wherein the encryption process comprises: acquiring a fixed key corresponding to the client communication identifier, and processing the fixed key according to the effective salt value in the effective salt value information to obtain a derivative key; and encrypting the short message to be sent according to a preset symmetric encryption algorithm and the derived key to obtain an encrypted short message.
Step S607, the short message service end sends the client communication identifier, the encrypted short message and the salt identifier in the effective salt information to a short message service provider.
Step S608, the short message service provider receives the encrypted short message and the salt identifier from the short message service end, and determines whether the short message service provider locally stores a salt corresponding to the salt identifier, if yes;
step S609, the short message service provider sends a second salt request to the salt generation service end, where the second salt request includes the salt identifier.
Step S610, after receiving the second salinity request, the salt generation service end searches for a salt corresponding to the salt identifier from the salt list according to the salt identifier in the second salinity request, and returns the found salt to the short message service provider.
Step S611, the short message service provider receives the salt value corresponding to the salt value identifier returned by the salt value generation service end, and stores the salt value locally.
Step S612, the short message service provider locally acquires the salt value, and decrypts the encrypted short message according to the acquired salt value to obtain the decrypted short message content; wherein the decryption process comprises: acquiring a fixed key corresponding to the client communication identifier, and processing the fixed key according to the acquired salt value to obtain a derivative key; and decrypting the encrypted short message according to a preset symmetric encryption algorithm and the derived key to obtain the decrypted short message content.
Referring to fig. 8, the present application further provides a system for transmitting a short message based on salt encryption, the system including a short message service end and a short message service provider, wherein,
the short message service end comprises:
the system comprises a first judging module, a second judging module and a third judging module, wherein the first judging module is used for judging whether effective salt value information corresponding to a client communication identifier is stored locally at a short message service end according to the client communication identifier corresponding to a short message to be sent, the effective salt value information comprises an effective salt value and a salt value identifier, the effective salt value and the salt value identifier have a unique corresponding relation, and the effective salt value is effective within a preset effective period;
the encryption module is used for encrypting the short message to be sent by utilizing the effective salt value in the effective salt value information to obtain an encrypted short message when the effective salt value information corresponding to the client communication identifier is locally stored in the short message service end;
the first sending module is used for sending the client communication identifier, the encrypted short message and the salt value identifier in the effective salt value information to a short message service provider;
the short message service provider comprises:
the first receiving module is used for receiving the encrypted short message and the salt value identifier from the short message service end;
and the decryption module is used for acquiring the salt value for decrypting the encrypted short message according to the salt value identification, and decrypting the encrypted short message according to the acquired salt value to obtain the decrypted short message content.
It can be understood that the short message transmission system further includes: and the salt value generation server side.
It can be understood that, the first sending module of the short message service end is further configured to: and when the short message service side does not locally store effective salt value information corresponding to the client communication identification, sending a first salt value request to the salt value generation service side, wherein the first salt value request carries the client communication identification.
It is to be understood that the salt value generation server includes a salt value generation module, and the salt value generation module is configured to: after the first salt value request is received, salt value information corresponding to the client communication identifier is generated according to the client communication identifier in the first salt value request, and the salt value information is returned to the short message service end, wherein the salt value information comprises a salt value and a salt value identifier, and the salt value identifier have a unique corresponding relation.
It can be understood that the short message service end further includes a storage module and a determination module, and the storage module is configured to: storing the salt value information returned by the salt value generation server locally; the determination module is to: and determining the valid period of the salt value information according to the storage time, wherein the salt value information is valid salt value information within the valid period.
It can be understood that the salt value generation server further includes a recording module, and the recording module is configured to: and adding the salt value and the salt value identification in the salt value information into a preset salt value list, wherein the salt value list is used for recording the salt value corresponding to each salt value identification.
It can be understood that the short message service provider further includes a second determining module and an obtaining module, where the second determining module is configured to: and judging whether the short message service provider locally stores a salt value corresponding to the salt value identification. The acquisition module is configured to: and when the salt value is locally stored in the short message service provider, acquiring the salt value from the local.
It can be understood that the short message service provider further includes a second sending module, where the second sending module is configured to: when the salt value is not locally stored in the short message service provider, the short message service provider sends a second salt value request to the salt value generation service end, wherein the second salt value request comprises the salt value identifier.
It is to be understood that the salt value generation module of the salt value generation server is further configured to: after receiving the second salinity request, according to the salt identifier in the second salinity request, searching a salt corresponding to the salt identifier from the salt list, and returning the searched salt to the short message service provider.
It can be understood that the encryption module of the short message service end is specifically configured to:
acquiring a fixed key corresponding to the client communication identifier, and processing the fixed key according to the effective salt value in the effective salt value information to obtain a derivative key;
and encrypting the short message to be sent according to a preset symmetric encryption algorithm and the derived key to obtain an encrypted short message.
It can be understood that the decryption module of the short message service provider is specifically configured to:
acquiring a fixed key corresponding to the client communication identifier, and processing the fixed key according to the acquired salt value to obtain a derivative key;
and decrypting the encrypted short message according to a preset symmetric encryption algorithm and the derived key to obtain the decrypted short message content.
An embodiment of the present application further provides an electronic device, including:
at least one processor; and the number of the first and second groups,
a memory communicatively coupled to the at least one processor; wherein the content of the first and second substances,
the memory stores a computer program that, when executed by the at least one processor, causes the at least one processor to perform the method for short message transmission based on salt value encryption as described in any one of the above embodiments.
The embodiment of the present application further provides a computer-readable storage medium, which stores a computer program, and when the computer program is executed by a processor, the method for transmitting a short message based on salt value encryption according to any of the above embodiments is implemented.
The above embodiments may be combined, and the modules with the same name may be the same or different between different embodiments.
While certain embodiments of the present application have been described above, other embodiments are within the scope of the following claims. In some cases, the actions or steps recited in the claims may be performed in a different order than in the embodiments and still achieve desirable results. In addition, the processes depicted in the accompanying figures do not necessarily have to be in the particular order shown or in sequential order to achieve desirable results. In some embodiments, multitasking and parallel processing may also be possible or may be advantageous.
The embodiments in the present application are described in a progressive manner, and the same and similar parts among the embodiments can be referred to each other, and each embodiment focuses on the differences from the other embodiments. In particular, for the apparatus, device, and computer-readable storage medium embodiments, since they are substantially similar to the method embodiments, the description is relatively simple, and in relation to the description, reference may be made to some portions of the description of the method embodiments.
The apparatus, the device, the computer-readable storage medium, and the method provided in the embodiments of the present application correspond to each other, and therefore, the apparatus, the device, and the nonvolatile computer storage medium also have advantageous technical effects similar to those of the corresponding method.
In the 90 s of the 20 th century, improvements in a technology could clearly distinguish between improvements in hardware (e.g., improvements in circuit structures such as diodes, transistors, switches, etc.) and improvements in software (improvements in process flow). However, as technology advances, many of today's process flow improvements have been seen as direct improvements in hardware circuit architecture. Designers almost always obtain the corresponding hardware circuit structure by programming an improved method flow into the hardware circuit. Thus, it cannot be said that an improvement in the process flow cannot be realized by hardware physical modules. For example, a Programmable Logic Device (PLD), such as a Field Programmable Gate Array (FPGA), is an integrated circuit whose Logic functions are determined by programming the Device by a user. A digital system is "integrated" on a PLD by the designer's own programming without requiring the chip manufacturer to design and fabricate application-specific integrated circuit chips. Furthermore, nowadays, instead of manually making an Integrated Circuit chip, such Programming is often implemented by "logic compiler" software, which is similar to a software compiler used in program development and writing, but the original code before compiling is also written by a specific Programming Language, which is called Hardware Description Language (HDL), and HDL is not only one but many, such as abel (advanced Boolean Expression Language), ahdl (alternate Hardware Description Language), traffic, pl (core universal Programming Language), HDCal (jhdware Description Language), lang, Lola, HDL, laspam, hardward Description Language (vhr Description Language), vhal (Hardware Description Language), and vhigh-Language, which are currently used in most common. It will also be apparent to those skilled in the art that hardware circuitry for implementing the logical method flows can be readily obtained by a mere need to program the method flows with some of the hardware description languages described above and into an integrated circuit.
The controller may be implemented in any suitable manner, for example, the controller may take the form of, for example, a microprocessor or processor and a computer-readable medium storing computer-readable program code (e.g., software or firmware) executable by the (micro) processor, logic gates, switches, an Application Specific Integrated Circuit (ASIC), a programmable logic controller, and an embedded microcontroller, examples of which include, but are not limited to, the following microcontrollers: ARC 625D, Atmel AT91SAM, Microchip PIC18F26K20, and Silicone Labs C8051F320, the memory controller may also be implemented as part of the control logic for the memory. Those skilled in the art will also appreciate that, in addition to implementing the controller as pure computer readable program code, the same functionality can be implemented by logically programming method steps such that the controller is in the form of logic gates, switches, application specific integrated circuits, programmable logic controllers, embedded microcontrollers and the like. Such a controller may thus be considered a hardware component, and the means included therein for performing the various functions may also be considered as a structure within the hardware component. Or even means for performing the functions may be regarded as being both a software module for performing the method and a structure within a hardware component.
The systems, devices, modules or units illustrated in the above embodiments may be implemented by a computer chip or an entity, or by a product with certain functions. One typical implementation device is a computer. In particular, the computer may be, for example, a personal computer, a laptop computer, a cellular telephone, a camera phone, a smartphone, a personal digital assistant, a media player, a navigation device, an email device, a game console, a tablet computer, a wearable device, or a combination of any of these devices.
For convenience of description, the above devices are described as being divided into various units by function, and are described separately. Of course, the functions of the units can be implemented in the same software and/or hardware or in a plurality of software and/or hardware when implementing the embodiment of the present application.
As will be appreciated by one skilled in the art, embodiments of the present application may be provided as a method, system, or computer program product. Accordingly, embodiments of the present application may take the form of an entirely hardware embodiment, an entirely software embodiment or an embodiment combining software and hardware aspects. Furthermore, embodiments of the present application may take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, and the like) having computer-usable program code embodied therein.
The present specification has been described with reference to flowchart illustrations and/or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of the application. It will be understood that each flow and/or block of the flow diagrams and/or block diagrams, and combinations of flows and/or blocks in the flow diagrams and/or block diagrams, can be implemented by computer program instructions. These computer program instructions may be provided to a processor of a general purpose computer, special purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, create means for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be stored in a computer-readable memory that can direct a computer or other programmable data processing apparatus to function in a particular manner, such that the instructions stored in the computer-readable memory produce an article of manufacture including instruction means which implement the function specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be loaded onto a computer or other programmable data processing apparatus to cause a series of operational steps to be performed on the computer or other programmable apparatus to produce a computer implemented process such that the instructions which execute on the computer or other programmable apparatus provide steps for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
In a typical configuration, a computing device includes one or more processors (CPUs), input/output interfaces, network interfaces, and memory.
The memory may include forms of volatile memory in a computer readable medium, Random Access Memory (RAM) and/or non-volatile memory, such as Read Only Memory (ROM) or flash memory (flash RAM). Memory is an example of a computer-readable medium.
Computer-readable media, including both permanent and non-permanent, removable and non-removable media, may implement the information storage by any method or technology. The information may be computer readable instructions, data structures, modules of a program, or other data. Examples of computer storage media include, but are not limited to, phase change memory (PRAM), Static Random Access Memory (SRAM), Dynamic Random Access Memory (DRAM), other types of Random Access Memory (RAM), Read Only Memory (ROM), Electrically Erasable Programmable Read Only Memory (EEPROM), flash memory or other memory technology, compact disc read only memory (CD-ROM), Digital Versatile Discs (DVD) or other optical storage, magnetic cassettes, magnetic tape disk storage or other magnetic storage devices, or any other non-transmission medium which can be used to store information that can be accessed by a computing device. As defined herein, a computer readable medium does not include a transitory computer readable medium such as a modulated data signal and a carrier wave.
It should also be noted that the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising an … …" does not exclude the presence of other like elements in a process, method, article, or apparatus that comprises the element.
In the embodiments of the present application, "at least one" means one or more, and "a plurality" means two or more. "and/or" describes the association relationship of the associated objects, and means that there may be three relationships, for example, a and/or B, and may mean that a exists alone, a and B exist simultaneously, and B exists alone. Wherein A and B can be singular or plural. The character "/" generally indicates that the former and latter associated objects are in an "or" relationship. "at least one of the following" and similar expressions refer to any combination of these items, including any combination of singular or plural items. For example, at least one of a, b, and c may represent: a, b, c, a and b, a and c, b and c or a and b and c, wherein a, b and c can be single or multiple.
Embodiments of the application may be described in the general context of computer-executable instructions, such as program modules, being executed by a computer. Generally, program modules include routines, programs, objects, components, data structures, etc. that perform particular tasks or implement particular abstract data types. Embodiments of the application may also be practiced in distributed computing environments where tasks are performed by remote processing devices that are linked through a communications network. In a distributed computing environment, program modules may be located in both local and remote computer storage media including memory storage devices.
The embodiments in the present application are described in a progressive manner, and the same and similar parts among the embodiments can be referred to each other, and each embodiment focuses on differences from other embodiments. In particular, for the system embodiment, since it is substantially similar to the method embodiment, the description is simple, and for the relevant points, reference may be made to the partial description of the method embodiment.
The above description is only an example of the present application and is not intended to limit the present application. Various modifications and changes may occur to those skilled in the art. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present application should be included in the scope of the claims of the present application.

Claims (10)

1. A short message transmission method based on salt value encryption is characterized in that the method is applied to a short message transmission system, the short message transmission system comprises a short message service end and a short message service provider, and the method comprises the following steps:
the short message service side judges whether effective salt value information corresponding to a client communication identifier is stored locally at the short message service side according to the client communication identifier corresponding to a short message to be sent, wherein the effective salt value information comprises an effective salt value and a salt value identifier, the effective salt value and the salt value identifier have a unique corresponding relation, and the effective salt value is effective within a preset effective period;
when the short message service end locally stores effective salt value information corresponding to the client communication identifier, the short message service end encrypts the short message to be sent by using the effective salt value in the effective salt value information to obtain an encrypted short message;
the short message service end sends the client communication identification, the encrypted short message and the salt value identification in the effective salt value information to a short message service provider;
and the short message service provider receives the encrypted short message and the salt value identification from the short message service end, acquires a salt value for decrypting the encrypted short message according to the salt value identification, and decrypts the encrypted short message according to the acquired salt value to obtain the decrypted short message content.
2. The method of claim 1, wherein the short message transmission system further comprises a salt value generation server, and the method further comprises:
when the short message service side does not locally store effective salt value information corresponding to the client communication identification, the short message service side sends a first salt value request to the salt value generation service side, wherein the first salt value request carries the client communication identification;
after receiving the first salt value request, the salt value generation service end generates salt value information corresponding to the client communication identifier according to the client communication identifier in the first salt value request, and returns the salt value information to the short message service end, wherein the salt value information comprises a salt value and a salt value identifier, and the salt value identifier have a unique corresponding relation;
and the short message service end stores the salt value information returned by the salt value generation service end locally, and determines the valid period of the salt value information according to the storage time, wherein the salt value information is valid salt value information within the valid period.
3. The method of claim 2, wherein after generating the salt information corresponding to the client communication identifier according to the client communication identifier in the first salt request, the method further comprises:
and the salt value generation server adds the salt values and the salt value identifications in the salt value information to a preset salt value list, wherein the salt value list is used for recording the salt values corresponding to the salt value identifications.
4. The method of claim 3, wherein the obtaining the salt value for decrypting the encrypted short message according to the salt value identifier comprises:
judging whether the short message service provider locally stores a salt value corresponding to the salt value identification;
when the salt value is locally stored in the short message service provider, the short message service provider acquires the salt value from the local.
5. The method as claimed in claim 4, wherein after said determining whether the SMS provider locally stores a salt corresponding to the salt identifier, the method further comprises:
when the salt value is not locally stored in the short message service provider, the short message service provider sends a second salt value request to the salt value generation service end, where the second salt value request includes the salt value identifier;
after receiving the second salinity request, the salinity generating service end searches the salinity corresponding to the salinity identifier from the salinity list according to the salinity identifier in the second salinity request, and returns the searched salinity to the short message service provider.
6. The method of claim 1, wherein the encrypting the short message to be sent by using the effective salt value in the effective salt value information to obtain an encrypted short message comprises:
acquiring a fixed key corresponding to the client communication identifier, and processing the fixed key according to the effective salt value in the effective salt value information to obtain a derivative key;
and encrypting the short message to be sent according to a preset symmetric encryption algorithm and the derived key to obtain an encrypted short message.
7. The method according to claim 1, wherein the decrypting the encrypted short message by the obtained salt value to obtain the decrypted short message content comprises:
acquiring a fixed key corresponding to the client communication identifier, and processing the fixed key according to the acquired salt value to obtain a derivative key;
and decrypting the encrypted short message according to a preset symmetric encryption algorithm and the derived key to obtain the decrypted short message content.
8. A short message transmission system based on salt value encryption is characterized in that the system comprises a short message service end and a short message service provider, wherein,
the short message service end comprises:
the system comprises a first judging module, a second judging module and a third judging module, wherein the first judging module is used for judging whether effective salt value information corresponding to a client communication identifier is stored locally at a short message service end according to the client communication identifier corresponding to a short message to be sent, the effective salt value information comprises an effective salt value and a salt value identifier, the effective salt value and the salt value identifier have a unique corresponding relation, and the effective salt value is effective within a preset effective period;
the encryption module is used for encrypting the short message to be sent by utilizing the effective salt value in the effective salt value information to obtain an encrypted short message when the effective salt value information corresponding to the client communication identifier is locally stored in the short message service terminal;
the first sending module is used for sending the client communication identifier, the encrypted short message and the salt value identifier in the effective salt value information to a short message service provider;
the short message service provider comprises:
the first receiving module is used for receiving the encrypted short message and the salt value identifier from the short message service end;
and the decryption module is used for acquiring the salt value for decrypting the encrypted short message according to the salt value identification, and decrypting the encrypted short message according to the acquired salt value to obtain the decrypted short message content.
9. An electronic device, comprising:
at least one processor; and the number of the first and second groups,
a memory communicatively coupled to the at least one processor; wherein the content of the first and second substances,
the memory stores a computer program that, when executed by the at least one processor, causes the at least one processor to perform the method of short message transmission based on salt value encryption of any one of claims 1 to 7.
10. A computer-readable storage medium storing a computer program, wherein the computer program, when executed by a processor, implements the method for transmitting a short message based on salt encryption according to any one of claims 1 to 7.
CN202210255011.9A 2022-03-15 2022-03-15 Short message transmission method, device, equipment and medium based on salt value encryption Pending CN114599032A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202210255011.9A CN114599032A (en) 2022-03-15 2022-03-15 Short message transmission method, device, equipment and medium based on salt value encryption

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202210255011.9A CN114599032A (en) 2022-03-15 2022-03-15 Short message transmission method, device, equipment and medium based on salt value encryption

Publications (1)

Publication Number Publication Date
CN114599032A true CN114599032A (en) 2022-06-07

Family

ID=81809438

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202210255011.9A Pending CN114599032A (en) 2022-03-15 2022-03-15 Short message transmission method, device, equipment and medium based on salt value encryption

Country Status (1)

Country Link
CN (1) CN114599032A (en)

Similar Documents

Publication Publication Date Title
CN111741028B (en) Service processing method, device, equipment and system
CN112287372B (en) Method and apparatus for protecting clipboard privacy
WO2021016265A1 (en) Systems and methods of securing digital conversations for its life cycle at source, during transit and at destination
CN111190974B (en) Method, device and equipment for forwarding and acquiring verifiable statement
CN107277028B (en) Method, device, equipment and storage medium for transmitting chat emoticons among applications
US20230050222A1 (en) Cryptographically secure request verification
US20220300643A1 (en) Cryptographically secure data protection
CN114826733B (en) File transmission method, device, system, equipment, medium and program product
US11095620B1 (en) Secure method, system, and computer program product for exchange of data
CN113918982B (en) Data processing method and system based on identification information
CN112100689A (en) Trusted data processing method, device and equipment
CN109191122B (en) Method and device for acquiring transaction information certificate
CN111901287A (en) Method and device for providing encryption information for light application and intelligent equipment
KR20170084802A (en) Methdo and system for transmitting secure data in a terminal
KR101992402B1 (en) Method for Protecting Personal Data Using Homomorphic Encryption
CN107872312B (en) Method, device, equipment and system for dynamically generating symmetric key
CN113037764B (en) System, method and device for executing service
CN114599032A (en) Short message transmission method, device, equipment and medium based on salt value encryption
CN112565156B (en) Information registration method, device and system
US9998444B2 (en) Chaining of use case-specific entity identifiers
CN110875820A (en) Management method and system for multimedia content protection key and key agent device
KR101511451B1 (en) Method of encryption to keyboard input information
KR102507864B1 (en) Secure instant messaging method and apparatus thereof
KR101275470B1 (en) Method for administering message input program and agent program by using the process of encoding-decoding process of multimedia message
CN112561523A (en) Block chain system, method, electronic device and storage medium

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