aboutsummaryrefslogtreecommitdiff
path: root/java_src
AgeCommit message (Collapse)Author
2023-07-27Ensure that generated HPKE private keys are encoded to the correct length.wconner
Also, added utility methods for determining HPKE key lengths from KEM id. PiperOrigin-RevId: 551532702
2023-07-27Introduce end-to-end testing of LegacyFullMac, and fix problems uncovered by ↵lizatretyakova
the new tests. PiperOrigin-RevId: 551486832
2023-07-26Make use of the new utility function for proto conversions.lizatretyakova
PiperOrigin-RevId: 551218413
2023-07-26Ensure that legacy proto hybrid keys are parsed to crunchy keys.wconner
PiperOrigin-RevId: 551182852
2023-07-26Register JwtRsaSsaPkcs1 proto serialization.ioannanedelcu
PiperOrigin-RevId: 551117542
2023-07-25Add parsers and serializers for JwtRsaSsaPkcs1 parameters, public key and ↵ioannanedelcu
private key. PiperOrigin-RevId: 550921147
2023-07-25Rewrite EnvelopeAeadExample.java so that it doesn't register the kms client.juerg
PiperOrigin-RevId: 550875209
2023-07-24Add a create function to KmsEnvelopeAead.juerg
This function uses the new Parameters instead of the old proto KeyTemplates. PiperOrigin-RevId: 550614620
2023-07-24Remove redundant secret key access when serializing/parsing public keys.ioannanedelcu
PiperOrigin-RevId: 550503544
2023-07-21Add serialization for Ecies Public Keys.tholenst
PiperOrigin-RevId: 549938077
2023-07-21Replace some calls to "KeyTemplate.create" with "KeyTemplate.createFrom", ↵tholenst
taking a Parameters object. The call to "create" will be deprecated. Note: if a user calls e.g. AesGcmKeyManager.aes128GcmTemplate() without registering the proto serialization, before this CL, it was possible to get the serialized version. After this CL, this will break. I don't think this should be an issue since users basically always register everything anyhow. PiperOrigin-RevId: 549932301
2023-07-21When parsing Ecies parameters with Curve25519, only accept compressed points.tholenst
PiperOrigin-RevId: 549927290
2023-07-21Add JwtRsaSsaPkcs1PrivateKey class in Java.ioannanedelcu
PiperOrigin-RevId: 549884443
2023-07-21Replace some calls to "KeyTemplate.create" with "KeyTemplate.createFrom", ↵tholenst
taking a Parameters object. The call to "create" will be deprecated. Note: if a user calls e.g. AesGcmKeyManager.aes128GcmTemplate() without registering the proto serialization, before this CL, it was possible to get the serialized version. After this CL, this will break. I don't think this should be an issue since users basically always register everything anyhow. PiperOrigin-RevId: 549859554
2023-07-20Add a test with two envelope AEAD keys in a keyset.juerg
PiperOrigin-RevId: 549657384
2023-07-20Change EciesPublicKey constructor and point accessor into two cases: one for ↵tholenst
NIST curves and one for X25519 PiperOrigin-RevId: 549613138
2023-07-20Remove "Convenience method for...".juerg
PiperOrigin-RevId: 549612275
2023-07-20Add JwtRsaSsaPkcs1PublicKey class in Java.ioannanedelcu
PiperOrigin-RevId: 549607483
2023-07-20Use a copy of testdata/gcp/credential_bad.json for testdata/gcp/credential.jsonambrosin
PiperOrigin-RevId: 549602714
2023-07-20Deprecate remaining functions in Registry that return a key manager.juerg
PiperOrigin-RevId: 549602066
2023-07-20In KeyTemplate, either store a proto or a parameters, and convert them on ↵tholenst
demand. This means registration of the respective serializer/parser can be done later. Users might save the object, and then later use it in e.g. Keysethandle.generateNew() and only have the serializer register at the later point. Hence we do it like this. Unfortunately, this means that we may have to throw a TinkBugException (or something else which is unchecked) since the APIs do not throw anything. Within Google nobody called these APIs outside of Tink, so I am relatively sure that this is no problem. Within Tink, the only remaining usage is in KeysetManager, and I changed things to throw a GeneralSecurityException there. PiperOrigin-RevId: 549594684
2023-07-20Remove remaining usages of Registry.getKeyManager and ↵juerg
Registry.getUntypedKeyManager in some tests. Instead, to verify that the key manager is registered, try to create a key. Also, remove the initialization test. It doesn't really add any additional value. PiperOrigin-RevId: 549582726
2023-07-19Add JwtRsaSsaPkcs1Parameters class in Java.ioannanedelcu
PiperOrigin-RevId: 549314771
2023-07-19Rename EcPointFormat accessors in EciesParameters and change behavior: if ↵tholenst
the curve is 25519 it must not be set. PiperOrigin-RevId: 549304481
2023-07-19Add support for full Mac primitive creation to HmacKeyManager.lizatretyakova
PiperOrigin-RevId: 549302486
2023-07-19Remove usages of Registry.getKeyManager and Registry.getUntypedKeyManager in ↵juerg
some tests. Instead, to verify that the key manager is registered, try to create a key. Also, remove the initialization test. It doesn't really add any additional value. PiperOrigin-RevId: 549278449
2023-07-19Add a way to create Macs from LegacyProtoKeys.lizatretyakova
PiperOrigin-RevId: 549266939
2023-07-18Fixed corrupt gradle jar file.Tink Team
Previous SHA256: 431b359c954de1e08ddeda3daad5e451641f9ff9b0e378a8edd7cdd95b6fe9e1 New SHA256: 14dfa961b6704bb3decdea06502781edaa796a82e6da41cd2e1962b14fbe21a3 Official SHA256 (https://gradle.org/release-checksums/): 14dfa961b6704bb3decdea06502781edaa796a82e6da41cd2e1962b14fbe21a3 PiperOrigin-RevId: 549052451
2023-07-18Move HmacProtoSerialization into internal/. This needs to be accessible from ↵lizatretyakova
a keymanager that is internal. PiperOrigin-RevId: 548968754
2023-07-17Upgrade Gradle to 7.6.2.Tink Team
https://fusion2.corp.google.com/presubmit/548768227/OCL:548768227:BASE:548705342:1689626898124:b176761c/targets PiperOrigin-RevId: 548821518
2023-07-17Deprecate "KeyTemplate.getOutputPrefixType"tholenst
PiperOrigin-RevId: 548647821
2023-07-14Avoid usages of "KeyTemplate.getOutputPrefix". We want to deprecate it in ↵tholenst
the future. PiperOrigin-RevId: 548076147
2023-07-14Deprecate "createEciesAeadHkdfPubKey" in HybridKeyTemplates.tholenst
PiperOrigin-RevId: 548069747
2023-07-13Add "toString()".tholenst
PiperOrigin-RevId: 547762047
2023-07-12Remove usages of Registry.getKeyManager and Registry.getUntypedKeyManager in ↵juerg
some tests. Instead, to verify that the key manager is registered, try to create a key. Also, remove the initialization test. It doesn't really add any additional value. PiperOrigin-RevId: 547475050
2023-07-12Create EciesPublicKey class in Java.ioannanedelcu
PiperOrigin-RevId: 547449244
2023-07-12Delete KeyDerivationkeyTemplates.tholenst
This isn't needed anymore -- we now fully support Parameters. Also, this was never in a release, so I'm sure that it's never used. Note that even if a user uses it, they can just replace KeyTemplate keyDerivationTemplate = KeyDerivationKeyTemplates.createPrfBasedKeyTemplate(a, b); with PrfBasedKeyDerivationParameters.builder() .setPrfParameters((PrfParameters) a.toParameters()) .setDerivedKeyParameters(b.toParameters()) .build(); (Typically, one doesn't need to convert it into a KeyTemplate -- if one does, one can just call KeyTemplate.fromProto()). PiperOrigin-RevId: 547406999
2023-07-11Make "equalsKeyset" public.tholenst
PiperOrigin-RevId: 547224118
2023-07-11Signature: Replace the validation tests with tests checking if the key ↵tholenst
generation succeeds. This is a bit more accurate, but has the disadvantage of being potentially slower. Anyhow, i want to change the template functions to not return these pairs (output_prefix, format) anymore, so we need to change this. PiperOrigin-RevId: 547128537
2023-07-11Deprecate "primaryKey".tholenst
PiperOrigin-RevId: 547121954
2023-07-10Prfs & StreamingAeads: Replace the validation tests with tests checking if ↵tholenst
the key generation succeeds. This is a bit more accurate, but has the disadvantage of being potentially slower. Anyhow, i want to change the template functions to not return these pairs (output_prefix, format) anymore, so we need to change this. PiperOrigin-RevId: 546854974
2023-07-10Aeads: Replace the validation tests with tests checking if the key ↵tholenst
generation succeeds. This is a bit more accurate, but has the disadvantage of being potentially slower. Anyhow, i want to change the template functions to not return these pairs (output_prefix, format) anymore, so we need to change this. PiperOrigin-RevId: 546832073
2023-07-10Add "KeysetHandle#equalsKeyset".tholenst
This allows to compare two keysets, which is useful when one wants to have a guarantee that the two keysets are equal (for example, if one gets one from a KMS and the other from disk, but wants no change). #tinkPublicApiChange PiperOrigin-RevId: 546812109
2023-07-10Macs: Replace the validation tests with tests checking if the key generation ↵tholenst
succeeds. This is a bit more accurate, but has the disadvantage of being potentially slower. Anyhow, i want to change the template functions to not return these pairs (output_prefix, format) anymore, so we need to change this. PiperOrigin-RevId: 546806101
2023-07-07Register the PrfBasedDeriver protoserialization.tholenst
Note: in the KeyDerivationKeyTemplatesTest we need to remove the "LEGACY" test case since when deserializaing this and serializing it again it may change to "CRUNCHY". PiperOrigin-RevId: 546274713
2023-07-07Add Parser and Serializer for EciesParameters.ioannanedelcu
PiperOrigin-RevId: 546265787
2023-07-07Deprecate "KeyTemplate.getTypeUrl"tholenst
PiperOrigin-RevId: 546215532
2023-07-06Remove usages of Registry.getKeyManager and Registry.getUntypedKeyManager in ↵juerg
some tests. Instead, to verify that the key manager is registered, try to create a key. Also, remove the initialization test. It doesn't really add any additional value. PiperOrigin-RevId: 546012816
2023-07-06Avoid KeyTemplate.getTypeUrl().tholenst
This method will be deprecated/removed. PiperOrigin-RevId: 545928847
2023-07-05Add a static factory method createFrom to "KeyTemplate.java".tholenst
PiperOrigin-RevId: 545702188