mirror of
https://github.com/brunoos/luasec.git
synced 2024-12-26 12:48:20 +01:00
Check if PSK is available
This commit is contained in:
parent
e01c6e63cd
commit
6405645155
@ -4,6 +4,11 @@
|
|||||||
local socket = require("socket")
|
local socket = require("socket")
|
||||||
local ssl = require("ssl")
|
local ssl = require("ssl")
|
||||||
|
|
||||||
|
if not ssl.config.capabilities.psk then
|
||||||
|
print("[ERRO] PSK not available")
|
||||||
|
os.exit(1)
|
||||||
|
end
|
||||||
|
|
||||||
-- @param hint (nil | string)
|
-- @param hint (nil | string)
|
||||||
-- @param max_identity_len (number)
|
-- @param max_identity_len (number)
|
||||||
-- @param max_psk_len (number)
|
-- @param max_psk_len (number)
|
||||||
|
@ -4,6 +4,11 @@
|
|||||||
local socket = require("socket")
|
local socket = require("socket")
|
||||||
local ssl = require("ssl")
|
local ssl = require("ssl")
|
||||||
|
|
||||||
|
if not ssl.config.capabilities.psk then
|
||||||
|
print("[ERRO] PSK not available")
|
||||||
|
os.exit(1)
|
||||||
|
end
|
||||||
|
|
||||||
-- @param identity (string)
|
-- @param identity (string)
|
||||||
-- @param max_psk_len (number)
|
-- @param max_psk_len (number)
|
||||||
-- @return psk (string)
|
-- @return psk (string)
|
||||||
|
Loading…
Reference in New Issue
Block a user