instead");
- }
-}
diff --git a/google-api-client/src/main/java/com/google/api/client/googleapis/auth/clientlogin/ClientLogin.java b/google-api-client/src/main/java/com/google/api/client/googleapis/auth/clientlogin/ClientLogin.java
deleted file mode 100644
index 06a96c752..000000000
--- a/google-api-client/src/main/java/com/google/api/client/googleapis/auth/clientlogin/ClientLogin.java
+++ /dev/null
@@ -1,209 +0,0 @@
-/*
- * Copyright (c) 2010 Google Inc.
- *
- * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except
- * in compliance with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software distributed under the License
- * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express
- * or implied. See the License for the specific language governing permissions and limitations under
- * the License.
- */
-
-package com.google.api.client.googleapis.auth.clientlogin;
-
-import com.google.api.client.http.GenericUrl;
-import com.google.api.client.http.HttpExecuteInterceptor;
-import com.google.api.client.http.HttpRequest;
-import com.google.api.client.http.HttpRequestInitializer;
-import com.google.api.client.http.HttpResponse;
-import com.google.api.client.http.HttpResponseException;
-import com.google.api.client.http.HttpTransport;
-import com.google.api.client.http.UrlEncodedContent;
-import com.google.api.client.util.Beta;
-import com.google.api.client.util.Key;
-import com.google.api.client.util.StringUtils;
-import com.google.api.client.util.Strings;
-
-import java.io.IOException;
-
-/**
- * {@link Beta}
- * Client Login authentication method as described in ClientLogin for
- * Installed Applications.
- *
- * @since 1.0
- * @author Yaniv Inbar
- */
-@Beta
-public final class ClientLogin {
-
- /**
- * HTTP transport required for executing request in {@link #authenticate()}.
- *
- * @since 1.3
- */
- public HttpTransport transport;
-
- /**
- * URL for the Client Login authorization server.
- *
- *
- * By default this is {@code "https://www.google.com"}, but it may be overridden for testing
- * purposes.
- *
- *
- * @since 1.3
- */
- public GenericUrl serverUrl = new GenericUrl("https://www.google.com");
-
- /**
- * Short string identifying your application for logging purposes of the form:
- * "companyName-applicationName-versionID".
- */
- @Key("source")
- public String applicationName;
-
- /**
- * Name of the Google service you're requesting authorization for, for example {@code "cl"} for
- * Google Calendar.
- */
- @Key("service")
- public String authTokenType;
-
- /** User's full email address. */
- @Key("Email")
- public String username;
-
- /** User's password. */
- @Key("Passwd")
- public String password;
-
- /**
- * Type of account to request authorization for. Possible values are:
- *
- *
- * - GOOGLE (get authorization for a Google account only)
- * - HOSTED (get authorization for a hosted account only)
- * - HOSTED_OR_GOOGLE (get authorization first for a hosted account; if attempt fails, get
- * authorization for a Google account)
- *
- *
- * Use HOSTED_OR_GOOGLE if you're not sure which type of account you want authorization for. If
- * the user information matches both a hosted and a Google account, only the hosted account is
- * authorized.
- *
- * @since 1.1
- */
- @Key
- public String accountType;
-
- /** (optional) Token representing the specific CAPTCHA challenge. */
- @Key("logintoken")
- public String captchaToken;
-
- /** (optional) String entered by the user as an answer to a CAPTCHA challenge. */
- @Key("logincaptcha")
- public String captchaAnswer;
-
- /**
- * Key/value data to parse a success response.
- *
- *
- * Sample usage, taking advantage that this class implements {@link HttpRequestInitializer}:
- *
- *
- *
- public static HttpRequestFactory createRequestFactory(
- HttpTransport transport, Response response) {
- return transport.createRequestFactory(response);
- }
- *
- *
- *
- * If you have a custom request initializer, take a look at the sample usage for
- * {@link HttpExecuteInterceptor}, which this class also implements.
- *
- */
- public static final class Response implements HttpExecuteInterceptor, HttpRequestInitializer {
-
- /** Authentication token. */
- @Key("Auth")
- public String auth;
-
- /** Returns the authorization header value to use based on the authentication token. */
- public String getAuthorizationHeaderValue() {
- return ClientLogin.getAuthorizationHeaderValue(auth);
- }
-
- public void initialize(HttpRequest request) {
- request.setInterceptor(this);
- }
-
- public void intercept(HttpRequest request) {
- request.getHeaders().setAuthorization(getAuthorizationHeaderValue());
- }
- }
-
- /** Key/value data to parse an error response. */
- public static final class ErrorInfo {
-
- @Key("Error")
- public String error;
-
- @Key("Url")
- public String url;
-
- @Key("CaptchaToken")
- public String captchaToken;
-
- @Key("CaptchaUrl")
- public String captchaUrl;
- }
-
- /**
- * Authenticates based on the provided field values.
- *
- * @throws ClientLoginResponseException if the authentication response has an error code, such as
- * for a CAPTCHA challenge.
- */
- public Response authenticate() throws IOException {
- GenericUrl url = serverUrl.clone();
- url.appendRawPath("/accounts/ClientLogin");
- HttpRequest request =
- transport.createRequestFactory().buildPostRequest(url, new UrlEncodedContent(this));
- request.setParser(AuthKeyValueParser.INSTANCE);
- request.setContentLoggingLimit(0);
- request.setThrowExceptionOnExecuteError(false);
- HttpResponse response = request.execute();
- // check for an HTTP success response (2xx)
- if (response.isSuccessStatusCode()) {
- return response.parseAs(Response.class);
- }
- HttpResponseException.Builder builder = new HttpResponseException.Builder(
- response.getStatusCode(), response.getStatusMessage(), response.getHeaders());
- // On error, throw a ClientLoginResponseException with the parsed error details
- ErrorInfo details = response.parseAs(ErrorInfo.class);
- String detailString = details.toString();
- StringBuilder message = HttpResponseException.computeMessageBuffer(response);
- if (!Strings.isNullOrEmpty(detailString)) {
- message.append(StringUtils.LINE_SEPARATOR).append(detailString);
- builder.setContent(detailString);
- }
- builder.setMessage(message.toString());
- throw new ClientLoginResponseException(builder, details);
- }
-
- /**
- * Returns Google Login {@code "Authorization"} header value based on the given authentication
- * token.
- *
- * @since 1.13
- */
- public static String getAuthorizationHeaderValue(String authToken) {
- return "GoogleLogin auth=" + authToken;
- }
-}
diff --git a/google-api-client/src/main/java/com/google/api/client/googleapis/auth/clientlogin/ClientLoginResponseException.java b/google-api-client/src/main/java/com/google/api/client/googleapis/auth/clientlogin/ClientLoginResponseException.java
deleted file mode 100644
index b6d74f549..000000000
--- a/google-api-client/src/main/java/com/google/api/client/googleapis/auth/clientlogin/ClientLoginResponseException.java
+++ /dev/null
@@ -1,54 +0,0 @@
-/*
- * Copyright (c) 2011 Google Inc.
- *
- * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except
- * in compliance with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software distributed under the License
- * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express
- * or implied. See the License for the specific language governing permissions and limitations under
- * the License.
- */
-
-package com.google.api.client.googleapis.auth.clientlogin;
-
-import com.google.api.client.googleapis.auth.clientlogin.ClientLogin.ErrorInfo;
-import com.google.api.client.http.HttpResponseException;
-import com.google.api.client.util.Beta;
-
-/**
- * {@link Beta}
- * Exception thrown when an error status code is detected in an HTTP response to a Google
- * ClientLogin request in {@link ClientLogin} .
- *
- *
- * To get the structured details, use {@link #getDetails()}.
- *
- *
- * @since 1.7
- * @author Yaniv Inbar
- */
-@Beta
-public class ClientLoginResponseException extends HttpResponseException {
-
- private static final long serialVersionUID = 4974317674023010928L;
-
- /** Error details or {@code null} for none. */
- private final transient ErrorInfo details;
-
- /**
- * @param builder builder
- * @param details error details or {@code null} for none
- */
- ClientLoginResponseException(Builder builder, ErrorInfo details) {
- super(builder);
- this.details = details;
- }
-
- /** Return the error details or {@code null} for none. */
- public final ErrorInfo getDetails() {
- return details;
- }
-}
diff --git a/google-api-client/src/main/java/com/google/api/client/googleapis/auth/clientlogin/package-info.java b/google-api-client/src/main/java/com/google/api/client/googleapis/auth/clientlogin/package-info.java
deleted file mode 100644
index 316a58b47..000000000
--- a/google-api-client/src/main/java/com/google/api/client/googleapis/auth/clientlogin/package-info.java
+++ /dev/null
@@ -1,26 +0,0 @@
-/*
- * Copyright (c) 2010 Google Inc.
- *
- * Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except
- * in compliance with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software distributed under the License
- * is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express
- * or implied. See the License for the specific language governing permissions and limitations under
- * the License.
- */
-
-/**
- * {@link com.google.api.client.util.Beta}
- * Google's legacy ClientLogin authentication method as described in ClientLogin for
- * Installed Applications.
- *
- * @since 1.0
- * @author Yaniv Inbar
- */
-@com.google.api.client.util.Beta
-package com.google.api.client.googleapis.auth.clientlogin;
-
diff --git a/pom.xml b/pom.xml
index 42800549c..a4791b0f7 100644
--- a/pom.xml
+++ b/pom.xml
@@ -481,7 +481,7 @@
org.codehaus.mojo
clirr-maven-plugin
- 1.19.0
+ 1.27.0
${basedir}/../clirr-ignored-differences.xml
true