A simple wrapper around signtool using node exec
.
npm install simple-signtool --save-dev
First, import simple-signtool
into your project:
import * as signtool from 'simple-signtool';
import * as signtool from 'simple-signtool';
const file = path.join(__dirname, 'my.exe');
signtool.sign(file, {
rawString: '/d mydescription',
rfcTimeStampUrl: {
url: 'http://sha1timestamp.ws.symantec.com/sha1/timestamp',
digestAlgorithm: 'sha256'
}
});
signtool.sign(file, options);
- Independent options should be in the top-level options interface, e.g.,
rawString
- Options that depend on each other should be in their own interface.
Example:export interface ISignOptions { rfcTimeStampUrl?: IRFCTimeStamp; } interface IRFCTimeStamp { url: string; digestAlgorithm?: 'sha256'; // depends on 'url' }
- Fork this repository
- Get project working locally
git clone git@github.com:<yourusername>/simple-signtool.git
cd simple-signtool
npm install
- Write/edit code
- Write tests
- Run
npm test
and fix any errors - Open a pull request
MIT, please see LICENSE.md for details.