mirror of
https://github.com/huashengdun/webssh.git
synced 2026-08-22 05:36:28 +00:00
Check pk size before reading
This commit is contained in:
@@ -336,7 +336,7 @@ jQuery(function($){
|
||||
}
|
||||
|
||||
var pk = data.get('privatekey');
|
||||
if (pk) {
|
||||
if (pk && pk.size) {
|
||||
if (pk.size > key_max_size) {
|
||||
console.log('Invalid private key: ' + pk.name);
|
||||
} else {
|
||||
|
||||
Reference in New Issue
Block a user