Code signing

Code signing

Code signing is the process of digitally signing executables and scripts to confirm the software author and guarantee that the code has not been altered or corrupted since it was signed by use of a cryptographic hash.

Code signing can provide several valuable features. The most common use of code signing is to provide security when deploying; in some languages, it can also be used to help prevent namespace conflicts. Almost every code signing implementation will provide some sort of digital signature mechanism to verify the identity of the author or build system, and a checksum to verify that the object has not been modified. It can also be used to provide versioning information about an object or to store other meta data about an object.

Contents

Providing security

Many code signing implementations will provide a way to sign the code using private and public key systems, similar to the process employed by SSL or SSH. For example, in the case of .NET, the developer uses a key to sign their libraries or executables each time they build. This key will be unique to a developer or group or sometimes per application or object. The developer can either generate this key on their own or obtain one from a trusted certificate authority (CA).

It is particularly valuable in distributed environments, where the source of a given piece of code may not be immediately evident - for example Java applets, ActiveX controls and other active web and browser scripting code. Another major usage is to safely provide updates and patches to existing software. Most Linux distributions, as well as both Apple Mac OS X and Microsoft Windows update services use code signing to ensure that it is not possible to maliciously distribute code via the patch system. It allows them to not have to worry about distribution security, such as mirror sites which may not be under the authors' complete control, or any other intermediate piece of the deployment.

Trusted identification using a certificate authority (CA)

The public key used for code signing should be traceable back to a trusted root authority, preferably using a secure public key infrastructure (PKI). This does not ensure that the code itself can be trusted, only that it comes from the stated source (or more explicitly, from a particular private key). A certificate authority provides a root trust level which is able to assign trust to others by proxy. If a user is set to trust one of these certificate authorities and receives an executable signed with a key generated by that CA, they can choose to trust the executable by proxy. In many frameworks and operating systems, a number of existing publicly trusted authorities will be pre-installed (such as VeriSign, TC TrustCenter, COMODO, GoDaddy and GlobalSign). When inside a large group of users, such as a large company, it is commonplace to employ a private internal certificate authority suitable for providing the same features of public certificate authority but for deploying signed objects internally.

Alternative to CAs

The other model is where developers can choose to provide their own self-generated key. In this scenario, the user would normally have to obtain the public key in some fashion directly from the developer to verify the object is from them for the first time. Many code signing systems will store the public key inside the signature. Some software frameworks and OSs that check the code's signature before executing will allow you to choose to trust that developer from that point on after the first run. An application developer can provide a similar system by including the public keys with the installer. The key can then be used to ensure that any subsequent objects that need to run, such as upgrades, plugins, or another application, are all verified as coming from that same developer.

Problems

Like any security measure, code signing can be defeated. Users can be tricked into running unsigned code, or even into running code that refuses to validate, and the system only remains secure as long as the private key remains private.

It is also important to note that code signing does not protect the end user from any malicious activity or unintentional software bugs by the software author - it merely ensures that the software has not been modified by anyone other than the author.

Implementations

IBM's Lotus Notes has had PKI signing of code from Release 1, and both client and server software have execution control lists to control what levels of access to data, environment and file system are permitted for given users. Individual design elements, including active items such as scripts, actions and agents, are always signed using the editor's ID file, which includes both the editor's and the domain's public keys. Core templates such as the mail template are signed with a dedicated ID held by the Lotus template development team.

Signed JavaScript is also popular; signed scripts are allowed to perform additional actions such as cross-domain referencing.[1]

Microsoft implements a form of code signing (based on Authenticode) provided for Microsoft tested drivers. Since drivers run in the kernel, they can destabilize the system or open the system to security holes. For this reason, Microsoft tests drivers submitted to its WHQL program. After the driver has passed, Microsoft signs that version of the driver as being safe. On 32-bit systems only, installing drivers that are not validated with Microsoft is possible after accepting to allow the installation in a prompt warning the user that the code is unsigned. For .NET (managed) code, there is an additional mechanism called Strong Name Signing that uses Public/Private keys and SHA1 hash as opposed to Certificates. However, Microsoft discourages reliance on Strong Name Signing as a replacement for Authenticode.[1]

References

External links


Wikimedia Foundation. 2010.

Игры ⚽ Поможем сделать НИР

Look at other dictionaries:

  • code signing — noun the attachment of a digital certificate (from a certification authority) to an executable program to ensure its validity …   Wiktionary

  • Code Access Security — (CAS), in the Microsoft .NET framework, is Microsoft s solution to prevent untrusted code from performing privileged actions. When the CLR loads an assembly it will obtain evidence for the assembly and use this to identify the code group that the …   Wikipedia

  • Signing Exact English — (SEE, sometimes Signed Exact English or Signed English) is a system of manual communication that strives to be an exact representation of English vocabulary and grammar. It is one of a number of such systems in use in English speaking countries,… …   Wikipedia

  • Code of Personal Status (Tunisia) — The Code of Personal Status (CPS) (Arabic: مجلة الأحوال الشخصية‎) is a series of progressive Tunisian laws aiming at the institution of equality between women and men in a number of areas. It was promulgated by beylical decree on August 13, 1956… …   Wikipedia

  • Signing statement (United States) — A signing statement is a written pronouncement issued by the President of the United States upon the signing of a bill into law. There is an ongoing controversy concerning the extensive use of signing statements by President George W. Bush to… …   Wikipedia

  • Code Pink — For the hospital emergency code, see Hospital emergency codes. Code Pink: Women for Peace Code Pink activists demonstrate in front of the White House on July 4, 2006. Formation …   Wikipedia

  • Code of Conduct for the International Red Cross and Red Crescent Movement and NGOs in Disaster Relief — The Code of Conduct for International Red Cross and Red Crescent Movement and NGOs in Disaster Relief was drawn up in 1992 by the Steering Committee for Humanitarian Response to set ethical standards for organizations involved in humanitarian… …   Wikipedia

  • Area code 678 — 678 is a telephone area code assigned to metropolitan Atlanta, Georgia and its suburbs and exurbs. This area code was first assigned to customers signing up for new telephone service on January 15, 1998.It is generally reserved for use outside… …   Wikipedia

  • Certificate signing request — In public key infrastructure (PKI) systems, a certificate signing request (also CSR or certification request) is a message sent from an applicant to a certificate authority in order to apply for a digital identity certificate. The most common… …   Wikipedia

  • United States Code Congressional and Administrative News — The United States Code Congressional and Administrative News (U.S.C.C.A.N.) is a West Group [cite web|url=http://www.loc.gov/rr/law/fedstat.html |title=Federal Statutes (Law Library Reading Room: Law Library of Congress)|accessdate=2007 03 30… …   Wikipedia

Share the article and excerpts

Direct link
Do a right-click on the link above
and select “Copy Link”