npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

grunt-osslsigncode

v0.2.3

Published

Codesign Application with osslsigncode utility based on a .pfx or .p12 certificate

Downloads

4

Readme

grunt-osslsigncode

Codesign Application with osslsigncode utility based on a .pfx or .p12 certificate

Getting Started

This plugin requires Grunt ~0.4.0

If you haven't used Grunt before, be sure to check out the Getting Started guide, as it explains how to create a Gruntfile as well as install and use Grunt plugins. Once you're familiar with that process, you may install this plugin with this command:

npm install grunt-osslsigncode --save-dev

Once the plugin has been installed, it may be enabled inside your Gruntfile with this line of JavaScript:

grunt.loadNpmTasks( 'grunt-osslsigncode' );

This plugin also requires you to have openssl and osslsigncode installed on your machine. You can install it with this command:

Mac OSX

brew install openssl
brew install osslsigncode

Linux

sudo apt-get install openssl
sudo apt-get install osslsigncode

The "osslsigncode" task

Overview

This module helps signing applications with a .pfx or .p12 certificate based on the osslsigncode utility.

When first running the task you should be prompted to enter the password for your certificate. The plugin generates a .key and .spc file to a temporary directory that should be excluded from version control. When running again it detects that the files have already been generated and won't ask you for a password for future releases.

Configuration

Setup the osslsigncode task like so:

grunt.initConfig( {
	osslsigncode: {
		your_target: {
			options: {
				// Task-specific options go here.
				certificate: 'path/to/certificate.pfx', // path to your .pfx or .p12 certificate
				certificateOutput: 'path/to/tmp/output_', // prefix to a temporary output directory for generated certificates
				sign: 'path/to/app.exe', // path to your executable that should be signed
				output: 'path/to/signed.app.exe', // (optional) path to your signed exe
				password: 'your_password', // (optional) certificate password
				timestamp: 'http://timestamp.globalsign.com/scripts/timestamp.dll', // (optional) url where timestamp should be fetched from
				name: 'App Name', // (optional) your app's name
				url: 'http://www.example.com' // (optional) author's url of app
			}
		},
	},
} )

Options

options.certificate

Type: String Default value: "certificate.pfx

A string value that determines the location of the certificate file that is used to sign the application.

options.certificateOutput

Type: String Default value: "tmp/certificate_"

A string that defines a temporary output directory for generated .key and .spc files. Highly recommended to exclude those files from version control.

For example:

options: {
	certificateOutput: 'store/gen_'
}

Generates the following files:

store/gen_output.key
store/gen_output.spc
store/gen_tmp_cert.pem
store/gen_tmp_key.pem

options.sign

Type: String Default value: null Required

A string that defines the path to the application's executable that should be signed. (.exe, .msi, etc.) Task will throw an error if the option is not set.

options.output

Type: String Default value: null Optional

An optional string that defines the output of the signed executable file. If not set overwrites the original executable file defined in options.sign.

options.password

Type: String Default value: null Optional

An optional string that defines the password stored inside the certificate. If defined no password prompt is shown while generating .key and .spc files.

options.timestamp

Type: String Default value: "http://timestamp.verisign.com/scripts/timstamp.dll" Optional

An optional string that defines the a url where the timestamp for signing the application should be fetched from.

options.name

Type: String Default value: null Optional

An optional string that defines the app's name.

options.url

Type: String Default value: null Optional

An optional string that defines the author's url of the app.

License

Copyright (c) 2015 Fabian Irsara (http://fabianirsara.com). Licensed under the MIT license.