asp.net-membership

How do I control MembershipProvider instance creation/lifetime?

余生长醉 提交于 2019-12-17 13:04:04
问题 I have registered a custom MembershipProvider class in my Web.Config file. I'm using Inversion Of Control using Castle Windsor and I have registered my custom MembershipProvider class as transient (because it's using a service that's transient as well). This means that I want the Membership provider instance recreated on every web request. Currently, it is created only once per application domain so when it tries to access the service it depends on, that service instance is reused while it is

Hashing vs. Encrypting Passwords

吃可爱长大的小学妹 提交于 2019-12-17 12:40:54
问题 I'm using ASP.NET membership for a site that will serve primarily sophisticated users. I understand the difference between hashed and encrypted passwords, and I'm trying to decide between the two. After my last client complained bitterly about hashed passwords being a total PITA, I've started to favor encrypted passwords. But someone suggested this just isn't secure enough. So my question is: What, exactly are the risks of encrypting passwords? Any person with the ability to steal passwords

Sitecore authenticate users against external membership database

萝らか妹 提交于 2019-12-17 11:00:27
问题 I have a Sitecore site where I want to have website visitor accounts stored in an external asp.net membership database but keep Sitecore content editors/admins managed via the Sitecore interface (and hence stored in the 'Core' database). I've read through the following forum post http://sdn.sitecore.net/SDN5/Forum/ShowPost.aspx?postid=35305 in which the following documents are mentioned http://sdn.sitecore.net/upload/sitecore6/62/membership_providers_sc62-a4.pdf http://sdn.sitecore.net/upload

ASP.NET MVC3 Role and Permission Management -> With Runtime Permission Assignment

安稳与你 提交于 2019-12-17 08:53:12
问题 ASP.NET MVC allows users the ability to assign permissions to functionality (i.e. Actions) at Design Time like so. [Authorize(Roles = "Administrator,ContentEditor")] public ActionResult Foo() { return View(); } To actually check the permission, one might use the following statement in a (Razor) view: @if (User.IsInRole("ContentEditor")) { <div>This will be visible only to users in the ContentEditor role.</div> } The problem with this approach is that all permissions must be set up and

Using one Asp.net Membership database with multiple applications Single Sign On

为君一笑 提交于 2019-12-17 06:35:36
问题 I have two asp.net applications on one IIS server and I would like to use the same back end asp_security database and membership provider. I've read that all I have to do is reference the same application name in both web configs as I'm doing now, but I must be doing something wrong In each applications web.config I have this section. <membership> <providers> <clear/> <add name="AspNetSqlMembershipProvider" type="System.Web.Security.SqlMembershipProvider, System.Web, Version=2.0.0.0, Culture

How do I use my own database with SimpleMembership and WebSecurity? What is MVC4 security all about?

南笙酒味 提交于 2019-12-17 06:21:43
问题 I've read everything on this topic I could find, including MSDN articles and SO posts, but I'm still very lost and confused. Questions Please answer the following (briefly, if possible): What is SimpleMembership/SimpleMembershipProvider ( WebMatrix.WebData ) and what is it/are they responsible for? What is WebSecurity ( WebMatrix.WebData )? What is the Membership ( System.Web.Security ) class? Why does MVC4 create a UserProfile table and a webpages_Membership table? What are they for and what

ASP.NET authentication login and logout with browser back button

我怕爱的太早我们不能终老 提交于 2019-12-17 03:39:40
问题 I am looking for a solution for user use the browser's back button to navigate to previous page once logged out. I have a web application build in asp.net and using a custom membership provider for authentication and authorization. Everything works fine except when the user click on the logout link to log out of the application and being redirect to a default cover page, if the use click on the BACK BUTTON on their browser, it will actually go back to where they were before and the data will

Login and Logout Redirection

大兔子大兔子 提交于 2019-12-14 04:03:04
问题 I have a simple Web Forms login. The application has three roles, Admin, Expert and Member. I want to re-direct to a different sub-page for each. I also want to be able to re-direct to home page on logout. I've asked a similar question here, but the solution overrode the LoginStatus LogoutPageUrl attribute. Can anyone suggest how to do this? UPDATE 12/28/2012 So far, the only solution to this I have found is to create a new menu page containing security-trimmed links to the different

Simple Membership Provider vs Universal vs Code-First

 ̄綄美尐妖づ 提交于 2019-12-14 03:49:44
问题 I would like to ask what is difference betweeen this three membership providers from SQL Server Compact perspective. As far I as I saw first two of them can use compact server by design and third one by coincidence I guess, because of entity framework. So, is there any difference in fact? 回答1: Difference is Universal is nearly the same as original with added support for SQL Compact and Azure. Simple membership is a bit simplified, has a few additional modern implementations like token based

Working with PagedList and Membership

元气小坏坏 提交于 2019-12-14 02:15:44
问题 I've been playing around with Troy Goode's PagedList http://pagedlist.codeplex.com/. I was wondering if anyone has gotten it to work with the built in asp.net Membership piece? I have over 8000 users so I need to be able to page thru the User list. using a line like this in my memberhsip controller doesn't work. It wont compile. Membership.GetAllUsers().ToPagedList(currentPageIndex, defaultPageSize); Appreciate any guidance in this area... TIA -MARK- putrtek@gmail.com 回答1: Membership