Skip to content

Commit

Permalink
add an else for unsupported key type
Browse files Browse the repository at this point in the history
  • Loading branch information
catbro666 committed Jan 21, 2025
1 parent c59edcb commit 88f06bb
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions spec/internal/misc.lua
Original file line number Diff line number Diff line change
Expand Up @@ -178,11 +178,15 @@ local function generate_keys(fmt, typ)
bits = 2048,
exp = 65537
})

elseif typ == "EC" then
key, err = pkey.new({
type = 'EC',
curve = 'prime256v1',
})

else
return nil, "unsupported key type"
end
assert(key)
assert(err == nil, err)
Expand Down

0 comments on commit 88f06bb

Please sign in to comment.