Tink is a multi-language, cross-platform library that provides simple and misuse-proof APIs for common cryptographic tasks.
This is Tink 1.4.0.
The complete list of changes since 1.3.0 can be found here.
What's new
Security fixes
This release fixes the following potential security issues, affected users are recommended to upgrade.
-
Quan Nguyen of Snap Inc. found that AES-CTR-HMAC-AEAD keys and the EncryptThenAuthenticate subtle implementation may be vulnerable to chosen-ciphertext attacks. An attacker can generate ciphertexts that bypass the HMAC verification if and only if all of the following conditions are true:
- Tink C++ is used on systems where size_t is a 32-bit integer. This is usually the case on 32-bit machines.
- The attacker can specify long (>= 2^29 bytes ~ 536MB) associated data.
-
Streaming AEAD implementations encrypt the plaintext in segments. Tink uses a 4-byte segment counter. When encrypting a stream consisting of more than 2^32 segments, the segment counter might overflow and lead to leakage of key material or plaintext. This problem was found in the Java and Go implementations of the AES-GCM-HKDF-Streaming key type.
Python
This version introduces support for Python 3.7 and 3.8.
Tink in Python is built on top of C++. It supports all primitives but Streaming AEAD. For an overview, see the HOW-TO. In addition, there are illustrative examples of using Tink in Python which can be used as a jumping off point.
PyPi binary packages for Linux and macOS are provided.
pip3 install tink
C++
-
Attempt to erase keys from memory after use.
-
Adding support for CordAead, which is a more memory-efficient version of
Aead
that uses absl::Cord.
We no longer offer prebuilt binaries for C++. Please check out this documentation for how to compile your application together with Tink using Bazel or CMake.
Obj-C
- Removing Obj-C protobufs.
cd /path/to/your/Xcode project/
pod init
pod 'Tink', '1.4.0'
pod install
Golang
- Cleaning up Godoc and adding better examples.
go get github.com/google/tink/go/...
Java
- Removing support for Java 7.
<dependency>
<groupId>com.google.crypto.tink</groupId>
<artifactId>tink</artifactId>
<version>1.4.0</version>
</dependency>
Android
-
Bundling a shaded copy of Google Protobuf. This fixes an annoying version conflict bug.
-
Bundling a rule file to ensure compatibility with Proguard/R8.
-
Refactoring Android Keystore integration
-
Running a self-test to only enable the integration if Android Keystore is working properly.
-
Do not automatically generate fresh keys if keys exist but are corrupt. This won't recover corrupt keys, but at least it will allow to gather more data on Android Keystore failures.
-
dependencies {
implementation 'com.google.crypto.tink:tink-android:1.4.0'
}
Tinkey
Tinkey can now be installed via Homebrew on Linux and macOS.
brew tap google/tink https://github.com/google/tink
brew install tinkey
The binaries can also be downloaded from
- https://storage.googleapis.com/tinkey/tinkey-darwin-x86_64-1.4.0.tar.gz
- https://storage.googleapis.com/tinkey/tinkey-linux-x86_64-1.4.0.tar.gz
Known issues
- Tink in Obj-C doesn't build. That is, you can't build it yourself using Bazel. You can still use it in your apps by installing our prebuilt package, as noted above.