Visit this for some code implemented for the NewCertification project
Find the whole project, along with the Database and its log file in mdf format here
You will probably have to change the connection string in the WebService Web Config file to make a successful connection to the DatabaseTechnologies/Techniques used
· MasterPages
· WebServices
· ADO.NET
· AJAX
· User roles
· Localization
· Exception Handling/Logging
· Authorization/Authentication
· C# object oriented programming
· Stored Procedures
· Cryptography
· Configuration Files
· CSS Files
· Encrypted Passwords in Database
Logging in the Web Application
1. LoginUser.aspx
a. The user enters a username and password
b. Online Certification makes a Web Service call to validate the credentials and returns a Dataset
c. If the Dataset contains no rows, the System alerts that there is no such user
d. If the Dataset contains more than one row, this means that the user is joined to more than one role. Note that due to the implementation on newUser.aspx, the usernames are unique. The system redirects the user to userRoles.aspx to choose the desired role and continue to the specific homepage.
e. If the Dataset contains a single row, redirect the user to his/hers homepage according to his/hers role
Authorization/Authentication
All WebContentForms use pageBase as their MasterPage. In the page load event of pageBase, the system checks if the Session userPk, username etc are set which can only be done with proper logging in. If these are not set Online Certification redirects the user to loginAgain.aspx, prompting for logging in. Thus if someone tries to bypass the log in page, by changing the text of the address bar to newUser.aspx for example, he/she will not be able to.
Exception Logging
Just like every system, Online Certification, will face exceptions. In order to provide better and faster support for the users, every exception will be logged in the Database. In the case of an exception, the user will be redirected to the exception page where he/she will receive the exception pk. After that he/she will be able to contact the system developers and provide them the pk, which will help them better understand what went wrong by querying the Database for the StackTrace and Message that corresponds to the specific pk.
Δεν υπάρχουν σχόλια:
Δημοσίευση σχολίου