├── iOS
├── ITunesArtwork
├── ITunesArtwork@2x
├── Resources
│ ├── Default.png
│ ├── Icon-76.png
│ ├── Default@2x.png
│ ├── Icon-60@2x.png
│ ├── Icon-60@3x.png
│ ├── Icon-76@2x.png
│ ├── Icon-Small.png
│ ├── Icon-Small-40.png
│ ├── Icon-Small@2x.png
│ ├── Icon-Small@3x.png
│ ├── Default-568h@2x.png
│ ├── Default-Portrait.png
│ ├── Icon-Small-40@2x.png
│ ├── Icon-Small-40@3x.png
│ ├── Default-Portrait@2x.png
│ └── LaunchScreen.storyboard
├── packages.config
├── Entitlements.plist
├── Main.cs
├── AppDelegate.cs
├── Renderers
│ └── LoginPageRenderer.cs
├── Info.plist
└── XamarinFormsOAuth2Demo.iOS.csproj
├── screenshots
├── Login_iOS.png
├── StartPage.png
├── ProfilePage.png
├── Login_AndroidPlayer.png
├── Login_AppPermissions.png
├── Google_CreateNewProject.png
├── Google_OAuth2Parameters.png
├── Google_EnableGooglePlusApi.png
├── Google_SetRedirectAddress.png
└── Google_ChooseWebApplication.png
├── Components
├── xamarin.auth-1.2.3.1.png
├── xamarin.auth-1.2.3.1
│ ├── docs
│ │ ├── xamarin.auth.tree
│ │ ├── xamarin.auth.zip
│ │ └── xamarin.auth.source
│ ├── component
│ │ ├── screenshots
│ │ │ └── 00.png
│ │ ├── icons
│ │ │ ├── xamarin.auth_128x128.png
│ │ │ └── xamarin.auth_512x512.png
│ │ ├── Manifest.xml
│ │ ├── Details.md
│ │ ├── GettingStarted.md
│ │ └── License.md
│ └── lib
│ │ ├── ios
│ │ ├── Xamarin.Auth.iOS.dll
│ │ └── Xamarin.Auth.iOS.xml
│ │ ├── android
│ │ ├── Xamarin.Auth.Android.dll
│ │ └── Xamarin.Auth.Android.xml
│ │ └── ios-unified
│ │ └── Xamarin.Auth.iOS.dll
└── xamarin.auth-1.2.3.1.info
├── Droid
├── Resources
│ ├── drawable
│ │ └── icon.png
│ ├── drawable-hdpi
│ │ └── icon.png
│ ├── drawable-xhdpi
│ │ └── icon.png
│ ├── drawable-xxhdpi
│ │ └── icon.png
│ └── AboutResources.txt
├── Properties
│ ├── AndroidManifest.xml
│ └── AssemblyInfo.cs
├── packages.config
├── Assets
│ └── AboutAssets.txt
├── MainActivity.cs
├── Renderers
│ ├── LoginPageRenderer.cs
│ └── TwitterLoginPageRenderer.cs
└── XamarinFormsOAuth2Demo.Droid.csproj
├── XamarinFormsOAuth2Demo
├── Pages
│ ├── LoginPage.cs
│ ├── TwitterLoginPage.cs
│ ├── StartPage.cs
│ └── ProfilePage.cs
├── Models
│ └── GoogleUserInfo.cs
├── packages.config
├── Properties
│ └── AssemblyInfo.cs
├── XamarinFormsOAuth2Demo.cs
└── XamarinFormsOAuth2Demo.csproj
├── .gitignore
├── README.md
└── XamarinFormsOAuth2Demo.sln
/iOS/ITunesArtwork:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/EdHubbell/XamarinFormsOauth2Demo/HEAD/iOS/ITunesArtwork
--------------------------------------------------------------------------------
/iOS/ITunesArtwork@2x:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/EdHubbell/XamarinFormsOauth2Demo/HEAD/iOS/ITunesArtwork@2x
--------------------------------------------------------------------------------
/iOS/Resources/Default.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/EdHubbell/XamarinFormsOauth2Demo/HEAD/iOS/Resources/Default.png
--------------------------------------------------------------------------------
/iOS/Resources/Icon-76.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/EdHubbell/XamarinFormsOauth2Demo/HEAD/iOS/Resources/Icon-76.png
--------------------------------------------------------------------------------
/screenshots/Login_iOS.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/EdHubbell/XamarinFormsOauth2Demo/HEAD/screenshots/Login_iOS.png
--------------------------------------------------------------------------------
/screenshots/StartPage.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/EdHubbell/XamarinFormsOauth2Demo/HEAD/screenshots/StartPage.png
--------------------------------------------------------------------------------
/screenshots/ProfilePage.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/EdHubbell/XamarinFormsOauth2Demo/HEAD/screenshots/ProfilePage.png
--------------------------------------------------------------------------------
/iOS/Resources/Default@2x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/EdHubbell/XamarinFormsOauth2Demo/HEAD/iOS/Resources/Default@2x.png
--------------------------------------------------------------------------------
/iOS/Resources/Icon-60@2x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/EdHubbell/XamarinFormsOauth2Demo/HEAD/iOS/Resources/Icon-60@2x.png
--------------------------------------------------------------------------------
/iOS/Resources/Icon-60@3x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/EdHubbell/XamarinFormsOauth2Demo/HEAD/iOS/Resources/Icon-60@3x.png
--------------------------------------------------------------------------------
/iOS/Resources/Icon-76@2x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/EdHubbell/XamarinFormsOauth2Demo/HEAD/iOS/Resources/Icon-76@2x.png
--------------------------------------------------------------------------------
/iOS/Resources/Icon-Small.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/EdHubbell/XamarinFormsOauth2Demo/HEAD/iOS/Resources/Icon-Small.png
--------------------------------------------------------------------------------
/iOS/Resources/Icon-Small-40.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/EdHubbell/XamarinFormsOauth2Demo/HEAD/iOS/Resources/Icon-Small-40.png
--------------------------------------------------------------------------------
/iOS/Resources/Icon-Small@2x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/EdHubbell/XamarinFormsOauth2Demo/HEAD/iOS/Resources/Icon-Small@2x.png
--------------------------------------------------------------------------------
/iOS/Resources/Icon-Small@3x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/EdHubbell/XamarinFormsOauth2Demo/HEAD/iOS/Resources/Icon-Small@3x.png
--------------------------------------------------------------------------------
/Components/xamarin.auth-1.2.3.1.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/EdHubbell/XamarinFormsOauth2Demo/HEAD/Components/xamarin.auth-1.2.3.1.png
--------------------------------------------------------------------------------
/Droid/Resources/drawable/icon.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/EdHubbell/XamarinFormsOauth2Demo/HEAD/Droid/Resources/drawable/icon.png
--------------------------------------------------------------------------------
/iOS/Resources/Default-568h@2x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/EdHubbell/XamarinFormsOauth2Demo/HEAD/iOS/Resources/Default-568h@2x.png
--------------------------------------------------------------------------------
/iOS/Resources/Default-Portrait.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/EdHubbell/XamarinFormsOauth2Demo/HEAD/iOS/Resources/Default-Portrait.png
--------------------------------------------------------------------------------
/iOS/Resources/Icon-Small-40@2x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/EdHubbell/XamarinFormsOauth2Demo/HEAD/iOS/Resources/Icon-Small-40@2x.png
--------------------------------------------------------------------------------
/iOS/Resources/Icon-Small-40@3x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/EdHubbell/XamarinFormsOauth2Demo/HEAD/iOS/Resources/Icon-Small-40@3x.png
--------------------------------------------------------------------------------
/screenshots/Login_AndroidPlayer.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/EdHubbell/XamarinFormsOauth2Demo/HEAD/screenshots/Login_AndroidPlayer.png
--------------------------------------------------------------------------------
/iOS/Resources/Default-Portrait@2x.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/EdHubbell/XamarinFormsOauth2Demo/HEAD/iOS/Resources/Default-Portrait@2x.png
--------------------------------------------------------------------------------
/screenshots/Login_AppPermissions.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/EdHubbell/XamarinFormsOauth2Demo/HEAD/screenshots/Login_AppPermissions.png
--------------------------------------------------------------------------------
/Droid/Resources/drawable-hdpi/icon.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/EdHubbell/XamarinFormsOauth2Demo/HEAD/Droid/Resources/drawable-hdpi/icon.png
--------------------------------------------------------------------------------
/Droid/Resources/drawable-xhdpi/icon.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/EdHubbell/XamarinFormsOauth2Demo/HEAD/Droid/Resources/drawable-xhdpi/icon.png
--------------------------------------------------------------------------------
/Droid/Resources/drawable-xxhdpi/icon.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/EdHubbell/XamarinFormsOauth2Demo/HEAD/Droid/Resources/drawable-xxhdpi/icon.png
--------------------------------------------------------------------------------
/screenshots/Google_CreateNewProject.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/EdHubbell/XamarinFormsOauth2Demo/HEAD/screenshots/Google_CreateNewProject.png
--------------------------------------------------------------------------------
/screenshots/Google_OAuth2Parameters.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/EdHubbell/XamarinFormsOauth2Demo/HEAD/screenshots/Google_OAuth2Parameters.png
--------------------------------------------------------------------------------
/screenshots/Google_EnableGooglePlusApi.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/EdHubbell/XamarinFormsOauth2Demo/HEAD/screenshots/Google_EnableGooglePlusApi.png
--------------------------------------------------------------------------------
/screenshots/Google_SetRedirectAddress.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/EdHubbell/XamarinFormsOauth2Demo/HEAD/screenshots/Google_SetRedirectAddress.png
--------------------------------------------------------------------------------
/screenshots/Google_ChooseWebApplication.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/EdHubbell/XamarinFormsOauth2Demo/HEAD/screenshots/Google_ChooseWebApplication.png
--------------------------------------------------------------------------------
/Components/xamarin.auth-1.2.3.1/docs/xamarin.auth.tree:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/EdHubbell/XamarinFormsOauth2Demo/HEAD/Components/xamarin.auth-1.2.3.1/docs/xamarin.auth.tree
--------------------------------------------------------------------------------
/Components/xamarin.auth-1.2.3.1/docs/xamarin.auth.zip:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/EdHubbell/XamarinFormsOauth2Demo/HEAD/Components/xamarin.auth-1.2.3.1/docs/xamarin.auth.zip
--------------------------------------------------------------------------------
/iOS/packages.config:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
--------------------------------------------------------------------------------
/Components/xamarin.auth-1.2.3.1/component/screenshots/00.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/EdHubbell/XamarinFormsOauth2Demo/HEAD/Components/xamarin.auth-1.2.3.1/component/screenshots/00.png
--------------------------------------------------------------------------------
/Components/xamarin.auth-1.2.3.1/lib/ios/Xamarin.Auth.iOS.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/EdHubbell/XamarinFormsOauth2Demo/HEAD/Components/xamarin.auth-1.2.3.1/lib/ios/Xamarin.Auth.iOS.dll
--------------------------------------------------------------------------------
/Components/xamarin.auth-1.2.3.1/lib/android/Xamarin.Auth.Android.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/EdHubbell/XamarinFormsOauth2Demo/HEAD/Components/xamarin.auth-1.2.3.1/lib/android/Xamarin.Auth.Android.dll
--------------------------------------------------------------------------------
/Components/xamarin.auth-1.2.3.1/lib/ios-unified/Xamarin.Auth.iOS.dll:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/EdHubbell/XamarinFormsOauth2Demo/HEAD/Components/xamarin.auth-1.2.3.1/lib/ios-unified/Xamarin.Auth.iOS.dll
--------------------------------------------------------------------------------
/XamarinFormsOAuth2Demo/Pages/LoginPage.cs:
--------------------------------------------------------------------------------
1 | using System;
2 |
3 | using Xamarin.Forms;
4 |
5 | namespace XamarinFormsOAuth2Demo
6 | {
7 | public class LoginPage : ContentPage
8 | {
9 | }
10 | }
--------------------------------------------------------------------------------
/Components/xamarin.auth-1.2.3.1/component/icons/xamarin.auth_128x128.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/EdHubbell/XamarinFormsOauth2Demo/HEAD/Components/xamarin.auth-1.2.3.1/component/icons/xamarin.auth_128x128.png
--------------------------------------------------------------------------------
/Components/xamarin.auth-1.2.3.1/component/icons/xamarin.auth_512x512.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/EdHubbell/XamarinFormsOauth2Demo/HEAD/Components/xamarin.auth-1.2.3.1/component/icons/xamarin.auth_512x512.png
--------------------------------------------------------------------------------
/XamarinFormsOAuth2Demo/Pages/TwitterLoginPage.cs:
--------------------------------------------------------------------------------
1 | using System;
2 |
3 | using Xamarin.Forms;
4 |
5 | namespace XamarinFormsOAuth2Demo
6 | {
7 | public class TwitterLoginPage : ContentPage
8 | {
9 | }
10 | }
11 |
12 |
13 |
--------------------------------------------------------------------------------
/iOS/Entitlements.plist:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
--------------------------------------------------------------------------------
/Droid/Properties/AndroidManifest.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
--------------------------------------------------------------------------------
/Components/xamarin.auth-1.2.3.1/docs/xamarin.auth.source:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
--------------------------------------------------------------------------------
/.gitignore:
--------------------------------------------------------------------------------
1 | #Autosave files
2 | *~
3 |
4 | # Build/test output
5 | obj
6 | bin
7 | test-results
8 | Debug
9 | samples
10 |
11 | packages
12 |
13 | # VS sometimes writes these for no apparent reason
14 | _UpgradeReport_Files
15 | UpgradeLog.*
16 |
17 | # Per-user data
18 | *.DS_Store
19 | *.sln.cache
20 | *.suo
21 | *.userprefs
22 | *.usertasks
23 | *.user
24 |
25 | # ReSharper
26 | *_Resharper.*
27 | *.Resharper
28 |
29 | # dotCover
30 | *.dotCover
31 |
32 |
--------------------------------------------------------------------------------
/iOS/Main.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using System.Collections.Generic;
3 | using System.Linq;
4 |
5 | using Foundation;
6 | using UIKit;
7 |
8 | namespace XamarinFormsOAuth2Demo.iOS
9 | {
10 | public class Application
11 | {
12 | // This is the main entry point of the application.
13 | static void Main (string[] args)
14 | {
15 | // if you want to use a different Application Delegate class from "AppDelegate"
16 | // you can specify it here.
17 | UIApplication.Main (args, null, "AppDelegate");
18 | }
19 | }
20 | }
21 |
22 |
--------------------------------------------------------------------------------
/iOS/AppDelegate.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using System.Collections.Generic;
3 | using System.Linq;
4 |
5 | using Foundation;
6 | using UIKit;
7 |
8 | namespace XamarinFormsOAuth2Demo.iOS
9 | {
10 | [Register ("AppDelegate")]
11 | public partial class AppDelegate : global::Xamarin.Forms.Platform.iOS.FormsApplicationDelegate
12 | {
13 | public override bool FinishedLaunching (UIApplication app, NSDictionary options)
14 | {
15 | global::Xamarin.Forms.Forms.Init ();
16 |
17 | LoadApplication (new App ());
18 |
19 | return base.FinishedLaunching (app, options);
20 | }
21 | }
22 | }
23 |
24 |
--------------------------------------------------------------------------------
/Droid/packages.config:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
--------------------------------------------------------------------------------
/Droid/Assets/AboutAssets.txt:
--------------------------------------------------------------------------------
1 | Any raw assets you want to be deployed with your application can be placed in
2 | this directory (and child directories) and given a Build Action of "AndroidAsset".
3 |
4 | These files will be deployed with your package and will be accessible using Android's
5 | AssetManager, like this:
6 |
7 | public class ReadAsset : Activity
8 | {
9 | protected override void OnCreate (Bundle bundle)
10 | {
11 | base.OnCreate (bundle);
12 |
13 | InputStream input = Assets.Open ("my_asset.txt");
14 | }
15 | }
16 |
17 | Additionally, some Android functions will automatically load asset files:
18 |
19 | Typeface tf = Typeface.CreateFromAsset (Context.Assets, "fonts/samplefont.ttf");
20 |
--------------------------------------------------------------------------------
/Droid/MainActivity.cs:
--------------------------------------------------------------------------------
1 | using System;
2 |
3 | using Android.App;
4 | using Android.Content;
5 | using Android.Content.PM;
6 | using Android.Runtime;
7 | using Android.Views;
8 | using Android.Widget;
9 | using Android.OS;
10 |
11 | namespace XamarinFormsOAuth2Demo.Droid
12 | {
13 | [Activity (Label = "XamarinFormsOAuth2Demo.Droid", Icon = "@drawable/icon", MainLauncher = true, ConfigurationChanges = ConfigChanges.ScreenSize | ConfigChanges.Orientation)]
14 | public class MainActivity : global::Xamarin.Forms.Platform.Android.FormsApplicationActivity
15 | {
16 | protected override void OnCreate (Bundle bundle)
17 | {
18 | base.OnCreate (bundle);
19 |
20 | global::Xamarin.Forms.Forms.Init (this, bundle);
21 |
22 | LoadApplication (new App ());
23 | }
24 | }
25 | }
26 |
27 |
--------------------------------------------------------------------------------
/XamarinFormsOAuth2Demo/Models/GoogleUserInfo.cs:
--------------------------------------------------------------------------------
1 | using System;
2 |
3 | namespace XamarinFormsOAuth2Demo
4 | {
5 | public class GoogleUserInfo
6 | {
7 | public GoogleUserInfo ()
8 | {
9 | }
10 |
11 | [Newtonsoft.Json.JsonProperty ("id")]
12 | public string id{ get; set; }
13 |
14 | [Newtonsoft.Json.JsonProperty ("email")]
15 | public string email{ get; set; }
16 |
17 | [Newtonsoft.Json.JsonProperty ("verified_email")]
18 | public bool verified_email{ get; set; }
19 |
20 | [Newtonsoft.Json.JsonProperty ("name")]
21 | public string name{ get; set; }
22 |
23 | [Newtonsoft.Json.JsonProperty ("given_name")]
24 | public string given_name{ get; set; }
25 |
26 | [Newtonsoft.Json.JsonProperty ("family_name")]
27 | public string family_name{ get; set; }
28 |
29 | [Newtonsoft.Json.JsonProperty ("picture")]
30 | public string picture{ get; set; }
31 |
32 | }
33 | }
34 |
35 |
--------------------------------------------------------------------------------
/XamarinFormsOAuth2Demo/packages.config:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
--------------------------------------------------------------------------------
/Components/xamarin.auth-1.2.3.1/component/Manifest.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 | Xamarin.Auth
4 | Xamarin
5 | http://xamarin.com/
6 | 1.2.3.1
7 | A cross-platform API for authenticating users and storing their accounts.
8 |
9 |
10 |
11 |
12 |
13 | Android Sample
14 | Android Sample
15 |
16 |
17 | iOS Unified Sample
18 | iOS Unified Sample
19 |
20 |
21 | iOS Classic Sample
22 | iOS Classic Sample
23 |
24 |
25 |
--------------------------------------------------------------------------------
/Components/xamarin.auth-1.2.3.1/component/Details.md:
--------------------------------------------------------------------------------
1 | Xamarin.Auth helps you authenticate users via standard authentication mechanisms (e.g. OAuth 1.0 and 2.0), and store user credentials. It's also straightforward to add support for non-standard authentication schemes. The library is cross-platform, so once you learn it on iOS, you're all set on Android.
2 |
3 | ```csharp
4 | using Xamarin.Auth;
5 |
6 | var auth = new OAuth2Authenticator (
7 | clientId: "App ID from https://developers.facebook.com/apps",
8 | scope: "",
9 | authorizeUrl: new Uri ("https://m.facebook.com/dialog/oauth/"),
10 | redirectUrl: new Uri ("http://www.facebook.com/connect/login_success.html"));
11 |
12 | auth.Completed += (sender, eventArgs) => {
13 | DismissViewController (true, null);
14 | if (eventArgs.IsAuthenticated) {
15 | // Use eventArgs.Account to do wonderful things
16 | }
17 | }
18 |
19 | PresentViewController (auth.GetUI (), true, null);
20 | ```
21 |
22 | It's that easy to authenticate users!
23 |
24 | *Some screenshots assembled with [PlaceIt](http://placeit.breezi.com/).*
25 |
--------------------------------------------------------------------------------
/XamarinFormsOAuth2Demo/Properties/AssemblyInfo.cs:
--------------------------------------------------------------------------------
1 | using System.Reflection;
2 | using System.Runtime.CompilerServices;
3 |
4 | // Information about this assembly is defined by the following attributes.
5 | // Change them to the values specific to your project.
6 |
7 | [assembly: AssemblyTitle ("XamarinFormsOAuth2Demo")]
8 | [assembly: AssemblyDescription ("")]
9 | [assembly: AssemblyConfiguration ("")]
10 | [assembly: AssemblyCompany ("")]
11 | [assembly: AssemblyProduct ("")]
12 | [assembly: AssemblyCopyright ("ed")]
13 | [assembly: AssemblyTrademark ("")]
14 | [assembly: AssemblyCulture ("")]
15 |
16 | // The assembly version has the format "{Major}.{Minor}.{Build}.{Revision}".
17 | // The form "{Major}.{Minor}.*" will automatically update the build and revision,
18 | // and "{Major}.{Minor}.{Build}.*" will update just the revision.
19 |
20 | [assembly: AssemblyVersion ("1.0.*")]
21 |
22 | // The following attributes are used to specify the signing key for the assembly,
23 | // if desired. See the Mono documentation for more information about signing.
24 |
25 | //[assembly: AssemblyDelaySign(false)]
26 | //[assembly: AssemblyKeyFile("")]
27 |
28 |
--------------------------------------------------------------------------------
/Droid/Properties/AssemblyInfo.cs:
--------------------------------------------------------------------------------
1 | using System.Reflection;
2 | using System.Runtime.CompilerServices;
3 | using Android.App;
4 |
5 | // Information about this assembly is defined by the following attributes.
6 | // Change them to the values specific to your project.
7 |
8 | [assembly: AssemblyTitle ("XamarinFormsOAuth2Demo.Droid")]
9 | [assembly: AssemblyDescription ("")]
10 | [assembly: AssemblyConfiguration ("")]
11 | [assembly: AssemblyCompany ("")]
12 | [assembly: AssemblyProduct ("")]
13 | [assembly: AssemblyCopyright ("ed")]
14 | [assembly: AssemblyTrademark ("")]
15 | [assembly: AssemblyCulture ("")]
16 |
17 | // The assembly version has the format "{Major}.{Minor}.{Build}.{Revision}".
18 | // The form "{Major}.{Minor}.*" will automatically update the build and revision,
19 | // and "{Major}.{Minor}.{Build}.*" will update just the revision.
20 |
21 | [assembly: AssemblyVersion ("1.0.0")]
22 |
23 | // The following attributes are used to specify the signing key for the assembly,
24 | // if desired. See the Mono documentation for more information about signing.
25 |
26 | //[assembly: AssemblyDelaySign(false)]
27 | //[assembly: AssemblyKeyFile("")]
28 |
29 |
--------------------------------------------------------------------------------
/Droid/Renderers/LoginPageRenderer.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using Android.App;
3 | using XamarinFormsOAuth2Demo;
4 | using XamarinFormsOAuth2Demo.Droid;
5 | using Xamarin.Auth;
6 | using Xamarin.Forms;
7 | using Xamarin.Forms.Platform.Android;
8 |
9 | [assembly: ExportRenderer (typeof (LoginPage), typeof (LoginPageRenderer))]
10 |
11 | namespace XamarinFormsOAuth2Demo.Droid
12 | {
13 | public class LoginPageRenderer : PageRenderer
14 | {
15 | bool done = false;
16 |
17 | protected override void OnElementChanged (ElementChangedEventArgs e)
18 | {
19 | base.OnElementChanged(e);
20 |
21 | if (!done) {
22 |
23 | // this is a ViewGroup - so should be able to load an AXML file and FindView<>
24 | var activity = this.Context as Activity;
25 |
26 | var auth = new OAuth2Authenticator (
27 | clientId: App.Current.Properties ["clientId"].ToString(),
28 | scope: App.Current.Properties ["scope"].ToString(),
29 | authorizeUrl: new Uri( App.Current.Properties ["authorizeUrl"].ToString()),
30 | redirectUrl: new Uri(App.Current.Properties ["redirectUrl"].ToString()));
31 |
32 | auth.Completed += (sender, eventArgs) => {
33 | if (eventArgs.IsAuthenticated)
34 | {
35 | App.Current.MainPage = new ProfilePage();
36 |
37 | App.Current.Properties ["access_token"] = eventArgs.Account.Properties ["access_token"].ToString();
38 |
39 | //AccountStore.Create (this).Save (eventArgs.Account, "Google");
40 | }
41 | else
42 | {
43 | // Auth failed - The only way to get to this branch on Google is to hit the 'Cancel' button.
44 | App.Current.MainPage = new StartPage();
45 | App.Current.Properties ["access_token"] = "";
46 | }
47 | };
48 |
49 | //auth.AllowCancel = false;
50 | activity.StartActivity (auth.GetUI (activity));
51 | done = true;
52 | }
53 | }
54 | }
55 | }
56 |
--------------------------------------------------------------------------------
/Droid/Resources/AboutResources.txt:
--------------------------------------------------------------------------------
1 | Images, layout descriptions, binary blobs and string dictionaries can be included
2 | in your application as resource files. Various Android APIs are designed to
3 | operate on the resource IDs instead of dealing with images, strings or binary blobs
4 | directly.
5 |
6 | For example, a sample Android app that contains a user interface layout (main.axml),
7 | an internationalization string table (strings.xml) and some icons (drawable-XXX/icon.png)
8 | would keep its resources in the "Resources" directory of the application:
9 |
10 | Resources/
11 | drawable/
12 | icon.png
13 |
14 | layout/
15 | main.axml
16 |
17 | values/
18 | strings.xml
19 |
20 | In order to get the build system to recognize Android resources, set the build action to
21 | "AndroidResource". The native Android APIs do not operate directly with filenames, but
22 | instead operate on resource IDs. When you compile an Android application that uses resources,
23 | the build system will package the resources for distribution and generate a class called "R"
24 | (this is an Android convention) that contains the tokens for each one of the resources
25 | included. For example, for the above Resources layout, this is what the R class would expose:
26 |
27 | public class R {
28 | public class drawable {
29 | public const int icon = 0x123;
30 | }
31 |
32 | public class layout {
33 | public const int main = 0x456;
34 | }
35 |
36 | public class strings {
37 | public const int first_string = 0xabc;
38 | public const int second_string = 0xbcd;
39 | }
40 | }
41 |
42 | You would then use R.drawable.icon to reference the drawable/icon.png file, or R.layout.main
43 | to reference the layout/main.axml file, or R.strings.first_string to reference the first
44 | string in the dictionary file values/strings.xml.
45 |
--------------------------------------------------------------------------------
/iOS/Renderers/LoginPageRenderer.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using Xamarin.Auth;
3 | using Xamarin.Forms.Platform.iOS;
4 | using Xamarin.Forms;
5 | using XamarinFormsOAuth2Demo;
6 | using XamarinFormsOAuth2Demo.iOS;
7 |
8 | [assembly: ExportRenderer (typeof (LoginPage), typeof (LoginPageRenderer))]
9 |
10 | namespace XamarinFormsOAuth2Demo.iOS
11 | {
12 | public class LoginPageRenderer : PageRenderer
13 | {
14 |
15 | bool IsShown;
16 |
17 | public override void ViewDidAppear (bool animated)
18 | {
19 | base.ViewDidAppear (animated);
20 |
21 | if( ! IsShown ) {
22 |
23 | IsShown = true;
24 |
25 | var auth = new OAuth2Authenticator (
26 | clientId: App.Current.Properties ["clientId"].ToString(),
27 | scope: App.Current.Properties ["scope"].ToString(),
28 | authorizeUrl: new Uri( App.Current.Properties ["authorizeUrl"].ToString()),
29 | redirectUrl: new Uri(App.Current.Properties ["redirectUrl"].ToString()));
30 |
31 |
32 | auth.Completed += (sender, eventArgs) => {
33 | if (eventArgs.IsAuthenticated) {
34 |
35 | App.Current.Properties ["access_token"] = eventArgs.Account.Properties ["access_token"].ToString();
36 |
37 | //AccountStore.Create ().Save (eventArgs.Account, "Google");
38 |
39 | // OK, if we get this far, then the user is authenticated - That's great.
40 | // So change the App MainPage so we're at a location that only Auth users can get to.
41 | App.Current.MainPage = new ProfilePage();
42 |
43 |
44 | } else {
45 | // Auth failed - The only way to get to this branch on Google is to hit the 'Cancel' button.
46 | App.Current.MainPage = new StartPage();
47 |
48 | App.Current.Properties ["access_token"] = "";
49 | }
50 | };
51 |
52 | // This is what actually launches the auth web UI.
53 | PresentViewController (auth.GetUI (), true, null);
54 |
55 | }
56 |
57 | }
58 |
59 | }
60 | }
61 |
--------------------------------------------------------------------------------
/Droid/Renderers/TwitterLoginPageRenderer.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using Android.App;
3 | using XamarinFormsOAuth2Demo;
4 | using XamarinFormsOAuth2Demo.Droid;
5 | using Xamarin.Auth;
6 | using Xamarin.Forms;
7 | using Xamarin.Forms.Platform.Android;
8 |
9 | [assembly: ExportRenderer (typeof (TwitterLoginPage), typeof (TwitterLoginPageRenderer))]
10 |
11 | namespace XamarinFormsOAuth2Demo.Droid
12 | {
13 | public class TwitterLoginPageRenderer : PageRenderer
14 | {
15 | bool done = false;
16 |
17 | protected override void OnElementChanged (ElementChangedEventArgs e)
18 | {
19 | base.OnElementChanged(e);
20 |
21 | if (!done) {
22 |
23 | // this is a ViewGroup - so should be able to load an AXML file and FindView<>
24 | var activity = this.Context as Activity;
25 |
26 |
27 | // Pretty sure we are on the right track here, but we to make it actually work we'll need to
28 | // override Xamarin Auth so we can get it to use the correct names in the requests. Pain in the ass.
29 | var auth = new OAuth2Authenticator (
30 | clientId: App.Current.Properties ["clientId"].ToString(),
31 | clientSecret: App.Current.Properties ["clientSecret"].ToString(),
32 | scope: App.Current.Properties ["scope"].ToString(),
33 | authorizeUrl: new Uri( App.Current.Properties ["authorizeUrl"].ToString()),
34 | redirectUrl: new Uri(App.Current.Properties ["redirectUrl"].ToString()),
35 | accessTokenUrl: new Uri(App.Current.Properties ["accessTokenUrl"].ToString()));
36 |
37 |
38 | auth.Completed += (sender, eventArgs) => {
39 | if (eventArgs.IsAuthenticated)
40 | {
41 | App.Current.MainPage = new ProfilePage();
42 |
43 | App.Current.Properties ["access_token"] = eventArgs.Account.Properties ["access_token"].ToString();
44 |
45 | }
46 | else
47 | {
48 | // Auth failed - The only way to get to this branch is to hit the 'Cancel' button.
49 | App.Current.MainPage = new StartPage();
50 | App.Current.Properties["access_token"] = "";
51 | }
52 | };
53 |
54 | //auth.AllowCancel = false;
55 | activity.StartActivity (auth.GetUI (activity));
56 | done = true;
57 | }
58 | }
59 | }
60 | }
61 |
--------------------------------------------------------------------------------
/iOS/Info.plist:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 | CFBundleDisplayName
6 | XamarinFormsOAuth2Demo.iOS
7 | CFBundleIdentifier
8 | com.your-company.XamarinFormsOAuth2Demo.iOS
9 | CFBundleShortVersionString
10 | 1.0
11 | CFBundleVersion
12 | 1.0
13 | LSRequiresIPhoneOS
14 |
15 | MinimumOSVersion
16 | 7.0
17 | UIDeviceFamily
18 |
19 | 1
20 | 2
21 |
22 | UIRequiredDeviceCapabilities
23 |
24 | armv7
25 |
26 | UISupportedInterfaceOrientations
27 |
28 | UIInterfaceOrientationPortrait
29 | UIInterfaceOrientationLandscapeLeft
30 | UIInterfaceOrientationLandscapeRight
31 |
32 | UISupportedInterfaceOrientations~ipad
33 |
34 | UIInterfaceOrientationPortrait
35 | UIInterfaceOrientationPortraitUpsideDown
36 | UIInterfaceOrientationLandscapeLeft
37 | UIInterfaceOrientationLandscapeRight
38 |
39 | CFBundleIconFiles
40 |
41 | Icon-60@2x
42 | Icon-60@3x
43 | Icon-76
44 | Icon-76@2x
45 | Default
46 | Default@2x
47 | Default-568h
48 | Default-568h@2x
49 | Default-Landscape
50 | Default-Landscape@2x
51 | Default-Portrait
52 | Default-Portrait@2x
53 | Icon-Small-40
54 | Icon-Small-40@2x
55 | Icon-Small-40@3x
56 | Icon-Small
57 | Icon-Small@2x
58 | Icon-Small@3x
59 |
60 | UILaunchStoryboardName
61 | LaunchScreen
62 |
63 |
64 |
65 |
--------------------------------------------------------------------------------
/XamarinFormsOAuth2Demo/XamarinFormsOAuth2Demo.cs:
--------------------------------------------------------------------------------
1 | using System;
2 |
3 | using Xamarin.Forms;
4 |
5 | namespace XamarinFormsOAuth2Demo
6 | {
7 | public class App : Application
8 | {
9 | private object accessToken;
10 | private bool loggedIn;
11 |
12 | public App ()
13 | {
14 |
15 | // This code is re-launched when an Android app is restarted from a sleep. So we need to make sure that any calls in this area
16 | // are idempotent, which is a word really only programmers and math geeks know. This shit will run again - Make sure it doesn't trip over itself.
17 |
18 | loggedIn = false;
19 |
20 | if (App.Current.Properties.TryGetValue ("access_token", out accessToken)) {
21 | if (accessToken.ToString ().Length > 0) {
22 | loggedIn = true;
23 | }
24 | }
25 |
26 | if (!loggedIn) {
27 | // If we aren't logged in, then this may be the first time we're starting the app, in which case we want to
28 | // jam some settings in for our auth that we can retrieve later.
29 | // But MAYBE, we are re-launching an app that was not logged in, in which case jamming these values in would
30 | // cause a crash. So we wrap them up in an empty try-catch, which is not elegant but is effective.
31 | try {
32 | App.Current.Properties.Add ("clientId", "730990345527-h7r23gcdmdllgke4iud4di76b0bmpnbb.apps.googleusercontent.com");
33 | App.Current.Properties.Add ("scope", "https://www.googleapis.com/auth/userinfo.email");
34 | App.Current.Properties.Add ("authorizeUrl", "https://accounts.google.com/o/oauth2/auth");
35 | App.Current.Properties.Add ("redirectUrl", "https://www.googleapis.com/plus/v1/people/me");
36 |
37 | // These are not applicable for Twitter login
38 | App.Current.Properties.Add ("clientSecret", "na");
39 | App.Current.Properties.Add ("accessTokenUrl", "na");
40 |
41 | } catch {
42 | }
43 |
44 | // The root page of your application before login.
45 | MainPage = new StartPage();
46 |
47 | } else {
48 | // If we ARE logged in, then fire up the root page of your application after login.
49 | MainPage = new ProfilePage();
50 | }
51 |
52 |
53 | }
54 |
55 | protected override void OnStart ()
56 | {
57 | // Handle when your app starts
58 | }
59 |
60 | protected override void OnSleep ()
61 | {
62 | // Handle when your app sleeps
63 | }
64 |
65 | protected override void OnResume ()
66 | {
67 | // Handle when your app resumes
68 | }
69 | }
70 | }
71 |
72 |
--------------------------------------------------------------------------------
/iOS/Resources/LaunchScreen.storyboard:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 |
36 |
37 |
38 |
39 |
40 |
--------------------------------------------------------------------------------
/XamarinFormsOAuth2Demo/Pages/StartPage.cs:
--------------------------------------------------------------------------------
1 | using System;
2 |
3 | using Xamarin.Forms;
4 |
5 | namespace XamarinFormsOAuth2Demo
6 | {
7 | public class StartPage : ContentPage
8 | {
9 | Button btnGoogleLogIn;
10 | Button btnTwitterLogIn;
11 |
12 | public StartPage ()
13 | {
14 | RenderContent();
15 |
16 | btnGoogleLogIn.Clicked += (sender, args) =>
17 | {
18 | var loginPage = new LoginPage ();
19 | Navigation.PushModalAsync (loginPage);
20 | };
21 |
22 |
23 | btnTwitterLogIn.Clicked += (sender, args) =>
24 | {
25 | // Consumer Key (API Key) for your app in twitter - In this case, the app is called XamarinFormsOAuth2Demo.
26 | App.Current.Properties["clientId"] = "oXiJOBDo4B1VtHjOo2uRqKA49";
27 | App.Current.Properties["scope"]= "Not Applicable for Twitter";
28 | // Address that we'll go to in the browser so the user can enter thier twitter credentials.
29 | App.Current.Properties["authorizeUrl"]= "https://api.twitter.com/oauth/authorize";
30 | App.Current.Properties["redirectUrl"] = "http://www.twitter.com";
31 |
32 | App.Current.Properties["clientSecret"] = "4tKAaLYwnDZaFbUJBFJN4M1XRGKRoocW9eC7CQGpjDTZtkk8fc";
33 | App.Current.Properties["accessTokenUrl"] = "https://api.twitter.com/oauth/request_token";
34 |
35 | var loginPage = new TwitterLoginPage ();
36 | Navigation.PushModalAsync (loginPage);
37 | };
38 |
39 | }
40 |
41 | private void RenderContent() {
42 |
43 | ScrollView scrollview = new ScrollView() { HorizontalOptions = LayoutOptions.FillAndExpand, VerticalOptions = LayoutOptions.FillAndExpand};
44 | var rootLayout = new StackLayout() { BackgroundColor = Color.Blue, Spacing = 15, Orientation = StackOrientation.Vertical, HorizontalOptions = LayoutOptions.FillAndExpand, Padding = new Thickness(0, 0, 0, 10) }; // Padding = new Thickness(45, 15, 45, 15),
45 |
46 |
47 | ContentView header = new ContentView() { BackgroundColor = Color.Blue, HorizontalOptions = LayoutOptions.FillAndExpand, Padding = new Thickness(0, 80, 0, 0) };
48 | rootLayout.Children.Add(header);
49 |
50 |
51 | btnGoogleLogIn = new Button() {
52 | Text = " LOG IN WITH GOOGLE ",
53 | FontAttributes = FontAttributes.Bold,
54 | BackgroundColor = Color.Aqua,
55 | TextColor = Color.White,
56 | HorizontalOptions = LayoutOptions.Center
57 | };
58 | rootLayout.Children.Add(btnGoogleLogIn);
59 |
60 | btnTwitterLogIn = new Button() {
61 | Text = " LOG IN WITH TWITTER ",
62 | FontAttributes = FontAttributes.Bold,
63 | BackgroundColor = Color.Aqua,
64 | TextColor = Color.White,
65 | HorizontalOptions = LayoutOptions.Center
66 | };
67 | rootLayout.Children.Add(btnTwitterLogIn);
68 |
69 | scrollview.Content = rootLayout;
70 |
71 | if (Device.OS == TargetPlatform.Android)
72 | {
73 | scrollview.IsClippedToBounds = true;
74 | }
75 |
76 | Content = scrollview;
77 |
78 | }
79 |
80 | }
81 | }
82 |
83 |
84 |
--------------------------------------------------------------------------------
/README.md:
--------------------------------------------------------------------------------
1 | ## XamarinFormsOauth2Demo
2 |
3 | This was based on https://github.com/jsauve/OAuthTwoDemo.XForms, which was published before Xamarin.Forms 1.3.X
4 |
5 | Xamarin.Forms 1.3.X allows for the ability to just set a MainPage, which looks like a logical way to do things. For reference, take a look here:
6 | http://developer.xamarin.com/guides/cross-platform/xamarin-forms/working-with/app-lifecycle/
7 |
8 | This is just a demo that allows you to see all the various config screens that you'll encounter when setting up a Google app. I included the api keys and whatnot, as I don't see any reason not to. It isn't a real app. If you set up your app to use this apps credentials, then you'll probably be bummed when I delete the app from my Google account. Or when I die. Or whatever.
9 |
10 | The app starts on a start page that has a button that says 'Log On With Google'. I'd love to get more auth methods in here. I'd especially love to see a demo of native Facebook auth in a Xamarin.Forms app.
11 |
12 | Any and all feedback is welcome - There are probably better ways to handle much of this.
13 |
14 | Some things that I don't like -
15 | - Every time there is a login, we're making new pages. Seems like the old ones are probably floating around somewhere, but I don't know how to find a reference to the previous page.
16 | - Probably should make that google button look decent if we're going to add other login methods.
17 | - Storing auth in App.Properties - Works as it is global, but probably a better way to do it.
18 |
19 | So here are some nice screenshots:
20 |
21 | ### Login Flow
22 |
23 | Startup screen - This gives us a place to go back to when someone logs out. If the app starts right out into an Auth page, I think that's a little befuddling. Apologies for the large screen shots - I really don't feel like going back and shrinking them.
24 |
25 | 
26 |
27 | 
28 |
29 | 
30 |
31 | This screen is only seen once per authenticating user - Once the user grants permission to the app, subsequent logins won't ask for permissions.
32 |
33 | 
34 |
35 |
36 |
37 | 
38 |
39 |
40 | ### Google OAuth2 Config Yak Shavin'
41 |
42 | Any time you set up a new app, you're going to have to go thru some screens over at https://console.developers.google.com/project I constantly have problems even getting to the correct screens, as my box is constantly logged in to at least 2 gmail addresses at any time.
43 |
44 | The redirect address used here is as suggested by a StackOverflow thread here:
45 | http://stackoverflow.com/questions/25520180/google-account-login-integration-for-android-xamarin
46 |
47 |
48 | 
49 | 
50 | 
51 | 
52 | 
53 |
--------------------------------------------------------------------------------
/XamarinFormsOAuth2Demo/Pages/ProfilePage.cs:
--------------------------------------------------------------------------------
1 | using System;
2 | using System.Collections.Generic;
3 | using System.Threading.Tasks;
4 | using Xamarin.Forms;
5 | using Newtonsoft.Json;
6 | using ModernHttpClient;
7 | using System.Net.Http;
8 | using System.Net.Http.Headers; // For AuthenticationHeaderValue
9 |
10 |
11 | namespace XamarinFormsOAuth2Demo
12 | {
13 | public class ProfilePage : ContentPage
14 | {
15 | private Button btnLogout;
16 | private object accessToken;
17 | private GoogleUserInfo googleUserInfo;
18 |
19 | public ProfilePage ()
20 | {
21 |
22 | RenderContent();
23 |
24 | btnLogout.Clicked += (sender, args) =>
25 | {
26 | // Kill the access_token so we don't look like we are logged in anymore.
27 | App.Current.Properties ["access_token"] = "";
28 | // Make the main page the StartPage, which is where auth is launched from.
29 | App.Current.MainPage = new StartPage();
30 | };
31 |
32 | //var res = await LoadUserData();
33 |
34 | LoadUserData ();
35 |
36 | }
37 |
38 | private async Task LoadUserData ()
39 | {
40 |
41 | if (IsBusy)
42 | return;
43 |
44 | IsBusy = true;
45 |
46 | // Since we have an access token, we may as well go out to google and find out who the hell just logged in.
47 | if (App.Current.Properties.TryGetValue ("access_token", out accessToken)) {
48 | if (accessToken.ToString ().Length > 0) {
49 |
50 | string url = @"https://www.googleapis.com/oauth2/v1/userinfo?alt=json";
51 |
52 | var httpClient = new HttpClient(new NativeMessageHandler());
53 | var authHeader = new AuthenticationHeaderValue ("Bearer", accessToken.ToString());
54 | httpClient.DefaultRequestHeaders.Authorization = authHeader;
55 |
56 | Task apiWebRequest = httpClient.GetStringAsync(url); // async method!
57 |
58 | string apiResponse = await apiWebRequest;
59 |
60 | try {
61 | googleUserInfo = JsonConvert.DeserializeObject (apiResponse);
62 | } catch (Exception ex) {
63 | var temp = ex;
64 | }
65 | }
66 | }
67 |
68 | IsBusy = false;
69 |
70 | try {
71 | // Change the logout button to be super customized. Sort of.
72 | btnLogout.Text = "Log Out " + googleUserInfo.given_name;
73 | }
74 | catch {
75 | }
76 |
77 | return;
78 | }
79 |
80 | private void RenderContent() {
81 |
82 | ScrollView scrollview = new ScrollView() { HorizontalOptions = LayoutOptions.FillAndExpand, VerticalOptions = LayoutOptions.FillAndExpand};
83 | var rootLayout = new StackLayout() { BackgroundColor = Color.Gray, Spacing = 15, Orientation = StackOrientation.Vertical, HorizontalOptions = LayoutOptions.FillAndExpand, Padding = new Thickness(0, 0, 0, 10) }; // Padding = new Thickness(45, 15, 45, 15),
84 |
85 |
86 | ContentView header = new ContentView() { BackgroundColor = Color.Gray, HorizontalOptions = LayoutOptions.FillAndExpand, Padding = new Thickness(0, 80, 0, 0) };
87 | rootLayout.Children.Add(header);
88 |
89 | btnLogout = new Button() {
90 | Text = " LOG OUT ",
91 | FontAttributes = FontAttributes.Bold,
92 | BackgroundColor = Color.Aqua,
93 | TextColor = Color.White,
94 | HorizontalOptions = LayoutOptions.Center
95 | };
96 | rootLayout.Children.Add(btnLogout);
97 |
98 | scrollview.Content = rootLayout;
99 |
100 | if (Device.OS == TargetPlatform.Android)
101 | {
102 | scrollview.IsClippedToBounds = true;
103 | }
104 |
105 | Content = scrollview;
106 |
107 | }
108 |
109 | }
110 | }
111 |
112 |
113 |
--------------------------------------------------------------------------------
/XamarinFormsOAuth2Demo/XamarinFormsOAuth2Demo.csproj:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | Debug
5 | AnyCPU
6 | {786C830F-07A1-408B-BD7F-6EE04809D6DB};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}
7 | {AA229D97-E641-4BE7-951B-52032F6E1E23}
8 | Library
9 | XamarinFormsOAuth2Demo
10 | XamarinFormsOAuth2Demo
11 | v4.5
12 | Profile78
13 |
14 |
15 | true
16 | full
17 | false
18 | bin\Debug
19 | DEBUG;
20 | prompt
21 | 4
22 | false
23 |
24 |
25 | full
26 | true
27 | bin\Release
28 | prompt
29 | 4
30 | false
31 |
32 |
33 |
34 |
35 |
36 |
37 |
38 |
39 |
40 |
41 |
42 |
43 |
44 |
45 |
46 |
47 |
48 |
49 | ..\packages\Xamarin.Forms.2.0.1.6505\lib\portable-win+net45+wp80+win81+wpa81+MonoAndroid10+MonoTouch10+Xamarin.iOS10\Xamarin.Forms.Core.dll
50 |
51 |
52 | ..\packages\Xamarin.Forms.2.0.1.6505\lib\portable-win+net45+wp80+win81+wpa81+MonoAndroid10+MonoTouch10+Xamarin.iOS10\Xamarin.Forms.Xaml.dll
53 |
54 |
55 | ..\packages\Xamarin.Forms.2.0.1.6505\lib\portable-win+net45+wp80+win81+wpa81+MonoAndroid10+MonoTouch10+Xamarin.iOS10\Xamarin.Forms.Platform.dll
56 |
57 |
58 | ..\packages\modernhttpclient.2.4.2\lib\Portable-Net45+WinRT45+WP8+WPA81\ModernHttpClient.dll
59 |
60 |
61 | ..\packages\Newtonsoft.Json.8.0.2\lib\portable-net45+wp80+win8+wpa81+dnxcore50\Newtonsoft.Json.dll
62 |
63 |
64 | ..\packages\Microsoft.Net.Http.2.2.29\lib\portable-net40+sl4+win8+wp71+wpa81\System.Net.Http.dll
65 |
66 |
67 | ..\packages\Microsoft.Net.Http.2.2.29\lib\portable-net40+sl4+win8+wp71+wpa81\System.Net.Http.Primitives.dll
68 |
69 |
70 | ..\packages\Microsoft.Net.Http.2.2.29\lib\portable-net40+sl4+win8+wp71+wpa81\System.Net.Http.Extensions.dll
71 |
72 |
73 |
74 |
75 |
76 |
--------------------------------------------------------------------------------
/Components/xamarin.auth-1.2.3.1/component/GettingStarted.md:
--------------------------------------------------------------------------------
1 | ## 1. Create and configure an authenticator
2 |
3 | Let's authenticate a user to access Facebook:
4 |
5 | ```csharp
6 | using Xamarin.Auth;
7 | ...
8 | var auth = new OAuth2Authenticator (
9 | clientId: "App ID from https://developers.facebook.com/apps",
10 | scope: "",
11 | authorizeUrl: new Uri ("https://m.facebook.com/dialog/oauth/"),
12 | redirectUrl: new Uri ("http://www.facebook.com/connect/login_success.html"));
13 | ```
14 |
15 | Facebook uses OAuth 2.0 authentication, so we create an `OAuth2Authenticator`. Authenticators are responsible for managing the user interface and communicating with authentication services.
16 |
17 | Authenticators take a variety of parameters; in this case, the application's ID, its authorization scope, and Facebook's various service locations are required.
18 |
19 |
20 |
21 |
22 | ## 2. Authenticate the user
23 |
24 | While authenticators manage their own UI, it's up to you to initially present the authenticator's UI on the screen. This lets you control how the authentication UI is displayed–modally, in navigation controllers, in popovers, etc.
25 |
26 | Before we present the UI, we need to start listening to the `Completed` event which fires when the user successfully authenticates or cancels. You can find out if the authentication succeeded by testing the `IsAuthenticated` property of `eventArgs`:
27 |
28 | ```csharp
29 | auth.Completed += (sender, eventArgs) => {
30 | // We presented the UI, so it's up to us to dimiss it on iOS.
31 | DismissViewController (true, null);
32 |
33 | if (eventArgs.IsAuthenticated) {
34 | // Use eventArgs.Account to do wonderful things
35 | } else {
36 | // The user cancelled
37 | }
38 | };
39 | ```
40 |
41 | All the information gathered from a successful authentication is available in `eventArgs.Account`.
42 |
43 | Now we're ready to present the login UI from `ViewDidAppear` on iOS:
44 |
45 | ```csharp
46 | PresentViewController (auth.GetUI (), true, null);
47 | ```
48 |
49 | The `GetUI` method returns `UINavigationControllers` on iOS, and `Intents` on Android. On Android, we would write the following code to present the UI from `OnCreate`:
50 |
51 | ```csharp
52 | StartActivity (auth.GetUI (this));
53 | ```
54 |
55 |
56 |
57 | ## 3. Making requests
58 |
59 | Since Facebook is an OAuth2 service, we'll make requests with `OAuth2Request` providing the account we retrieved from the `Completed` event. Assuming we're authenticated, we'll grab the user's info to demonstrate:
60 |
61 | ```csharp
62 | var request = new OAuth2Request ("GET", new Uri ("https://graph.facebook.com/me"), null, eventArgs.Account);
63 | request.GetResponseAsync().ContinueWith (t => {
64 | if (t.IsFaulted)
65 | Console.WriteLine ("Error: " + t.Exception.InnerException.Message);
66 | else {
67 | string json = t.Result.GetResponseText();
68 | Console.WriteLine (json);
69 | }
70 | });
71 | ```
72 |
73 |
74 | ## 4. Store the account
75 |
76 | Xamarin.Auth securely stores `Account` objects so that you don't always have to reauthenticate the user. The `AccountStore` class is responsible for storing `Account` information, backed by the [Keychain](https://developer.apple.com/library/ios/#documentation/security/Reference/keychainservices/Reference/reference.html) on iOS and a [KeyStore](http://developer.android.com/reference/java/security/KeyStore.html) on Android:
77 |
78 | ```csharp
79 | // On iOS:
80 | AccountStore.Create ().Save (eventArgs.Account, "Facebook");
81 |
82 | // On Android:
83 | AccountStore.Create (this).Save (eventArgs.Account, "Facebook");
84 | ```
85 |
86 | Saved Accounts are uniquely identified using a key composed of the account's `Username` property and a "Service ID". The "Service ID" is any string that is used when fetching accounts from the store.
87 |
88 | If an `Account` was previously saved, calling `Save` again will overwrite it. This is convenient for services that expire the credentials stored in the account object.
89 |
90 |
91 |
92 |
93 | ## 5. Retrieve stored accounts
94 |
95 | You can fetch all `Account` objects stored for a given service:
96 |
97 | ```csharp
98 | // On iOS:
99 | IEnumerable accounts = AccountStore.Create ().FindAccountsForService ("Facebook");
100 |
101 | // On Android:
102 | IEnumerable accounts = AccountStore.Create (this).FindAccountsForService ("Facebook");
103 | ```
104 |
105 | It's that easy.
106 |
107 |
108 |
109 |
110 | ## 6. Make your own authenticator
111 |
112 | Xamarin.Auth includes OAuth 1.0 and OAuth 2.0 authenticators, providing support for thousands of popular services. For services that use traditional username/password authentication, you can roll your own authenticator by deriving from `FormAuthenticator`.
113 |
114 | If you want to authenticate against an ostensibly unsupported service, fear not – Xamarin.Auth is extensible! It's very easy to create your own authenticators – just derive from any of the existing authenticators and start overriding methods.
115 |
116 |
117 |
--------------------------------------------------------------------------------
/XamarinFormsOAuth2Demo.sln:
--------------------------------------------------------------------------------
1 |
2 | Microsoft Visual Studio Solution File, Format Version 12.00
3 | # Visual Studio 2012
4 | Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "XamarinFormsOAuth2Demo", "XamarinFormsOAuth2Demo\XamarinFormsOAuth2Demo.csproj", "{AA229D97-E641-4BE7-951B-52032F6E1E23}"
5 | EndProject
6 | Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "XamarinFormsOAuth2Demo.iOS", "iOS\XamarinFormsOAuth2Demo.iOS.csproj", "{ACC29BA4-D3DE-4B7E-9171-B93EBCD0DD44}"
7 | EndProject
8 | Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "XamarinFormsOAuth2Demo.Droid", "Droid\XamarinFormsOAuth2Demo.Droid.csproj", "{9653F6AF-0F8A-4009-8831-EE7A04A03149}"
9 | EndProject
10 | Global
11 | GlobalSection(SolutionConfigurationPlatforms) = preSolution
12 | Debug|Any CPU = Debug|Any CPU
13 | Release|Any CPU = Release|Any CPU
14 | Debug|iPhoneSimulator = Debug|iPhoneSimulator
15 | Release|iPhoneSimulator = Release|iPhoneSimulator
16 | Debug|iPhone = Debug|iPhone
17 | Release|iPhone = Release|iPhone
18 | Ad-Hoc|iPhone = Ad-Hoc|iPhone
19 | AppStore|iPhone = AppStore|iPhone
20 | EndGlobalSection
21 | GlobalSection(ProjectConfigurationPlatforms) = postSolution
22 | {9653F6AF-0F8A-4009-8831-EE7A04A03149}.Ad-Hoc|iPhone.ActiveCfg = Release|Any CPU
23 | {9653F6AF-0F8A-4009-8831-EE7A04A03149}.Ad-Hoc|iPhone.Build.0 = Release|Any CPU
24 | {9653F6AF-0F8A-4009-8831-EE7A04A03149}.AppStore|iPhone.ActiveCfg = Release|Any CPU
25 | {9653F6AF-0F8A-4009-8831-EE7A04A03149}.AppStore|iPhone.Build.0 = Release|Any CPU
26 | {9653F6AF-0F8A-4009-8831-EE7A04A03149}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
27 | {9653F6AF-0F8A-4009-8831-EE7A04A03149}.Debug|Any CPU.Build.0 = Debug|Any CPU
28 | {9653F6AF-0F8A-4009-8831-EE7A04A03149}.Debug|iPhone.ActiveCfg = Debug|Any CPU
29 | {9653F6AF-0F8A-4009-8831-EE7A04A03149}.Debug|iPhone.Build.0 = Debug|Any CPU
30 | {9653F6AF-0F8A-4009-8831-EE7A04A03149}.Debug|iPhoneSimulator.ActiveCfg = Debug|Any CPU
31 | {9653F6AF-0F8A-4009-8831-EE7A04A03149}.Debug|iPhoneSimulator.Build.0 = Debug|Any CPU
32 | {9653F6AF-0F8A-4009-8831-EE7A04A03149}.Release|Any CPU.ActiveCfg = Release|Any CPU
33 | {9653F6AF-0F8A-4009-8831-EE7A04A03149}.Release|Any CPU.Build.0 = Release|Any CPU
34 | {9653F6AF-0F8A-4009-8831-EE7A04A03149}.Release|iPhone.ActiveCfg = Release|Any CPU
35 | {9653F6AF-0F8A-4009-8831-EE7A04A03149}.Release|iPhone.Build.0 = Release|Any CPU
36 | {9653F6AF-0F8A-4009-8831-EE7A04A03149}.Release|iPhoneSimulator.ActiveCfg = Release|Any CPU
37 | {9653F6AF-0F8A-4009-8831-EE7A04A03149}.Release|iPhoneSimulator.Build.0 = Release|Any CPU
38 | {AA229D97-E641-4BE7-951B-52032F6E1E23}.Ad-Hoc|iPhone.ActiveCfg = Debug|Any CPU
39 | {AA229D97-E641-4BE7-951B-52032F6E1E23}.Ad-Hoc|iPhone.Build.0 = Debug|Any CPU
40 | {AA229D97-E641-4BE7-951B-52032F6E1E23}.AppStore|iPhone.ActiveCfg = Debug|Any CPU
41 | {AA229D97-E641-4BE7-951B-52032F6E1E23}.AppStore|iPhone.Build.0 = Debug|Any CPU
42 | {AA229D97-E641-4BE7-951B-52032F6E1E23}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
43 | {AA229D97-E641-4BE7-951B-52032F6E1E23}.Debug|Any CPU.Build.0 = Debug|Any CPU
44 | {AA229D97-E641-4BE7-951B-52032F6E1E23}.Debug|iPhone.ActiveCfg = Debug|Any CPU
45 | {AA229D97-E641-4BE7-951B-52032F6E1E23}.Debug|iPhone.Build.0 = Debug|Any CPU
46 | {AA229D97-E641-4BE7-951B-52032F6E1E23}.Debug|iPhoneSimulator.ActiveCfg = Debug|Any CPU
47 | {AA229D97-E641-4BE7-951B-52032F6E1E23}.Debug|iPhoneSimulator.Build.0 = Debug|Any CPU
48 | {AA229D97-E641-4BE7-951B-52032F6E1E23}.Release|Any CPU.ActiveCfg = Release|Any CPU
49 | {AA229D97-E641-4BE7-951B-52032F6E1E23}.Release|Any CPU.Build.0 = Release|Any CPU
50 | {AA229D97-E641-4BE7-951B-52032F6E1E23}.Release|iPhone.ActiveCfg = Release|Any CPU
51 | {AA229D97-E641-4BE7-951B-52032F6E1E23}.Release|iPhone.Build.0 = Release|Any CPU
52 | {AA229D97-E641-4BE7-951B-52032F6E1E23}.Release|iPhoneSimulator.ActiveCfg = Release|Any CPU
53 | {AA229D97-E641-4BE7-951B-52032F6E1E23}.Release|iPhoneSimulator.Build.0 = Release|Any CPU
54 | {ACC29BA4-D3DE-4B7E-9171-B93EBCD0DD44}.Ad-Hoc|iPhone.ActiveCfg = Ad-Hoc|iPhone
55 | {ACC29BA4-D3DE-4B7E-9171-B93EBCD0DD44}.Ad-Hoc|iPhone.Build.0 = Ad-Hoc|iPhone
56 | {ACC29BA4-D3DE-4B7E-9171-B93EBCD0DD44}.AppStore|iPhone.ActiveCfg = AppStore|iPhone
57 | {ACC29BA4-D3DE-4B7E-9171-B93EBCD0DD44}.AppStore|iPhone.Build.0 = AppStore|iPhone
58 | {ACC29BA4-D3DE-4B7E-9171-B93EBCD0DD44}.Debug|Any CPU.ActiveCfg = Debug|iPhoneSimulator
59 | {ACC29BA4-D3DE-4B7E-9171-B93EBCD0DD44}.Debug|Any CPU.Build.0 = Debug|iPhoneSimulator
60 | {ACC29BA4-D3DE-4B7E-9171-B93EBCD0DD44}.Debug|iPhone.ActiveCfg = Debug|iPhone
61 | {ACC29BA4-D3DE-4B7E-9171-B93EBCD0DD44}.Debug|iPhone.Build.0 = Debug|iPhone
62 | {ACC29BA4-D3DE-4B7E-9171-B93EBCD0DD44}.Debug|iPhoneSimulator.ActiveCfg = Debug|iPhoneSimulator
63 | {ACC29BA4-D3DE-4B7E-9171-B93EBCD0DD44}.Debug|iPhoneSimulator.Build.0 = Debug|iPhoneSimulator
64 | {ACC29BA4-D3DE-4B7E-9171-B93EBCD0DD44}.Release|Any CPU.ActiveCfg = Release|iPhoneSimulator
65 | {ACC29BA4-D3DE-4B7E-9171-B93EBCD0DD44}.Release|Any CPU.Build.0 = Release|iPhoneSimulator
66 | {ACC29BA4-D3DE-4B7E-9171-B93EBCD0DD44}.Release|iPhone.ActiveCfg = Release|iPhone
67 | {ACC29BA4-D3DE-4B7E-9171-B93EBCD0DD44}.Release|iPhone.Build.0 = Release|iPhone
68 | {ACC29BA4-D3DE-4B7E-9171-B93EBCD0DD44}.Release|iPhoneSimulator.ActiveCfg = Release|iPhoneSimulator
69 | {ACC29BA4-D3DE-4B7E-9171-B93EBCD0DD44}.Release|iPhoneSimulator.Build.0 = Release|iPhoneSimulator
70 | EndGlobalSection
71 | EndGlobal
72 |
--------------------------------------------------------------------------------
/Components/xamarin.auth-1.2.3.1.info:
--------------------------------------------------------------------------------
1 | {"Name":"Xamarin.Auth","Id":1313,"Alias":"xamarin.auth","Description":"Xamarin.Auth helps you authenticate users via standard authentication mechanisms (e.g. OAuth 1.0 and 2.0), and store user credentials. It\u0027s also straightforward to add support for non-standard authentication schemes. The library is cross-platform, so once you learn it on iOS, you\u0027re all set on Android.\n\n```csharp\nusing Xamarin.Auth;\n\nvar auth = new OAuth2Authenticator (\n\tclientId: \"App ID from https://developers.facebook.com/apps\",\n\tscope: \"\",\n\tauthorizeUrl: new Uri (\"https://m.facebook.com/dialog/oauth/\"),\n\tredirectUrl: new Uri (\"http://www.facebook.com/connect/login_success.html\"));\n\nauth.Completed += (sender, eventArgs) =\u003e {\n\tDismissViewController (true, null);\n\tif (eventArgs.IsAuthenticated) {\n\t\t// Use eventArgs.Account to do wonderful things\n\t}\n}\n\nPresentViewController (auth.GetUI (), true, null);\n```\n\nIt\u0027s that easy to authenticate users!\n\n*Some screenshots assembled with [PlaceIt](http://placeit.breezi.com/).*\n","Version":"1.2.3.1","Summary":"A cross-platform API for authenticating users and storing their accounts.","QuickStart":"## 1. Create and configure an authenticator\n\nLet\u0027s authenticate a user to access Facebook:\n\n```csharp\nusing Xamarin.Auth;\n...\nvar auth = new OAuth2Authenticator (\n\tclientId: \"App ID from https://developers.facebook.com/apps\",\n\tscope: \"\",\n\tauthorizeUrl: new Uri (\"https://m.facebook.com/dialog/oauth/\"),\n\tredirectUrl: new Uri (\"http://www.facebook.com/connect/login_success.html\"));\n```\n\nFacebook uses OAuth 2.0 authentication, so we create an `OAuth2Authenticator`. Authenticators are responsible for managing the user interface and communicating with authentication services.\n\nAuthenticators take a variety of parameters; in this case, the application\u0027s ID, its authorization scope, and Facebook\u0027s various service locations are required.\n\n\n\n\n## 2. Authenticate the user\n\nWhile authenticators manage their own UI, it\u0027s up to you to initially present the authenticator\u0027s UI on the screen. This lets you control how the authentication UI is displayed–modally, in navigation controllers, in popovers, etc.\n\nBefore we present the UI, we need to start listening to the `Completed` event which fires when the user successfully authenticates or cancels. You can find out if the authentication succeeded by testing the `IsAuthenticated` property of `eventArgs`:\n\n```csharp\nauth.Completed += (sender, eventArgs) =\u003e {\n\t// We presented the UI, so it\u0027s up to us to dimiss it on iOS.\n\tDismissViewController (true, null);\n\n\tif (eventArgs.IsAuthenticated) {\n\t\t// Use eventArgs.Account to do wonderful things\n\t} else {\n\t\t// The user cancelled\n\t}\n};\n```\n\nAll the information gathered from a successful authentication is available in `eventArgs.Account`.\n\nNow we\u0027re ready to present the login UI from `ViewDidAppear` on iOS:\n\n```csharp\nPresentViewController (auth.GetUI (), true, null);\n```\n\nThe `GetUI` method returns `UINavigationControllers` on iOS, and `Intents` on Android. On Android, we would write the following code to present the UI from `OnCreate`:\n\n```csharp\nStartActivity (auth.GetUI (this));\n```\n\n\n\n## 3. Making requests\n\nSince Facebook is an OAuth2 service, we\u0027ll make requests with `OAuth2Request` providing the account we retrieved from the `Completed` event. Assuming we\u0027re authenticated, we\u0027ll grab the user\u0027s info to demonstrate:\n\n```csharp\nvar request = new OAuth2Request (\"GET\", new Uri (\"https://graph.facebook.com/me\"), null, eventArgs.Account);\nrequest.GetResponseAsync().ContinueWith (t =\u003e {\n\tif (t.IsFaulted)\n\t\tConsole.WriteLine (\"Error: \" + t.Exception.InnerException.Message);\n\telse {\n\t\tstring json = t.Result.GetResponseText();\n\t\tConsole.WriteLine (json);\n\t}\n});\n```\n\n\n## 4. Store the account\n\nXamarin.Auth securely stores `Account` objects so that you don\u0027t always have to reauthenticate the user. The `AccountStore` class is responsible for storing `Account` information, backed by the [Keychain](https://developer.apple.com/library/ios/#documentation/security/Reference/keychainservices/Reference/reference.html) on iOS and a [KeyStore](http://developer.android.com/reference/java/security/KeyStore.html) on Android:\n\n```csharp\n// On iOS:\nAccountStore.Create ().Save (eventArgs.Account, \"Facebook\");\n\n// On Android:\nAccountStore.Create (this).Save (eventArgs.Account, \"Facebook\");\n```\n\nSaved Accounts are uniquely identified using a key composed of the account\u0027s `Username` property and a \"Service ID\". The \"Service ID\" is any string that is used when fetching accounts from the store.\n\nIf an `Account` was previously saved, calling `Save` again will overwrite it. This is convenient for services that expire the credentials stored in the account object.\n\n\n\n\n## 5. Retrieve stored accounts\n\nYou can fetch all `Account` objects stored for a given service:\n\n```csharp\n// On iOS:\nIEnumerable\u003cAccount\u003e accounts = AccountStore.Create ().FindAccountsForService (\"Facebook\");\n\n// On Android:\nIEnumerable\u003cAccount\u003e accounts = AccountStore.Create (this).FindAccountsForService (\"Facebook\");\n```\n\nIt\u0027s that easy.\n\n\n\n\n## 6. Make your own authenticator\n\nXamarin.Auth includes OAuth 1.0 and OAuth 2.0 authenticators, providing support for thousands of popular services. For services that use traditional username/password authentication, you can roll your own authenticator by deriving from `FormAuthenticator`.\n\nIf you want to authenticate against an ostensibly unsupported service, fear not – Xamarin.Auth is extensible! It\u0027s very easy to create your own authenticators – just derive from any of the existing authenticators and start overriding methods.\n\n\n","Hash":"7288a449461b0dc1d5470133e022bb6d","TargetPlatforms":["ios","android"],"TrialHash":null}
--------------------------------------------------------------------------------
/Droid/XamarinFormsOAuth2Demo.Droid.csproj:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | Debug
5 | AnyCPU
6 | {EFBA0AD7-5A72-4C68-AF49-83D382785DCF};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}
7 | {9653F6AF-0F8A-4009-8831-EE7A04A03149}
8 | Library
9 | XamarinFormsOAuth2Demo.Droid
10 | Assets
11 | Resources
12 | Resource
13 | Resources\Resource.designer.cs
14 | True
15 | True
16 | XamarinFormsOAuth2Demo.Droid
17 | Properties\AndroidManifest.xml
18 | v6.0
19 |
20 |
21 | true
22 | full
23 | false
24 | bin\Debug
25 | DEBUG;
26 | prompt
27 | 4
28 | None
29 | false
30 |
31 |
32 | full
33 | true
34 | bin\Release
35 | prompt
36 | 4
37 | false
38 | false
39 |
40 |
41 |
42 |
43 |
44 |
45 |
46 | ..\Components\xamarin.auth-1.2.3.1\lib\android\Xamarin.Auth.Android.dll
47 |
48 |
49 | ..\packages\Xamarin.Android.Support.v4.23.0.1.3\lib\MonoAndroid403\Xamarin.Android.Support.v4.dll
50 |
51 |
52 | ..\packages\Xamarin.Android.Support.v7.AppCompat.23.0.1.3\lib\MonoAndroid403\Xamarin.Android.Support.v7.AppCompat.dll
53 |
54 |
55 | ..\packages\Xamarin.Android.Support.Design.23.0.1.3\lib\MonoAndroid403\Xamarin.Android.Support.Design.dll
56 |
57 |
58 | ..\packages\Xamarin.Android.Support.v7.CardView.23.0.1.3\lib\MonoAndroid403\Xamarin.Android.Support.v7.CardView.dll
59 |
60 |
61 | ..\packages\Xamarin.Android.Support.v7.MediaRouter.23.0.1.3\lib\MonoAndroid403\Xamarin.Android.Support.v7.MediaRouter.dll
62 |
63 |
64 | ..\packages\Xamarin.Forms.2.0.1.6505\lib\MonoAndroid10\Xamarin.Forms.Platform.Android.dll
65 |
66 |
67 | ..\packages\Xamarin.Forms.2.0.1.6505\lib\MonoAndroid10\FormsViewGroup.dll
68 |
69 |
70 | ..\packages\Xamarin.Forms.2.0.1.6505\lib\MonoAndroid10\Xamarin.Forms.Core.dll
71 |
72 |
73 | ..\packages\Xamarin.Forms.2.0.1.6505\lib\MonoAndroid10\Xamarin.Forms.Xaml.dll
74 |
75 |
76 | ..\packages\Xamarin.Forms.2.0.1.6505\lib\MonoAndroid10\Xamarin.Forms.Platform.dll
77 |
78 |
79 |
80 |
81 | {AA229D97-E641-4BE7-951B-52032F6E1E23}
82 | XamarinFormsOAuth2Demo
83 |
84 |
85 |
86 |
87 |
88 |
89 |
90 |
91 |
92 |
93 |
94 |
95 |
96 |
97 |
98 |
99 |
100 |
101 |
102 |
103 |
104 |
105 |
106 |
107 |
108 |
109 |
110 |
111 |
112 |
113 | 1.2.3.1
114 | False
115 |
116 |
117 |
--------------------------------------------------------------------------------
/iOS/XamarinFormsOAuth2Demo.iOS.csproj:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 | Debug
5 | iPhoneSimulator
6 | {FEACFBD2-3405-455C-9665-78FE426C6842};{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}
7 | {ACC29BA4-D3DE-4B7E-9171-B93EBCD0DD44}
8 | Exe
9 | XamarinFormsOAuth2Demo.iOS
10 | Resources
11 | XamarinFormsOAuth2Demo.iOS
12 |
13 |
14 | true
15 | full
16 | false
17 | bin\iPhoneSimulator\Debug
18 | DEBUG;
19 | prompt
20 | 4
21 | false
22 | i386
23 | None
24 | Entitlements.plist
25 | iPhone Developer
26 | true
27 |
28 |
29 | full
30 | true
31 | bin\iPhoneSimulator\Release
32 | prompt
33 | 4
34 | false
35 | i386
36 | None
37 | iPhone Developer
38 | Entitlements.plist
39 |
40 |
41 | true
42 | full
43 | false
44 | bin\iPhone\Debug
45 | DEBUG;
46 | prompt
47 | 4
48 | false
49 | ARMv7, ARM64
50 | Entitlements.plist
51 | iPhone Developer
52 | true
53 |
54 |
55 | full
56 | true
57 | bin\iPhone\Release
58 | prompt
59 | 4
60 | Entitlements.plist
61 | ARMv7, ARM64
62 | false
63 | iPhone Developer
64 |
65 |
66 | full
67 | true
68 | bin\iPhone\Ad-Hoc
69 | prompt
70 | 4
71 | false
72 | ARMv7, ARM64
73 | Entitlements.plist
74 | true
75 | iPhone Distribution
76 | Automatic:AdHoc
77 | true
78 |
79 |
80 | full
81 | true
82 | bin\iPhone\AppStore
83 | prompt
84 | 4
85 | false
86 | ARMv7, ARM64
87 | Entitlements.plist
88 | Automatic:AppStore
89 | iPhone Distribution
90 |
91 |
92 |
93 |
94 |
95 |
96 |
97 | ..\Components\xamarin.auth-1.2.3.1\lib\ios-unified\Xamarin.Auth.iOS.dll
98 |
99 |
100 | ..\packages\Xamarin.Forms.2.0.1.6505\lib\Xamarin.iOS10\Xamarin.Forms.Platform.iOS.dll
101 |
102 |
103 | ..\packages\Xamarin.Forms.2.0.1.6505\lib\Xamarin.iOS10\Xamarin.Forms.Core.dll
104 |
105 |
106 | ..\packages\Xamarin.Forms.2.0.1.6505\lib\Xamarin.iOS10\Xamarin.Forms.Xaml.dll
107 |
108 |
109 | ..\packages\Xamarin.Forms.2.0.1.6505\lib\Xamarin.iOS10\Xamarin.Forms.Platform.dll
110 |
111 |
112 |
113 |
114 | {AA229D97-E641-4BE7-951B-52032F6E1E23}
115 | XamarinFormsOAuth2Demo
116 |
117 |
118 |
119 |
120 |
121 |
122 |
123 |
124 |
125 |
126 |
127 |
128 |
129 |
130 |
131 |
132 |
133 |
134 |
135 |
136 |
137 |
138 |
139 |
140 |
141 |
142 |
143 |
144 |
145 |
146 |
147 |
148 |
149 |
150 |
151 |
152 |
153 |
154 |
155 |
156 | 1.2.3.1
157 | False
158 |
159 |
160 |
161 |
162 |
163 |
--------------------------------------------------------------------------------
/Components/xamarin.auth-1.2.3.1/component/License.md:
--------------------------------------------------------------------------------
1 | # Apache License
2 | Version 2.0, January 2004
3 | [http://www.apache.org/licenses/](http://www.apache.org/licenses/)
4 |
5 | TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
6 |
7 | 1. Definitions.
8 |
9 | "License" shall mean the terms and conditions for use, reproduction,
10 | and distribution as defined by Sections 1 through 9 of this document.
11 |
12 | "Licensor" shall mean the copyright owner or entity authorized by
13 | the copyright owner that is granting the License.
14 |
15 | "Legal Entity" shall mean the union of the acting entity and all
16 | other entities that control, are controlled by, or are under common
17 | control with that entity. For the purposes of this definition,
18 | "control" means (i) the power, direct or indirect, to cause the
19 | direction or management of such entity, whether by contract or
20 | otherwise, or (ii) ownership of fifty percent (50%) or more of the
21 | outstanding shares, or (iii) beneficial ownership of such entity.
22 |
23 | "You" (or "Your") shall mean an individual or Legal Entity
24 | exercising permissions granted by this License.
25 |
26 | "Source" form shall mean the preferred form for making modifications,
27 | including but not limited to software source code, documentation
28 | source, and configuration files.
29 |
30 | "Object" form shall mean any form resulting from mechanical
31 | transformation or translation of a Source form, including but
32 | not limited to compiled object code, generated documentation,
33 | and conversions to other media types.
34 |
35 | "Work" shall mean the work of authorship, whether in Source or
36 | Object form, made available under the License, as indicated by a
37 | copyright notice that is included in or attached to the work
38 | (an example is provided in the Appendix below).
39 |
40 | "Derivative Works" shall mean any work, whether in Source or Object
41 | form, that is based on (or derived from) the Work and for which the
42 | editorial revisions, annotations, elaborations, or other modifications
43 | represent, as a whole, an original work of authorship. For the purposes
44 | of this License, Derivative Works shall not include works that remain
45 | separable from, or merely link (or bind by name) to the interfaces of,
46 | the Work and Derivative Works thereof.
47 |
48 | "Contribution" shall mean any work of authorship, including
49 | the original version of the Work and any modifications or additions
50 | to that Work or Derivative Works thereof, that is intentionally
51 | submitted to Licensor for inclusion in the Work by the copyright owner
52 | or by an individual or Legal Entity authorized to submit on behalf of
53 | the copyright owner. For the purposes of this definition, "submitted"
54 | means any form of electronic, verbal, or written communication sent
55 | to the Licensor or its representatives, including but not limited to
56 | communication on electronic mailing lists, source code control systems,
57 | and issue tracking systems that are managed by, or on behalf of, the
58 | Licensor for the purpose of discussing and improving the Work, but
59 | excluding communication that is conspicuously marked or otherwise
60 | designated in writing by the copyright owner as "Not a Contribution."
61 |
62 | "Contributor" shall mean Licensor and any individual or Legal Entity
63 | on behalf of whom a Contribution has been received by Licensor and
64 | subsequently incorporated within the Work.
65 |
66 | 2. Grant of Copyright License. Subject to the terms and conditions of
67 | this License, each Contributor hereby grants to You a perpetual,
68 | worldwide, non-exclusive, no-charge, royalty-free, irrevocable
69 | copyright license to reproduce, prepare Derivative Works of,
70 | publicly display, publicly perform, sublicense, and distribute the
71 | Work and such Derivative Works in Source or Object form.
72 |
73 | 3. Grant of Patent License. Subject to the terms and conditions of
74 | this License, each Contributor hereby grants to You a perpetual,
75 | worldwide, non-exclusive, no-charge, royalty-free, irrevocable
76 | (except as stated in this section) patent license to make, have made,
77 | use, offer to sell, sell, import, and otherwise transfer the Work,
78 | where such license applies only to those patent claims licensable
79 | by such Contributor that are necessarily infringed by their
80 | Contribution(s) alone or by combination of their Contribution(s)
81 | with the Work to which such Contribution(s) was submitted. If You
82 | institute patent litigation against any entity (including a
83 | cross-claim or counterclaim in a lawsuit) alleging that the Work
84 | or a Contribution incorporated within the Work constitutes direct
85 | or contributory patent infringement, then any patent licenses
86 | granted to You under this License for that Work shall terminate
87 | as of the date such litigation is filed.
88 |
89 | 4. Redistribution. You may reproduce and distribute copies of the
90 | Work or Derivative Works thereof in any medium, with or without
91 | modifications, and in Source or Object form, provided that You
92 | meet the following conditions:
93 |
94 | (a) You must give any other recipients of the Work or
95 | Derivative Works a copy of this License; and
96 |
97 | (b) You must cause any modified files to carry prominent notices
98 | stating that You changed the files; and
99 |
100 | (c) You must retain, in the Source form of any Derivative Works
101 | that You distribute, all copyright, patent, trademark, and
102 | attribution notices from the Source form of the Work,
103 | excluding those notices that do not pertain to any part of
104 | the Derivative Works; and
105 |
106 | (d) If the Work includes a "NOTICE" text file as part of its
107 | distribution, then any Derivative Works that You distribute must
108 | include a readable copy of the attribution notices contained
109 | within such NOTICE file, excluding those notices that do not
110 | pertain to any part of the Derivative Works, in at least one
111 | of the following places: within a NOTICE text file distributed
112 | as part of the Derivative Works; within the Source form or
113 | documentation, if provided along with the Derivative Works; or,
114 | within a display generated by the Derivative Works, if and
115 | wherever such third-party notices normally appear. The contents
116 | of the NOTICE file are for informational purposes only and
117 | do not modify the License. You may add Your own attribution
118 | notices within Derivative Works that You distribute, alongside
119 | or as an addendum to the NOTICE text from the Work, provided
120 | that such additional attribution notices cannot be construed
121 | as modifying the License.
122 |
123 | You may add Your own copyright statement to Your modifications and
124 | may provide additional or different license terms and conditions
125 | for use, reproduction, or distribution of Your modifications, or
126 | for any such Derivative Works as a whole, provided Your use,
127 | reproduction, and distribution of the Work otherwise complies with
128 | the conditions stated in this License.
129 |
130 | 5. Submission of Contributions. Unless You explicitly state otherwise,
131 | any Contribution intentionally submitted for inclusion in the Work
132 | by You to the Licensor shall be under the terms and conditions of
133 | this License, without any additional terms or conditions.
134 | Notwithstanding the above, nothing herein shall supersede or modify
135 | the terms of any separate license agreement you may have executed
136 | with Licensor regarding such Contributions.
137 |
138 | 6. Trademarks. This License does not grant permission to use the trade
139 | names, trademarks, service marks, or product names of the Licensor,
140 | except as required for reasonable and customary use in describing the
141 | origin of the Work and reproducing the content of the NOTICE file.
142 |
143 | 7. Disclaimer of Warranty. Unless required by applicable law or
144 | agreed to in writing, Licensor provides the Work (and each
145 | Contributor provides its Contributions) on an "AS IS" BASIS,
146 | WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
147 | implied, including, without limitation, any warranties or conditions
148 | of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
149 | PARTICULAR PURPOSE. You are solely responsible for determining the
150 | appropriateness of using or redistributing the Work and assume any
151 | risks associated with Your exercise of permissions under this License.
152 |
153 | 8. Limitation of Liability. In no event and under no legal theory,
154 | whether in tort (including negligence), contract, or otherwise,
155 | unless required by applicable law (such as deliberate and grossly
156 | negligent acts) or agreed to in writing, shall any Contributor be
157 | liable to You for damages, including any direct, indirect, special,
158 | incidental, or consequential damages of any character arising as a
159 | result of this License or out of the use or inability to use the
160 | Work (including but not limited to damages for loss of goodwill,
161 | work stoppage, computer failure or malfunction, or any and all
162 | other commercial damages or losses), even if such Contributor
163 | has been advised of the possibility of such damages.
164 |
165 | 9. Accepting Warranty or Additional Liability. While redistributing
166 | the Work or Derivative Works thereof, You may choose to offer,
167 | and charge a fee for, acceptance of support, warranty, indemnity,
168 | or other liability obligations and/or rights consistent with this
169 | License. However, in accepting such obligations, You may act only
170 | on Your own behalf and on Your sole responsibility, not on behalf
171 | of any other Contributor, and only if You agree to indemnify,
172 | defend, and hold each Contributor harmless for any liability
173 | incurred by, or claims asserted against, such Contributor by reason
174 | of your accepting any such warranty or additional liability.
--------------------------------------------------------------------------------
/Components/xamarin.auth-1.2.3.1/lib/ios/Xamarin.Auth.iOS.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 | Xamarin.Auth
4 |
5 |
6 |
7 | An Account that represents an authenticated user of a social network.
8 |
9 |
10 |
11 | Initializes a new blank .
12 |
13 |
14 |
15 | The username for the account.
16 | Initializes an with the given username.
17 |
18 |
19 |
20 | The username for the account.
21 | Properties for the account.
22 | Initializes an with the given username and properties.
23 |
24 |
25 |
26 | The username for the account.
27 | The cookies to be stored with the account.
28 | Initializes an with the given username and cookies.
29 |
30 |
31 |
32 | The username for the account.
33 | Properties for the account.
34 | The cookies to be stored with the account.
35 | Initializes an with the given username, properties, and cookies.
36 |
37 |
38 |
39 | Cookies that are stored with the account for web services that control access using cookies.
40 |
41 |
42 |
43 |
44 | The serialized account generated by .
45 | Restores an account from its serialized string representation.
46 |
47 | An instance represented by .
48 |
49 |
50 |
51 |
52 |
53 | A key-value store associated with this account. These get encrypted when the account is stored.
54 |
55 |
56 |
57 |
58 | Serialize this account into a string that can be deserialized.
59 | A string representing the instance.
60 |
61 |
62 |
63 |
64 | Returns a that represents the current .
65 | A that represents the current .
66 |
67 |
68 |
69 | The username used as a key when storing this account
70 |
71 |
72 |
73 |
74 |
75 | A persistent storage for s. This storage is encrypted.
76 | Accounts are stored using a service ID and the username of the account
77 | as a primary key.
78 |
79 |
80 |
81 |
82 |
83 |
84 |
85 |
86 | Create an account store.
87 | A new instance.
88 |
89 |
90 |
91 | Account to delete.
92 | Service identifier.
93 | Deletes the account for a given serviceId.
94 |
95 |
96 |
97 | Service identifier.
98 | Finds the accounts for a given service.
99 | The accounts for the service.
100 |
101 |
102 |
103 | Account to store.
104 | Service identifier.
105 | Save the specified account by combining its username and the serviceId
106 | to form its primary key.
107 |
108 |
109 |
110 | A process and user interface to authenticate a user.
111 | To be added.
112 |
113 |
114 | Initializes a new instance of the class.
115 | To be added.
116 |
117 |
118 | Gets or sets whether to allow user cancellation.
119 |
120 | true by default.
121 |
122 |
123 |
124 |
125 | Occurs when authentication has been successfully or unsuccessfully completed.
126 | Consult the event argument to determine if
127 | authentication was successful.
128 |
129 |
130 |
131 | Occurs when there an error is encountered when authenticating.
132 |
133 |
134 |
135 | Gets the UI for this authenticator.
136 | The UI that needs to be presented.
137 |
138 |
139 |
140 | Gets the UI for this authenticator.
141 | The UI that needs to be presented.
142 |
143 |
144 |
145 | Gets whether this authenticator has completed its interaction with the user.
146 |
147 | true if authorization has been completed, false otherwise.
148 |
149 |
150 |
151 |
152 | Implementations must call this function when they have cancelled the operation.
153 |
154 |
155 |
156 | The reason that this authentication has failed.
157 | Implementations must call this function when they have failed to authenticate.
158 |
159 |
160 |
161 | The reason that this authentication has failed.
162 | Implementations must call this function when they have failed to authenticate.
163 |
164 |
165 |
166 | The authenticated account.
167 | Implementations must call this function when they have successfully authenticated.
168 |
169 |
170 |
171 | User name of the account.
172 | Additional data, such as access tokens, that need to be stored with the account. This
173 | information is secured.
174 | Implementations must call this function when they have successfully authenticated.
175 |
176 |
177 |
178 | Gets or sets the title of any UI elements that need to be presented for this authenticator.
179 |
180 | "Authenticate" by default.
181 |
182 |
183 |
184 |
185 | Authenticator completed event arguments.
186 |
187 |
188 |
189 | The account created or if authentication failed or was canceled.
190 | Initializes a new instance of the class.
191 |
192 |
193 |
194 | Gets the account created that represents this authentication.
195 | The account.
196 |
197 |
198 |
199 | Whether the authentication succeeded and there is a valid .
200 |
201 | if the user is authenticated; otherwise, .
202 |
203 |
204 |
205 | Authenticator error event arguments.
206 |
207 |
208 |
209 | The exception signaling the error. The message of this object is retrieved from this exception or
210 | its inner exceptions.
211 | Initializes a new instance of the class with an exception.
212 |
213 |
214 |
215 | A message describing the error.
216 | Initializes a new instance of the class
217 | with a message but no exception.
218 |
219 |
220 |
221 | Gets the exception that signaled the error if there was one.
222 | The exception or .
223 |
224 |
225 |
226 | Gets a message describing the error.
227 | The message.
228 |
229 |
230 |
231 | An exception generated by the Xamarin.Auth library.
232 |
233 |
234 |
235 | Initializes a new instance of the class..
236 |
237 |
238 |
239 | A that describes the exception.
240 | Initializes a new instance of the class.
241 |
242 |
243 |
244 | The object that holds the serialized object data.
245 | The contextual information about the source or destination.
246 | Initializes a new instance of the class.
247 |
248 |
249 |
250 | A that describes the exception.
251 | The exception that is the cause of the current exception.
252 | Initializes a new instance of the class.
253 |
254 |
255 |
256 | An authenticator that presents a form to the user.
257 |
258 |
259 |
260 | A link to a website or other resource that allows the user to create a new account.
261 | Initializes a new instance of the class with the given link to create accounts.
262 |
263 |
264 |
265 | A link to a website or other resource that allows the user to create a new account.
266 | The create account link.
267 |
268 |
269 |
270 | The fields that need to be filled in by the user in order to authenticate.
271 | The fields.
272 |
273 |
274 |
275 | The key of the field.
276 | Gets the value of a field using its key.
277 | The field value.
278 |
279 |
280 |
281 | Gets the UI to present this form.
282 | The UI that needs to be presented.
283 |
284 |
285 |
286 | Cancellation token used to cancel the authentication.
287 | Method called to authenticate the user using the values in the .
288 | A task to retrieve the for the authenticated user.
289 |
290 |
291 |
292 | Account credential form field.
293 |
294 |
295 |
296 | Initializes a new instance of the class.
297 |
298 |
299 |
300 | A key used to identify the field.
301 | The title of the field when presented in a UI.
302 | The type of the field.
303 | Placeholder text shown when there is no input value for the field.
304 | The value of the field.
305 | Initializes a new instance of the class.
306 |
307 |
308 |
309 | The type of this field.
310 | The type.
311 |
312 |
313 |
314 | A key used to identify this field.
315 | The key.
316 |
317 |
318 |
319 | Placeholder text shown when there is no input value for this field.
320 | The placeholder.
321 |
322 |
323 |
324 | The title of this field when presented in a UI.
325 | The title.
326 |
327 |
328 |
329 | The value of this field.
330 | The value.
331 |
332 |
333 |
334 | The display type of a credential field.
335 |
336 |
337 |
338 | The field is an email address.
339 |
340 |
341 | The field is protected from onlookers.
342 |
343 |
344 | The field is plain text.
345 |
346 |
347 | To be added.
348 |
349 | Type of method used to fetch the username of an account
350 | after it has been successfully authenticated.
351 |
352 | The username.
353 |
354 |
355 |
356 | A collection of utility functions for signing OAuth 1.0 requests.
357 | To be added.
358 |
359 |
360 | HTTP request method.
361 | The request resource URI.
362 | Parameters covered by: http://tools.ietf.org/html/rfc5849#section-3.4.1.3
363 | Consumer key.
364 | Consumer secret.
365 | Token secret.
366 | Creates an OAuth 1.0 signed request.
367 | The request.
368 |
369 |
370 |
371 | The string to encode.
372 | Encodes a string according to: http://tools.ietf.org/html/rfc5849#section-3.6
373 | The encoded string.
374 |
375 |
376 |
377 | HTTP request method.
378 | The request resource URI.
379 | Parameters covered by: http://tools.ietf.org/html/rfc5849#section-3.4.1.3
380 | Consumer key.
381 | Consumer secret.
382 | Token.
383 | Token secret.
384 | Gets the authorization header for a signed request.
385 | The authorization header.
386 |
387 |
388 |
389 | HTTP request method.
390 | The request resource URI.
391 | Parameters covered by: http://tools.ietf.org/html/rfc5849#section-3.4.1.3
392 | Gets the signature base string according to: http://tools.ietf.org/html/rfc5849#section-3.4.1
393 | The signature base string.
394 |
395 |
396 |
397 | HTTP request method.
398 | The request resource URI.
399 | Parameters covered by: http://tools.ietf.org/html/rfc5849#section-3.4.1.3
400 | Consumer secret.
401 | Token secret.
402 | Gets the signature of a request according to: http://tools.ietf.org/html/rfc5849#section-3.4
403 | The signature.
404 |
405 |
406 |
407 | OAuth 1.0 authenticator.
408 |
409 |
410 |
411 |
412 | Consumer key.
413 |
414 |
415 | Consumer secret.
416 |
417 |
418 | Request token URL.
419 |
420 |
421 | Authorize URL.
422 |
423 |
424 | Access token URL.
425 |
426 |
427 | Callback URL.
428 |
429 |
430 | Method used to fetch the username of an account
431 | after it has been successfully authenticated.
432 |
433 |
434 | Initializes a new instance of the class.
435 |
436 |
437 |
438 |
439 | Method that returns the initial URL to be displayed in the web browser.
440 | A task that will return the initial URL.
441 |
442 |
443 |
444 | The URL of the loaded page.
445 | Event handler that watches for the callback URL to be loaded.
446 |
447 |
448 |
449 | Request that is authenticated using an account retrieved from an .
450 |
451 |
452 |
453 |
454 | The HTTP method.
455 |
456 |
457 | The URL.
458 |
459 |
460 | Parameters that will pre-populate the property or .
461 |
462 |
463 | The account used to authenticate this request.
464 |
465 |
466 | If set to include multiparts when calculating the OAuth 1.0 signature.
467 |
468 |
469 | Initializes a new instance of the class.
470 |
471 |
472 |
473 |
474 | Gets OAuth authorization header.
475 | To be added.
476 |
477 |
478 | Make sure that the parameters array contains mulitpart keys if we're dealing with a buggy
479 | OAuth implementation (such as Flickr).
480 |
481 |
482 | These normally shouldn't be included: http://tools.ietf.org/html/rfc5849#section-3.4.1.3.1
483 |
484 |
485 |
486 |
487 | To be added.
488 | Asynchronously gets the response.
489 | The response.
490 |
491 |
492 | is null.
493 |
494 |
495 | Implements OAuth 2.0 implicit granting. http://tools.ietf.org/html/draft-ietf-oauth-v2-31#section-4.2
496 |
497 |
498 |
499 |
500 | Client identifier.
501 |
502 |
503 | Authorization scope.
504 |
505 |
506 | Authorize URL.
507 |
508 |
509 | Redirect URL.
510 |
511 |
512 | Method used to fetch the username of an account
513 | after it has been successfully authenticated.
514 |
515 |
516 | Initializes a new instance
517 | that authenticates using authorization codes (code).
518 |
519 |
520 |
521 |
522 |
523 | Client identifier.
524 |
525 | Client secret.
526 |
527 | Authorization scope.
528 |
529 |
530 | Authorize URL.
531 |
532 |
533 | Redirect URL.
534 |
535 | URL used to request access tokens after an authorization code was received.
536 |
537 | Method used to fetch the username of an account
538 | after it has been successfully authenticated.
539 |
540 |
541 | Initializes a new
542 | that authenticates using implicit granting (token).
543 |
544 |
545 |
546 |
547 | Method that returns the initial URL to be displayed in the web browser.
548 | A task that will return the initial URL.
549 |
550 |
551 |
552 | URL of the page.
553 | The parsed query of the URL.
554 | The parsed fragment of the URL.
555 | Raised when a new page has been encountered.
556 |
557 |
558 | This is invoked on any event that has a URL:
559 | and . Not all platforms may support triggering
560 | , so this is provided as a blanket method to check redirect
561 | URLs at the earliest possible time to avoid showing redirect pages if unnecessary.
562 |
563 |
564 |
565 |
566 | URL of the page.
567 | The parsed query of the URL.
568 | The parsed fragment of the URL.
569 | Raised when a new page has been loaded.
570 |
571 |
572 |
573 |
574 | URL of the page.
575 |
576 |
577 | The parsed query string of the URL.
578 |
579 |
580 | The parsed fragment of the URL.
581 |
582 |
583 | Raised when a new page has been loaded.
584 |
585 |
586 |
587 |
588 | The retrieved account properties
589 | Event handler that is fired when an access token has been retreived.
590 |
591 |
592 |
593 | The parameters to make the request with.
594 | Asynchronously makes a request to the access token URL with the given parameters.
595 | The data provided in the response to the access token request.
596 |
597 |
598 |
599 | Request that is authenticated using an account retrieved from an .
600 |
601 |
602 |
603 |
604 | The HTTP method.
605 |
606 |
607 | The URL.
608 |
609 |
610 | Parameters that will pre-populate the property or .
611 |
612 |
613 | The account used to authenticate this request.
614 |
615 |
616 | Initializes a new instance of the class.
617 |
618 |
619 |
620 |
621 | Gets or sets the access token parameter name.
622 |
623 | "access_token" by default.
624 |
625 | Some providers, such as FourSquare do not use the somewhat-standard "access_token" name for their parameter.
626 |
627 |
628 |
629 | The that's been authenticated.
630 | The unauthenticated URL.
631 | Transforms an unauthenticated URL to an authenticated one.
632 | The authenticated URL.
633 |
634 |
635 |
636 | The that's been authenticated.
637 | The unauthenticated URL.
638 | The name of the access token parameter.
639 | Transforms an unauthenticated URL to an authenticated one.
640 | The authenticated URL.
641 |
642 |
643 |
644 |
645 | The that's been authenticated.
646 | Gets an authenticated HTTP Authorization header.
647 | The authorization header.
648 |
649 |
650 |
651 | Gets the OAuth2 prepared URL.
652 | The OAuth2 prepared URL.
653 |
654 |
655 |
656 |
657 | An HTTP web request that provides a convenient way to make authenticated
658 | requests using account objects obtained from an authenticator.
659 |
660 |
661 |
662 |
663 |
664 | The HTTP method.
665 |
666 |
667 | The URL.
668 |
669 |
670 | Parameters that will pre-populate the property or null.
671 |
672 |
673 | The account used to authenticate this request.
674 |
675 |
676 | Initializes a new instance of the class.
677 |
678 |
679 |
680 |
681 | The account that will be used to authenticate this request.
682 | The instance associated with this request.
683 |
684 |
685 |
686 | Name of the part.
687 | Text value of the part.
688 | Adds a part to the request. Doing so will make this request be sent as multipart/form-data.
689 |
690 |
691 |
692 |
693 | Name of the part.
694 |
695 |
696 | Data used when transmitting this part.
697 |
698 |
699 | The MIME type of this part.
700 |
701 |
702 | The filename of this part if it represents a file.
703 |
704 |
705 | Adds a part to the request. Doing so will make this request be sent as multipart/form-data.
706 |
707 |
708 |
709 |
710 | Gets the prepared URL.
711 | The prepared URL.
712 |
713 | Service implementors should override this function and add any needed parameters
714 | from the Account to the URL before it is used to get the response.
715 |
716 |
717 |
718 |
719 | Returns the that will be used for this . All properties
720 | should be set to their correct values before accessing this object.
721 |
722 |
723 | The prepared HTTP web request.
724 |
725 |
726 | Service implementors should modify the returned request to add whatever
727 | authentication data is needed before getting the response.
728 |
729 |
730 |
731 | Gets the response.
732 | The response.
733 |
734 |
735 |
736 | To be added.
737 | Gets the response.
738 | The response.
739 |
740 | Service implementors should override this method to modify the PreparedWebRequest
741 | to authenticate it.
742 |
743 |
744 |
745 | The HTTP method.
746 | A string representing the HTTP method to be used with this request.
747 |
748 |
749 |
750 | The parts of a multipart request.
751 |
752 |
753 |
754 |
755 | The parameters of the request. These will be added to the query string of the
756 | URL for GET requests, encoded as form a parameters for POSTs, and added as
757 | multipart values if the request uses .
758 |
759 |
760 |
761 |
762 |
763 | The URL of the resource to request.
764 |
765 |
766 |
767 |
768 | A single part of a multipart request.
769 |
770 |
771 |
772 | Constructs and intializes a new instance of the class.
773 |
774 |
775 |
776 | The data.
777 |
778 |
779 |
780 | The filename of this part if it represents a file.
781 |
782 |
783 |
784 | The MIME type.
785 |
786 |
787 |
788 | The name.
789 |
790 |
791 |
792 | The optional textual representation of the
793 |
794 |
795 |
796 | An HTTP web response.
797 | To be added.
798 |
799 |
800 | Initializes a new blank .
801 |
802 |
803 |
804 | The that this response will wrap.
805 | Initializes a new that wraps a .
806 |
807 |
808 |
809 | Releases all resource used by the object.
810 |
811 |
812 |
813 | Whether this function was called from the Dispose method.
814 | Releases all resource used by the object.
815 |
816 |
817 |
818 |
819 | Releases unmanaged resources and performs other cleanup operations before the
820 | is reclaimed by garbage collection.
821 |
822 |
823 |
824 |
825 | Gets the response stream.
826 | The response stream.
827 |
828 |
829 |
830 | Reads all the response data and interprets it as a string.
831 | The response text.
832 |
833 |
834 |
835 | Gets the headers returned with this response.
836 | A dictionary containing the headers.
837 |
838 |
839 |
840 | Gets the response URI.
841 | The actual Uri of the final request returned.
842 |
843 | Some requests may automatically redirecet before turning a final response. This
844 | property will return the final that this response is actually from.
845 |
846 |
847 |
848 | Gets the response status code.
849 | The response status code.
850 |
851 |
852 |
853 | Returns a that represents the current .
854 | A that represents the current .
855 |
856 |
857 |
858 | An authenticator that displays a web page.
859 |
860 |
861 |
862 |
863 |
864 |
865 |
866 |
867 | Occurs when the visual, user-interactive, browsing has completed but there
868 | is more authentication work to do.
869 |
870 |
871 |
872 |
873 | Clears any cookies available to the app.
874 |
875 |
876 |
877 |
878 | Gets or sets whether to automatically clear cookies before logging in.
879 |
880 |
881 |
882 | true by default.
883 |
884 |
885 | Disabling this is useful when they have previously logged into the page in question in your app
886 | and you have not stored their account information. It's true by default under the assumption
887 | that you would store any account information and the only reason for reauthenticating is for
888 | switching or adding an additional account.
889 |
890 |
891 |
892 |
893 |
894 | Method that returns the initial URL to be displayed in the web browser.
895 | A task that will return the initial URL.
896 |
897 |
898 |
899 | Gets the UI for this authenticator.
900 | The UI that needs to be presented.
901 |
902 |
903 |
904 | Raises the browsing completed event.
905 |
906 |
907 |
908 | The URL of the page.
909 |
910 | Event handler called when a new page has been loaded in the web browser.
911 | Implementations should call if this page
912 | signifies a successful authentication.
913 |
914 |
915 |
916 |
917 | The URL of the page.
918 | Event handler called when a new page is being loaded in the web browser.
919 |
920 |
921 |
922 |
923 | An authenticator that displays web pages until a given "redirect" page is encountered. It then
924 | returns an account with the fragment on that URL.
925 |
926 |
927 |
928 |
929 |
930 | The initial URL loaded into the web browser.
931 |
932 |
933 | The URL watched for.
934 |
935 |
936 | Initializes a new instance of the class.
937 |
938 |
939 |
940 |
941 | Method that returns the initial URL to be displayed in the web browser.
942 | A task that will return the initial URL.
943 |
944 |
945 |
946 | URL of the page.
947 | The parsed query of the URL.
948 | The parsed fragment of the URL.
949 | Raised when a new page has been encountered.
950 |
951 |
952 | This is invoked on any event that has a URL:
953 | and . Not all platforms may support triggering
954 | , so this is provided as a blanket method to check redirect
955 | URLs at the earliest possible time to avoid showing redirect pages if unnecessary.
956 |
957 |
958 |
959 |
960 | The URL of the page.
961 | Event handler called when a page has completed loading.
962 |
963 |
964 |
965 |
966 | Raised when a new page has been loaded.
967 |
968 |
969 | URL of the page.
970 |
971 |
972 | The parsed query of the URL.
973 |
974 |
975 | The parsed fragment of the URL.
976 |
977 |
978 |
979 |
980 | The URL of the page.
981 | Event handler called when a new page is being loaded in the web browser.
982 |
983 |
984 |
985 |
986 | URL of the page.
987 |
988 |
989 | The parsed query of the URL.
990 |
991 |
992 | The parsed fragment of the URL.
993 |
994 |
995 | Raised when the redirect page has been loaded.
996 |
997 |
998 |
999 |
1000 | To be added.
1001 | To be added.
1002 |
1003 |
1004 | To be added.
1005 | To be added.
1006 | To be added.
1007 | To be added.
1008 |
1009 |
1010 | To be added.
1011 | To be added.
1012 | To be added.
1013 | To be added.
1014 |
1015 |
1016 |
1017 |
--------------------------------------------------------------------------------
/Components/xamarin.auth-1.2.3.1/lib/android/Xamarin.Auth.Android.xml:
--------------------------------------------------------------------------------
1 |
2 |
3 | Xamarin.Auth
4 |
5 |
6 |
7 | An Account that represents an authenticated user of a social network.
8 |
9 |
10 |
11 | Initializes a new blank .
12 |
13 |
14 |
15 | The username for the account.
16 | Initializes an with the given username.
17 |
18 |
19 |
20 | The username for the account.
21 | Properties for the account.
22 | Initializes an with the given username and properties.
23 |
24 |
25 |
26 | The username for the account.
27 | The cookies to be stored with the account.
28 | Initializes an with the given username and cookies.
29 |
30 |
31 |
32 | The username for the account.
33 | Properties for the account.
34 | The cookies to be stored with the account.
35 | Initializes an with the given username, properties, and cookies.
36 |
37 |
38 |
39 | Cookies that are stored with the account for web services that control access using cookies.
40 |
41 |
42 |
43 |
44 | The serialized account generated by .
45 | Restores an account from its serialized string representation.
46 |
47 | An instance represented by .
48 |
49 |
50 |
51 |
52 |
53 | A key-value store associated with this account. These get encrypted when the account is stored.
54 |
55 |
56 |
57 |
58 | Serialize this account into a string that can be deserialized.
59 | A string representing the instance.
60 |
61 |
62 |
63 |
64 | Returns a that represents the current .
65 | A that represents the current .
66 |
67 |
68 |
69 | The username used as a key when storing this account
70 |
71 |
72 |
73 |
74 |
75 | A persistent storage for s. This storage is encrypted.
76 | Accounts are stored using a service ID and the username of the account
77 | as a primary key.
78 |
79 |
80 |
81 |
82 |
83 |
84 |
85 |
86 | Create an account store.
87 | A new instance.
88 |
89 |
90 |
91 | Account to delete.
92 | Service identifier.
93 | Deletes the account for a given serviceId.
94 |
95 |
96 |
97 | Service identifier.
98 | Finds the accounts for a given service.
99 | The accounts for the service.
100 |
101 |
102 |
103 | Account to store.
104 | Service identifier.
105 | Save the specified account by combining its username and the serviceId
106 | to form its primary key.
107 |
108 |
109 |
110 | A process and user interface to authenticate a user.
111 | To be added.
112 |
113 |
114 | Initializes a new instance of the class.
115 | To be added.
116 |
117 |
118 | Gets or sets whether to allow user cancellation.
119 |
120 | true by default.
121 |
122 |
123 |
124 |
125 | Occurs when authentication has been successfully or unsuccessfully completed.
126 | Consult the event argument to determine if
127 | authentication was successful.
128 |
129 |
130 |
131 | Occurs when there an error is encountered when authenticating.
132 |
133 |
134 |
135 | Gets the UI for this authenticator.
136 | The UI that needs to be presented.
137 |
138 |
139 |
140 | Gets the UI for this authenticator.
141 | The UI that needs to be presented.
142 |
143 |
144 |
145 | Gets whether this authenticator has completed its interaction with the user.
146 |
147 | true if authorization has been completed, false otherwise.
148 |
149 |
150 |
151 |
152 | Implementations must call this function when they have cancelled the operation.
153 |
154 |
155 |
156 | The reason that this authentication has failed.
157 | Implementations must call this function when they have failed to authenticate.
158 |
159 |
160 |
161 | The reason that this authentication has failed.
162 | Implementations must call this function when they have failed to authenticate.
163 |
164 |
165 |
166 | The authenticated account.
167 | Implementations must call this function when they have successfully authenticated.
168 |
169 |
170 |
171 | User name of the account.
172 | Additional data, such as access tokens, that need to be stored with the account. This
173 | information is secured.
174 | Implementations must call this function when they have successfully authenticated.
175 |
176 |
177 |
178 | Gets or sets the title of any UI elements that need to be presented for this authenticator.
179 |
180 | "Authenticate" by default.
181 |
182 |
183 |
184 |
185 | Authenticator completed event arguments.
186 |
187 |
188 |
189 | The account created or if authentication failed or was canceled.
190 | Initializes a new instance of the class.
191 |
192 |
193 |
194 | Gets the account created that represents this authentication.
195 | The account.
196 |
197 |
198 |
199 | Whether the authentication succeeded and there is a valid .
200 |
201 | if the user is authenticated; otherwise, .
202 |
203 |
204 |
205 | Authenticator error event arguments.
206 |
207 |
208 |
209 | The exception signaling the error. The message of this object is retrieved from this exception or
210 | its inner exceptions.
211 | Initializes a new instance of the class with an exception.
212 |
213 |
214 |
215 | A message describing the error.
216 | Initializes a new instance of the class
217 | with a message but no exception.
218 |
219 |
220 |
221 | Gets the exception that signaled the error if there was one.
222 | The exception or .
223 |
224 |
225 |
226 | Gets a message describing the error.
227 | The message.
228 |
229 |
230 |
231 | An exception generated by the Xamarin.Auth library.
232 |
233 |
234 |
235 | Initializes a new instance of the class..
236 |
237 |
238 |
239 | A that describes the exception.
240 | Initializes a new instance of the class.
241 |
242 |
243 |
244 | The object that holds the serialized object data.
245 | The contextual information about the source or destination.
246 | Initializes a new instance of the class.
247 |
248 |
249 |
250 | A that describes the exception.
251 | The exception that is the cause of the current exception.
252 | Initializes a new instance of the class.
253 |
254 |
255 |
256 | An authenticator that presents a form to the user.
257 |
258 |
259 |
260 | A link to a website or other resource that allows the user to create a new account.
261 | Initializes a new instance of the class with the given link to create accounts.
262 |
263 |
264 |
265 | A link to a website or other resource that allows the user to create a new account.
266 | The create account link.
267 |
268 |
269 |
270 | The fields that need to be filled in by the user in order to authenticate.
271 | The fields.
272 |
273 |
274 |
275 | The key of the field.
276 | Gets the value of a field using its key.
277 | The field value.
278 |
279 |
280 |
281 | Gets the UI to present this form.
282 | The UI that needs to be presented.
283 |
284 |
285 |
286 | Cancellation token used to cancel the authentication.
287 | Method called to authenticate the user using the values in the .
288 | A task to retrieve the for the authenticated user.
289 |
290 |
291 |
292 | Account credential form field.
293 |
294 |
295 |
296 | Initializes a new instance of the class.
297 |
298 |
299 |
300 | A key used to identify the field.
301 | The title of the field when presented in a UI.
302 | The type of the field.
303 | Placeholder text shown when there is no input value for the field.
304 | The value of the field.
305 | Initializes a new instance of the class.
306 |
307 |
308 |
309 | The type of this field.
310 | The type.
311 |
312 |
313 |
314 | A key used to identify this field.
315 | The key.
316 |
317 |
318 |
319 | Placeholder text shown when there is no input value for this field.
320 | The placeholder.
321 |
322 |
323 |
324 | The title of this field when presented in a UI.
325 | The title.
326 |
327 |
328 |
329 | The value of this field.
330 | The value.
331 |
332 |
333 |
334 | The display type of a credential field.
335 |
336 |
337 |
338 | The field is an email address.
339 |
340 |
341 | The field is protected from onlookers.
342 |
343 |
344 | The field is plain text.
345 |
346 |
347 | To be added.
348 |
349 | Type of method used to fetch the username of an account
350 | after it has been successfully authenticated.
351 |
352 | The username.
353 |
354 |
355 |
356 | A collection of utility functions for signing OAuth 1.0 requests.
357 | To be added.
358 |
359 |
360 | HTTP request method.
361 | The request resource URI.
362 | Parameters covered by: http://tools.ietf.org/html/rfc5849#section-3.4.1.3
363 | Consumer key.
364 | Consumer secret.
365 | Token secret.
366 | Creates an OAuth 1.0 signed request.
367 | The request.
368 |
369 |
370 |
371 | The string to encode.
372 | Encodes a string according to: http://tools.ietf.org/html/rfc5849#section-3.6
373 | The encoded string.
374 |
375 |
376 |
377 | HTTP request method.
378 | The request resource URI.
379 | Parameters covered by: http://tools.ietf.org/html/rfc5849#section-3.4.1.3
380 | Consumer key.
381 | Consumer secret.
382 | Token.
383 | Token secret.
384 | Gets the authorization header for a signed request.
385 | The authorization header.
386 |
387 |
388 |
389 | HTTP request method.
390 | The request resource URI.
391 | Parameters covered by: http://tools.ietf.org/html/rfc5849#section-3.4.1.3
392 | Gets the signature base string according to: http://tools.ietf.org/html/rfc5849#section-3.4.1
393 | The signature base string.
394 |
395 |
396 |
397 | HTTP request method.
398 | The request resource URI.
399 | Parameters covered by: http://tools.ietf.org/html/rfc5849#section-3.4.1.3
400 | Consumer secret.
401 | Token secret.
402 | Gets the signature of a request according to: http://tools.ietf.org/html/rfc5849#section-3.4
403 | The signature.
404 |
405 |
406 |
407 | OAuth 1.0 authenticator.
408 |
409 |
410 |
411 |
412 | Consumer key.
413 |
414 |
415 | Consumer secret.
416 |
417 |
418 | Request token URL.
419 |
420 |
421 | Authorize URL.
422 |
423 |
424 | Access token URL.
425 |
426 |
427 | Callback URL.
428 |
429 |
430 | Method used to fetch the username of an account
431 | after it has been successfully authenticated.
432 |
433 |
434 | Initializes a new instance of the class.
435 |
436 |
437 |
438 |
439 | Method that returns the initial URL to be displayed in the web browser.
440 | A task that will return the initial URL.
441 |
442 |
443 |
444 | The URL of the loaded page.
445 | Event handler that watches for the callback URL to be loaded.
446 |
447 |
448 |
449 | Request that is authenticated using an account retrieved from an .
450 |
451 |
452 |
453 |
454 | The HTTP method.
455 |
456 |
457 | The URL.
458 |
459 |
460 | Parameters that will pre-populate the property or .
461 |
462 |
463 | The account used to authenticate this request.
464 |
465 |
466 | If set to include multiparts when calculating the OAuth 1.0 signature.
467 |
468 |
469 | Initializes a new instance of the class.
470 |
471 |
472 |
473 |
474 | Gets OAuth authorization header.
475 | To be added.
476 |
477 |
478 | Make sure that the parameters array contains mulitpart keys if we're dealing with a buggy
479 | OAuth implementation (such as Flickr).
480 |
481 |
482 | These normally shouldn't be included: http://tools.ietf.org/html/rfc5849#section-3.4.1.3.1
483 |
484 |
485 |
486 |
487 | To be added.
488 | Asynchronously gets the response.
489 | The response.
490 |
491 |
492 | is null.
493 |
494 |
495 | Implements OAuth 2.0 implicit granting. http://tools.ietf.org/html/draft-ietf-oauth-v2-31#section-4.2
496 |
497 |
498 |
499 |
500 | Client identifier.
501 |
502 |
503 | Authorization scope.
504 |
505 |
506 | Authorize URL.
507 |
508 |
509 | Redirect URL.
510 |
511 |
512 | Method used to fetch the username of an account
513 | after it has been successfully authenticated.
514 |
515 |
516 | Initializes a new instance
517 | that authenticates using authorization codes (code).
518 |
519 |
520 |
521 |
522 |
523 | Client identifier.
524 |
525 | Client secret.
526 |
527 | Authorization scope.
528 |
529 |
530 | Authorize URL.
531 |
532 |
533 | Redirect URL.
534 |
535 | URL used to request access tokens after an authorization code was received.
536 |
537 | Method used to fetch the username of an account
538 | after it has been successfully authenticated.
539 |
540 |
541 | Initializes a new
542 | that authenticates using implicit granting (token).
543 |
544 |
545 |
546 |
547 | Method that returns the initial URL to be displayed in the web browser.
548 | A task that will return the initial URL.
549 |
550 |
551 |
552 | URL of the page.
553 | The parsed query of the URL.
554 | The parsed fragment of the URL.
555 | Raised when a new page has been encountered.
556 |
557 |
558 | This is invoked on any event that has a URL:
559 | and . Not all platforms may support triggering
560 | , so this is provided as a blanket method to check redirect
561 | URLs at the earliest possible time to avoid showing redirect pages if unnecessary.
562 |
563 |
564 |
565 |
566 | URL of the page.
567 | The parsed query of the URL.
568 | The parsed fragment of the URL.
569 | Raised when a new page has been loaded.
570 |
571 |
572 |
573 |
574 | URL of the page.
575 |
576 |
577 | The parsed query string of the URL.
578 |
579 |
580 | The parsed fragment of the URL.
581 |
582 |
583 | Raised when a new page has been loaded.
584 |
585 |
586 |
587 |
588 | The retrieved account properties
589 | Event handler that is fired when an access token has been retreived.
590 |
591 |
592 |
593 | The parameters to make the request with.
594 | Asynchronously makes a request to the access token URL with the given parameters.
595 | The data provided in the response to the access token request.
596 |
597 |
598 |
599 | Request that is authenticated using an account retrieved from an .
600 |
601 |
602 |
603 |
604 | The HTTP method.
605 |
606 |
607 | The URL.
608 |
609 |
610 | Parameters that will pre-populate the property or .
611 |
612 |
613 | The account used to authenticate this request.
614 |
615 |
616 | Initializes a new instance of the class.
617 |
618 |
619 |
620 |
621 | Gets or sets the access token parameter name.
622 |
623 | "access_token" by default.
624 |
625 | Some providers, such as FourSquare do not use the somewhat-standard "access_token" name for their parameter.
626 |
627 |
628 |
629 | The that's been authenticated.
630 | The unauthenticated URL.
631 | Transforms an unauthenticated URL to an authenticated one.
632 | The authenticated URL.
633 |
634 |
635 |
636 | The that's been authenticated.
637 | The unauthenticated URL.
638 | The name of the access token parameter.
639 | Transforms an unauthenticated URL to an authenticated one.
640 | The authenticated URL.
641 |
642 |
643 |
644 |
645 | The that's been authenticated.
646 | Gets an authenticated HTTP Authorization header.
647 | The authorization header.
648 |
649 |
650 |
651 | Gets the OAuth2 prepared URL.
652 | The OAuth2 prepared URL.
653 |
654 |
655 |
656 |
657 | An HTTP web request that provides a convenient way to make authenticated
658 | requests using account objects obtained from an authenticator.
659 |
660 |
661 |
662 |
663 |
664 | The HTTP method.
665 |
666 |
667 | The URL.
668 |
669 |
670 | Parameters that will pre-populate the property or null.
671 |
672 |
673 | The account used to authenticate this request.
674 |
675 |
676 | Initializes a new instance of the class.
677 |
678 |
679 |
680 |
681 | The account that will be used to authenticate this request.
682 | The instance associated with this request.
683 |
684 |
685 |
686 | Name of the part.
687 | Text value of the part.
688 | Adds a part to the request. Doing so will make this request be sent as multipart/form-data.
689 |
690 |
691 |
692 |
693 | Name of the part.
694 |
695 |
696 | Data used when transmitting this part.
697 |
698 |
699 | The MIME type of this part.
700 |
701 |
702 | The filename of this part if it represents a file.
703 |
704 |
705 | Adds a part to the request. Doing so will make this request be sent as multipart/form-data.
706 |
707 |
708 |
709 |
710 | Gets the prepared URL.
711 | The prepared URL.
712 |
713 | Service implementors should override this function and add any needed parameters
714 | from the Account to the URL before it is used to get the response.
715 |
716 |
717 |
718 |
719 | Returns the that will be used for this . All properties
720 | should be set to their correct values before accessing this object.
721 |
722 |
723 | The prepared HTTP web request.
724 |
725 |
726 | Service implementors should modify the returned request to add whatever
727 | authentication data is needed before getting the response.
728 |
729 |
730 |
731 | Gets the response.
732 | The response.
733 |
734 |
735 |
736 | To be added.
737 | Gets the response.
738 | The response.
739 |
740 | Service implementors should override this method to modify the PreparedWebRequest
741 | to authenticate it.
742 |
743 |
744 |
745 | The HTTP method.
746 | A string representing the HTTP method to be used with this request.
747 |
748 |
749 |
750 | The parts of a multipart request.
751 |
752 |
753 |
754 |
755 | The parameters of the request. These will be added to the query string of the
756 | URL for GET requests, encoded as form a parameters for POSTs, and added as
757 | multipart values if the request uses .
758 |
759 |
760 |
761 |
762 |
763 | The URL of the resource to request.
764 |
765 |
766 |
767 |
768 | A single part of a multipart request.
769 |
770 |
771 |
772 | Constructs and intializes a new instance of the class.
773 |
774 |
775 |
776 | The data.
777 |
778 |
779 |
780 | The filename of this part if it represents a file.
781 |
782 |
783 |
784 | The MIME type.
785 |
786 |
787 |
788 | The name.
789 |
790 |
791 |
792 | The optional textual representation of the
793 |
794 |
795 |
796 | An HTTP web response.
797 | To be added.
798 |
799 |
800 | Initializes a new blank .
801 |
802 |
803 |
804 | The that this response will wrap.
805 | Initializes a new that wraps a .
806 |
807 |
808 |
809 | Releases all resource used by the object.
810 |
811 |
812 |
813 | Whether this function was called from the Dispose method.
814 | Releases all resource used by the object.
815 |
816 |
817 |
818 |
819 | Releases unmanaged resources and performs other cleanup operations before the
820 | is reclaimed by garbage collection.
821 |
822 |
823 |
824 |
825 | Gets the response stream.
826 | The response stream.
827 |
828 |
829 |
830 | Reads all the response data and interprets it as a string.
831 | The response text.
832 |
833 |
834 |
835 | Gets the headers returned with this response.
836 | A dictionary containing the headers.
837 |
838 |
839 |
840 | Gets the response URI.
841 | The actual Uri of the final request returned.
842 |
843 | Some requests may automatically redirecet before turning a final response. This
844 | property will return the final that this response is actually from.
845 |
846 |
847 |
848 | Gets the response status code.
849 | The response status code.
850 |
851 |
852 |
853 | Returns a that represents the current .
854 | A that represents the current .
855 |
856 |
857 |
858 | An authenticator that displays a web page.
859 |
860 |
861 |
862 |
863 |
864 |
865 |
866 |
867 | Occurs when the visual, user-interactive, browsing has completed but there
868 | is more authentication work to do.
869 |
870 |
871 |
872 |
873 | Clears any cookies available to the app.
874 |
875 |
876 |
877 |
878 | Gets or sets whether to automatically clear cookies before logging in.
879 |
880 |
881 |
882 | true by default.
883 |
884 |
885 | Disabling this is useful when they have previously logged into the page in question in your app
886 | and you have not stored their account information. It's true by default under the assumption
887 | that you would store any account information and the only reason for reauthenticating is for
888 | switching or adding an additional account.
889 |
890 |
891 |
892 |
893 |
894 | Method that returns the initial URL to be displayed in the web browser.
895 | A task that will return the initial URL.
896 |
897 |
898 |
899 | Gets the UI for this authenticator.
900 | The UI that needs to be presented.
901 |
902 |
903 |
904 | Raises the browsing completed event.
905 |
906 |
907 |
908 | The URL of the page.
909 |
910 | Event handler called when a new page has been loaded in the web browser.
911 | Implementations should call if this page
912 | signifies a successful authentication.
913 |
914 |
915 |
916 |
917 | The URL of the page.
918 | Event handler called when a new page is being loaded in the web browser.
919 |
920 |
921 |
922 |
923 | An authenticator that displays web pages until a given "redirect" page is encountered. It then
924 | returns an account with the fragment on that URL.
925 |
926 |
927 |
928 |
929 |
930 | The initial URL loaded into the web browser.
931 |
932 |
933 | The URL watched for.
934 |
935 |
936 | Initializes a new instance of the class.
937 |
938 |
939 |
940 |
941 | Method that returns the initial URL to be displayed in the web browser.
942 | A task that will return the initial URL.
943 |
944 |
945 |
946 | URL of the page.
947 | The parsed query of the URL.
948 | The parsed fragment of the URL.
949 | Raised when a new page has been encountered.
950 |
951 |
952 | This is invoked on any event that has a URL:
953 | and . Not all platforms may support triggering
954 | , so this is provided as a blanket method to check redirect
955 | URLs at the earliest possible time to avoid showing redirect pages if unnecessary.
956 |
957 |
958 |
959 |
960 | The URL of the page.
961 | Event handler called when a page has completed loading.
962 |
963 |
964 |
965 |
966 | Raised when a new page has been loaded.
967 |
968 |
969 | URL of the page.
970 |
971 |
972 | The parsed query of the URL.
973 |
974 |
975 | The parsed fragment of the URL.
976 |
977 |
978 |
979 |
980 | The URL of the page.
981 | Event handler called when a new page is being loaded in the web browser.
982 |
983 |
984 |
985 |
986 | URL of the page.
987 |
988 |
989 | The parsed query of the URL.
990 |
991 |
992 | The parsed fragment of the URL.
993 |
994 |
995 | Raised when the redirect page has been loaded.
996 |
997 |
998 |
999 |
1000 | To be added.
1001 | To be added.
1002 |
1003 |
1004 | To be added.
1005 | To be added.
1006 | To be added.
1007 | To be added.
1008 |
1009 |
1010 | To be added.
1011 | To be added.
1012 | To be added.
1013 | To be added.
1014 |
1015 |
1016 |
1017 |
--------------------------------------------------------------------------------