# US 2012/0255027 A1 · Detecting code injections through cryptographic methods

> Agents: this data is available as JSON from the patentgrep API and MCP server — see https://patentgrep.com/llms.txt

- Number: US 2012/0255027 A1
- Document ID: US20120255027A1
- Status: Published application
- Kind: A1
- Application number: 13/109,748
- Filed: 2011-05-17
- Published: 2012-10-04
- Earliest claimed: 2011-03-31
- Assignees: Infosys Technologies Limited
- Inventors: Prashant Venkatesh Kanakapura; Arjun Govindaraju; Abishek C
- Web page: https://patentgrep.com/patent/US20120255027A1

## CPC

- G06F 21/64: Protecting data integrity, e.g. using checksums, certificates or signatures
- G06F 16/9577: {Optimising the visualization of content, e.g. distillation of HTML documents}
- G06F 21/51: at application loading time, e.g. accepting, rejecting, starting or inhibiting executable software based on integrity or source reliability
- H04L 63/126: {the source of the received data}
- H04L 63/1441: {Countermeasures against malicious traffic (countermeasures against attacks on cryptographic mechanisms H04L9/002)}
- H04L 67/10: in which an application is distributed across nodes in the network (software deployment G06F8/60; multiprogramming arrangements G06F9/46)
- G06F 2221/2119: Authenticating web pages, e.g. with suspicious links
- G06F: ELECTRIC DIGITAL DATA PROCESSING (computer systems based on specific computational models G06N)
- H04L: TRANSMISSION OF DIGITAL INFORMATION, e.g. TELEGRAPHIC COMMUNICATION (arrangements common to telegraphic and telephonic communication H04M)

## Abstract

Code injection is detected based on code digests associated with hashes of selected portions of content supplied to clients by a server. A client receives the content and generates a corresponding code digest, and based upon a comparison with the code digest received from the server, determines if the received content has been corrupted. The code digest can be signed or supplied with a digital certification for verification that the code digest originated from the server providing the content.

## Claims

### Claim 1

A method, comprising:
receiving a code digest associated with content received from a content server;
determining if the received content corresponds to the code digest; and
processing the received content based on the determination.

### Claim 2 (depends on 1)

The method of claim 1, wherein the content received from the content server includes at least one web page.

### Claim 3 (depends on 1)

The method of claim 1, wherein determining if the received content corresponds to the message digest is based on applying a hash function to the received content.

### Claim 4 (depends on 3)

The method of claim 3, wherein the determining is based on a comparison of the received code digest with a digest obtained by applying the hash function to the received content.

### Claim 5 (depends on 1)

The method of claim 1, wherein the received code digest is associated with static content portions, and further comprising:
parsing the received content to identify static content portions;
obtaining a static content digest associated with the identified static content portions; and
determining if the received content corresponds to the received message digest based on a comparison of the static content digest and the received content digest.

### Claim 6 (depends on 5)

The method of claim 5, wherein the static content digest is obtained by applying a hash function to the identified static content portions.

### Claim 7 (depends on 6)

The method of claim 6, wherein the hash function is the SHA function.

### Claim 8 (depends on 5)

The method of claim 5, further comprising determining that the content digest is associated with the content provider based on a digital signature.

### Claim 9 (depends on 5)

The method of claim 5, wherein the digital signature is extracted from the content digest.

### Claim 10

A method of providing content on a network, comprising:
receiving content for communication to one or more network clients from a content provider;
preparing a web page for communication to a selected client in response to a client request;
obtaining a web page identifier associated with the prepared web page; and
forwarding the web page and the web page identifier to the selected client.

### Claim 11 (depends on 10)

The method of claim 10, further comprising storing a plurality of web page identifiers associated with respective web pages, and obtaining the web page identifier from among the stored web page identifiers.

### Claim 12 (depends on 10)

The method of claim 10, wherein the web page identifier is a hash corresponding to at least a portion of the prepared web page.

### Claim 13 (depends on 12)

The method of claim 12, wherein the web page identifier is a hash corresponding to a static portion of the prepared web page.

### Claim 14 (depends on 12)

The method of claim 12, wherein the web page identifier is a hash associated with at least one client-side script contained in the prepared web page.

### Claim 15 (depends on 10)

The method of claim 10, wherein the web page identifier is associated with client-side scripts and client input fields contained in the prepared web page.

### Claim 16 (depends on 15)

The method of claim 15, wherein the web page identifier is a hash of the portions of the prepared web page corresponding to the client-side scripts and the client input fields.

### Claim 17

At least one computer readable storage medium containing computer-executable instructions for a method, comprising:
transmitting a content request to a content provider via a wide area network;
receiving content and a content identifier in response to the request;
based on the received content, obtaining a local content identifier;
comparing the local content identifier to the received content identifier; and
based on the comparison, processing the received content.

### Claim 18 (depends on 17)

The at least one computer readable storage medium of claim 17, wherein the method further comprises communicating a notification to the content provider if the received content provider and the local content identifier indicate an injection in the received content.

### Claim 19 (depends on 17)

The at least one computer readable storage medium of claim 17, wherein the method further comprises displaying a warning if the received content identifier and the local content identifier indicate an injection in the received content.

### Claim 20 (depends on 17)

The at least one computer readable storage medium of claim 17, wherein the received content identifier includes a hash of at least a portion of web page content to be provided and a digital signature associated with the content provider, and further comprising determining that the digital signature corresponds to the content provider.

### Claim 21 (depends on 20)

The at least one computer-readable storage medium of claim 20, wherein the received content identifier is a digitally signed hash of at least a portion of a web page to be provided.

### Claim 22

A system, comprising:
a network interface configured to transmit a request for content over a wide-area network; and
a processor configured to:
receive content in response to the request and a hash of at least a portion of the received content;
compute a local hash based on a corresponding portion of the received content; and
compare the local hash and the received hash.

### Claim 23 (depends on 22)

The system of claim 22, wherein the interface is a network communication interface, and the processor is configured to communicate an indication of code injection to the content provider based on the comparisons of the local hash and the received hash.

### Claim 24 (depends on 22)

The system of claim 22, wherein the interface is a display interface, and the processor is configured to produce a display based on the comparison of the local hash and the received hash.
