CN109067805A - Anti- crawler method, apparatus, terminal and the readable medium of direct broadcasting room data - Google Patents

Anti- crawler method, apparatus, terminal and the readable medium of direct broadcasting room data Download PDF

Info

Publication number
CN109067805A
CN109067805A CN201811189748.5A CN201811189748A CN109067805A CN 109067805 A CN109067805 A CN 109067805A CN 201811189748 A CN201811189748 A CN 201811189748A CN 109067805 A CN109067805 A CN 109067805A
Authority
CN
China
Prior art keywords
direct broadcasting
broadcasting room
data
room data
obscure
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.)
Granted
Application number
CN201811189748.5A
Other languages
Chinese (zh)
Other versions
CN109067805B (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.)
Wuhan Douyu Network Technology Co Ltd
Original Assignee
Wuhan Douyu Network 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 Wuhan Douyu Network Technology Co Ltd filed Critical Wuhan Douyu Network Technology Co Ltd
Priority to CN201811189748.5A priority Critical patent/CN109067805B/en
Publication of CN109067805A publication Critical patent/CN109067805A/en
Application granted granted Critical
Publication of CN109067805B publication Critical patent/CN109067805B/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
    • H04L63/00Network architectures or network communication protocols for network security
    • H04L63/04Network architectures or network communication protocols for network security for providing a confidential data exchange among entities communicating through data packet networks
    • H04L63/0428Network architectures or network communication protocols for network security for providing a confidential data exchange among entities communicating through data packet networks wherein the data content is protected, e.g. by encrypting or encapsulating the payload
    • H04L63/0478Network architectures or network communication protocols for network security for providing a confidential data exchange among entities communicating through data packet networks wherein the data content is protected, e.g. by encrypting or encapsulating the payload applying multiple layers of encryption, e.g. nested tunnels or encrypting the content with a first key and then with at least a second key
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L63/00Network architectures or network communication protocols for network security
    • H04L63/14Network architectures or network communication protocols for network security for detecting or protecting against malicious traffic
    • H04L63/1441Countermeasures against malicious traffic
    • H04L63/145Countermeasures against malicious traffic the attack involving the propagation of malware through the network, e.g. viruses, trojans or worms
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L63/00Network architectures or network communication protocols for network security
    • H04L63/14Network architectures or network communication protocols for network security for detecting or protecting against malicious traffic
    • H04L63/1441Countermeasures against malicious traffic
    • H04L63/1491Countermeasures against malicious traffic using deception as countermeasure, e.g. honeypots, honeynets, decoys or entrapment
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L65/00Network arrangements, protocols or services for supporting real-time applications in data packet communication
    • H04L65/60Network streaming of media packets
    • H04L65/61Network streaming of media packets for supporting one-way streaming services, e.g. Internet radio
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04LTRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION
    • H04L67/00Network arrangements or protocols for supporting network services or applications
    • H04L67/01Protocols
    • H04L67/02Protocols based on web technology, e.g. hypertext transfer protocol [HTTP]
    • 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/085Secret sharing or secret splitting, e.g. threshold schemes

Abstract

The embodiment of the invention discloses anti-crawler method, apparatus, terminal and the readable medium of a kind of direct broadcasting room data, one of method includes: to obtain direct broadcasting room data, obscures direct broadcasting room data according to rule file is obscured;Primary encryption is carried out using the low obfuscated data of security classification in the adjacent security classification obfuscated data high to security classification, secondary encryption carried out to the data after primary encryption using shared key, and the minimum obfuscated data of security classification utilizes preset shared key progress primary encryption;The file name for obscuring rule file is encrypted using shared key;Encrypted obfuscated data and file name are issued to client, so that client, which issues data according to server, determines direct broadcasting room data.Anti- crawler method, apparatus, terminal and the readable medium of a kind of direct broadcasting room data provided in an embodiment of the present invention, improve direct broadcasting room data and crack intensity, prevent crawler from crawling correct direct broadcasting room data, ensure that the safety of direct broadcasting room data.

Description

Anti- crawler method, apparatus, terminal and the readable medium of direct broadcasting room data
Technical field
The present embodiments relate to computer technology more particularly to a kind of anti-crawler method, apparatus of direct broadcasting room data, end End and readable medium.
Background technique
With the fast development of internet and stream media technology, all kinds of live streaming platforms are dazzling, bring more to user For excellent entertainment abundant and social experience.
Direct broadcasting room data include the focused data of direct broadcasting room, bean vermicelli data, watch number online, receive in live streaming platform User gradation reaches the private datas such as the number of users of predetermined level in the user watched online in present quantity and direct broadcasting room. However, web crawlers can crawl these private datas, with the information such as statistics live streaming platform income and main broadcaster's income.Cause This, needs a kind of anti-crawler method and protects to direct broadcasting room data.
Existing anti-crawler method is usually, and replaces direct broadcasting room data the behaviour such as to be transmitted or shown using picture format file Make, to prevent crawler from directly crawling direct broadcasting room data.Existing anti-crawler method disadvantage, which is that picture format file is larger, to be unfavorable for depositing The processing such as storage or transmission, and crawler crawls that image recognition can be carried out after picture format file with indirect gain direct broadcasting room data, number It is lower according to intensity is cracked.
Summary of the invention
In view of this, the embodiment of the invention provides a kind of anti-crawler method, apparatus of direct broadcasting room data, terminal and readable Medium improves direct broadcasting room data and cracks intensity, prevents crawler from crawling correct direct broadcasting room data, ensure that direct broadcasting room data Safety.
In a first aspect, the embodiment of the invention provides a kind of anti-crawler methods of direct broadcasting room data, comprising:
Direct broadcasting room data are obtained, are obscured direct broadcasting room data according to rule file is obscured, wherein direct broadcasting room data class Type includes at least following two kinds: the focused data of direct broadcasting room, watches number online, receives present data and live streaming at bean vermicelli data User gradation reaches the number of users of predetermined level in the interior user watched online;
The corresponding security classification of each direct broadcasting room data type is obtained, is obscured using security classification in adjacent security classification is low The obscure rear direct broadcasting room data high to security classification of direct broadcasting room data afterwards carry out primary encryption, utilize preset shared key pair Data after primary encryption carry out secondary encryption, and security classification it is minimum obscure after direct broadcasting room data using preset shared Key carries out primary encryption;
The file name for obscuring rule file is encrypted using preset shared key;
To obscure and encrypted direct broadcasting room data and it is encrypted obscure rule file title and be issued to client, with So that client is issued data according to server and determines direct broadcasting room data.
Optionally, the acquisition direct broadcasting room data, obscure direct broadcasting room data according to rule file is obscured, comprising:
Direct broadcasting room data are obtained by data acquisition interface, are wherein enumerated in direct broadcasting room data type and default enumeration object Element is corresponding;
Choose it is corresponding with the enumerated value of enumeration element obscures rule file, obscure rule file to enumerating according to described The direct broadcasting room data of element corresponding types are obscured, wherein described, corresponding with the enumerated value of enumeration element to obscure rule literary Part is replaced every preset time.
Optionally, described to obscure and encrypted direct broadcasting room data and encrypted obscure rule file title and issue To client, so that client, which issues data according to server, determines direct broadcasting room data, comprising:
It will be obscured by long connection and encrypted direct broadcasting room data and encrypted obscure rule file title and issue To client, so that client is to obscuring and encrypted direct broadcasting room data and encryption are obscured rule file title and solved It is close, direct broadcasting room data after being obscured and obscure rule file title, rule file name is obscured by HTTP interface downloading Claim corresponding direct broadcasting room data obscured after obscuring in rule file corresponding direct broadcasting room data.
Optionally, before the acquisition direct broadcasting room data, further includes:
Client generates the first public key and the first private key, and first public key is sent to the server;
Server generates the second public key and the second private key, and second public key is sent to the client;
Client generates the first shared key according to first private key and second public key;
Server generates the second shared key according to second private key and first public key;
Wherein the numerical value of the first shared key is consistent with the numerical value of the second shared key, respectively as client and server Preset shared key.
Second aspect, the embodiment of the invention provides a kind of anti-crawler methods of direct broadcasting room data, comprising:
It connects obscuring of receiving that server issues by long and encrypted direct broadcasting room data and encrypted obscures rule Then file name;
According to obscuring and encrypted direct broadcasting room data and encryption are obscured rule file title and be decrypted, mixed Direct broadcasting room data after confusing and obscure rule file title;
The corresponding direct broadcasting room number obscured after obscuring in rule file of rule file title is obscured by HTTP interface downloading According to corresponding direct broadcasting room data.
The third aspect, the embodiment of the invention provides a kind of anti-crawler devices of direct broadcasting room data, comprising:
Data obfuscation module obscures direct broadcasting room data according to rule file is obscured for obtaining direct broadcasting room data, Wherein direct broadcasting room data type includes at least following two kinds: the focused data of direct broadcasting room, watches number online, receives at bean vermicelli data User gradation reaches the number of users of predetermined level in the user watched online in present data and direct broadcasting room;
Obfuscated data encrypting module utilizes adjacent secrecy for obtaining the corresponding security classification of each direct broadcasting room data type Direct broadcasting room data after what security classification was low in grade obscure it is high to security classification obscure rear direct broadcasting room data carry out once plus It is close, secondary encryption carried out to the data after primary encryption using preset shared key, and security classification it is minimum obscure after Direct broadcasting room data carry out primary encryption using preset shared key;
File name encrypting module, for being added using preset shared key to the file name for obscuring rule file It is close;
Data transmission blocks, for that will obscure and encrypted direct broadcasting room data and encrypted obscure rule file name Title is issued to client, so that client, which issues data according to server, determines direct broadcasting room data.
Fourth aspect, the embodiment of the invention provides a kind of anti-crawler devices of direct broadcasting room data, comprising:
Data reception module, for by it is long connect obscuring of receiving that server issues and encrypted direct broadcasting room data with And encrypted obscure rule file title;
Data decryption module, for according to obscure and encrypted direct broadcasting room data and encryption obscure rule file name Title is decrypted, and direct broadcasting room data after being obscured and obscures rule file title;
Data solution obscures module, and for being obscured by HTTP interface downloading, rule file title is corresponding to obscure rule file In obscure after the corresponding direct broadcasting room data of direct broadcasting room data.
5th aspect, the embodiment of the invention provides a kind of servers, comprising:
One or more processors;
Memory, for storing one or more programs;
When one or more of programs are executed by one or more of processors, so that one or more of processing Device realizes the anti-crawler method of the direct broadcasting room data as described in the embodiment of the present invention one.
6th aspect, the embodiment of the invention provides a kind of terminals, comprising:
One or more processors;
Memory, for storing one or more programs;
When one or more of programs are executed by one or more of processors, so that one or more of processing Device realizes the anti-crawler method of the direct broadcasting room data as described in the embodiment of the present invention two.
7th aspect, the embodiment of the invention provides a kind of readable mediums, are stored thereon with computer program, the program quilt The anti-crawler method of the direct broadcasting room data as described in any embodiment of the present invention is realized when processor executes.
Anti- crawler method, apparatus, terminal and the readable medium of a kind of direct broadcasting room data provided in an embodiment of the present invention, service Device obtains direct broadcasting room data, obscures direct broadcasting room data according to rule file is obscured;It obtains all types of in direct broadcasting room data Corresponding security classification, using security classification in adjacent security classification it is low obscure after direct broadcasting room data it is high to security classification Obscure rear direct broadcasting room data and carry out primary encryption, using preset shared key is carried out to the data after primary encryption secondary add It is close, and security classification it is minimum obscure after direct broadcasting room data utilize preset shared key carry out primary encryption;Using default Shared key the file name for obscuring rule file is encrypted;It will obscure and encrypted direct broadcasting room data and encryption Rule file title of obscuring afterwards is issued to client, so that client, which issues data according to server, determines direct broadcasting room data. It is associated layer by layer to obfuscated data progress by obscuring direct broadcasting room data, and according to the security classification of direct broadcasting room data Primary encryption, and encrypted again using shared key, direct broadcasting room data can be improved and crack intensity, prevent crawler from crawling just True direct broadcasting room data, ensure that the safety of direct broadcasting room data.
Detailed description of the invention
In order to more clearly explain the embodiment of the invention or the technical proposal in the existing technology, to embodiment or will show below There is attached drawing needed in technical description to do one simply to introduce, it should be apparent that, the accompanying drawings in the following description is this hair Bright some embodiments for those of ordinary skill in the art without creative efforts, can be with root Other attached drawings are obtained according to these attached drawings.
Fig. 1 is a kind of anti-crawler method flow diagram for direct broadcasting room data that the embodiment of the present invention one provides;
Fig. 2 is a kind of anti-crawler method flow diagram of direct broadcasting room data provided by Embodiment 2 of the present invention;
Fig. 3 is a kind of anti-crawler apparatus structure schematic diagram for direct broadcasting room data that the embodiment of the present invention three provides;
Fig. 4 is a kind of anti-crawler apparatus structure schematic diagram for direct broadcasting room data that the embodiment of the present invention four provides;
Fig. 5 is a kind of structural schematic diagram for server that the embodiment of the present invention five provides;
Fig. 6 is a kind of structural schematic diagram for terminal that the embodiment of the present invention six provides.
Specific embodiment
To make the object, technical solutions and advantages of the present invention clearer, hereinafter with reference to attached in the embodiment of the present invention Figure, clearly and completely describes technical solution of the present invention by embodiment, it is clear that described embodiment is the present invention one Section Example, instead of all the embodiments.Based on the embodiments of the present invention, those of ordinary skill in the art are not doing Every other embodiment obtained under the premise of creative work out, shall fall within the protection scope of the present invention.
Embodiment one
Fig. 1 is a kind of anti-crawler method flow diagram for direct broadcasting room data that the embodiment of the present invention one provides, and the present embodiment can The case where anti-crawler suitable for direct broadcasting room data, this method can be realized by server, specifically can be by soft in server Part and/or hardware are implemented.
Referring to Fig. 1, the anti-crawler method of the direct broadcasting room data includes the following steps:
S110, direct broadcasting room data are obtained, obscured direct broadcasting room data according to rule file is obscured, wherein direct broadcasting room number Include at least following two kinds according to type: the focused data of direct broadcasting room, bean vermicelli data, watch number online, receive present data and User gradation reaches the number of users of predetermined level in the user watched online in direct broadcasting room.
Wherein, obscuring rule file can be form document, be also possible to text file, can also be server system journey Global variable in sequence.Wherein, server may include at least one and obscure rule file, and different direct broadcasting rooms can be using not Same obscures rule file, and what the different types of direct broadcasting room data in preferred each direct broadcasting room used obscures rule file not Together.Different types of direct broadcasting room data in rule file and same direct broadcasting room are obscured using different by different direct broadcasting rooms Rule file is obscured using different, and the difficulty that crawler obscures obfuscated data solution can be improved.
Wherein, it is corresponding that different types of direct broadcasting room data in each direct broadcasting room of map container storage can be used in server Obscure rule file, specifically can be and stored by Map<int, fontdata>mapFont, wherein key assignments int can be used In the room number of storage direct broadcasting room, fontdata can be a kind of structural body for indicating to obscure rule file.Illustratively, Fontdata structural body can be defined in the following way:
Struct fontdata{
String fontname1;
Int nData1[10];
String fontname2;
Int nData2[10];
String fontname3;
Int nData3[10];
};
Wherein, fontname can indicate to obscure the file name of rule file, and it is corresponding unique each to obscure rule file File name;Wherein the title of fontname1, fontname2 and fontname3 can be the same or different, it can Select it is consistent obscure rule file and can also select different rule files of obscuring, preferred three title differences are selected Different obscures rule file;And the quantity of fontname is consistent with the quantity of the data type of direct broadcasting room data, i.e., and every kind Data type corresponding one is obscured the file name of rule file, and file name quantity is not limited to 3.Wherein, nData can be with table Show and obscure rule file, when wherein fontname1, fontname2 are identical with the title of fontname3, obscures rule file NData1, nData2 are identical with nData3, when the title difference of fontname1, fontname2 and fontname3, obscure rule Then file nData1, nData2 and nData3 is also different.
Wherein, to ensure, each obscuring rule file corresponds to unique file name, and file name can pass through calling Fontname=Md5.Create (nData) sentence obtains, wherein the algorithm for obtaining file name is not limited to MD5 algorithm, also It can be other algorithms, such as can be five calculations of secure hash algorithm (Secure Hash Algorithm, SHA) family Method is SHA-1, SHA-224, SHA-256, SHA-384 and SHA-512 respectively, is also possible to can be MD4 algorithm or CRC32 Algorithm etc..
Illustratively, the content for obscuring rule file nData specifically can be, and 2038694751.Wherein, 2 038694751 it is corresponding obscure rear data be 0123456789.For example, if straight after obscuring Broadcasting a data is 012, then corresponding correct direct broadcasting room data are 203.
Wherein, the focused data of direct broadcasting room may include the number of users and use of other users of interest between current live Family information etc.;Bean vermicelli data may include the number of users paid close attention between current live by other users and user information etc.;Online Viewing number can be understood as the number of users watched online when being broadcast live between current live, wherein viewing number can be with online Carry out real-time update;The present data received may include the quantity etc. of the present type received and every kind of present type, and The present data received can also carry out real-time update.It wherein, just can be into when direct broadcasting room data type includes at least two kinds In row S120 step, using security classification in adjacent security classification it is low obscure after mixed high to security classification of direct broadcasting room data Direct broadcasting room data carry out the ciphering process of primary encryption after confusing.
Optionally, direct broadcasting room data are obtained, obscure direct broadcasting room data according to rule file is obscured, comprising:
Direct broadcasting room data are obtained by data acquisition interface, are wherein enumerated in direct broadcasting room data type and default enumeration object Element is corresponding;Choose it is corresponding with the enumerated value of enumeration element obscures rule file, according to obscuring rule file to enumerating The direct broadcasting room data of element corresponding types are obscured, wherein corresponding with the enumerated value of enumeration element, to obscure rule file every It is replaced every preset time.
Wherein, direct broadcasting room data are obtained by data acquisition interface, specifically may is that
Int GetData(int nroomid,int type,int data){};
Wherein, GetData is data acquisition interface title, for indicating data acquisition interface, and data acquisition interface Title is not limited to GetData;Wherein nroomid is the room number title of direct broadcasting room, for indicating the room number of direct broadcasting room, and The room number title of direct broadcasting room is not limited to nroomid, and the room number title of each direct broadcasting room is different;Wherein type is direct broadcasting room The typonym of data, for indicating the type of direct broadcasting room data, and the typonym of direct broadcasting room data is not limited to type;Its Middle data is direct broadcasting room data name, indicates direct broadcasting room data, and direct broadcasting room data name is not limited to data.
Wherein, direct broadcasting room data type is corresponding with enumeration element in default enumeration object, specifically may is that
Enum dataType{
edataType_Focus
edataType_Fans
edataType_Noble
};
Wherein, dataType is the enumeration object for the data type that can indicate that direct broadcasting room includes;Wherein, edataType_ Focus, edataType_Fans and edataType_Noble are the enumeration element in enumeration object dataType;Wherein, EdataType_Focus can pay close attention to the data type of data, and edataType_Fans can indicate the number of bean vermicelli data According to type, edataType_Noble can indicate noble's quantity (user in the user watched online in direct broadcasting room of direct broadcasting room Grade arrival predetermined level number of users) data type.Wherein, the data class of the quantity of enumeration element and direct broadcasting room data Type is consistent, i.e. the corresponding enumeration element of every kind of data type, the quantity of enumeration element is not limited to 3, direct broadcasting room data Type is also not necessarily limited to above-mentioned three kinds.Wherein, there is fixed enumerated value, first enumeration element in the enumeration element in enumeration object Enumerated value be 0, the enumerated value of second enumeration element is 1, and so on, i.e. edataType_Focus, edataType_ The enumerated value of Fans and edataType_Noble is respectively 0,1 and 2.When server gets direct broadcasting room data type, at once The enumerated value of the direct broadcasting room data type is obtained by enumeration object.Regular text is obscured by establishing in enumerated value and map container The corresponding relationship of part nData can be searched in map container according to the enumerated value and corresponding obscure rule file nData, and root The direct broadcasting room data of enumeration element corresponding types are obscured according to rule file is obscured.
Illustratively, searched in map container according to the enumerated value it is corresponding obscure rule file nData, and according to mixed Rule file of confusing obscures the direct broadcasting room data of enumeration element corresponding types, specifically may is that
Map<int,fontdata>::iterator itr;
Itr=mapFont.find (nroomid);
Int nResult=0;
If (type==edataType_Focus)
NResult=(* itr) .nData1 [data];
Else if (type==edataType_Fans)
NResult=(* itr) .nData2 [data];
Else if (type==edataType_Noble
NResult=(* itr) .nData3 [data];
}
Retrurn nResult;
Wherein, by Map<int, fontdata>:: iterator itr defines an iterator, for passing through map appearance The lookup function mapFont.find (nroomid) of device searches the relevant information of the room number nroomid of direct broadcasting room;Wherein, By defining a result data nResult, it to be used for storage result value, that is, the direct broadcasting room data after obscuring;Wherein according to difference The corresponding enumerated value of direct broadcasting room data type edataType_Focus, edataType_Fans and edataType_Noble, can To be obscured using different Obfuscating Algorithms nData direct broadcasting room data.
By being arranged enumeration object, the corresponding enumerated value of available direct broadcasting room data type, according to enumerated value with obscure The corresponding relationship of rule file, can be searched from map container it is corresponding obscure rule file nData, and according to obscuring rule File obscures the direct broadcasting room data of enumeration element corresponding types.And it can be to each direct broadcasting room every a preset time Interior direct broadcasting room data type is corresponding to be obscured rule file and is constantly updated, and is obscured to improve crawler obfuscated data solution Degree-of-difficulty factor.
S120, the corresponding security classification of each direct broadcasting room data type is obtained, it is low using security classification in adjacent security classification Obscure after direct broadcasting room data obscure rear direct broadcasting room data high to security classification carry out primary encryption, using preset shared Data after key pair primary encryption carry out secondary encryption, and security classification it is minimum obscure after direct broadcasting room data using default Shared key carry out primary encryption.
Wherein, the corresponding security classification of direct broadcasting room data type can be preset in server, and can basis Live streaming platform service demand is modified.Wherein, using security classification in adjacent security classification it is low obscure after direct broadcasting room number According to the ciphering process obscuring rear direct broadcasting room data carry out primary encryption high to security classification, different types of direct broadcasting room can be made Data carry out encryption from level to level as low as the high sequence of grade by grade, by being associated different types of direct broadcasting room data Encryption can be improved data and crack threshold.
Illustratively, if direct broadcasting room data type includes focused data nFocus, bean vermicelli data nFans and noble's data Tri- kinds of nNoble, and security classification is gradually increased.It can then complete to obscure the encryption of rear direct broadcasting room data as follows:
1.KEY value obtains.
HASH is carried out to the focused data after obscuring, KEY1 value is calculated, such as can be KEY1=Md5.Create (nFocus);KEY2 value is calculated to rear bean vermicelli data progress HASH is obscured, such as can be KEY2=MD4.Create (nFans)。
2. obscuring rear focused data encryption.
The focused data after obscuring is encrypted using preset shared key, such as may is that
EncryptnFocus=Tea.Encrypt (nFocus, ShareKey).
3. obscuring rear bean vermicelli data encryption.
Primary encryption is carried out to rear bean vermicelli data are obscured using KEY1 value, such as may is that
EncryptnFans=Tea.Encrypt (nFans, KEY1);
Secondary encryption is carried out to the data after primary encryption using preset shared key, such as may is that
EncryptnFans2=Blowfish.Encrypt (EncryptnFans, ShareKey).
4. obscuring rear noble's data encryption.
Primary encryption is carried out to rear noble's data are obscured using KEY2 value, such as may is that
EncryptnNoble=Rc4.Encrypt (nNoble, KEY2);
Secondary encryption is carried out to the data after primary encryption using preset shared key, such as may is that
EncryptnNoble2=IDEA.Encrypt (EncryptnNoble, ShareKey).
Wherein, HASH algorithm can be five of secure hash algorithm (Secure Hash Algorithm, SHA) family Algorithm is SHA-1, SHA-224, SHA-256, SHA-384 and SHA-512 respectively, is also possible to other algorithms, such as CRC32 Algorithm etc..Wherein, Encryption Algorithm can be Tea algorithm, Blowfish algorithm or international data encryption algorithm (International Data Encryption Algorithm, IDEA), can also be Advanced Encryption Standard (Advanced Encryption Standard, AES), data encryption standards (Data Encryption Standard, DES), triple data Encryption standard (Triple DES, 3DES) etc., it is not limited here.
S130, the file name for obscuring rule file is encrypted using preset shared key.
Illustratively, using preset shared key to obscure rule file file name Fontname1, Fontname2 and Fontname3 are encrypted, and specifically may is that
Encryptname1=AES.Encrypt (Fontname1, ShareKey);
Encryptname2=AES.Encrypt (Fontname2, ShareKey);
Encryptname3=AES.Encrypt (Fontname3, ShareKey);
Equally, Encryption Algorithm can be Tea algorithm, Blowfish algorithm or international data encryption algorithm (International Data Encryption Algorithm, IDEA), can also be Advanced Encryption Standard (Advanced Encryption Standard, AES), data encryption standards (Data Encryption Standard, DES), triple data Encryption standard (Triple DES, 3DES) etc., it is not limited here.
S140, it will obscure and encrypted direct broadcasting room data and encrypted obscure rule file title and be issued to client End, so that client, which issues data according to server, determines direct broadcasting room data.
Optionally, it will obscure and encrypted direct broadcasting room data and encrypted obscure rule file title and be issued to visitor Family end, so that client, which issues data according to server, determines direct broadcasting room data, comprising:
It will be obscured by long connection and encrypted direct broadcasting room data and encrypted obscure rule file title and issue To client, so that client is to obscuring and encrypted direct broadcasting room data and encryption are obscured rule file title and solved It is close, direct broadcasting room data after being obscured and obscure rule file title, rule file name is obscured by HTTP interface downloading Claim corresponding direct broadcasting room data obscured after obscuring in rule file corresponding direct broadcasting room data.
Wherein, long connection can be understood as being used for transmission between client and server after the completion of a webpage is opened Transmission control protocol (Transmission Control Protocol, the TCP) connection of HTTP data does not turn off, client When accessing this server again, it will continue to use this established connection.Wherein, direct broadcasting room data are with direct broadcasting room Interior true live streaming situation is the data, such as online viewing number of continuous renewal etc. of foundation, therefore server sends direct broadcasting room It can be preferably using long connection when data.
Wherein, client can be interacted by long connection and both interfaces of HTTP interface with server, from And the safety of direct broadcasting room data can be enhanced.
Optionally, before obtaining direct broadcasting room data, further includes:
Client generates the first public key and the first private key, and the first public key is sent to server;
Server generates the second public key and the second private key, and the second public key is issued to client;
Client generates the first shared key according to the first private key and the second public key;
Server generates the second shared key according to the second private key and the first public key;
Wherein the numerical value of the first shared key is consistent with the numerical value of the second shared key, respectively as client and server Preset shared key.
Wherein, when client logs on to server, server client can generate a pair of of public, private key information thus, i.e., Second public key and the second private key;Client oneself can also generate a pair of of public, private key information, i.e. the first public key and the first private simultaneously Key;Client and server exchanges respective public key information, i.e., the first public key is sent to server by client, and server is by the Two public keys are issued to client, and client generates shared key according to the first private key and the second public key, and server is according to the second private Key and the first public key generate shared key, and the numerical value of two shared keys is consistent.
Wherein, random data can be used to generate the first private key in client, seeks the first public key using the first private key, from And ensure that different clients correspond to different private key and public key as far as possible, improve the threshold cracked.Wherein, client generates the The step of one public key, can be specific as follows:
1. generating random data.
RandData=rand ();
One section of random data RandData is generated by calling system function rand.
2. using random data as the first private key.
ClientPrivatekey=RandData.
3. calculating the first public key.
ClientPublickey=EccEncryption.CreatePair (ClientPrivatekey);
First public key then calls the generation of elliptic curve encryption algorithm (Elliptic curve cryptography, ECC) Pair-wise key interface EccEncryption.CreatePair is generated.It wherein, can also be non-using other in addition to calling ECC Symmetry algorithm, such as can be Elgamal algorithm, knapsack algorithm or RSA cryptographic algorithms etc..
Wherein, server is also raw according to the generation method of the first private key and the first public key when detecting client login At the second private key and the second public key, to ensure that different clients correspond to different private key and public key, improve brokenly as far as possible The threshold of solution.Wherein, it is specific as follows to generate the step of the second public key for server:
1. generating random data
Randdata=rand ();
One section of random data Randdata is generated by calling system function rand.
2. using random data as the second private key.
ServerPrivatekey=Randdata.
3. calculating the second public key.
ServerPublickey=EccEncryption. (ServerPrivatekey);
Second public key then calls the generation of elliptic curve encryption algorithm (Elliptic curve cryptography, ECC) Pair-wise key interface EccEncryption.CreatePair is generated.It wherein, can also be non-using other in addition to calling ECC Symmetry algorithm, such as can be Elgamal algorithm, knapsack algorithm or RSA cryptographic algorithms etc..
Wherein, client and server generates shared key according to the first public key and the second public key respectively, and specific steps are such as Under:
1. exchanging public key.
Second public key ServerPublickey is sent to client by server.
First public key ClientPublickey is sent to server by client.
2. server generates shared key.
ShareKey=EccEncryption.CreateShareKey (ClientPublickey, ServerPrivatekey);
3. client generates shared key.
ShareKey=EccEncryption.CreateShareKey (ServerPublickey, ClientPrivatekey);
Wherein, the shared key that server generates is consistent with the value for 2 ShareKey of shared key that client generates 's.It is arranged by shared key, can ensures the safety of data transmission.
The anti-crawler method of direct broadcasting room data provided in this embodiment, by obscuring direct broadcasting room data, Yi Jigen Associated primary encryption layer by layer is carried out to obfuscated data according to the security classification of direct broadcasting room data, and is carried out again using shared key Encryption, can be improved direct broadcasting room data and cracks intensity, prevent crawler from crawling correct direct broadcasting room data, ensure that direct broadcasting room data Safety.
Embodiment two
Fig. 2 is a kind of anti-crawler method flow diagram of direct broadcasting room data provided by Embodiment 2 of the present invention, and the present embodiment can The case where anti-crawler suitable for direct broadcasting room data, this method can be realized by terminal, specifically can by software in terminal and/ Or hardware is implemented.
Referring to fig. 2, the anti-crawler method of the direct broadcasting room data includes the following steps:
S210, obscuring of receiving that server issues is connected and encrypted direct broadcasting room data and encrypted mixed by long Rule file of confusing title;
S220, according to obscuring and encrypted direct broadcasting room data and encryption are obscured rule file title and be decrypted, Direct broadcasting room data after being obscured and obscure rule file title;
S230, the corresponding live streaming obscured after obscuring in rule file of rule file title is obscured by HTTP interface downloading Between the corresponding direct broadcasting room data of data.
Optionally, obscure rule file title to encryption to be decrypted, comprising: using preset shared key to obscure rule Then the file name of file is decrypted.
Wherein, decipherment algorithm used by being decrypted and server carry out obscuring the encryption used when rule file encryption Algorithm is consistent.Illustratively, when server obscure the Encryption Algorithm used when rule file encryption for aes algorithm, then Client is decrypted the decipherment algorithm of use and is similarly aes algorithm to the rule file title of obscuring of encryption, specifically may is that
Fontname=AES.Decrypt (encryptname, ShareKey).
Optionally, to obscuring and encrypted direct broadcasting room data are decrypted, comprising:
Using preset shared key it is minimum to security classification obscure after direct broadcasting room data be decrypted;
Secondary encrypted data are once decrypted using preset shared key, using being protected in adjacent security classification Close grade it is low obscure after direct broadcasting room data it is high to security classification it is primary decryption after data carry out two decryption.
Wherein, it is minimum to security classification obscure after direct broadcasting room data be decrypted used by decipherment algorithm and service Device it is minimum to security classification obscure after direct broadcasting room data to carry out the Encryption Algorithm that uses when primary encryption consistent.It is exemplary , when server it is minimum to security classification obscure after direct broadcasting room data carry out primary encryption when the Encryption Algorithm that uses for When Tea algorithm, then used decipherment algorithm is decrypted in the direct broadcasting room data after what client was minimum to security classification obscure It is similarly Tea algorithm.Similarly, the decipherment algorithm and server by utilizing used when once being decrypted to secondary encrypted data The Encryption Algorithm that preset shared key carries out secondary encryption to the data after primary encryption is consistent.
Wherein it is possible to using security classification it is minimum obscure rear direct broadcasting room data to security classification inverse after primary decryption the Data carry out secondary decryption after two low primary decryption, obtain that security classification is second from the bottom low to obscure rear direct broadcasting room data;Together Reason can use security classification, and second from the bottom low to obscure rear direct broadcasting room data third from the bottom low to security classification after primary decryption Primary decryption after data carry out secondary decryption, until obtain all obscuring rear direct broadcasting room data, that is, complete to obscuring and add Direct broadcasting room data after close are decrypted.
Illustratively, the data that the received server of client issues include the focused data of primary encryption Noble's data of EncryptnFocus, the bean vermicelli data EncryptnFans2 of secondary encryption and secondary encryption Tri- kinds of EncryptnNoble2, wherein security classification is gradually increased.After can then completing as follows to obscuring and encrypting Direct broadcasting room data deciphering:
1. decryption primary encryption obscures rear focused data.
The focused data after obscuring is decrypted using preset shared key, such as may is that
NFocus=Tea.Decrypt (EncryptnFocus, ShareKey).
2.KEY1 value obtains.
HASH is carried out to the focused data nFocus after obscuring, KEY1 value is calculated, such as can be KEY1= Md5.Create(nFocus)。
3. that decrypts secondary encryption obscures rear bean vermicelli data.
Secondary encrypted data are once decrypted using preset shared key, such as may is that
EncryptnFans=Blowfish.Encrypt (EncryptnFans2, ShareKey);
Secondary decryption is carried out to the data after primary decryption using KEY1 value, such as may is that
NFans=Tea.Decrypt (EncryptnFans, KEY1).
4.KEY2 value obtains.
HASH is carried out to the bean vermicelli data nFans after obscuring, KEY2 value is calculated, such as can be KEY2= Md4.Create(nFocus)。
5. that decrypts secondary encryption obscures rear noble's data.
Secondary encrypted data are once decrypted using preset shared key, such as may is that
EncryptnNoble=IDEA.Encrypt (EncryptnNoble2, ShareKey);
Secondary decryption is carried out to the data after primary decryption using KEY2 value, such as may is that
NNoble=Rc4.Encrypt (EncryptnNoble, KEY2).
Optionally, by HTTP interface downloading obscure rule file title it is corresponding obscure it is straight after obscuring in rule file Broadcast the corresponding direct broadcasting room data of a data, comprising:
Rule file is obscured corresponding to the file name for obscuring rule file obtained by HTTP interface request decryption; Rule file is obscured in inquiry, obtains the corresponding direct broadcasting room data of direct broadcasting room data after obscuring.
Wherein, client can be interacted by long connection and both interfaces of HTTP interface with server, from And the safety of direct broadcasting room data can be enhanced.
Optionally, before S210 step, further includes:
Client generates the first public key and the first private key, and the first public key is sent to server;
Server generates the second public key and the second private key, and the second public key is issued to client;
Client generates the first shared key according to the first private key and the second public key;
Server generates the second shared key according to the second private key and the first public key;
Wherein the numerical value of the first shared key is consistent with the numerical value of the second shared key, respectively as client and server Preset shared key.
The anti-crawler method of direct broadcasting room data provided in this embodiment, the anti-creep of the direct broadcasting room data proposed with embodiment one Worm method belongs to same inventive concept, and the technical detail of detailed description not can be found in embodiment one, and this in the present embodiment Embodiment and the beneficial effect having the same of embodiment one.
Embodiment three
Fig. 3 is a kind of anti-crawler apparatus structure schematic diagram for direct broadcasting room data that the embodiment of the present invention three provides, this implementation The case where example is applicable to the anti-crawler of direct broadcasting room data.
Referring to Fig. 3, the anti-crawler device of direct broadcasting room data in the present embodiment, comprising:
Data obfuscation module 310 mixes direct broadcasting room data according to rule file is obscured for obtaining direct broadcasting room data Confuse, wherein direct broadcasting room data type includes at least following two kinds: the focused data of direct broadcasting room, bean vermicelli data, watch online number, Receive the number of users that user gradation in the user watched online in present data and direct broadcasting room reaches predetermined level;
Obfuscated data encrypting module 320 utilizes adjacent guarantor for obtaining the corresponding security classification of each direct broadcasting room data type Direct broadcasting room data after what security classification was low in close grade obscure it is high to security classification obscure rear direct broadcasting room data carry out it is primary Encryption carries out secondary encryption to the data after primary encryption using preset shared key, and security classification it is minimum obscure after Direct broadcasting room data utilize preset shared key carry out primary encryption;
File name encrypting module 330, for using preset shared key to obscure the file name of rule file into Row encryption;
Data transmission blocks 340, for that will obscure and encrypted direct broadcasting room data and encrypted obscure regular text Part title is issued to client, so that client, which issues data according to server, determines direct broadcasting room data.
Optionally, data obfuscation module 310, is specifically used for:
Direct broadcasting room data are obtained by data acquisition interface, are wherein enumerated in direct broadcasting room data type and default enumeration object Element is corresponding;Choose it is corresponding with the enumerated value of enumeration element obscures rule file, according to obscuring rule file to enumerating The direct broadcasting room data of element corresponding types are obscured, wherein corresponding with the enumerated value of enumeration element, to obscure rule file every It is replaced every preset time.
Optionally, data transmission blocks 340 are specifically used for:
It will be obscured by long connection and encrypted direct broadcasting room data and encrypted obscure rule file title and issue To client, so that client is to obscuring and encrypted direct broadcasting room data and encryption are obscured rule file title and solved It is close, direct broadcasting room data after being obscured and obscure rule file title, rule file name is obscured by HTTP interface downloading Claim corresponding direct broadcasting room data obscured after obscuring in rule file corresponding direct broadcasting room data.
Optionally, the anti-crawler device of direct broadcasting room data, further includes:
Second public key for generating the second public key and the second private key, and is issued to client by shared key generation module; The second shared key is generated according to the first public key that the second private key and client are sent;Using the second shared key as preset Shared key.
The anti-crawler device of direct broadcasting room data provided in this embodiment, the anti-creep of the direct broadcasting room data proposed with embodiment one Worm method belongs to same inventive concept, and the technical detail of detailed description not can be found in embodiment one, and this in the present embodiment Embodiment and the beneficial effect having the same of embodiment one.
Example IV
Fig. 4 is a kind of anti-crawler apparatus structure schematic diagram for direct broadcasting room data that the embodiment of the present invention four provides, this implementation The case where example is applicable to the anti-crawler of direct broadcasting room data.
Referring to fig. 4, in the present embodiment direct broadcasting room data anti-crawler device, comprising:
Data reception module 410, for connecting obscuring of receiving that server issues and encrypted direct broadcasting room number by long Accordingly and encrypted obscure rule file title;
Data decryption module 420, for according to obscuring and regular text is obscured in encrypted direct broadcasting room data and encryption Part title is decrypted, and direct broadcasting room data after being obscured and obscures rule file title;
Data solution obscures module 430, and for being obscured by HTTP interface downloading, rule file title is corresponding to obscure rule The corresponding direct broadcasting room data of direct broadcasting room data after obscuring in file.
Optionally, data decryption module 420, comprising:
File name decrypts submodule, for being carried out using preset shared key to the file name for obscuring rule file Decryption.
Obfuscated data decrypt submodule, for using preset shared key it is minimum to security classification obscure after live streaming Between data be decrypted;Secondary encrypted data are once decrypted using preset shared key, utilize adjacent secrecy Data carry out two decryption after the primary decryption high to security classification of direct broadcasting room data after what security classification was low in grade obscure.
Optionally, data solution obscures module 430, is specifically used for:
Rule file is obscured corresponding to the file name for obscuring rule file obtained by HTTP interface request decryption; Rule file is obscured in inquiry, obtains the corresponding direct broadcasting room data of direct broadcasting room data after obscuring.
Optionally, the anti-crawler device of direct broadcasting room data, further includes:
First public key for generating the first public key and the first private key, and is sent to server by shared key generation module; The first shared key is generated according to the second public key that the first private key and server are sent;Using the first shared key as preset Shared key.
The anti-crawler device of direct broadcasting room data provided in this embodiment, the anti-creep of the direct broadcasting room data proposed with embodiment two Worm method belongs to same inventive concept, and the technical detail of detailed description not can be found in embodiment two, and this in the present embodiment Embodiment and the beneficial effect having the same of embodiment two.
Embodiment five
The case where present embodiments providing a kind of terminal, can be used for the anti-crawler of direct broadcasting room data.Fig. 5 is of the invention real A kind of structural schematic diagram of terminal of the offer of example five is provided.Referring to Fig. 5, which includes:
One or more processors 510;
Memory 520, for storing one or more programs;
When one or more of programs are executed by one or more of processors 510, so that one or more of Processor 510 realizes the anti-crawler method of the direct broadcasting room data proposed such as embodiment one.
In Fig. 5 by taking a processor 510 as an example;Processor 510 and memory 520 can be connected by bus or other modes It connects, in Fig. 5 for being connected by bus.
Memory 520 is used as a kind of computer readable storage medium, can be used for storing software program, journey can be performed in computer Sequence and module, such as the corresponding program instruction/module of anti-crawler method of the direct broadcasting room data in the embodiment of the present invention.Processor 510 software program, instruction and the modules being stored in memory 520 by operation, are answered thereby executing the various functions of terminal With and data processing, that is, realize the anti-crawler method of above-mentioned direct broadcasting room data.
Memory 520 can mainly include storing program area and storage data area, wherein storing program area can store operation system Application program needed for system, at least one function;Storage data area, which can be stored, uses created data etc. according to terminal.This Outside, memory 520 may include high-speed random access memory, can also include nonvolatile memory, for example, at least one Disk memory, flush memory device or other non-volatile solid state memory parts.In some instances, memory 520 can be into one Step includes the memory remotely located relative to processor 510, these remote memories can pass through network connection to terminal.On The example for stating network includes but is not limited to internet, intranet, local area network, mobile radio communication and combinations thereof.
The anti-crawler method for the direct broadcasting room data that the terminal and embodiment one that the present embodiment proposes propose belongs to same invention Design, the technical detail of detailed description not can be found in embodiment one in the present embodiment, and the present embodiment and embodiment one have There is identical beneficial effect.
Embodiment six
The case where present embodiments providing a kind of terminal, can be used for the anti-crawler of direct broadcasting room data.Fig. 6 is of the invention real A kind of structural schematic diagram of terminal of the offer of example six is provided.Referring to Fig. 6, which includes:
One or more processors 610;
Memory 620, for storing one or more programs;
When one or more of programs are executed by one or more of processors 610, so that one or more of Processor 610 realizes the anti-crawler method of the direct broadcasting room data proposed such as embodiment two.
In Fig. 6 by taking a processor 610 as an example;Processor 610 and memory 620 can be connected by bus or other modes It connects, in Fig. 6 for being connected by bus.
Memory 620 is used as a kind of computer readable storage medium, can be used for storing software program, journey can be performed in computer Sequence and module, such as the corresponding program instruction/module of anti-crawler method of the direct broadcasting room data in the embodiment of the present invention.Processor 610 software program, instruction and the modules being stored in memory 620 by operation, are answered thereby executing the various functions of terminal With and data processing, that is, realize the anti-crawler method of above-mentioned direct broadcasting room data.
Memory 620 can mainly include storing program area and storage data area, wherein storing program area can store operation system Application program needed for system, at least one function;Storage data area, which can be stored, uses created data etc. according to terminal.This Outside, memory 620 may include high-speed random access memory, can also include nonvolatile memory, for example, at least one Disk memory, flush memory device or other non-volatile solid state memory parts.In some instances, memory 620 can be into one Step includes the memory remotely located relative to processor 610, these remote memories can pass through network connection to terminal.On The example for stating network includes but is not limited to internet, intranet, local area network, mobile radio communication and combinations thereof.
The anti-crawler method for the direct broadcasting room data that the terminal and embodiment two that the present embodiment proposes propose belongs to same invention Design, the technical detail of detailed description not can be found in embodiment two in the present embodiment, and the present embodiment and embodiment two have There is identical beneficial effect.
Embodiment seven
The present embodiment provides a kind of readable mediums, are stored thereon with computer program, real when which is executed by processor The anti-crawler method of the direct broadcasting room data now proposed such as embodiment one or two.
The anti-crawler method for the direct broadcasting room data that the readable medium that the present embodiment proposes is proposed with embodiment one or two belongs to Same inventive concept, the technical detail of detailed description not can be found in embodiment one or two, and the present embodiment in the present embodiment With the beneficial effect having the same of embodiment one or two.
By the description above with respect to embodiment, it is apparent to those skilled in the art that, the present invention It can be realized by software and required common hardware, naturally it is also possible to which by hardware realization, but in many cases, the former is more Good embodiment.Based on this understanding, technical solution of the present invention substantially in other words contributes to the prior art Part can be embodied in the form of software products, which can store in computer readable storage medium In, floppy disk, read-only memory (Read-Only Memory, ROM), random access memory (Random such as computer Access Memory, RAM), flash memory (FLASH), hard disk or CD etc., including some instructions are with so that a computer is set Standby (can be personal computer, server or the network equipment etc.) executes method described in each embodiment of the present invention.
Note that the above is only a better embodiment of the present invention and the applied technical principle.It will be appreciated by those skilled in the art that The invention is not limited to the specific embodiments described herein, be able to carry out for a person skilled in the art it is various it is apparent variation, It readjusts and substitutes without departing from protection scope of the present invention.Therefore, although being carried out by above embodiments to the present invention It is described in further detail, but the present invention is not limited to the above embodiments only, without departing from the inventive concept, also It may include more other equivalent embodiments, and the scope of the invention is determined by the scope of the appended claims.

Claims (10)

1. a kind of anti-crawler method of direct broadcasting room data characterized by comprising
Direct broadcasting room data are obtained, obscure direct broadcasting room data according to rule file is obscured, wherein direct broadcasting room data type is extremely Less include following two kinds: the focused data of direct broadcasting room, watches number online, receives in present data and direct broadcasting room at bean vermicelli data User gradation reaches the number of users of predetermined level in the user watched online;
Obtain the corresponding security classification of each direct broadcasting room data type, using security classification in adjacent security classification it is low obscure after Direct broadcasting room data the obscure rear direct broadcasting room data high to security classification carry out primary encryption, using preset shared key to primary Encrypted data carry out secondary encryption, and security classification it is minimum obscure after direct broadcasting room data utilize preset shared key Carry out primary encryption;
The file name for obscuring rule file is encrypted using preset shared key;
To obscure and encrypted direct broadcasting room data and it is encrypted obscure rule file title and be issued to client so that objective Family end issues data according to server and determines direct broadcasting room data.
2. the method according to claim 1, wherein the acquisition direct broadcasting room data, according to obscuring rule file Direct broadcasting room data are obscured, comprising:
Direct broadcasting room data are obtained by data acquisition interface, wherein direct broadcasting room data type and enumeration element in default enumeration object It is corresponding;
Selection is corresponding with the enumerated value of enumeration element to obscure rule file, obscures rule file to enumeration element according to described The direct broadcasting room data of corresponding types are obscured, wherein described, corresponding with the enumerated value of enumeration element to obscure rule file every It is replaced every preset time.
3. the method according to claim 1, wherein it is described will obscure and encrypted direct broadcasting room data and add Rule file title of obscuring after close is issued to client, so that client, which issues data according to server, determines direct broadcasting room number According to, comprising:
It will be obscured by long connection and encrypted direct broadcasting room data and encrypted obscure rule file title and be issued to visitor Family end, so that client is obtained to obscuring and encrypted direct broadcasting room data and encryption are obscured rule file title and be decrypted Direct broadcasting room data to after obscuring and obscure rule file title, it is corresponding to obscure rule file title by HTTP interface downloading The corresponding direct broadcasting room data of the direct broadcasting room data obscured after obscuring in rule file.
4. the method according to claim 1, wherein before the acquisition direct broadcasting room data, further includes:
Client generates the first public key and the first private key, and first public key is sent to the server;
Server generates the second public key and the second private key, and second public key is sent to the client;
Client generates the first shared key according to first private key and second public key;
Server generates the second shared key according to second private key and first public key;
Wherein the numerical value of the first shared key is consistent with the numerical value of the second shared key, respectively as the pre- of client and server If shared key.
5. a kind of anti-crawler method of direct broadcasting room data characterized by comprising
It connects obscuring of receiving that server issues by long and encrypted direct broadcasting room data and encrypted obscures regular text Part title;
According to obscuring and encrypted direct broadcasting room data and encryption are obscured rule file title and be decrypted, after being obscured Direct broadcasting room data and obscure rule file title;
The corresponding direct broadcasting room data pair obscured after obscuring in rule file of rule file title are obscured by HTTP interface downloading The direct broadcasting room data answered.
6. a kind of anti-crawler device of direct broadcasting room data characterized by comprising
Data obfuscation module obscures direct broadcasting room data according to rule file is obscured for obtaining direct broadcasting room data, wherein Direct broadcasting room data type includes at least following two kinds: the focused data of direct broadcasting room, watches number online, receives gift at bean vermicelli data User gradation reaches the number of users of predetermined level in the user watched online in object data and direct broadcasting room;
Obfuscated data encrypting module utilizes adjacent security classification for obtaining the corresponding security classification of each direct broadcasting room data type Middle security classification it is low obscure after direct broadcasting room data obscure rear direct broadcasting room data high to security classification carry out primary encryption, benefit Secondary encryption carried out to the data after primary encryption with preset shared key, and security classification it is minimum obscure after direct broadcasting room Data carry out primary encryption using preset shared key;
File name encrypting module, for being encrypted using preset shared key to the file name for obscuring rule file;
Data transmission blocks, for that will obscure and encrypted direct broadcasting room data and encrypted obscure under rule file title It is sent to client, so that client, which issues data according to server, determines direct broadcasting room data.
7. a kind of anti-crawler device of direct broadcasting room data characterized by comprising
Data reception module, for connecting obscuring of receiving that server issues by long and encrypted direct broadcasting room data and adding Rule file title is obscured after close;
Data decryption module, for according to obscure and encrypted direct broadcasting room data and encryption obscure rule file title into Row decryption, direct broadcasting room data after being obscured and obscures rule file title;
Data solution obscures module, for by HTTP interface downloading obscure rule file title it is corresponding obscure in rule file mix The corresponding direct broadcasting room data of direct broadcasting room data after confusing.
8. a kind of server, which is characterized in that the server includes:
One or more processors;
Memory, for storing one or more programs;
When one or more of programs are executed by one or more of processors, so that one or more of processors are real The now anti-crawler method of the direct broadcasting room data as described in any in claim 1-4.
9. a kind of terminal, which is characterized in that the terminal includes:
One or more processors;
Memory, for storing one or more programs;
When one or more of programs are executed by one or more of processors, so that one or more of processors are real The now anti-crawler method of direct broadcasting room data as described in claim 5.
10. a kind of readable medium, is stored thereon with computer program, which is characterized in that the realization when program is executed by processor The anti-crawler method of direct broadcasting room data as described in any in claim 1-4 or 5.
CN201811189748.5A 2018-10-12 2018-10-12 Live broadcast room data anti-crawling method and device, terminal and readable medium Active CN109067805B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201811189748.5A CN109067805B (en) 2018-10-12 2018-10-12 Live broadcast room data anti-crawling method and device, terminal and readable medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201811189748.5A CN109067805B (en) 2018-10-12 2018-10-12 Live broadcast room data anti-crawling method and device, terminal and readable medium

Publications (2)

Publication Number Publication Date
CN109067805A true CN109067805A (en) 2018-12-21
CN109067805B CN109067805B (en) 2021-07-23

Family

ID=64764791

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201811189748.5A Active CN109067805B (en) 2018-10-12 2018-10-12 Live broadcast room data anti-crawling method and device, terminal and readable medium

Country Status (1)

Country Link
CN (1) CN109067805B (en)

Cited By (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109768978A (en) * 2019-01-16 2019-05-17 武汉斗鱼鱼乐网络科技有限公司 A kind of method and relevant apparatus of obfuscated data
CN110929270A (en) * 2019-10-29 2020-03-27 北京芯盾集团有限公司 Information security encryption method and device
CN111314351A (en) * 2020-02-19 2020-06-19 望海康信(北京)科技股份公司 Anti-crawler data processing method and device, electronic equipment and storage medium
CN112449204A (en) * 2019-08-30 2021-03-05 武汉斗鱼网络科技有限公司 Method and related device for obfuscating data

Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102932349A (en) * 2012-10-31 2013-02-13 成都主导软件技术有限公司 Data transmission method, device and system
CN105577684A (en) * 2016-01-25 2016-05-11 北京京东尚科信息技术有限公司 Anti-crawling methods, server, client and system
US20170070481A1 (en) * 2015-09-03 2017-03-09 Pilixo Limited Communication channel security against packet sniffing
CN107220291A (en) * 2017-04-25 2017-09-29 深圳中兴网信科技有限公司 The method and system of the anti-crawl of web data
CN108197482A (en) * 2017-12-27 2018-06-22 致象尔微电子科技(上海)有限公司 A kind of internal storage data encrypting and decrypting method and device
CN108289096A (en) * 2018-01-05 2018-07-17 武汉斗鱼网络科技有限公司 The method and device of direct broadcasting room concern is paid close attention to, verified to a kind of direct broadcasting room

Patent Citations (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102932349A (en) * 2012-10-31 2013-02-13 成都主导软件技术有限公司 Data transmission method, device and system
US20170070481A1 (en) * 2015-09-03 2017-03-09 Pilixo Limited Communication channel security against packet sniffing
CN105577684A (en) * 2016-01-25 2016-05-11 北京京东尚科信息技术有限公司 Anti-crawling methods, server, client and system
CN107220291A (en) * 2017-04-25 2017-09-29 深圳中兴网信科技有限公司 The method and system of the anti-crawl of web data
CN108197482A (en) * 2017-12-27 2018-06-22 致象尔微电子科技(上海)有限公司 A kind of internal storage data encrypting and decrypting method and device
CN108289096A (en) * 2018-01-05 2018-07-17 武汉斗鱼网络科技有限公司 The method and device of direct broadcasting room concern is paid close attention to, verified to a kind of direct broadcasting room

Cited By (6)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN109768978A (en) * 2019-01-16 2019-05-17 武汉斗鱼鱼乐网络科技有限公司 A kind of method and relevant apparatus of obfuscated data
CN109768978B (en) * 2019-01-16 2021-05-25 武汉斗鱼鱼乐网络科技有限公司 Method and related device for obfuscating data
CN112449204A (en) * 2019-08-30 2021-03-05 武汉斗鱼网络科技有限公司 Method and related device for obfuscating data
CN112449204B (en) * 2019-08-30 2022-09-09 武汉斗鱼网络科技有限公司 Method and related device for obfuscating data
CN110929270A (en) * 2019-10-29 2020-03-27 北京芯盾集团有限公司 Information security encryption method and device
CN111314351A (en) * 2020-02-19 2020-06-19 望海康信(北京)科技股份公司 Anti-crawler data processing method and device, electronic equipment and storage medium

Also Published As

Publication number Publication date
CN109067805B (en) 2021-07-23

Similar Documents

Publication Publication Date Title
CN109067805A (en) Anti- crawler method, apparatus, terminal and the readable medium of direct broadcasting room data
EP2830282B1 (en) Storage method, system and apparatus
CN103763319B (en) Method for safely sharing mobile cloud storage light-level data
CN110650010B (en) Method, device and equipment for generating and using private key in asymmetric key
Han et al. A data sharing protocol to minimize security and privacy risks of cloud storage in big data era
GB2533279B (en) Secure media player
Huang et al. Secure data group sharing and dissemination with attribute and time conditions in public cloud
US20230025052A1 (en) Method and system for securing data
JP2009526322A (en) Secure digital content management using change identifiers
US8619978B2 (en) Multiple account authentication
WO2018165835A1 (en) Cloud ciphertext access control method and system
US11681499B2 (en) Data set including a secure key
Tayade Mobile cloud computing: Issues, security, advantages, trends
Rani et al. Enhanced data storage security in cloud environment using encryption, compression and splitting technique
Qinlong et al. Improving security and efciency for encrypted data sharing in online social networks
Reshma et al. Pairing-free CP-ABE based cryptography combined with steganography for multimedia applications
JP2007095077A (en) Secure recoverable password
CN1443421A (en) Secure digital content delivery system and method over broadcast network
Ramachandran et al. Secure and efficient data forwarding in untrusted cloud environment
JP4891933B2 (en) Access control device, access control method and program
CN111382451A (en) Security level identification method and device, electronic equipment and storage medium
CN103685239A (en) Real-time encryption and decryption system and real-time encryption and decryption method for mobile products
Thatmann et al. A secure DHT-based key distribution system for attribute-based encryption and decryption
Dudiki et al. A Hybrid Cryptography Algorithm to Improve Cloud Computing Security
KR101812311B1 (en) User terminal and data sharing method of user terminal based on attributed re-encryption

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