mirror of
https://github.com/Ylianst/MeshCentral.git
synced 2025-02-12 11:01:52 +00:00
Check for invalid certificate name.
This commit is contained in:
parent
803555b0dc
commit
9b7dfff4b1
1 changed files with 3 additions and 0 deletions
|
@ -182,6 +182,9 @@ function CreateMeshCentralServer(config, args) {
|
|||
return;
|
||||
}
|
||||
|
||||
// Check for invalid cert name
|
||||
if ((obj.args.cert != null) && ((typeof obj.args.cert != "string") || (obj.args.cert.indexOf('@') >= 0) || (obj.args.cert.indexOf('/') >= 0) || (obj.args.cert.indexOf(':') >= 0))) { console.log("Invalid certificate name"); process.exit(); return; }
|
||||
|
||||
// Perform a password hash
|
||||
if (obj.args.hashpassword) { require('./pass').hash(obj.args.hashpassword, function (err, salt, hash, tag) { console.log(salt + ',' + hash); process.exit(); }); return; }
|
||||
|
||||
|
|
Loading…
Reference in a new issue