Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion OneTimePassword.podspec
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
Pod::Spec.new do |s|
s.name = "OneTimePassword"
s.version = "3.1.5"
s.version = "3.1.6"
s.summary = "A small library for generating TOTP and HOTP one-time passwords."
s.homepage = "https://github.com/mattrubin/OneTimePassword"
s.license = "MIT"
Expand Down
2 changes: 1 addition & 1 deletion Sources/Crypto.swift
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ import Foundation
import CommonCryptoShim
#endif

func HMAC(algorithm: Generator.Algorithm, key: Data, data: Data) -> Data {
public func HMAC(algorithm: Generator.Algorithm, key: Data, data: Data) -> Data {
let (hashFunction, hashLength) = algorithm.hashInfo

let macOut = UnsafeMutablePointer<UInt8>.allocate(capacity: hashLength)
Expand Down
3 changes: 3 additions & 0 deletions Sources/Keychain.swift
Original file line number Diff line number Diff line change
Expand Up @@ -123,6 +123,9 @@ private extension Token {
kSecAttrGeneric as String: data as NSData,
kSecValueData as String: generator.secret as NSData,
kSecAttrService as String: kOTPService as NSString,

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Trailing Whitespace Violation: Lines should not have trailing whitespace. (trailing_whitespace)

// Allow keychain access in the background after first unlock.
kSecAttrAccessible as String: kSecAttrAccessibleAfterFirstUnlock as NSString
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Colon Violation: Colons should be next to the identifier when specifying a type and next to the key in dictionary literals. (colon)

]
}
}
Expand Down