CN110399578A - Page access method and device - Google Patents

Page access method and device Download PDF

Info

Publication number
CN110399578A
CN110399578A CN201810344719.5A CN201810344719A CN110399578A CN 110399578 A CN110399578 A CN 110399578A CN 201810344719 A CN201810344719 A CN 201810344719A CN 110399578 A CN110399578 A CN 110399578A
Authority
CN
China
Prior art keywords
page
webpage
data packet
service end
access
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
CN201810344719.5A
Other languages
Chinese (zh)
Other versions
CN110399578B (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.)
Tencent Technology Shenzhen Co Ltd
Original Assignee
Tencent 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 Tencent Technology Shenzhen Co Ltd filed Critical Tencent Technology Shenzhen Co Ltd
Priority to CN201810344719.5A priority Critical patent/CN110399578B/en
Publication of CN110399578A publication Critical patent/CN110399578A/en
Application granted granted Critical
Publication of CN110399578B publication Critical patent/CN110399578B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Landscapes

  • Information Transfer Between Computers (AREA)

Abstract

The present invention relates to a kind of page access method and devices, the page access method includes: during client provides primary page online access by primary channel, web access requests are received, the web access requests indicate the webpage of the client request access;Proprietary protocol encapsulation is carried out to the web access requests, and the data packet that encapsulation obtains is transmitted to by agency service end by the primary channel;It controls the business service end that the agency service end is indicated to the data packet and forwards the data packet;Receive the page resource that the business service end is returned by parsing the data packet, according to the page resource carry out the web access requests indicated by webpage online access.Solve the problems, such as that development cost is excessively high in the prior art using page access method and device provided by the present invention.

Description

Page access method and device
Technical field
The present invention relates to field of computer technology more particularly to a kind of page access method and devices.
Background technique
With the development of computer technology, all kinds of app for providing different function for user are come into being, are met with this The diversified demand of user.
Provided function is applied in order to further enrich app, developer using the primary page for user in addition to providing Except app intrinsic function, also showed using webpages such as H5 (HTML5, hypertext markup language the 5th edition) pages more Information, especially some of short duration rich and changeful information are provided with the online access by webpage for user more additional Function.
Currently, developer need to develop different channels with and meanwhile support the primary page and webpage, this is resulted in as branch Additional channel exploitation must be carried out by holding webpage, and then cause development cost excessively high.
Summary of the invention
In order to solve the above-mentioned technical problem, it is an object of the present invention to provide a kind of page access method and devices.
Wherein, the technical scheme adopted by the invention is as follows:
A kind of page access method, comprising: during client provides primary page online access by primary channel, Web access requests are received, the web access requests indicate the webpage of the client request access;To the web page access Request carries out proprietary protocol encapsulation, and the data packet that encapsulation obtains is transmitted to agency service end by the primary channel;Control It makes the business service end that the agency service end is indicated to the data packet and forwards the data packet;Receive the business service end The page resource returned by parsing the data packet, according to indicated by the page resource progress web access requests The online access required parameter required parameter of webpage.
A kind of page access method, comprising: receive client and providing primary page online access mistake by primary channel The data packet of primary channel transfer described in Cheng Zhongcong, the data packet are to carry out proprietary protocol to web access requests to encapsulate to obtain , the web access requests indicate the webpage of the client request access;Obtain the business service of the data packet instruction Hold the agreement tenability information stored in agency service end;It is the business service according to the agreement tenability information End executes the forward process of the data packet;It receives the business service end and is provided by parsing the page that the data packet returns Source, and the online access that the page resource is sent to webpage indicated by web access requests described in the client executing is asked Seek parameter.
A kind of page access device, comprising: request receiving module provides the primary page by primary channel for client During online access, web access requests are received, the web access requests indicate the net of the client request access Page;Protocol encapsulation module for carrying out proprietary protocol encapsulation to the web access requests, and will be sealed by the primary channel It fills obtained data packet and is transmitted to agency service end;Forwarding module is controlled, for controlling the agency service end to the data The business service end of packet instruction forwards the data packet;Page access module passes through parsing for receiving the business service end The data packet and the page resource returned, according to the page resource carry out the web access requests indicated by webpage Line access request parameters required parameter.
A kind of page access device, comprising: packet-receiving module is provided for receiving client by primary channel From the data packet of the primary channel transfer during primary page online access, the data packet is that basis asks web page access It asks and carries out what proprietary protocol encapsulated, the web access requests indicate the webpage of the client request access;Ability letter Breath obtains module, the agreement tenability that the business service end for obtaining the data packet instruction stores in agency service end Information;Forward process module, for being that the business service end executes the data packet according to the agreement tenability information Forward process;Resource return module, the page returned for receiving the business service end by parsing the data packet Resource, and the page resource is sent to the online access of webpage indicated by web access requests described in the client executing Required parameter.
A kind of page access device, including processor and memory are stored with computer-readable instruction on the memory, The computer-readable instruction realizes page access method as described above when being executed by the processor.
A kind of computer readable storage medium, is stored thereon with computer program, and the computer program is held by processor Page access method as described above is realized when row.
In the above-mentioned technical solutions, client is during providing primary page online access by primary channel, to asking It asks parameter to receive web access requests and carries out proprietary protocol encapsulation, transmitted with the data packet for being obtained encapsulation by primary channel To agency service end, and then the business service end that control agent server-side is indicated to data packet forwards the data packet, passes through reception Business service end parses the page resource that data packet returns, with the webpage according to indicated by page resource progress web access requests Online access, that is to say, that by proprietary protocol package request parameter web access requests, so that web access requests indicated The agreement that webpage is supported is consistent with the agreement that the primary page is supported, so that this webpage can be as used in the primary page Primary channel is supported, to avoid the channel to support this webpage development additional, solves existing in the prior art open with this Send out the excessively high problem of cost.
It should be understood that above general description and following detailed description be only it is exemplary and explanatory, not It can the limitation present invention.
Detailed description of the invention
The drawings herein are incorporated into the specification and forms part of this specification, and shows and meets implementation of the invention Example, and in specification together principle for explaining the present invention.
Fig. 1 is the system architecture schematic diagram of the page access method according to involved in the prior art.
Fig. 2 is the schematic diagram of related implementation environment according to the present invention.
Fig. 3 is a kind of hardware block diagram of terminal shown according to an exemplary embodiment.
Fig. 4 is the hardware block diagram at another agency service end shown according to an exemplary embodiment.
Fig. 5 is a kind of flow chart of page access method shown according to an exemplary embodiment.
Fig. 6 be in Fig. 5 corresponding embodiment step 310 in the flow chart of one embodiment.
Fig. 7 be in Fig. 5 corresponding embodiment step 330 in the flow chart of one embodiment.
Fig. 8 be in Fig. 5 corresponding embodiment step 370 in the flow chart of one embodiment.
Fig. 9 is the flow chart of another page access method shown according to an exemplary embodiment.
Figure 10 is the flow chart of another page access method shown according to an exemplary embodiment.
Figure 11 be in Figure 10 corresponding embodiment step 550 in the flow chart of one embodiment.
Figure 12 is the flow chart of another page access method shown according to an exemplary embodiment.
Figure 13 is the system architecture schematic diagram of related page access method according to the present invention.
Figure 14 is a kind of request process timing diagram of page access method in an application scenarios.
Figure 15 is a kind of push process timing diagram of page access method in an application scenarios.
Figure 16 is a kind of block diagram of page access device shown according to an exemplary embodiment.
Figure 17 be in Figure 16 corresponding embodiment request receiving module in the block diagram of one embodiment.
Figure 18 be in Figure 16 corresponding embodiment protocol encapsulation module in the block diagram of one embodiment.
Figure 19 be in Figure 16 corresponding embodiment page access module in the block diagram of one embodiment.
Figure 20 is the block diagram of another page access device shown according to an exemplary embodiment.
Figure 21 is the block diagram of another page access device shown according to an exemplary embodiment.
Figure 22 is to forward processing module in the block diagram of one embodiment in Figure 21 corresponding embodiment.
Figure 23 is the block diagram of another page access device shown according to an exemplary embodiment.
Through the above attached drawings, it has been shown that the specific embodiment of the present invention will be hereinafter described in more detail, these attached drawings It is not intended to limit the scope of the inventive concept in any manner with verbal description, but is by referring to specific embodiments Those skilled in the art illustrate idea of the invention.
Specific embodiment
Here will the description is performed on the exemplary embodiment in detail, the example is illustrated in the accompanying drawings.Following description is related to When attached drawing, unless otherwise indicated, the same numbers in different drawings indicate the same or similar elements.Following exemplary embodiment Described in embodiment do not represent all embodiments consistented with the present invention.On the contrary, they be only with it is such as appended The example of device and method being described in detail in claims, some aspects of the invention are consistent.
As previously mentioned, to support the H5 page that must develop additional channel, and then cause development cost excessively high.
As shown in Figure 1, for the page resource for being compatible with the H5 page and primary page invocation business service end is stored, it is a kind of Page access method is that CGI layers and Dispatcher layers are disposed in business service end, with what is supported by CGI layers webpage Http protocol carries out translation proxy, and by the agency of the Dispatcher layers of primary page of progress, in order to business service end to The terminal that client is run returns to page resource corresponding to the primary page requested access to or the webpage requested access to.
Described herein to be, CGI layers and Dispatcher layers are substantially the client being deployed in business service end, area The client not run in terminal just can take as CGI layers and Dispatcher layers run on business service end for business Business end executes conversion of page agency service.
The above method realizes the separation of the primary page and webpage, under the premise of guaranteeing that proprietary protocol is safe and efficient, also Supported web page simultaneously, but carry out supported web page due to extraly developing CGI layers, cause development efficiency low, causes development cost It is high.
Based on this, the prior art additionally provides a kind of page access method of simple possible, even primary page object web page It draws close, that is to say, that the primary page and webpage all support http protocol, although channel need not additionally be developed, development efficiency is high, simultaneous Capacitive is strong, but excessively too fat to move agreement causes often to connect realization difficulty, and safety is poor.
For this purpose, spy of the present invention proposes a kind of page access method, the additional exploitation in channel is not only avoided, is effectively reduced Development cost, and it is highly-safe, and correspondingly, page access device corresponding to this kind of page access method, which is deployed in, to be had In the electronic equipment of von Neumann system, for example, electronic equipment can be smart phone, server etc., herein without limiting.
Fig. 2 is a kind of schematic diagram of implementation environment involved in page access method.The implementation environment include terminal 100, Agency service end 200 and business service end 300.
Wherein, terminal 100 can be desktop computer, laptop, tablet computer, smart phone or other it is any can For initiating the electronic equipment of the client operation of web access requests, it is not defined herein.Wherein, web page access is initiated to ask The client asked can be the end app, be also possible to web terminal.
Page resource corresponding to webpage is stored in business service end 300, is carried out for client according to page resource The online access of corresponding webpage.
Routing addressing is responsible at agency service end 200, when client request carries out the online access of webpage, to this webpage pair Business service end 300 where answering page resource requests to return to the page resource, and then the page resource of return is sent to visitor Family end, and the online access that client carries out corresponding webpage is controlled according to the page resource.
Certainly, according to the needs actually operated, agency service end 200 and business service end 300 can be under the jurisdiction of different Server cluster also may be integrally incorporated to same server, so that thus same server provides for the online access service of webpage.
Referring to Fig. 3, Fig. 3 is a kind of block diagram of terminal shown according to an exemplary embodiment.
It should be noted that the terminal, which is one, adapts to example of the invention, it must not believe that there is provided to this hair Any restrictions of bright use scope.The terminal can not be construed to need to rely on or must have shown in Fig. 3 to show One or more component in the terminal 100 of example property.
As shown in figure 3, terminal 100 (only shows one including memory 101, storage control 103, one or more in Fig. 3 It is a) processor 105, Peripheral Interface 107, radio-frequency module 109, locating module 111, photographing module 113, audio-frequency module 115, touch-control Screen 117 and key module 119.These components are mutually communicated by one or more communication bus/signal wire 121.
Wherein, memory 101 can be used for storing computer program and module, such as the page in exemplary embodiment of the present The corresponding computer-readable instruction of method and device and module are asked in interview, and processor 105 is stored in memory 101 by operation Computer-readable instruction, thereby executing various functions and data processing, i.e. completion page access method.
The carrier that memory 101 is stored as resource, can be random access memory, for example high speed random access memory, it is non-easily The property lost memory, such as one or more magnetic storage devices, flash memory or other solid-state memories.Storage mode can be short Temporary storage permanently stores.
Peripheral Interface 107 may include an at least wired or wireless network interface, at least one series-parallel translation interface, at least One input/output interface and at least USB interface etc., for coupleeing memory 101 for external various input/output devices And processor 105, to realize the communication with external various input/output devices.
Radio-frequency module 109 is used for transceiving electromagnetic wave, the mutual conversion of electromagnetic wave and electric signal is realized, to pass through communication network Network is communicated with other equipment.Communication network includes cellular telephone networks, WLAN or Metropolitan Area Network (MAN), above-mentioned communication network Various communication standards, agreement and technology can be used in network.
Locating module 111 is used to obtain the geographical location of terminal 100 being currently located.The example of locating module 111 includes But it is not limited to GPS (GPS), the location technology based on WLAN or mobile radio communication.
Photographing module 113 is under the jurisdiction of camera, for shooting picture or video.The picture or video of shooting can be deposited In storage to memory 101, host computer can also be sent to by radio-frequency module 109.
Audio-frequency module 115 provides a user audio interface, may include one or more microphone interfaces, one or more Speaker interface and one or more earphone interfaces.The interaction of audio data is carried out by audio interface and other equipment.Sound Frequency can also be sent according to can store to memory 101 by radio-frequency module 109.
Touch Screen 117 provides an I/O Interface between terminal 100 and user.Specifically, user can pass through Touch Screen 117 carries out the gesture operations such as input operation, such as click, touch, sliding, so that terminal 100 operates the input It is responded.Any one form of text, picture or video or combination are then formed by output content and passed through by terminal 100 Touch Screen 117 shows to user and exports.
Key module 119 includes at least one key, to provide user's interface inputted to terminal 100, user Terminal 100 can be made to execute different functions by pressing different keys.For example, sound regulating key is for user's realization pair The adjusting for the wave volume that terminal 100 plays.
It is appreciated that structure shown in Fig. 3 is only to illustrate, terminal 100 may also include more more or fewer than shown in Fig. 3 Component, or with the component different from shown in Fig. 3.Each component shown in Fig. 3 can use hardware, software or a combination thereof To realize.
Fig. 4 is the hardware block diagram at another agency service end shown according to an exemplary embodiment.It needs to illustrate , which is one and adapts to example of the invention, must not believe that there is provided use model to of the invention Any restrictions enclosed.The agency service end can not be construed to need to rely on or must have exemplary shown in Fig. 4 Agency service end 200 in one or more component.
The hardware configuration at the agency service end 200 can generate biggish difference due to the difference of configuration or performance, such as Fig. 4 Shown, agency service end 200 includes: power supply 210, interface 230, at least a memory 250 and an at least central processing unit (CPU,Central Processing Units)270。
Wherein, power supply 210 is used to provide operating voltage for each hardware device on agency service end 200.
Interface 230 includes an at least wired or wireless network interface 231, at least a string and translation interface 233, at least one defeated Enter output interface 235 and at least USB interface 237 etc., is used for and external device communication.
The carrier that memory 250 is stored as resource, can be read-only memory, random access memory, disk or CD Deng the resource stored thereon includes operating system 251, application program 253 and data 255 etc., and storage mode can be of short duration It stores or permanently stores.Wherein, operating system 251 be used for manage and control agent server-side 200 on each hardware device with And application program 253 can be Windows to realize calculating and processing of the central processing unit 270 to mass data 255 ServerTM, Mac OS XTM, UnixTM, LinuxTM, FreeBSDTM etc..Application program 253 be based on operating system 251 it The upper computer program for completing at least one particular job, may include an at least module (being not shown in Fig. 4), each module The series of computation machine readable instruction to agency service end 200 can be separately included.Data 255 can be stored in disk In photo, picture etc..
Central processing unit 270 may include the processor of one or more or more, and be set as through bus and memory 250 communications, for the mass data 255 in operation and processing memory 250.
As described in detail above, being applicable in agency service end 200 of the invention will be deposited by the reading of central processing unit 270 The form of the series of computation machine readable instruction stored in reservoir 250 completes page access method.
In addition, also can equally realize the present invention by hardware circuit or hardware circuit combination software, therefore, this hair is realized The bright combination for being not limited to any specific hardware circuit, software and the two.
Referring to Fig. 5, in one exemplary embodiment, a kind of page access method is suitable for implementation environment shown in Fig. 2 The structure of terminal, the terminal can be as shown in Figure 3.
This kind of page access method can be executed by terminal, may comprise steps of:
Step 310, it during client provides primary page online access by primary channel, receives web page access and asks It asks.
Wherein, web access requests, indicate the webpage of client request access, this webpage is different from client request visit The primary page request parameter asked.
Thus, it should be noted that the primary page, be it is intrinsic in client, the online access of this primary page is logical Cross the primary channel realization for being deployed in client.
For the diversified demand for meeting user, the process of primary page online access is provided by primary channel in client In, will also receive client incessantly is the web access requests for providing webpage online access and being initiated, so that business takes Business end is able to respond this web access requests and provides the online access service of webpage to client.
Further, web access requests, the webpage in addition to being used to indicate client request access, are also used to indicate this net The routing iinformation at business service end, login state information, data domain information, safety check information etc. where page corresponding page resource Deng.It is also understood that web access requests, which include at least, requests access to the relevant page data of webpage and required parameter.Its In, page data indicates the webpage requested access to, and required parameter then includes business service where this webpage corresponding page resource The routing iinformation at end logs in state information, data domain information, safety check information etc..
Step 330, proprietary protocol encapsulation, and the data for encapsulation being obtained by primary channel are carried out to web access requests Packet is transmitted to agency service end.
Proprietary protocol is different from http protocol, is that application developers are customized according to actual business demand, for its institute The intrinsic primary page is supported in the client of exploitation.Correspondingly, primary channel is the primary page to meet proprietary protocol Face corresponds to the channel that data packet executes data transmission.Based on this, the online access of webpage will also be met by primary channel The transmission of the webpage corresponding data packet of proprietary protocol, with this is avoided supported web page and additional exploitation channel.
For this purpose, the web access requests got are just encapsulated according to proprietary protocol after getting web access requests, And by primary channel be that the obtained data packet of encapsulation executes data transmission, so that business service end is able to respond this web page access It requests and provides the online access service of webpage indicated by web access requests for client.
Step 350, the business service end that control agent server-side is indicated to data packet forwards data packet.
As previously mentioned, data packet is to be encapsulated by web access requests according to proprietary protocol, and in web access requests The routing iinformation at business service end where required parameter includes at least instruction webpage corresponding page resource.Therefore, pass through data packet Just it can know that client is to request access to webpage data packet generated actually which business service end be transmitted to.
For agency service end, corresponding terminal is mostly magnanimity, can receive each terminal incessantly Client wherein to run provides data packet transmitted by webpage online access, and carries out data packet according to the instruction of data packet Forwarding.
That is, being magnanimity with the deployment at agency service end between the run terminal of client and business service end Data packet provides level-one forwarding capability, ensure that the smoothness of data transmission with this, simultaneously effective alleviates business service The data processing pressure at end.
Step 370, the page resource that business service end is returned by parsing data packet is received, is carried out according to page resource The online access of webpage indicated by web access requests.
It should be appreciated that then being visited by webpage since the required parameter in web access requests has included at least data domain information Ask the data packet that encapsulates according to proprietary protocol of request, necessarily indicative webpage corresponding page resource is in business service end Storage location.
Based on this, for business service end, after receiving the data packet forwarded by agency service end, just can Resolve packet is carried out according to the proprietary protocol that it is supported, the storage location of webpage corresponding page resource is known with this, in turn The page resource for requesting access to webpage is correspondingly obtained according to the storage location.
For client, the page resource of business service end return will be received, and realize and asked with this Seek the online access of access webpage.
Specifically, by primary channel reception page resource, since the page resource that primary channel is transmitted is to meet Proprietary protocol, and the page resource for being used for web displaying needs to meet JSON syntax rule, for this purpose, the page resource received Protocol conversion process will be carried out, in order to which client carries out web displaying according to the page resource after conversion process, and then will be realized The online access of webpage.
By process as described above, primary channel is realized to the compatibility of the primary page and webpage, avoids additionally developing Business service end is not only developed without coupling in the channel of supported web page, but also primary channel is not deposited by client deployment In intrusion problem, development efficiency is thus greatly increased, development cost is low.
Referring to Fig. 6, in one exemplary embodiment, step 310 may comprise steps of:
Step 311, operation is directed toward according to the page that triggering carries out and obtains the corresponding domain of webpage indicated by web access requests Name information.
Client is additionally arranged the corresponding access entrance of webpage, and the online access of webpage is realized with this.When user wishes When accessing the webpage, just the online access that operation carries out the webpage can be directed toward by the page triggered in the access entrance.
Based on this, the page is directed toward operation, substantially refers to that the direction of access entrance triggering requests access to the operation of webpage, It is to be understood that the page, which is directed toward operation, has been directed toward the webpage to access desired by user.The page is directed toward operation according to client The difference for holding run terminal, will correspondingly be varied, for example, the page is directed toward operation when client runs on smart phone It can be the single operations such as click, sliding, long-pressing or a series of gesture operation etc. formed by single operations, client When running on laptop, the page be directed toward operation then can be by the input units such as mouse or keyboard manipulated click, The operations such as double-click, dragging, herein and are not limited.
For example, in the Touch Screen provided by smart phone, the corresponding access entrance of webpage is a virtual graph Mark, the virtual icon, i.e. expression user desire access to webpage pointed by the virtual icon when the user clicks, wherein the click Operation is that user triggers the page direction operation carried out.
In an embodiment in the specific implementation, the page, which is directed toward operation, to be detected by event sniffer.
From the foregoing, it will be observed that being operated when detecting that the page for triggering progress in access entrance is directed toward, just can be referred to according to the page The webpage carried out to operation, which is directed toward, knows that the page is directed toward the pointed webpage of operation, and then correspondingly obtains the corresponding domain of the webpage Name information.
Wherein, domain-name information corresponds to storage location of the web page resources in business service end for uniquely identifying webpage. That is, when being webpage when business service end carries out corresponding web page resources storage, it can be according to the IP at the business service end Address uniquely generates the domain-name information of webpage, in order to obtain when the subsequent webpage online access.
Step 313, the calling authorization check of webpage is carried out to the domain-name information got according to white list.
Wherein, the calling permission of webpage refers to that webpage calls specified interface to execute the incoming permission of required parameter.
White list is stored in the terminal that client is run, for verifying the calling permission of webpage.That is, only It is present in webpage corresponding to the domain-name information in white list, just has and call permission, that is, allows that specified interface execution is called to ask Ask the incoming of parameter.
For this purpose, allowing that specified interface is called to execute the incoming webpage of required parameter, all stored in white list corresponding Domain-name information.
It follows that the calling authorization check of webpage, is to carry out matching to the domain-name information of webpage in white list to search Rope.If searching the domain-name information to match with the domain-name information of webpage in white list, then it is assumed that webpage is by calling permission Verification, and then go to step 315.
, whereas if the domain-name information searched in white list is mismatched with the domain-name information of webpage, then it is assumed that webpage By calling authorization check, the webpage just can not call specified interface to execute required parameter incoming as a result, and then also not It cannot achieve the online access of webpage.
Step 315, authorization check is called when webpage passes through, calls specified interface to execute required parameter for webpage and is passed to, leads to It crosses incoming required parameter and generates the web access requests.
As previously mentioned, required parameter includes but is not limited to: the road at business service end where instruction webpage corresponding page resource By information and login state information, data domain information, safety check information etc..
This required parameter requests access to the online access of webpage for combining page data realization.For carry out webpage Line access will configure corresponding required parameter and page data by webpage thus, and then by required parameter and page data come real The online access of existing webpage.
It should be appreciated that webpage is different, the required parameter and page data configured by webpage is by different from.It is right as a result, For the client that webpage online access function is provided, when client installation and deployment are when terminal, provided and existed by the client The webpage of line access, corresponding required parameter are the page data associated storage with this webpage in configuration file, in order to The subsequent required parameter according in configuration file and associated page data realize the online access of corresponding web page.
When requesting access to webpage, that is, know the page data of this webpage, and then can be according to the page data of this webpage The required parameter that access webpage is configured is made requests in configuration file to search, and thus obtains the request ginseng for requesting access to webpage Number.
In an embodiment in the specific implementation, required parameter calls specified interface to be passed to by configuration file.For example, referring to Stationary interface can be to be previously deployed in client by the JSBridge technology for providing the primary page and webpage interaction.
After obtaining the required parameter and associated page data that webpage is configured, just can according to required parameter and Associated page data generation indicates the web access requests for requesting access to this webpage.
Under the action of above-described embodiment, the calling permission for making webpage is constrained by white list, i.e., only white list is specified Webpage just allow that specified interface is called to execute required parameter incoming, and then specified interface is avoided to be exposed to unsafe webpage, To fully ensure that the safety of webpage online access.
Referring to Fig. 7, in one exemplary embodiment, step 330 may comprise steps of:
Step 331, web access requests filling is carried out according to the data format of proprietary protocol, generates data packet.
As previously mentioned, proprietary protocol is that application developers are customized according to actual business demand, it is understood that be, Proprietary protocol be for realize the online access of webpage and to the rule that client and business service end are formulated, as long as then client This rule is abided by with business service end, just can be realized the online access of webpage.
For this purpose, for client, just being needed prepared in accordance with proprietary protocol after obtaining web access requests Rule correspondingly handles web access requests, in order to the identification of business service end rule according to specified by proprietary protocol The web access requests out, and then respond this web access requests and execute and subsequently handle.
Specifically, firstly, requesting access to the page data of webpage and associated by extracting in web access requests Required parameter.
For this purpose, the data format of proprietary protocol, be in web access requests required parameter and page data in data Filling position in packet is specified, as a result, required parameter and page data can be filled according to specified filling position to Data packet realizes the filling of web access requests with this.The filling of web access requests to be done, that is, correspondingly generate data Packet.
Step 333, an assignment is marked according to the webpage that web access requests indicate, and the marker bit of assignment is added To data packet.
As previously mentioned, primary channel while the compatible primary page and webpage, in other words, data packet corresponding to the primary page Primary channel transfer to business service end can be passed through with data packet corresponding to webpage.
Based on this, marker bit, being used to indicate the data packet transmitted in primary channel is the corresponding primary page or webpage.Example Such as, when marker bit is assigned a value of 1, indicate that the data packet transmitted in primary channel is corresponding webpage, and when marker bit is assigned a value of 0, refer to Show that the data packet transmitted in primary channel is the corresponding primary page.
Certainly, the assignment of marker bit can be flexibly set according to the actual demand of application scenarios, can also be other words Symbol, for example, true indicates webpage, and false indicates primary page etc., and the present embodiment is limited not to this.
From the foregoing, it will be observed that after reception of the data packet, just can increase according in data packet for business service end Marker bit, actually or know primary page webpage corresponding to the data packet, in order to according to corresponding to data packet Different objects execute different dissection process, and then return to corresponding page resource, so that client carries out the online visit of webpage It asks.
Step 335, data packet is transmitted to agency service end by primary channel.
Under the action of above-described embodiment, for primary channel, the compatible primary page and webpage provide foundation simultaneously, in turn It ensure that the webpage online access based on primary channel.
Referring to Fig. 8, in one exemplary embodiment, step 370 may comprise steps of:
Step 371, protocol conversion process is carried out to page resource.
For client, carry out web displaying and need to meet JSON syntax rule, and its pass through it is primary Channel reception to page resource then meet proprietary protocol.
For this purpose, needing to carry out protocol conversion process to the page resource received, that is, right before carrying out web displaying Page resource provided according to JSON syntax rule to the page by proprietary protocol to the conversion of JSON syntax rule in order to subsequent Source carries out page rendering.
Step 373, page rendering is carried out according to the page resource after conversion process, web page access is shown by page rendering The indicated webpage of request.
Page rendering, including but not limited to: user interface element is carried out in webpage (for example, virtual icon, virtual push button Etc.) layout, coloring, display.
As a result, after carrying out page rendering according to page resource, user can view user shown in webpage Interface element, and then realize by the relevant operation triggered to user interface element the online access to webpage.
For example, webpage, which provides red packet for user, gets function, then red packet is considered as user interface element shown in webpage, And then user can trigger opening operation to the red packet being shown in webpage, thus complete red packet and get, realize to webpage Online access.
Under the cooperation of above-described embodiment, " request-response " mode is provided for webpage, so that webpage is by primary channel It obtains by the full request channel capacity of client to business service end, is convenient to client upgrading, is further conducive to mention High development efficiency realizes lower development cost.
Referring to Fig. 9, in one exemplary embodiment, method as described above can with the following steps are included:
Step 410, in the online access of webpage indicated by web access requests, subscription identity registration is carried out for webpage, and It is registered by subscription identity and wakes up the corresponding subscription list of webpage.
In the online access of webpage, the subscription information of business service end push will be received, and then subscription information is shown In the webpage accessed, more rich and changeful information are showed to user with this, so that user is able to enjoyment webpage and is provided It is more multi-functional.
Subscription identity is to be uniquely identified with character style to subscription information, in order to which differentiated service server-side pushes away The magnanimity subscription information sent.That is, subscription information is different, corresponding to subscription identity it is also different.
As previously mentioned, the subscription information that business service end is pushed is magnanimity, so that visitor during webpage online access Family end will constantly receive subscription information, it should be understood that subscription information shown in webpage can be only that the webpage is specified.
Based on this, after web displaying, that is, it is notified which its specified subscription information of client is, then, for For client, it can be filtered out specified by the webpage in the subsequent magnanimity subscription information pushed from business server-side Subscription information.
In the present embodiment, subscription information specified by client terminal web page will be notified by subscription identity registration.
Subscription identity registration refers to that the subscription identity by subscription information specified by webpage is stored to corresponding and subscribes to column The subscription identity of table, the subscription information only pushed as a result, when business service end is present in the corresponding subscription list of webpage, the subscription Information can just be shown in webpage.
It should be noted that subscription identity registration, is carried out during the online access of webpage, is i.e. web displaying Subscription identity registration can be initiated, as a result, if webpage is not shown, client can not know that subscription specified by the webpage is believed Breath, even if business service end has pushed subscription information specified by the webpage, client will not push to the subscription information Webpage is shown.
From the foregoing, it will be observed that, even if business service end has carried out subscription information push, client will not if webpage is not shown Subscription information is pushed into webpage, as a result, for webpage provide subscription identity registration subscription list at this time will in a dormant state, Correspondingly, client need not also carry out the subscription information that business service end pushes according to subscription list in a dormant state It monitors.
Once client has carried out the online access of webpage, it is necessary to for the subscription letter of webpage monitoring service server-side push Breath, is shown in order to which subscription information specified by webpage is pushed to webpage.For this purpose, when for webpage in subscription list into It has gone subscription identity registration, will wake up subscription list in a dormant state for webpage.
It remarks additionally herein, subscription list can be as the configuration of each webpage, can be in the present embodiment It is to be configured for client, i.e., for all webpages that client provides, subscription list has and only one, at this point, with The display and closing of any one webpage, the List Identification in subscription list will update therewith, guarantee the subscription waken up column with this Subscription identity is specified by the webpage that is currently accessing, herein without limiting in table.
Step 430, the subscription information transmitted in primary channel is monitored according to the subscription list of wake-up.
Specifically, monitor, be in the subscription list according to wake-up subscription identity judge that business service end is pushed Whether the subscription identity of subscription information belongs to the subscription list of wake-up.
If the subscription identity for listening to subscription information belongs to the subscription list of wake-up, illustrate that subscription information is webpage institute Specified, and then execute step 450.
, whereas if do not hear the subscription identity for belonging to subscription list, then illustrate not yet to receive that webpage is specified to be ordered Message is read, and then continues to execute step 430.
Step 450, when the subscription identity for listening to subscription information belongs to subscription list, triggering webpage readjustment carries out subscription letter The displaying of breath.
In above process, in addition to " request-response " mode, " server-side push " mode also is provided for webpage, so that Webpage obtains the complete push channel ability by business service end to client by primary channel, is conducive to meet user's Diversified demand is further conducive to improve development efficiency, realizes lower development cost.
Referring to Fig. 10, in one exemplary embodiment, a kind of page access method is suitable for implementation environment shown in Fig. 1 The structure at agency service end, the agency service end can be as shown in Figure 4.
This kind of page access method can be executed by the agency service end, may comprise steps of:
Step 510, client is received during providing primary page online access by primary channel from primary channel The data packet of transmission, data packet are to carry out proprietary protocol to web access requests to encapsulate, web access requests instruction visitor The webpage that family end requests access to.
Step 530, the agreement tenability letter that the business service end of data packet instruction stores in agency service end is obtained Breath.
As previously mentioned, primary channel realizes the compatibility to the primary page and webpage, it is possible to the two be caused to be supported Agreement and the asymmetric problem in business service end, that is to say, that the business service end having can support analyzing web page and original simultaneously The corresponding data packet of the life page, and some business service ends can also only be supported to parse the corresponding data packet of the primary page.
For this purpose, agreement tenability, indicates whether business service end has the ability to parse the data packet received Processing.
For agency service end, when business service end is disposed, can with for deployment business service end into The registration of row agreement tenability, is consequently formed agreement tenability information, in order to subsequent true according to agreement tenability information Determine the agreement tenability at business service end, and then executes according to the agreement tenability at business service end at the forwarding of data packet Reason.
It step 550, is the forward process of business service end execution data packet according to agreement tenability information.
Forward process can be and directly forward for the business service end with resolve packet ability, is also possible to needle Business service end agency's forwarding to not having resolve packet ability.
Wherein, agency's forwarding refers to the data packet progress protocol conversion process that business service end is not supported to first parsing, It is to be converted that the data packet of parsing is supported by business service end and then carries out the forwarding of data packet.
It will need to register what it was supported by business service end for carrying out the protocol conversion process of data packet based on this Agreement, in order to be able to protocol conversion process be carried out to data packet according to the agreement that it is supported.
In an embodiment in the specific implementation, as shown in figure 11, step 550 be may comprise steps of:
Step 551, if parsing data packet is supported at agreement tenability information instruction business service end, data packet is forwarded To business service end.
Step 553, if parsing data packet is not supported at agreement tenability information instruction business service end, according to business The agreement that server-side is supported carries out protocol conversion process to data packet, and the data packet after conversion process is sent to business service End.
Under the action of above-described embodiment, the adaptation of the transition to new and old business service end is realized, can either be adapted to simultaneously The new business services end for supporting analyzing web page and primary page corresponding data packet can also be adapted to and only support to parse the primary page pair The old service server-side of data packet is answered, with the compatible different agreement of this perfection and the asymmetric problem in business service end, is conducive to new The smooth transition of old service server-side has stronger versatility and applicability.
Step 570, the page resource that business service end is returned by parsing data packet is received, and page resource is sent To the online access of webpage indicated by client executing web access requests.
By realizing process as described above, general-purpose proxy is provided by agency service end, avoids carrying out volume for supported web page Outer development realizes the compatible effect of primary development, efficiently solves the problems, such as that development cost is excessively high.
Please refer to Figure 12, in one exemplary embodiment, before step 550, method as described above can also include with Lower step:
Step 610, the check information corresponding to data packet is found from protocol registration file.
It should be appreciated that the function as provided by different webpages is different, safety possessed by different web pages is wanted Also different from is sought, for example, the security requirement for providing the webpage of payment function, which is higher than, provides the webpage that red packet gets function Security requirement.
For this purpose, protocol registration file, is stored in agency service end, it is used to indicate which net agency service end needs for Page carries out proof of identity to the client for initiating web access requests.For agency service end, received by data Packet is to carry out proprietary protocol according to the required parameter for requesting access to webpage to encapsulate, for this purpose, proof of identity substantially may be used To be considered to the client progress for sending webpage corresponding data packet.
Based on this, client is that its provided each webpage stores corresponding verification letter in protocol registration file Breath, this check information correspond to data packet, this check information be indicate send corresponding data packet client whether need into Row proof of identity.
Before carrying out data packet forwarding, corresponding check information can be carried out in protocol registration file according to this data packet Lookup, and then obtain indicating whether the check information that proof of identity is carried out to the client for sending this data packet.
If check information instruction does not need to carry out proof of identity to the client for sending data packet, execution step is jumped 550。
, whereas if check information instruction needs to carry out proof of identity to the client for sending data packet, then execution is jumped Step 630.
Step 630, when check information instruction needs to carry out proof of identity to the client for sending data packet, from data packet Extract the token for being distributed to client.
Step 650, the proof of identity that client is carried out according to the key that token carries, when client passes through proof of identity Execute the forward process of data packet.
Token is that client is periodically issued in effective period of time, for carrying out the proof of identity of client.
For example, client identification uniquely identifies the identity of client, and client is just close according to what is carried in token Key encrypts client identification, and then is sent to agency service end by primary channel by data packet.
For agency service end, before carrying out data packet forwarding, first know needs to the transmission number by check information After carrying out proof of identity according to the client of packet, just from extracting the key carried in token in data packet, and decrypted with this To client identification, to demonstrate the identity for sending the client of the data packet.
Under the action of above-described embodiment, fully ensure that data packet by client to the peace transmitted between business service end Quan Xing, and then effectively ensured the safety of webpage online access.
Figure 13~Figure 15 is a kind of specific implementation schematic diagram of page access method in an application scenarios.The application scenarios In, realize that the system architecture of page access method includes terminal, agency service end and business service end Server.Wherein, it initiates The client of web access requests is run in this terminal, this client is the end app, and the webpage requested access to is the H5 page.
Level is further divided, as shown in figure 13, terminal includes H5 layers and Client Agent layer, wherein H5 layers are responsible for The H5 page shows that Client Agent layer then disposes the promising H5 page and provides the REQ-Proxy layer of " request-response " mode, is H5 The Push-Proxy layer and primary channel Native-SDK of page offer " server-side push " mode.
It is responsible for the forwarding of data packet corresponding to the H5 page, including Dispatcher layers and Proxy layers in agency service end.
In the system architecture, CGI layers of exploitation is avoided, but is realized by Client Agent layer to the primary page and H5 pages The perfection in face is compatible, greatly reduces development, reduces exploitation manpower, improve development efficiency, thus realize exploitation at This is low.
In addition, decoupling the relationship between agreement and business service end, and base by Client Agent layer and agency service end Proxy layer in agency service end effectively solves the old service server-side transition problem compatible to the H5 page.
In conjunction with Figure 14~Figure 15, to each level of system architecture in Figure 13, realization of functions is subject in page access method It is described as follows.
As shown in figure 14, H5 layers of acquisition web access requests, and encapsulate to obtain by REQ-Proxy layers of progress proprietary protocol Data packet, and then it is transmitted to by primary channel Native-SDK the Dispatcher layer at agency service end.
Dispatcher layers are responsible for data packet and carry out routing addressing, determine business service end to be forwarded, and according to this The agreement tenability at business service end judges whether notice Proxy layer proxy forwarding (as shown in Figure 14 dotted line), or by certainly Body directly forwards, and then initiates web access requests to business service end Server by forwarding client, so that business service End Server correspondingly returns to the page resource of the H5 page.
For the Server of business service end, then after receiving the data packet of forwarding, the association that is supported according to it After view carries out dissection process, H5 layers of corresponding page resource are returned to, so that H5 layers according to the aobvious of the page resource execution H5 page Show, and then realizes the online access of the H5 page.
Wherein, the Returning process of page resource is equivalent to the inverse process of H5 accessing page request process, herein no longer in detail Description.
As shown in figure 15, as the H5 page is shown in H5 layers, the H5 page that Push-Proxy layers are display will be controlled and carried out Subscription identity registration, wakes up the corresponding subscription list of the H5 page with this.
Push-Proxy layers wake up subscription list from dormant state, just start to transmit in primary channel Native-SDK Business service end Server push subscribe to message monitored, and listen to subscribe to message subscription identity belong to wake-up Subscription list when, triggering the H5 page readjustment so that the subscription message that business service end Server is pushed is opened up in the H5 page Show.
In this application scene, pull-push model is provided completely, i.e. the H5 page is obtained by primary channel and completely asked Channel capacity and push channel ability are asked, the multi-protocols parallel processing that page resource returns and subscription message pushes is solved and asks Topic, client end response is more timely, and interactive experience is more preferably.
In addition, the changeable and abundant information displaying of client is no longer limited by client release publication, can quickly expire Sufficient product demand, and can adapt to rapidly project setting and product up-gradation, be effectively guaranteed product renewing iteration ability and Perfect function.
Following is apparatus of the present invention embodiment, can be used for executing page access method according to the present invention.For this Undisclosed details in invention device embodiment please refers to the embodiment of the method for page access method according to the present invention.
Figure 16 is please referred to, in one exemplary embodiment, a kind of page access device 900 is applied to client, including but It is not limited to: request receiving module 910, protocol encapsulation module 930, control forwarding module 950 and page access module 970.
Wherein, request receiving module 910 provides the process of primary page online access by primary channel for client In, web access requests are received, the web access requests indicate the webpage of the client request access.
Protocol encapsulation module 930 is used to carry out web access requests proprietary protocol encapsulation, and will be sealed by primary channel It fills obtained data packet and is transmitted to agency service end.
The business service end forwarding data packet that control forwarding module 950 is indicated for control agent server-side to data packet.
Page access module 970 is used to receive the page resource that business service end is returned by parsing data packet, according to Page resource carries out the online access of webpage indicated by web access requests.
Figure 17 is please referred to, in one exemplary embodiment, request receiving module 910 includes but is not limited to: acquisition of information list Member 911, authorization check unit 913 and parameter are passed to unit 915.
Wherein, information acquisition unit 911, which is used to be directed toward operation according to the page that triggering carries out, obtains web access requests institute Indicate the corresponding domain-name information of webpage.
Authorization check unit 913 is used to carry out the domain-name information got according to white list the calling permission school of webpage It tests.
Parameter is passed to unit 915 and is used to call authorization check when webpage passes through, and calls specified interface to execute request for webpage Parameter is incoming, generates web access requests by incoming required parameter.
Please refer to Figure 18, in one exemplary embodiment, protocol encapsulation module 930 includes but is not limited to: data packet generates Unit 931, marker bit assignment unit 933 and data packet transmission unit 935.
Wherein, data package generating unit 931 is used to carry out web access requests filling according to the data format of proprietary protocol, Generate data packet.
Marker bit assignment unit 933 is used to be marked an assignment according to the webpage that web access requests indicate, and will assign The marker bit of value is added to data packet.
Data packet transmission unit 935 is used to transmit data packet to agency service end by primary channel.
Please refer to Figure 19, in one exemplary embodiment, page access module 970 includes but is not limited to: resource conversion is single Member 971 and page rendering unit 973.
Wherein, resource converting unit 971 is used to carry out protocol conversion process to page resource.
Page rendering unit 973 is used to carry out page rendering according to the page resource after conversion process, passes through page rendering Show the webpage of web access requests instruction.
Figure 20 is please referred to, in one exemplary embodiment, device 900 as described above further includes but is not limited to: subscription registration Module 1010, subscription information monitor module 1030 and page callback module 1050.
Wherein, in online access of the subscription registration module 1010 for webpage indicated by web access requests, be webpage into The registration of row subscription identity, and registered by subscription identity and wake up the corresponding subscription list of webpage.
Subscription information monitors module 1030 and is used for the subscription list according to wake-up to the subscription information transmitted in primary channel It is monitored.
Page callback module 1050 is used to belong to subscription list when the subscription identity for listening to subscription information, and triggering webpage returns Transfer in the displaying of row subscription information.
Figure 21 is please referred to, in one exemplary embodiment, a kind of page access device 1300 is applied to agency service end, packet Include but be not limited to: packet-receiving module 1310, capability information obtaining module 1330, forward process module 1350 and resource return Module 1370.
Wherein, packet-receiving module 1310 is visited by primary channel in the primary page of offer online for receiving client From the data packet of the primary channel transfer during asking, the data packet is to carry out proprietary protocol according to web access requests What encapsulation obtained, the web access requests indicate the webpage of the client request access.
The business service end that capability information obtaining module 1330 is used to obtain data packet instruction stores in agency service end Agreement tenability information.
Forward process module 1350 is used to execute the forwarding of data packet for business service end according to agreement tenability information Processing.
Resource return module 1370 is used to receive the page resource that business service end is returned by parsing data packet, and will Page resource is sent to the online access of webpage indicated by client executing web access requests.
Figure 22 is please referred to, in one exemplary embodiment, forward process module 1350 includes but is not limited to: retransmission unit 1351 and processing forward unit 1353.
Wherein, if retransmission unit 1351 supports parsing data for agreement tenability information instruction business service end Packet, then forward data packet to business service end.
If processing forward unit 1353 does not support parsing data for agreement tenability information instruction business service end Packet then carries out protocol conversion process to data packet according to the agreement that business service end is supported, and by the data packet after conversion process It is sent to business service end.
Figure 23 is please referred to, in one exemplary embodiment, device 1300 as described above further includes but is not limited to: information is looked into Look for module 1410, token extraction module 1430 and proof of identity module 1450.
Wherein, information searching module 1410 is used to find the verification letter corresponding to data packet from protocol registration file Breath.
Token extraction module 1430 is used to need to carry out identity school to the client for sending data packet when check information instruction It tests, the token for being distributed to client is extracted from data packet.
The key that proof of identity module 1450 is used to be carried according to token carries out the proof of identity of client, logical in client The forward process of data packet is executed when crossing proof of identity.
It should be noted that page access device provided by above-described embodiment is when carrying out page access processing, only with The division progress of above-mentioned each functional module can according to need and for example, in practical application by above-mentioned function distribution by not Same functional module is completed, i.e., the internal structure of page access device will be divided into different functional modules, to complete above retouch The all or part of function of stating.
In addition, the embodiment of page access device provided by above-described embodiment and page access method belongs to same structure Think, the concrete mode that wherein modules execute operation is described in detail in embodiment of the method, no longer superfluous herein It states.
In one exemplary embodiment, a kind of page access device, including processor and memory.
Wherein, it is stored with computer-readable instruction on memory, realization when which is executed by processor Page access method in the various embodiments described above.
In one exemplary embodiment, a kind of computer readable storage medium, is stored thereon with computer program, the calculating The page access method in the various embodiments described above is realized when machine program is executed by processor.
Above content, preferable examples embodiment only of the invention, is not intended to limit embodiment of the present invention, this Field those of ordinary skill central scope according to the present invention and spirit can be carried out very easily corresponding flexible or repaired Change, therefore protection scope of the present invention should be subject to protection scope required by claims.

Claims (15)

1. a kind of page access method characterized by comprising
During client provides primary page online access by primary channel, web access requests, the webpage are received Access request indicates the webpage of the client request access;
Proprietary protocol encapsulation is carried out to the web access requests, and is passed by the data packet that the primary channel obtains encapsulation Transport to agency service end;
It controls the business service end that the agency service end is indicated to the data packet and forwards the data packet;
The page resource that the business service end is returned by parsing the data packet is received, is carried out according to the page resource The online access of webpage indicated by the web access requests.
2. the method as described in claim 1, which is characterized in that the client is online by the primary channel primary page of offer During access, web access requests are received, comprising:
Operation, which is directed toward, according to the page that triggering carries out obtains the corresponding domain-name information of webpage indicated by the web access requests;
The calling authorization check of the webpage is carried out to the domain-name information got according to white list;
Authorization check is called when the webpage passes through, calls specified interface to execute required parameter for the webpage and is passed to, passes through biography The required parameter entered generates the web access requests.
3. the method as described in claim 1, which is characterized in that described privately owned to required parameter web access requests progress Protocol encapsulation, and the data packet that encapsulation obtains is transmitted to by agency service end by the primary channel, comprising:
The web access requests filling is carried out according to the data format of the proprietary protocol, generates the data packet;
An assignment is marked according to the webpage that the web access requests indicate, and the marker bit of assignment is added to the number According to packet;
The data packet is transmitted to the agency service end by the primary channel.
4. the method as described in claim 1, which is characterized in that described to be asked according to the page resource progress web page access Seek the online access of indicated webpage, comprising:
Protocol conversion process is carried out to the page resource;
Page rendering is carried out according to the page resource after conversion process, the web access requests are shown by the page rendering Indicated webpage.
5. such as the described in any item methods of Claims 1-4, which is characterized in that the method also includes:
In the online access of webpage indicated by the web access requests, subscription identity registration is carried out for the webpage, and pass through The subscription identity registration wakes up the corresponding subscription list of webpage;
The subscription information transmitted in the primary channel is monitored according to the subscription list of wake-up;
When the subscription identity for listening to the subscription information belongs to the subscription list, trigger the webpage readjustment carry out described in order Read the displaying of information.
6. a kind of page access method characterized by comprising
Client is received during providing primary page online access by primary channel from the number of the primary channel transfer According to packet, the data packet is to carry out proprietary protocol to web access requests to encapsulate, and the web access requests indicate institute State the webpage of client request access;
Obtain the agreement tenability information that the business service end of the data packet instruction stores in agency service end;
It is the forward process that the business service end executes the data packet according to the agreement tenability information;
The page resource that the business service end is returned by parsing the data packet is received, and the page resource is sent To the online access of webpage indicated by web access requests described in the client executing.
7. method as claimed in claim 6, which is characterized in that it is described according to the agreement tenability information be the business Server-side executes the forward process of the data packet, comprising:
If the agreement tenability information indicates that the business service end is supported to parse the data packet, the number is forwarded According to packet to the business service end;
Otherwise, protocol conversion process is carried out to the data packet according to the agreement that the business service end is supported, and will be at conversion Data packet after reason is sent to the business service end.
8. method according to claim 6 or 7, which is characterized in that described according to the agreement tenability information is described Before business service end executes the forward process of the data packet, the method also includes:
The check information corresponding to the data packet is found from protocol registration file;
When check information instruction needs to carry out proof of identity to the client for sending the data packet, from the data packet Extract the token for being distributed to the client;
The proof of identity that the client is carried out according to the key that the token carries, when the client passes through proof of identity Execute the forward process of the data packet.
9. a kind of page access device characterized by comprising
Request receiving module during providing primary page online access by primary channel for client, receives webpage Access request, the web access requests indicate the web-page requests parameter of the client request access;
Protocol encapsulation module, for carrying out proprietary protocol encapsulation to the web access requests, and will by the primary channel It encapsulates obtained data packet and is transmitted to agency service end;
Forwarding module is controlled, forwards the number for controlling the business service end that the agency service end is indicated to the data packet According to packet;
Page access module, the page resource returned for receiving the business service end by parsing the data packet, root The online access of webpage indicated by the web access requests is carried out according to the page resource.
10. device as claimed in claim 9, which is characterized in that the request receiving module includes:
Information acquisition unit, the page for being carried out according to triggering are directed toward operation and obtain webpage indicated by the web access requests Corresponding domain-name information;
Authorization check unit, for carrying out the calling authorization check of the webpage to the domain-name information got according to white list;
Parameter is passed to unit, for calling authorization check when the webpage passes through, calls specified interface execution to ask for the webpage It asks parameter incoming, the web access requests is generated by incoming required parameter.
11. device as claimed in claim 9, which is characterized in that the protocol encapsulation module includes:
Data package generating unit carries out the web access requests filling for the data format according to the proprietary protocol, raw At the data packet;
Marker bit assignment unit, the webpage for being indicated according to the web access requests are marked an assignment, and by assignment Marker bit be added to the data packet;
Data packet transmission unit, for transmitting the data packet to the agency service end by the primary channel.
12. device as claimed in claim 9, which is characterized in that the page access module includes:
Resource converting unit, for carrying out protocol conversion process to the page resource;
Page rendering unit, it is aobvious by the page rendering for carrying out page rendering according to the page resource after conversion process Show webpage indicated by the web access requests.
13. such as the described in any item devices of claim 9 to 12, which is characterized in that described device further include:
Subscription registration module in the online access for webpage indicated by the web access requests, is ordered for the webpage Identifier register is read, and the corresponding subscription list of webpage is waken up by subscription identity registration;
Subscription information monitors module, for being carried out according to the subscription list of wake-up to the subscription information transmitted in the primary channel It monitors;
Page callback module, for belonging to the subscription list when the subscription identity that listen to the subscription information, described in triggering Webpage readjustment carries out the displaying of the subscription information.
14. a kind of page access device characterized by comprising
Packet-receiving module, for receiving client during providing primary page online access by primary channel from institute The data packet of primary channel transfer is stated, the data packet encapsulates to obtain according to web access requests progress proprietary protocol, The web access requests indicate the webpage of the client request access;
Capability information obtaining module, the association that the business service end for obtaining the data packet instruction stores in agency service end Discuss tenability information;
Forward process module, for being that the business service end executes the data packet according to the agreement tenability information Forward process;
Resource return module, the page resource returned for receiving the business service end by parsing the data packet, and The page resource is sent to the online access of webpage indicated by web access requests described in the client executing.
15. a kind of page access device characterized by comprising
Processor;And
Memory is stored with computer-readable instruction on the memory, and the computer-readable instruction is held by the processor Such as page access method described in any item of the claim 1 to 8 is realized when row.
CN201810344719.5A 2018-04-17 2018-04-17 Page access method and device Active CN110399578B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201810344719.5A CN110399578B (en) 2018-04-17 2018-04-17 Page access method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201810344719.5A CN110399578B (en) 2018-04-17 2018-04-17 Page access method and device

Publications (2)

Publication Number Publication Date
CN110399578A true CN110399578A (en) 2019-11-01
CN110399578B CN110399578B (en) 2023-07-14

Family

ID=68319520

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201810344719.5A Active CN110399578B (en) 2018-04-17 2018-04-17 Page access method and device

Country Status (1)

Country Link
CN (1) CN110399578B (en)

Cited By (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110908711A (en) * 2019-11-21 2020-03-24 北京字节跳动网络技术有限公司 Control development method and device of application program and electronic equipment
CN111193725A (en) * 2019-12-20 2020-05-22 北京淇瑀信息科技有限公司 Configuration-based combined login method and device and computer equipment
CN111885006A (en) * 2020-06-29 2020-11-03 上海巧房信息科技有限公司 Page access and authorized access method and device
CN111897613A (en) * 2020-07-31 2020-11-06 平安普惠企业管理有限公司 Page access method and related equipment
CN112769802A (en) * 2020-12-31 2021-05-07 微医云(杭州)控股有限公司 Access verification method and device based on server, electronic equipment and storage medium
CN113657890A (en) * 2021-08-04 2021-11-16 支付宝(杭州)信息技术有限公司 Page rebound method and device
CN115017436A (en) * 2022-08-05 2022-09-06 太平金融科技服务(上海)有限公司深圳分公司 Data interaction method and device of application program, computer equipment and storage medium

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107040609A (en) * 2017-05-25 2017-08-11 腾讯科技(深圳)有限公司 A kind of network request treating method and apparatus
CN107438993A (en) * 2015-04-10 2017-12-05 德国电信股份有限公司 For the method and system of packet to be dispatched in boundling scene based on TCP channel and primary TCP message

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN107438993A (en) * 2015-04-10 2017-12-05 德国电信股份有限公司 For the method and system of packet to be dispatched in boundling scene based on TCP channel and primary TCP message
CN107040609A (en) * 2017-05-25 2017-08-11 腾讯科技(深圳)有限公司 A kind of network request treating method and apparatus

Cited By (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110908711A (en) * 2019-11-21 2020-03-24 北京字节跳动网络技术有限公司 Control development method and device of application program and electronic equipment
CN111193725A (en) * 2019-12-20 2020-05-22 北京淇瑀信息科技有限公司 Configuration-based combined login method and device and computer equipment
CN111885006A (en) * 2020-06-29 2020-11-03 上海巧房信息科技有限公司 Page access and authorized access method and device
CN111897613A (en) * 2020-07-31 2020-11-06 平安普惠企业管理有限公司 Page access method and related equipment
CN112769802A (en) * 2020-12-31 2021-05-07 微医云(杭州)控股有限公司 Access verification method and device based on server, electronic equipment and storage medium
CN113657890A (en) * 2021-08-04 2021-11-16 支付宝(杭州)信息技术有限公司 Page rebound method and device
CN115017436A (en) * 2022-08-05 2022-09-06 太平金融科技服务(上海)有限公司深圳分公司 Data interaction method and device of application program, computer equipment and storage medium
CN115017436B (en) * 2022-08-05 2023-01-10 太平金融科技服务(上海)有限公司深圳分公司 Data interaction method and device of application program, computer equipment and storage medium

Also Published As

Publication number Publication date
CN110399578B (en) 2023-07-14

Similar Documents

Publication Publication Date Title
CN110399578A (en) Page access method and device
CN109152095B (en) Wireless network connection method for terminal
CN108306877B (en) NODE JS-based user identity information verification method and device and storage medium
US10880399B2 (en) Method and system for implementing network experience shifting using shared objects
US10311877B2 (en) Performing tasks and returning audio and visual answers based on voice command
US10673680B2 (en) Electronic device providing dialog contents, server and method thereof
CN109152094B (en) Wireless network connection method for terminal
WO2017024842A1 (en) Internet access authentication method, client, computer storage medium
CN107277153A (en) Method, device and server for providing voice service
CN105812323B (en) A kind of method and apparatus of the cross-domain access data of network
CN105426448B (en) Interface display method, apparatus and system
US11277486B2 (en) Access to data source via proxy
CN108881228A (en) Cloud registration activation method, device, equipment and storage medium
CN104683313B (en) Multimedia service processing unit, method and system
US20220171011A1 (en) Positioning method and device, server, storage medium and terminal
CN110198333B (en) Data acquisition method and device, storage medium and electronic device
CN103812900A (en) Data synchronization method, device and system
CN106850384A (en) A kind of method and mobile terminal for realizing accessing equipment in LAN
CN109767257A (en) Advertisement placement method, system and electronic equipment based on big data analysis
CN112243016B (en) Middleware platform, terminal equipment, 5G artificial intelligence cloud processing system and processing method
CN106789561B (en) Terminal physical address binding method and system based on intranet service platform
CN103685491B (en) A kind of application service provides method, system and relevant device
KR20060118221A (en) System and method for jointing contents using sync server
US20230048931A1 (en) Split input and output remote access
CN104424260A (en) Browser information sharing method and device

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