15
Google API Oauth2 + Android #GDGLima #AndroidTourPeru 2 de Abril, 2013 #AndroidLimaDay

Google api oauth2 + android

Embed Size (px)

Citation preview

Page 1: Google api oauth2 + android

Google API Oauth2 + Android

#GDGLima

#AndroidTourPeru

2 de Abril, 2013 #AndroidLimaDay

Page 2: Google api oauth2 + android

Google API Oauth2 + AndroidDiego Urbina López

Technologist & [email protected]/alevandie

@alevandie

Page 3: Google api oauth2 + android

IntroducciónToday I want explain how to implement this for your android proyect in a sample demo app, very quick and sure it helps you to research more about that.

Hoy aprenderemos:● Indicaciones básicas para el desarrollo del App Android implementando el

servicio Google+ API Oauth2 para Autenticación y Autorización del usuario. ● Mecanismo de seguridad y Proceso de Login desde la óptica de un Analista de

Sistemas.● Demo App Android, 'PlusSampleActivity'

https://github.com/GDGLima/GoogleAPIOauth2Android

#AndroidTourPeru

Page 4: Google api oauth2 + android

¿Qué es Google API Oauth2?

#AndroidTourPeru

Page 5: Google api oauth2 + android

● Servicio de Autenticación y Autorización en términos generales.

● Google ofrece sus propios mecanismos de OAuth para sus usuarios

● Servicio dedicado y orientado a la validación de cuentas Google.

● Orientado a brindar seguridad e integridad en la data (Google Account) de cada usuario.

#AndroidTourPeru

Page 6: Google api oauth2 + android

#AndroidTourPeru

Proceso del OAuth 2.0

https://developers.google.com/accounts/docs/OAuth2?hl=es#demo

Page 7: Google api oauth2 + android

#AndroidTourPeru

Page 8: Google api oauth2 + android

Oauth 2.0 App Android

#AndroidTourPeru

Medios de Autenticación

OAuth 1.0 (Hace un año)

OAuth 2.0 para aplicaciones

webOpen ID

Page 9: Google api oauth2 + android

¿A partir de qué versión de Android puedo utilizar?

#AndroidTourPeru

Using OAuth 2.0 for Login

¿Qué debo saber sobre OAuth para implementarlo?

https://developers.google.com/accounts/docs/OAuth2Login?hl=es

Page 10: Google api oauth2 + android

https://code.google.com/apis/console/

#AndroidTourPeru

1. API Console

a. Enable The Google+ API● In the Google APIs Console , create an API project for your application.● In the Services pane, enable the Google+ API and any other APIs that your app requires.● In the API Access pane, create an OAuth 2.0 client ID by clicking Create an OAuth 2.0 Client ID .● Type a product name in the dialog box that displays, and click Next.● Choose Installed application as your Application type and select Android as type.

● In the Package name field, enter your Android's app's package name. The package name used by the sample app is:

com.google.android.gms.samples.plus

Page 11: Google api oauth2 + android

#AndroidTourPeru

● In a terminal, run the the Keytool utility to get the SHA-1 fingerprint of the certificate.

keytool -exportcert -alias androiddebugkey -keystore

<path-to-debug-or-production-keystore> -list -v

Page 12: Google api oauth2 + android

#AndroidTourPeru

● The keytool prompts you to enter a password for the keystore. The default password for the debug keystore is android. Keytool then prints the fingerprint to the shell. For example:

Certificate fingerprint:

SHA1: DA:39:A3:EE:5E:6B:4B:0D:32:55:BF:EF:95:60:18:90:AF:

D8:07:09

cd c:\Program Files\Java\jdk1.6.0_25\bin

Page 13: Google api oauth2 + android

<Gracias por participar>http://gdgandroidtour.gdglima.org

[email protected]

@gdglima

Page 14: Google api oauth2 + android

<Preguntas?>

Page 15: Google api oauth2 + android

¡Muchas Gracias!

#AndroidTourPeru