Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Added key reading to callback, added forcing, opts with default location
- Loading branch information
1 parent
2252a2d
commit b175d73
Showing
4 changed files
with
107 additions
and
26 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,7 +1,13 @@ | ||
var keygen = require('./src/ssh-keygen'); | ||
|
||
console.log('Generating key pair') | ||
keygen(__dirname + '/foobar_rsa', 'john@doe.com', 'keyPassword', function(err){ | ||
if(err) console.log('There was a problem'); | ||
else console.log('Done generating key pairs in '+__dirname); | ||
|
||
keygen({ | ||
comment: 'john@doe.com', | ||
read: true | ||
}, function(err, out){ | ||
if(err) return console.log('There was a problem : '+err); | ||
console.log('Done generating key pairs'); | ||
console.log(out.key) | ||
console.log(out.pubKey) | ||
}); |