Skip to content

Remove deprecated encode/decode methods, fix warnings and other… #112

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 25 commits into from
Sep 23, 2019
Merged
Changes from 1 commit
Commits
Show all changes
25 commits
Select commit Hold shift + click to select a range
7f42251
Remove CommonCrypto directory as Swift 4.2 no longer requires this
jonblatho Jul 23, 2018
8004906
Correct encoding unit tests to account for unordered Swift dictionaries
jonblatho Jul 23, 2018
398c825
Reindent to match existing style
jonblatho Jul 23, 2018
ec735aa
Fix warning about deallocate(capacity:) deprecation
jonblatho Jul 23, 2018
264a622
Update many unit tests to stop using deprecated decode method
jonblatho Jul 23, 2018
61e4cd7
Fix remaining unit tests
jonblatho Jul 24, 2018
14ddad4
Bump CryptoSwift to 0.10.0
jonblatho Jul 24, 2018
2ab9490
Correct misspelled method name for validateExpiry(leeway:), retain ol…
jonblatho Jul 24, 2018
312dce7
Remove deprecated encode/decode methods
jonblatho Jul 24, 2018
30677df
Undo removal of CommonCrypto; will try to find compatible solution be…
jonblatho Jul 24, 2018
884e032
Merge pull request #1 from jonblatho/swift-4.2
jonblatho Jul 24, 2018
662871d
see if stripping down the Travis config gets builds working on macOS …
jonblatho Jul 24, 2018
47a8b7f
try adding Ubuntu back into Travis builds
jonblatho Jul 24, 2018
1135108
Travis doesn’t support Xenial, back to Trusty
jonblatho Jul 24, 2018
a50823d
getting closer to original config
jonblatho Jul 24, 2018
44d6d59
Sync up LinuxMain.swift (hopefully)
jonblatho Jul 24, 2018
8d1482a
Merge pull request #2 from jonblatho/swift-4.2
jonblatho Jul 24, 2018
32b7b6e
Fix LinuxMain.swift typo
jonblatho Jul 24, 2018
65dfb1a
See if converting TimeInterval/Double to Int might help Travis builds…
jonblatho Jul 24, 2018
f2bbd1d
See if explicitly handling Ints in parsing JWT times fixes Ubuntu builds
jonblatho Jul 24, 2018
4b83583
simplify Travis config to use swift test only
jonblatho Jul 24, 2018
708c7a7
Correct misspelled unit test method name
jonblatho Jul 24, 2018
44f4b7a
Fix for CommonCrypto inclusion in Swift 4.2
jonblatho Jul 24, 2018
898f0c8
Add podspec
jonblatho Aug 7, 2018
50b7757
Delete JSONWebToken.podspec
jonblatho Aug 7, 2018
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
Prev Previous commit
Next Next commit
Fix warning about deallocate(capacity:) deprecation
  • Loading branch information
jonblatho committed Jul 23, 2018
commit ec735aa8e5516f698540c013b57b4628a9ab9ffc
2 changes: 1 addition & 1 deletion Sources/JWA/HMAC/HMACCommonCrypto.swift
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import CommonCrypto
extension HMACAlgorithm: SignAlgorithm, VerifyAlgorithm {
public func sign(_ message: Data) -> Data {
let context = UnsafeMutablePointer<CCHmacContext>.allocate(capacity: 1)
defer { context.deallocate(capacity: 1) }
defer { context.deallocate() }

key.withUnsafeBytes() { (buffer: UnsafePointer<UInt8>) in
CCHmacInit(context, hash.commonCryptoAlgorithm, buffer, size_t(key.count))
Expand Down