Embodiments pertain to systems and devices for, and methods of, HTTP encapsulation to access web resources.
Computer resources may be hosted on a local device behind a network firewall from a remote host. The remote server may not be able to initiate outgoing HTTP connections to a Hypertext Transfer Protocol (HTTP) browser client on a local device residing within the firewall. An intermediary third-party server may be required to connect a client and server which are residing behind a network firewall from each other. Another method may implement persistent tunnel connections to be established between client and server.
Embodiments include methods, systems, and devices where, for example a method embodiment of a system accessing web resources using HTTP encapsulation may include the steps, not necessarily in the following order, of: (a) receiving, by an HTTP-encapsulator server component, HTTP request data from a web client; (b) saving, by the HTTP-encapsulator server, the HTTP request data; (c) creating, by the HTTP-encapsulator server, based on the request of the web client, a first web resource accessible through an endpoint Uniform Resource Locator (URL); (d) creating, by the HTTP-encapsulator server, a second web resource containing data, wherein the data comprises: a URL to access the first web resource; and an endpoint URL pointing to a file handler on the HTTP-encapsulator server; (e) fetching, by an HTTP-encapsulator client of a local computing device, a command data of the HTTP-encapsulator server; (f) receiving, by the HTTP-encapsulator client, the command data of the HTTP-encapsulator server comprising a retrieval instruction to a data file stored at the local computing device as a destination page; (g) generating, by the HTTP-encapsulator client, a response to the request of the HTTP-encapsulator server, based on a protected network resource; and (h) sending the generated response to the URL endpoint of the HTTP-encapsulator server hosted at the source external to the HTTP-encapsulator client of the local computing device. Optionally, the web client may be external to a local device behind a network firewall. Optionally, the second web resource may be a data file. Method embodiments may further comprise the step where the receiving of the HTTP request data from the web client is via a socket connection. In some embodiments the data may be optionally saved to a file. Some embodiments may include sending and receiving by the HTTP-encapsulator server of the request and response is via at least one of: HTTP GET and HTTP POST.
Embodiments include methods, systems, and devices where, for example a method embodiment of a server accessing web resources using HTTP encapsulation may include the steps of: (a) receiving, by an HTTP-encapsulator server component, an HTTP request data from a web client; (b) creating, by the HTTP-encapsulator server, based on the HTTP request data from the web client, a first web resource accessible through an endpoint URL; (c) creating, by an HTTP-encapsulator server, a second web resource containing data, wherein the data comprises: a URL to access the first web resource; and an endpoint URL pointing to a file handler on the HTTP-encapsulator server; (d) sending, by the HTTP-encapsulator server, a request to an HTTP-encapsulator client of a local computing device, wherein the request is via an HTTP GET by the HTTP-encapsulator client; (e) receiving, by the HTTP-encapsulator server, a response to the HTTP-encapsulator server's request, wherein the response is via an HTTP POST by the HTTP-encapsulator client; (f) generating, by the HTTP-encapsulator server, a binary file based on the received response to the sent request, wherein the HTTP-encapsulation is removed; and (g) sending the generated response to the web client. Optionally, the web client may be external to a local device behind a network firewall. Optionally, the second web resource may be a data file. Method embodiments may further comprise the step where the receiving of the HTTP request data from the web client is via a socket connection. In some embodiments the data may be optionally saved to a file.
Embodiments include methods, systems, and devices where, for example a method embodiment of a client accessing web resources using HTTP encapsulation may include the steps of: (a) polling, by an HTTP-encapsulator client of a local computing device, of an HTTP-encapsulator server component via an HTTP GET for HTTP command data; (b) receiving, by the HTTP-encapsulator client, a response to the command data from the HTTP-encapsulator server; (c) fetching, by the HTTP-encapsulator client, an HTTP request data from the HTTP-encapsulator server via an HTTP GET; (d) receiving, by the HTTP-encapsulator client, a response to the request data from the HTTP-encapsulator server, wherein the received request data is HTTP-encapsulated; (e) invoking, by the HTTP-encapsulator client, a call based on the request data; (f) sending, by the HTTP-encapsulator client, the response data to the HTTP-encapsulator server, wherein the response is HTTP-encapsulated and sent to the HTTP-encapsulator server via an HTTP POST; and (g) generating, by the HTTP-encapsulator server, a file, such as a binary file, based on the received response to the sent request, wherein the HTTP-encapsulation is removed. Optionally, the HTTP-encapsulator server is external to a local device behind a network firewall.
Embodiments pertain to server devices for accessing web resources using HTTP encapsulation, and the device embodiment may comprise: (a) a processor and (b) addressable memory, wherein the processor is configured to: (a) receive, by an HTTP-encapsulator server component, an HTTP request data from a web client; (b) create, by the HTTP-encapsulator server, a first web resource accessible through an endpoint URL; (c) create, by an HTTP-encapsulator server, based on the HTTP request data from the web client, a second web resource containing data, wherein the data comprises: a URL to access the first web resource; and an endpoint URL pointing to a file handler on the HTTP-encapsulator server; (d) send, by the HTTP-encapsulator server, a request to an HTTP-encapsulator client of a local computing device, wherein the request is via an HTTP GET from the HTTP-encapsulator client; (e) receive, by the HTTP-encapsulator server, a response to the HTTP-encapsulator server's request, wherein the response is via an HTTP POST from the HTTP-encapsulator client; (f) generate, by the HTTP-encapsulator server, a file, such as a binary file, based on the received response to the sent request, wherein the HTTP-encapsulation is removed; and (g) send the generated response to the web client.
Embodiments pertain to server devices for accessing web resources using HTTP encapsulation, and the device embodiment may comprise: (a) a processor and (b) addressable memory, wherein the processor is configured to: (a) poll, by an HTTP-encapsulator client of a local computing device, of an HTTP-encapsulator server component via an HTTP GET for HTTP command data; (b) receive, by the HTTP-encapsulator client, a response to the command data from the HTTP-encapsulator server; (c) fetch, by the HTTP-encapsulator client, an HTTP request data from the HTTP-encapsulator server via an HTTP GET; (d) receive, by the HTTP-encapsulator client, a response to the request data from the HTTP-encapsulator server, wherein the received request data is HTTP-encapsulated; (e) invoke, by the HTTP-encapsulator client, a call based on the request data; (f) send, by the HTTP-encapsulator client, the response data to the HTTP-encapsulator server, wherein the response is HTTP-encapsulated and sent to the HTTP-encapsulator server via an HTTP POST; and (g) generate, by the HTTP-encapsulator server, a file, such as a binary file, based on the received response to the sent request, wherein the HTTP-encapsulation is removed.
Embodiments are illustrated by way of example and not limitation in the figures of the accompanying drawings, and in which:
Reference is made to
The HTTP-encapsulator server 500 comprises a computer and/or computing circuitry that may be configured to execute the steps of a server as depicted in
The local device, e.g., an MFP device behind the network firewall, comprises a computer and/or computing circuitry that may be configured to execute the steps of a client as depicted in
The steps of an exemplary system operation may be characterized as follows: The web client 810 connects to the MFP device via a connection to the HTTP-encapsulator server component 830. The HTTP-encapsulator server 830 accepts a socket connection from the web client 810, and reads the HTTP request data sent from the web client 810. The HTTP-encapsulator server 830 saves the HTTP request data from the web client. The request data may be saved to a file, thereby creating a first web resource 834 (RequestData) that may be accessible through an endpoint URL. A second web resource 832 (CommandData) is created that may also be accessible through an endpoint URL. The second web resource is a data container that holds two URLs, e.g., GetURL and PostURL. GetURL is the URL to access the first web resource and PostURL is an endpoint URL that points to a file handler on the HTTP-encapsulator server 830. The file handler allows a standard HTTP POST of multipart-form format to upload files to the HTTP-encapsulator server 830.
The HTTP-encapsulator client 850 may be residing behind a firewall 870 and may be pre-configured to a valid CommandURL endpoint. At periodic intervals, the HTTP-encapsulator client 850 may make an HTTP GET request to the CommandURL endpoint. Upon retrieving a CommandData that contains GetURL and PostURL elements, the client may perform the steps of: (a) make an HTTP GET to the GetURL that retrieves the RequestData web resource, and effectively HTTP-encapsulates the RequestData in the HTTP response; (b) The HTTP-encapsulator client component then parses through ReqestData to determine the HTTP method, e.g., a set of at least POST, GET, PUT, or combination thereof, in the request. The necessary modifications are made to an HTTP header field e.g., “Host”, to ensure that the HTTP request is accepted by the target e.g., a protected web resource 860; (c) The HTTP-encapsulator client 850 makes an HTTP connection 852 to the protected network resource 860 and sends the modified RequestData. The protected web resource 860 may respond with an HTTP response 854. The HTTP-encapsulator client component either buffers in memory or saves to file the entire HTTP response (ResponseData). It then may make an HTTP POST to the PostURL, sending the ResponseData via, e.g., a file upload attachment. This serves to HTTP-encapsulate the ResponseData in the HTTP request. The HTTP-encapsulator server 830 file handler may save the attached ResponseData locally e.g., as a binary file. This serves to remove the HTTP-encapsulation on the ResponseData. The HTTP-encapsulator server component then sends the ResponseData to the web client through the established socket connection, thereby completing the entire web client HTTP request-response cycle.
It is contemplated that various combinations and/or sub-combinations of the specific features and aspects of the above embodiments may be made and still fall within the scope of the invention. Accordingly, it should be understood that various features and aspects of the disclosed embodiments may be combined with or substituted for one another in order to form varying modes of the disclosed invention. Further it is intended that the scope of the present invention herein disclosed by way of examples should not be limited by the particular disclosed embodiments described above.