aboutsummaryrefslogtreecommitdiff
path: root/auth
AgeCommit message (Collapse)Author
2020-07-24Merge tag 'upstream/v1.16.1' into HEADHadrien Zalek
Update the Java gRPC implementation source to that of a released version (v1.16.1) instead of some intermediate commit after v1.15.0. Test: m grpc-java Bug: 148404241 Change-Id: I9c072aee054a4aecc1bdf39adf45e9a243b907f5
2020-06-29Build the gRPC Java Authentication libraryHadrien Zalek
Add a Soong module to build the gRPC authentication library from source. Test: m grpc-java-auth grpc-java Bug: 148404241 Change-Id: I8afdf8c14773de4c13889016b0bfd8b6da132548
2018-10-26core: Make MetadataApplier an interface againEric Anderson
Swapping MetadataApplier to an abstract class is not ABI-safe for callers. So I revert back to the previous interface definition and introduce a CallCredentials2.MetadataApplier which is an abstract class. Once everyone is on CallCredentials2 then we can swap it to an abstract class again. Fixes #5002
2018-10-10core: add CallCredentials2 and deprecate CallCredentials' old interface (#4902)Kun Zhang
This is the first step of smoothly changing the CallCredentials API. Security level and authority are parameters required to be passed to applyRequestMetadata(). This change wraps them, along with MethodDescriptor and the transport attributes to RequestInfo, which is more clear to the implementers. ATTR_SECURITY_LEVEL is moved to the internal GrpcAttributes and annotated as TransportAttr, because transports are required to set it, but no user is actually reading them from {Client,Server}Call.getAttributes(). ATTR_AUTHORITY is removed, because no transport is overriding it. All involved interfaces are changed to abstract classes, as this will make further API changes smoother. The CallCredentials name is stabilized, thus we first introduce CallCredentials2, ask CallCredentials implementations to migrate to it, while GRPC accepting both at the same time, then replace CallCredentials with CallCredentials2.
2018-09-14all: use Java7 bracketsCarl Mastrangelo
2018-08-09all: update animalsniffer to Java 7 and add Android 14 (#4727)Eric Gribkoff
2018-07-31auth: Small improvement to test coverageEric Anderson
This removes an impossible condition and adds a test for another condition.
2018-06-11all: add gradle format checkerZHANG Dapeng
This PR adds an automatic gradle format checker and reformats all the *.gradle files. After this, new changes to *.gradle files will fail to build if not in good format, just like checkStyle failure.
2018-06-07auth: Require PRIVACY_AND_INTEGRITY for GoogleCredentials (#4524)Kun Zhang
This keeps them more secure. Other types of creds are left as-is, snce we don't quite know if it makes sense to have a similar restriction. (It likely does make sense, but this is a more precise change for our needs.) This is a rollforward of 8e9d4cbe5cb455315e55846e91706cccecb4b577 which was rolled back in de9515269635d2e8e84540fcd6744cc1a69ce81b Additional changes that were not in the original commit: 1. Treat null security level as NONE 2. When GoogleCredentials can't be loaded, log it at FINE
2018-05-31Revert "auth: Require PRIVACY_AND_INTEGRITY for GoogleCredentials" (#4521)Kun Zhang
This reverts commit 8e9d4cbe5cb455315e55846e91706cccecb4b577.
2018-05-24auth: Require PRIVACY_AND_INTEGRITY for GoogleCredentialsEric Anderson
This keeps them more secure. Other types of creds are left as-is, since we don't quite know if it makes sense to have a similar restriction. (It likely does make sense, but this is a more precise change for our needs.)
2018-05-03 all: normalize copyright header Carl Mastrangelo
2018-01-08auth,bazel: add a bazel build definitionjyane
2018-01-08Enable the Guava Beta CheckerEric Anderson
2017-12-04all: add Status messages to all statusesCarl Mastrangelo
2017-11-17auth: Use async version of getRequestMetadataEric Anderson
This avoids using DelayedStream and a thread hop when the credentials are known immediately.
2017-11-17auth: Treat IOExceptions as UNAVAILABLEEric Anderson
Fixes #3267
2017-10-02auth: remove use of JDK7 ReflectiveOperationExceptionEric Gribkoff
2017-08-11all: fix typo of overriddenZHANG Dapeng
s/overriden/overridden/g
2017-07-27core,auth: Stabilize auth flow using CallCredentialsEric Anderson
As discussed in #1914, we need CallCredentials and MoreCallCredentials to be stable, but there's less of a strong need for the contents of CallCredentials to be stable. We're willing to commit to the name, without needing to commit to the plumbing.
2017-06-30all: Use fixed version number for java 6/7 signaturesEric Anderson
This is important for stable builds, as if the signature changes the old source may no longer validate.
2017-06-01all: fix licence whitespaceCarl Mastrangelo
2017-05-31all: update to Apache 2 licenceCarl Mastrangelo
Also, update the authors.
2017-05-15core: don't expose internal Metadata.headerCountCarl Mastrangelo
2017-05-10doc: initiate some package javadocZHANG Dapeng
Initated package javadoc for * `io.grpc.stub`, * `io.grpc.auth`, * `io.grpc.util`, * `io.grpc.protobuf`, * `io.grpc.protobuf.lite`, * `io.grpc.protobuf.nano`
2017-02-07all: swap to newer animalsniffer pluginEric Anderson
The new plugin uses a newer version of animalsniffer, allows overriding the animalsniffer version used, and has up-to-date handling. The up-to-date handling cuts fully incremental parallel build times in half, from 5.5s to 2.7s. The previous plugin was supposed to be verifying tests. However, either it wasn't verifying them or its verification was broken.
2017-01-26all: update to latest import orderingCarl Mastrangelo
2017-01-23core: change method descriptor to be builder basedCarl Mastrangelo
2017-01-18docs: fix deprecation reference in ClientAuthInterceptor. (#2621)Kun Zhang
2016-08-30all/tests: unmock ClientCall and ServerCallCarl Mastrangelo
2016-08-12all: add parameter name to checkNotNullCarl Mastrangelo
After debugging #2153, it would have been nice to know what the exact parameter was that was null. This change adds a name for each checkNotNull (and tries to normalized on static imports in order to shorten lines)
2016-08-11auth: Tests should end in Test, not TestsEric Anderson
We use globs internally to find tests, and weren't finding these two tests. git ls-files confirmed these were the only two files ending in Tests.
2016-06-30auth: Promote OAuth2 service accounts to JWTEric Anderson
JWT needs less configuration and zero round-trips to initialize. Fixes #785
2016-06-24Remove unused variablesEric Anderson
This fixed a threading issue in ServerImpl because the unused variable should have been used.
2016-06-21auth: handle null value from getRequestMetadata().Kun Zhang
It appears some Credentials implementations may return null.
2016-06-21auth: revert ClientAuthInterceptor to its original implementation.Kun Zhang
This partially reverts commit def237d9606cc226f6b523f0818ae2ae664645cf. This is to avoid breaking internal tests that specifically verify the behavior of the original implementation.
2016-06-16auth: MoreCallCredentials.from(Credentials).Kun Zhang
It converts Google Auth Library Credentials to CallCredentials, and supersedes ClientAuthInterceptor, which is now deprecated. Also swaps out the ClientAuthInterceptor implementation. Caveat: This in fact changes ClientAuthInterceptor's behavior. Before this change, if multiple ClientAuthInterceptors were attached, their effects would be additive. After this change, only the last executed one would take effect, and it would also overwrite the CallCredentials set in CallOptions. We don't think it's an issue, since other languages also only allow one call credentials to be attached to an RPC.
2016-04-27Allow application to pass cancellation details.Kun Zhang
Resolves #1221 Add ClientCall.cancel(String, Throwable) and deprecate ClientCall.cancel(). Will delete cancel() after all known third-party overriders have switched to overriding the new one.
2016-04-18Update checkstyle version and sync style updatesEric Anderson
2016-02-11pauseCarl Mastrangelo
2015-09-11Use real authority parsing in ClientAuthInterceptorEric Anderson
2015-09-10Prevent construction of container classes and reduce APIEric Anderson
2015-09-04Remove uncessary javaee_api dependency as it causes trouble on android build.Xiao Hang
Seems no one actually depends on it. Please correct me if I was wrong.
2015-09-01Ease use of JWT by passing URI to auth libraryEric Anderson
The URI no longer needs to be provided to the Credential explicitly, which prevents needing to know a magic string and allows using the same Credential with multiple services.
2015-08-24Remove HeadersCarl Mastrangelo
2015-08-13Remove TrailersCarl Mastrangelo
2015-08-13Change some error status usages to be consistent with other gRPC ↵Xudong Ma
implementations.
2015-07-07Add CallOptions.Kun Zhang
- Pass CallOptions to Channel.newCall() and ClientInterceptor.interceptCall(). - Remove timeout from AbstractStub.StubConfigBuilder and add deadline, which is stored in a CallOptions inside the stub. - Deadline is in nanoseconds in the clock defined by System.nanoTime(). It is converted to timeout before transmitting on the wire. Fail the call with DEADLINE_EXCEEDED if it's already expired.
2015-06-19Make the code clearer, fixes #531.Xudong Ma
2015-06-04Rename Call to ClientCalls.Kun Zhang
Other classes are already following the convention that ClientFoo for client-side, and ServerFoo for server-side. Call has been the black sheep of the family. - Call -> ClientCall - Calls -> ClientCalls - ForwardingCall* -> ForwardingClientCall*