Skip to content

Commit 811f9b7

Browse files
committed
Fix fomratting
Signed-off-by: Dusan Borovcanin <[email protected]>
1 parent 79bb158 commit 811f9b7

File tree

3 files changed

+7
-7
lines changed

3 files changed

+7
-7
lines changed

crypto/README.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,7 +6,7 @@
66
- `aes_encrypt(string, string, string, string)` - return AES encrypted hex-encoded ciphertext
77
- `aes_decrypt(string, string, string, string)` - return AES decrypted hex-encoded plain text
88

9-
AES support 3 modes: GCM, CBC, and CTR - first parameter is mode, second is key, third is initialization vector or nonce - depending on the mode, and forth is plain text or ciphertext.
9+
AES support 3 modes: GCM, CBC, and CTR - first parameter is mode, second is hex-encoded key, third is hex-encoded initialization vector or nonce - depending on the mode, and forth is hex-encoded plain text or ciphertext.
1010

1111
## Examples
1212

crypto/loader.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@ import lua "github.com/yuin/gopher-lua"
55
// Preload adds crypto to the given Lua state's package.preload table. After it
66
// has been preloaded, it can be loaded using require:
77
//
8-
// local crypto = require("crypto")
8+
// local crypto = require("crypto")
99
func Preload(L *lua.LState) {
1010
L.PreloadModule("crypto", Loader)
1111
}

crypto/test/test_api.lua

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -82,12 +82,12 @@ function TestAESEncrypt(t)
8282
err = "failed to encrypt: incorrect GCM nonce size: 14, expected: 12",
8383
},
8484
{
85-
data = "48656c6c6f20776f726c64", -- "Hello world" in hex
86-
mode = "cbc",
87-
key = "86e15cbc1cbf510d8f2e51d4b63a2144",
88-
init = "068bb92e032884ba8b260fa7d3a80005",
85+
data = "48656c6c6f20776f726c64", -- "Hello world" in hex
86+
mode = "cbc",
87+
key = "86e15cbc1cbf510d8f2e51d4b63a2144",
88+
init = "068bb92e032884ba8b260fa7d3a80005",
8989
expected = "dfba6f71cce4d4b76be301b577d9f095",
90-
err = nil,
90+
err = nil,
9191
},
9292
{
9393
data = "48656c6c6f20776f726c64", -- "Hello world" in hex

0 commit comments

Comments
 (0)