forms-authentication

python authentication with requests library via POST

那年仲夏 提交于 2021-02-19 08:16:14
问题 I read several similar topic.. I try to follow the others examples but I'm still stuck in the middle of nowhere.. I have basic skills of python programming and little knowledge about http protocol, my two goals are: -succesfull authentication to a website via requests library -fetch data from the website after the login while the session is active This is the code: import requests targetws = 'https://secure.advfn.com/login/secure' s = requests.session() payload_data = {'login_username': 'xxx'

ASP.NET authentication cookie disappears, only in IE, only from specific locations

亡梦爱人 提交于 2021-02-19 01:40:50
问题 Internet explorer is not keeping my authentication cookie after one page redirect. Here is the situation: I have an ASP.NET 2.0 web application running on a shared iis7 hosting. The application uses forms authentication to handle login and user identity and writing a cookie (.ASPXFORMSAUTH) on the client machine for that purpose. in IE (checked with version 8, 9), from some locations , the authentication cookie is not being kept after the first page. The observed behavior is: User name and

How to prevent anonymous users from accessing a file using forms authentication?

吃可爱长大的小学妹 提交于 2021-02-10 14:50:20
问题 We are using forms authentication to authenticate users. In our application there is a page to download an exe. When I am debugging the code in visual studio, it allows only logged-in users to download the file. When other users try to download the file, they are automatically redirected to the login page. But when I am running this from a virtual directory, all users (whether logged-in or not) can download the file by accessing the direct path like http://testappln/foldername/test.exe . How

SignOut of claims authentication

ε祈祈猫儿з 提交于 2021-01-29 20:27:35
问题 I have successfully implemented claims authentication in to my project. As shown here: var userCredentials = new[] { new Claim("UserId", userProfile.UserId.ToString()), new Claim("Username", userProfile.UserName)}; var id = new ClaimsIdentity(userCredentials, "Forms"); var cp = new ClaimsPrincipal(id); var token = new SessionSecurityToken(cp); var sam = FederatedAuthentication.SessionAuthenticationModule; sam.WriteSessionTokenToCookie(token); Which is working correctly, the issue I'm trying

ASP .net forms authentication very slow on first login

最后都变了- 提交于 2021-01-28 08:04:59
问题 I have a web application (.net 4.0) with forms authentication (username and password). I have been trying to track down an issue with a slow login, and have come to the conclusion that on the initial login the page takes anywhere from 20-50seconds to login, and each subsequent logins (logoff and log back in) take an average of 3 seconds. What is causing this to take so long on an initial login? Most users will only log into the site once a day, so this seems like the site is slow, when in