Esempio n. 1
0
        public static void RegisterProviders()
        {
            var oauthConfig = OAuthConfig.Current;

            if (oauthConfig.MicrosoftEnabled)
            {
                OAuthWebSecurity.RegisterMicrosoftClient(oauthConfig.MicrosoftClientId, oauthConfig.MicrosoftClientSecret, Views.Literal_OAuth_Microsoft);
            }

            if (oauthConfig.LinkedInEnabled)
            {
                OAuthWebSecurity.RegisterLinkedInClient(oauthConfig.LinkedInConsumerKey, oauthConfig.LinkedInConsumerSecret, Views.Literal_OAuth_LinkedIn);
            }

            if (oauthConfig.TwitterEnabled)
            {
                OAuthWebSecurity.RegisterTwitterClient(oauthConfig.TwitterConsumerKey, oauthConfig.TwitterConsumerSecret, Views.Literal_OAuth_Twitter);
            }

            if (oauthConfig.FacebookEnabled)
            {
                OAuthWebSecurity.RegisterFacebookClient(oauthConfig.FacebookAppId, oauthConfig.FacebookAppSecret, Views.Literal_OAuth_Facebook);
            }

            if (oauthConfig.GoogleEnabled)
            {
                OAuthWebSecurity.RegisterGoogleClient(Views.Literal_OAuth_Google);
            }

            if (oauthConfig.YahooEnabled)
            {
                OAuthWebSecurity.RegisterYahooClient(Views.Literal_OAuth_Yahoo);
            }
        }
Esempio n. 2
0
        public static void RegisterAuth()
        {
            // To let users of this site log in using their accounts from other sites such as Microsoft, Facebook, and Twitter,
            // you must update this site. For more information visit http://go.microsoft.com/fwlink/?LinkID=252166

            var appSettings = ConfigurationManager.AppSettings;
            Func <string, Dictionary <string, string> > getOAuthSetting = key =>
                                                                          JsonConvert.DeserializeObject <Dictionary <string, string> >(appSettings[key]);

            var oauthMicrosoftSetting = getOAuthSetting("OAuth.Microsoft");

            OAuthWebSecurity.RegisterMicrosoftClient(
                oauthMicrosoftSetting["clientId"],
                oauthMicrosoftSetting["clientSecret"]);

            var oauthTwitterSetting = getOAuthSetting("OAuth.Twitter");

            OAuthWebSecurity.RegisterTwitterClient(
                oauthTwitterSetting["consumerKey"],
                oauthTwitterSetting["consumerSecret"]);

            var oauthFacebookSetting = getOAuthSetting("OAuth.facebook");

            OAuthWebSecurity.RegisterFacebookClient(
                oauthFacebookSetting["appId"],
                oauthFacebookSetting["appSecret"]);

            OAuthWebSecurity.RegisterGoogleClient();

            var oauthGitHubSetting = getOAuthSetting("OAuth.GitHub");

            OAuthWebSecurity.RegisterClient(new GitHubOAuth2Client(
                                                oauthGitHubSetting["clientId"],
                                                oauthGitHubSetting["clientSecret"]), "GitHub", null);
        }
Esempio n. 3
0
        public static void RegisterAuth()
        {
            // To let users of this site log in using their accounts from other sites such as Microsoft, Facebook, and Twitter,
            // you must update this site. For more information visit http://go.microsoft.com/fwlink/?LinkID=252166

            //OAuthWebSecurity.RegisterMicrosoftClient(
            //    clientId: "0000000048103B7E",
            //    clientSecret: "jf74p1tZMh6wGcsIGQJdBGmTbcTSlAok");

            //OAuthWebSecurity.RegisterTwitterClient(
            //    consumerKey: "",
            //    consumerSecret: "");

            //OAuthWebSecurity.RegisterFacebookClient(
            //    appId: "",
            //    appSecret: "");

            Dictionary <string, object> gglm = new Dictionary <string, object>();

            gglm.Add("Icon", "../Images/Login/glm.png");
            OAuthWebSecurity.RegisterGoogleClient("Gimnasio La Montaña", gglm);

            Dictionary <string, object> yahoo = new Dictionary <string, object>();

            yahoo.Add("Icon", "../Images/Login/yahoo.png");
            OAuthWebSecurity.RegisterYahooClient("Yahoo", yahoo);
        }
Esempio n. 4
0
        public static void RegisterAuth()
        {
            // To let users of this site log in using their accounts from other sites such as Microsoft, Facebook, and Twitter,
            // you must update this site. For more information visit http://go.microsoft.com/fwlink/?LinkID=252166
            Dictionary <string, object> microsoftSocialData = new Dictionary <string, object>();

            microsoftSocialData.Add("Icon", "/images/icons/social/microsoft.png");
            OAuthWebSecurity.RegisterMicrosoftClient(
                clientId: ConfigurationManager.AppSettings["Auth-MicrosoftAuthClientId"],
                clientSecret: ConfigurationManager.AppSettings["Auth-MicrosoftAuthClientSecret"],
                displayName: "Windows Live",
                extraData: microsoftSocialData);

            Dictionary <string, object> googleSocialData = new Dictionary <string, object>();

            googleSocialData.Add("Icon", "/images/icons/social/google.png");
            OAuthWebSecurity.RegisterGoogleClient("Google", googleSocialData);

            //OAuthWebSecurity.RegisterTwitterClient(
            //    consumerKey: "",
            //    consumerSecret: "");

            //OAuthWebSecurity.RegisterFacebookClient(
            //    appId: "",
            //    appSecret: "");
        }
Esempio n. 5
0
        public static void RegisterAuth()
        {
            // To let users of this site log in using their accounts from other sites such as Microsoft, Facebook, and Twitter,
            // you must update this site. For more information visit http://go.microsoft.com/fwlink/?LinkID=252166

            //var msAppSecret = ConfigurationManager.AppSettings["MsAppSecret"];
            //if (!string.IsNullOrEmpty(msAppSecret))
            //{
            //    OAuthWebSecurity.RegisterMicrosoftClient(
            //        clientId: "a",
            //        clientSecret: msAppSecret);
            //}

            var twitterAppSecret = ConfigurationManager.AppSettings["TwitterAppSecret"];

            if (!string.IsNullOrEmpty(twitterAppSecret))
            {
                OAuthWebSecurity.RegisterTwitterClient(
                    consumerKey: "d6tePBz3jD7nGnk0E50Qg",
                    consumerSecret: twitterAppSecret);
            }

            var fbAppSecret = ConfigurationManager.AppSettings["FacebookAppSecret"];

            if (!string.IsNullOrEmpty(fbAppSecret))
            {
                OAuthWebSecurity.RegisterFacebookClient(
                    appId: "513621042063202",
                    appSecret: fbAppSecret);
            }

            OAuthWebSecurity.RegisterGoogleClient();
        }
Esempio n. 6
0
        public static void RegisterAuth()
        {
            // To let users of this site log in using their accounts from other sites such as Microsoft, Facebook, and Twitter,
            // you must update this site. For more information visit http://go.microsoft.com/fwlink/?LinkID=252166

            //OAuthWebSecurity.RegisterMicrosoftClient(
            //    clientId: "",
            //    clientSecret: "");

            OAuthWebSecurity.RegisterTwitterClient(
                consumerKey: Credentials.Twitter.KEY,
                consumerSecret: Credentials.Twitter.SECRET);

            OAuthWebSecurity.RegisterFacebookClient(
                appId: Credentials.Facebook.KEY,
                appSecret: Credentials.Facebook.SECRET);

            OAuthWebSecurity.RegisterGoogleClient();

            OAuthWebSecurity.RegisterClient(
                new MxClient(Credentials.MxMerchant.KEY, Credentials.MxMerchant.SECRET), "MxMerchant", null);


            //OAuthWebSecurity.RegisterClient(
            //    new MxOAuth2Client(Credentials.MxMerchant.KEY, Credentials.MxMerchant.SECRET), "MxMerchant OAuth2", null);
        }
Esempio n. 7
0
        public static void RegisterAuth()
        {
            // To let users of this site log in using their accounts from other sites such as Microsoft, Facebook, and Twitter,
            // you must update this site. For more information visit http://go.microsoft.com/fwlink/?LinkID=252166

            //OAuthWebSecurity.RegisterMicrosoftClient(
            //	clientId: "",
            //	clientSecret: ""
            //);

            // https://dev.twitter.com/apps
            //OAuthWebSecurity.RegisterTwitterClient(
            //	consumerKey: "",
            //	consumerSecret: ""
            //);

            // https://developers.facebook.com/apps
            //OAuthWebSecurity.RegisterFacebookClient(
            //	appId: "",
            //	appSecret: ""
            //);

            //OAuthWebSecurity.RegisterLinkedInClient(
            //	consumerKey: "",
            //	consumerSecret: "",
            //);

            OAuthWebSecurity.RegisterGoogleClient();
            OAuthWebSecurity.RegisterYahooClient();
        }
Esempio n. 8
0
        public static void RegisterAuth()
        {
            var fbClient = new FbClient();

            // To let users of this site log in using their accounts from other sites such as Microsoft, Facebook, and Twitter,
            // you must update this site. For more information visit http://go.microsoft.com/fwlink/?LinkID=252166

            //OAuthWebSecurity.RegisterMicrosoftClient(
            //    clientId: "",
            //    clientSecret: "");

            //OAuthWebSecurity.RegisterTwitterClient(
            //    consumerKey: "",
            //    consumerSecret: "");

            // prod
            //OAuthWebSecurity.RegisterFacebookClient(
            //    appId: "262309163906980",
            //    appSecret: "3439950f4bf262d8041e28cdb1b7416c");

            // dev
            //OAuthWebSecurity.RegisterFacebookClient(
            //    appId: "170633953128198",
            //    appSecret: "2a94e68adc55ff563a8c4ff178a85662");

            OAuthWebSecurity.RegisterFacebookClient(
                appId: fbClient.AppId,
                appSecret: fbClient.AppSecret);

            OAuthWebSecurity.RegisterGoogleClient();
        }
Esempio n. 9
0
        public static void RegisterAuth()
        {
            // To let users of this site log in using their accounts from other sites such as Microsoft, Facebook, and Twitter,
            // you must update this site. For more information visit http://go.microsoft.com/fwlink/?LinkID=252166

            OAuthWebSecurity.RegisterGoogleClient();
        }
Esempio n. 10
0
        public static void RegisterAuth()
        {
            //This is added to avoid multiple DBContext creation.
            WebSecurity.InitializeDatabaseConnection("DefaultConnection", "Users", "UserId", "UserName", autoCreateTables: true);
            // To let users of this site log in using their accounts from other sites such as Microsoft, Facebook, and Twitter,
            // you must update this site. For more information visit http://go.microsoft.com/fwlink/?LinkID=252166

            /*  NOTE: you MUST replace of the xxxxxxxxxxxxxxx's with a valid appId and appSecret for your application
             *  in order to be able to connect!  Also, passing the extra data is only necessary if you want to
             *  show the images for the OpenID provider.
             */

            // Facebook
            OAuthWebSecurity.RegisterFacebookClient(
                appId: "xxxxxxxxxxxxxxx",
                appSecret: "xxxxxxxxxxxxxxx");

            // Twitter
            OAuthWebSecurity.RegisterTwitterClient(
                consumerKey: "xxxxxxxxxxxxxxx",
                consumerSecret: "xxxxxxxxxxxxxxx");

            // Google
            OAuthWebSecurity.RegisterGoogleClient();

            // Yahoo
            OAuthWebSecurity.RegisterYahooClient();

            // Microsoft Windows Live Id
            OAuthWebSecurity.RegisterMicrosoftClient(
                clientId: "xxxxxxxxxxxxxxx",
                clientSecret: "xxxxxxxxxxxxxxx");
        }
        public static void RegisterAuth()
        {
            string str  = ConfigurationManager.AppSettings.AsString("oauthMicrosoftClientId", null);
            string str2 = ConfigurationManager.AppSettings.AsString("oauthMicrosoftClientSecret", null);

            if (!(string.IsNullOrEmpty(str) || string.IsNullOrEmpty(str2)))
            {
                OAuthWebSecurity.RegisterMicrosoftClient(str, str2);
            }
            str  = ConfigurationManager.AppSettings.AsString("oauthTwitterConsumerKey", null);
            str2 = ConfigurationManager.AppSettings.AsString("oauthTwitterConsumerSecret", null);
            if (!(string.IsNullOrEmpty(str) || string.IsNullOrEmpty(str2)))
            {
                OAuthWebSecurity.RegisterTwitterClient(str, str2);
            }
            str  = ConfigurationManager.AppSettings.AsString("oauthFacebookAppId", null);
            str2 = ConfigurationManager.AppSettings.AsString("oauthFacebookAppSecret", null);
            if (!(string.IsNullOrEmpty(str) || string.IsNullOrEmpty(str2)))
            {
                OAuthWebSecurity.RegisterFacebookClient(str, str2);
            }
            if (ConfigurationManager.AppSettings.AsBool("oauthGoogle", false))
            {
                OAuthWebSecurity.RegisterGoogleClient();
            }
            str  = ConfigurationManager.AppSettings.AsString("oauthVKontakteAppId", null);
            str2 = ConfigurationManager.AppSettings.AsString("oauthVKontakteAppSecret", null);
            if (!(string.IsNullOrEmpty(str) || string.IsNullOrEmpty(str2)))
            {
                IAuthenticationClient client           = new VKontakteAuthenticationClient(str, str2);
                string displayName                     = "VK";
                IDictionary <string, object> extraData = null;
                OAuthWebSecurity.RegisterClient(client, displayName, extraData);
            }
        }
Esempio n. 12
0
        public static void RegisterAuth()
        {
            // To let users of this site log in using their accounts from other sites such as Microsoft, Facebook, and Twitter,
            // you must update this site. For more information visit http://go.microsoft.com/fwlink/?LinkID=252166

            // https://manage.dev.live.com
            OAuthWebSecurity.RegisterMicrosoftClient(
                clientId: "00000000480F3528",
                clientSecret: "CAogwwIeS3jcJLbb-1GtNT2nzGfqWYMx");

            //OAuthWebSecurity.RegisterTwitterClient(
            //    consumerKey: "",
            //    consumerSecret: "");

            //OAuthWebSecurity.RegisterFacebookClient(
            //    appId: "",
            //    appSecret: "");

            //OAuthWebSecurity.RegisterLinkedInClient(
            //    consumerKey: "",
            //    consumerSecret: "");

            //OAuthWebSecurity.RegisterYahooClient();

            OAuthWebSecurity.RegisterGoogleClient();
        }
Esempio n. 13
0
 public static void RegisterProvders()
 {
     OAuthWebSecurity.RegisterGoogleClient();
     OAuthWebSecurity.RegisterFacebookClient
     (
         appId: ConfigurationManager.AppSettings["FBAppID"],
         appSecret: ConfigurationManager.AppSettings["FBAppSecret"]
     );
 }
Esempio n. 14
0
 public static void RegisterProviders()
 {
     OAuthWebSecurity.RegisterGoogleClient();
     OAuthWebSecurity.RegisterFacebookClient(
         appId: "834877566554270",
         appSecret: "7192831fc3a6a4769f671902defc28ee",
         displayName: "facebook"
         );
 }
Esempio n. 15
0
        protected void Application_Start()
        {
            AreaRegistration.RegisterAllAreas();

            WebApiConfig.Register(GlobalConfiguration.Configuration);
            FilterConfig.RegisterGlobalFilters(GlobalFilters.Filters);
            RouteConfig.RegisterRoutes(RouteTable.Routes);
            DurandalBundleConfig.RegisterBundles(BundleTable.Bundles);

            OAuthWebSecurity.RegisterGoogleClient();
        }
Esempio n. 16
0
        public static void RegisterAuth()
        {
            // To let users of this site log in using their accounts from other sites such as Microsoft, Facebook, and Twitter,
            // you must update this site. For more information visit http://go.microsoft.com/fwlink/?LinkID=252166

            OAuthWebSecurity.RegisterFacebookClient(
                appId: "265950490105673",
                appSecret: "a7caeb3736c59684d943d776b2d519a2");

            //OAuthWebSecurity.RegisterClient(new NetflixClient("7qf3845qydavuucmhj96b6hd", "5jYe5FVhhF"));

            OAuthWebSecurity.RegisterGoogleClient();
        }
        public void TestRegisterGoogleClient()
        {
            // Arrange
            OAuthWebSecurity.RegisterGoogleClient(displayName: "GOOG", extraData: null);

            // Act
            var data = OAuthWebSecurity.RegisteredClientData;

            // Assert
            Assert.True(data.IsReadOnly);
            Assert.Equal(1, data.Count);
            Assert.Equal("google", data.First().AuthenticationClient.ProviderName);
            Assert.Equal("GOOG", data.First().DisplayName);
            Assert.Null(data.First().ExtraData);
        }
Esempio n. 18
0
        public static void RegisterAuth()
        {
            // To let users of this site log in using their accounts from other sites such as Microsoft, Facebook, and Twitter,
            // you must update this site. For more information visit http://go.microsoft.com/fwlink/?LinkID=252166

            OAuthWebSecurity.RegisterGoogleClient();

            OAuthWebSecurity.RegisterFacebookClient(
                appId: "343050129164564",
                appSecret: "6576a6253624845a4b40de37e63f9362");

            //    OAuthWebSecurity.RegisterTwitterClient(
            //        consumerKey: "Ao1rpYXjeTauCGwDEpg5w",
            //        consumerSecret: "ieMyxQWLap4XqJEaCeEpvR2xp1Qcg021NuJ44Forv0M");
        }
Esempio n. 19
0
        public static void RegisterAuth()
        {
            OAuthWebSecurity.RegisterMicrosoftClient(
                clientId: "000000004C10C01A",
                clientSecret: "NQRkZAtTHwjbsIeESF6exh02XPwshsrz");

            OAuthWebSecurity.RegisterTwitterClient(
                consumerKey: "BH2aXJW3LXxdaYpBdGzQ",
                consumerSecret: "q5fZyWwOEW9mIXVAxRd1VygY0pqUR9HiaA7cQIKZQ");
            OAuthWebSecurity.RegisterFacebookClient(
                appId: "187654464761762",
                appSecret: "62cfd93111645f7a956a0625adc3d2c5");

            OAuthWebSecurity.RegisterGoogleClient();
        }
Esempio n. 20
0
        public static void RegisterAuth()
        {
            // To let users of this site log in using their accounts from other sites such as Microsoft, Facebook, and Twitter,
            // you must update this site. For more information visit http://go.microsoft.com/fwlink/?LinkID=252166

            OAuthWebSecurity.RegisterTwitterClient(
                consumerKey: "YfQiIJwfNNgNP5wdrbFGQ",
                consumerSecret: "32FMF5tLWuZSncDv1gtPSvf9n9MNXoE5bTin57k88g");

            OAuthWebSecurity.RegisterFacebookClient(
                appId: "648995925117562",
                appSecret: "e4f6bed3ceb08b673d186bc0096d1ce9");

            OAuthWebSecurity.RegisterGoogleClient();
        }
        public void Execute(Castle.Windsor.IWindsorContainer container)
        {
            //OAuthWebSecurity.RegisterMicrosoftClient(
            //    clientId: "",
            //    clientSecret: "");

            //OAuthWebSecurity.RegisterTwitterClient(
            //    consumerKey: "",
            //    consumerSecret: "");

            OAuthWebSecurity.RegisterFacebookClient(
                appId: "319649478165197",
                appSecret: "6e1cd15283a6598c89f7f7eb56f81735");

            OAuthWebSecurity.RegisterGoogleClient();
        }
Esempio n. 22
0
        /// <summary>
        /// Registers OAuth providers.
        /// </summary>
        public static void RegisterOAuth()
        {
            OAuthWebSecurity.RegisterFacebookClient(
                appId: "521113044653315",
                appSecret: "1a269b3d873b0bb1b5f68ed9fae14899");

            OAuthWebSecurity.RegisterTwitterClient(
                consumerKey: "nH7XAt2NM1vSaZsr6VW84g",
                consumerSecret: "KdsOZIvx1Iuv8JJSc2rGFXYUwLnxKZNsOmgWc4H2OTA"
                );

            OAuthWebSecurity.RegisterGoogleClient("Sprites", new Dictionary <string, object>()
            {
                { "firstName", null },
                { "lastName", null }
            });
        }
Esempio n. 23
0
        public static void RegisterAuth()
        {
            // To let users of this site log in using their accounts from other sites such as Microsoft, Facebook, and Twitter,
            // you must update this site. For more information visit http://go.microsoft.com/fwlink/?LinkID=252166

            //OAuthWebSecurity.RegisterMicrosoftClient(
            //    clientId: "",
            //    clientSecret: "");
            OAuthWebSecurity.RegisterFacebookClient(
                appId: "1419590428264107",
                appSecret: "ff3864334ec86bc63b4c327da5e6e1df");

            OAuthWebSecurity.RegisterTwitterClient(
                consumerKey: "U19Px06YoRQyG40eHxN5LA",
                consumerSecret: "J5cLkLpUxagjKUAQhtWdHfrEJobhLOr9ZiKoai0");

            OAuthWebSecurity.RegisterGoogleClient();
        }
        public static void RegisterAuth()
        {
            // To let users of this site log in using their accounts from other sites such as Microsoft, Facebook, and Twitter,
            // you must update this site. For more information visit http://go.microsoft.com/fwlink/?LinkID=252166
            OAuthWebSecurity.RegisterMicrosoftClient(
                clientId: ConfigurationManager.AppSettings["MicrosoftClientId"],
                clientSecret: ConfigurationManager.AppSettings["MicrosoftClientSecret"]);

            OAuthWebSecurity.RegisterTwitterClient(
                consumerKey: ConfigurationManager.AppSettings["TwitterConsumerKey"],
                consumerSecret: ConfigurationManager.AppSettings["TwitterConsumerSecret"]);

            OAuthWebSecurity.RegisterFacebookClient(
                appId: ConfigurationManager.AppSettings["FacebookApplicationId"],
                appSecret: ConfigurationManager.AppSettings["FacebookApplicationSecret"]);

            OAuthWebSecurity.RegisterGoogleClient();
        }
Esempio n. 25
0
        public static void RegisterProviders()
        {
            OAuthWebSecurity.RegisterGoogleClient();



            OAuthWebSecurity.RegisterFacebookClient(
                //appId: "2062881093756392",
                //appSecret: "565ab39ae98b2d1107c3fd30c37b5488"

                appId: "1154056031415680",
                appSecret: "d83289de8f3051f2393a4ab9911836aa"

                //appId: ConfigurationManager.AppSettings["AppId"],
                //appSecret: ConfigurationManager.AppSettings["AppSecret"]

                );
        }
Esempio n. 26
0
        public static void RegisterAuth()
        {
            // To let users of this site log in using their accounts from other sites such as Microsoft, Facebook, and Twitter,
            // you must update this site. For more information visit http://go.microsoft.com/fwlink/?LinkID=252166

            //OAuthWebSecurity.RegisterMicrosoftClient(
            //    clientId: "",
            //    clientSecret: "");

            //OAuthWebSecurity.RegisterTwitterClient(
            //    consumerKey: "",
            //    consumerSecret: "");

            OAuthWebSecurity.RegisterFacebookClient(
                appId: "1435173723392144",
                appSecret: "af2a67fe0b36199e14fc7f1a69e14d2e");

            OAuthWebSecurity.RegisterGoogleClient();
        }
Esempio n. 27
0
        public static void RegisterAuth()
        {
            // To let users of this site log in using their accounts from other sites such as Microsoft, Facebook, and Twitter,
            // you must update this site. For more information visit http://go.microsoft.com/fwlink/?LinkID=252166

            OAuthWebSecurity.RegisterMicrosoftClient(
                clientId: "000000004C0FF117",
                clientSecret: "-WXHKeSgH2wdJLpbr2mFmOD09g4-cgL6");

            OAuthWebSecurity.RegisterTwitterClient(
                consumerKey: "dRur8eZeyU4cY6cdo8VVFQ",
                consumerSecret: "OegIG39lu6dMGJjVAXySsGHgSpF1UMtBqJGOmnJti4");

            //OAuthWebSecurity.RegisterFacebookClient(
            //    appId: "",
            //    appSecret: "");

            OAuthWebSecurity.RegisterGoogleClient();
        }
Esempio n. 28
0
        public static void RegisterAuth()
        {
            // To let users of this site log in using their accounts from other sites such as Microsoft, Facebook, and Twitter,
            // you must update this site. For more information visit http://go.microsoft.com/fwlink/?LinkID=252166

            //OAuthWebSecurity.RegisterMicrosoftClient(
            //    clientId: "",
            //    clientSecret: "");

            OAuthWebSecurity.RegisterTwitterClient(
                consumerKey: "MtgnhFefAWmyDniRjm9TA",
                consumerSecret: "Lu9PrdPXyBoKN33oj8dKOoJ61uXRjyV4wYTxY8T4");

            //OAuthWebSecurity.RegisterFacebookClient(
            //    appId: "",
            //    appSecret: "");

            OAuthWebSecurity.RegisterGoogleClient();
        }
Esempio n. 29
0
        public static void RegisterAuth()
        {
            // To let users of this site log in using their accounts from other sites such as Microsoft, Facebook, and Twitter,
            // you must update this site. For more information visit http://go.microsoft.com/fwlink/?LinkID=252166

            //OAuthWebSecurity.RegisterMicrosoftClient(
            //    clientId: "",
            //    clientSecret: "");

            OAuthWebSecurity.RegisterTwitterClient(
                consumerKey: "no",
                consumerSecret: "sorry not for you");

            OAuthWebSecurity.RegisterFacebookClient(
                appId: "you can't have my login info",
                appSecret: "i am sometimes security conscious");

            OAuthWebSecurity.RegisterGoogleClient();
        }
Esempio n. 30
0
        public static void RegisterAuth()
        {
            // To let users of this site log in using their accounts from other sites such as Microsoft, Facebook, and Twitter,
            // you must update this site. For more information visit http://go.microsoft.com/fwlink/?LinkID=252166

            //OAuthWebSecurity.RegisterMicrosoftClient(
            //    clientId: "",
            //    clientSecret: "");

            //OAuthWebSecurity.RegisterTwitterClient(
            //    consumerKey: "",
            //    consumerSecret: "");

            OAuthWebSecurity.RegisterFacebookClient(
                appId: OAuthConfig.Facebook.Id,
                appSecret: OAuthConfig.Facebook.Secret);

            OAuthWebSecurity.RegisterGoogleClient();
        }