Click here to Skip to main content
15,924,318 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
See more:
hi,

I would like to use modules in vb.net to make track of Username and password NOT any form of database like ms or access or sql etc.

I am currently using the my.settings.username to store usernames and passwords however its not secure and also I want every single user to feel special as when they log in I want to generate a label which will say "Welcome {username}" Any suggestions please

its for my stock system :D

What I have tried:

tried to generate a label with my.settings.username to show output username on the label welcoming them however it just outputs the latest registered username saved
Posted
Updated 9-Dec-17 20:09pm

1 solution

The problem is that you need to sort out some form of "backing storage" to preserve login details once your app is closed. If you don't then unless you hard-code the users and their details into your application - and that's a very bad idea - then you will have to "teach" it the users anew each time.

The backing storage doesn't have to be a database - though that is the most usual method - you can use almost anything, including XML, CSV, or even flat text files.
Or even My.Settings (though this makes "sharing" user details between two or more PC's on a network a lot harder to do).

But the choice of backing storage isn't what makes it secure or insecure: how you store the data in that storage is what controls that.
If you store:
Smith, John, BigJohn, MyPasswordIsStrong!
Then it will always be insecure.
If instead you hash the password, and store the hash:
Smith, John, BigJohn, 479a49ed4105db89b429482a9c8355537210158740964554b636f86ed00ec91b
Then the password info is secure regardless of how you store it.
Have a look at this: Password Storage: How to do it.[^] - the code is in C#, but it's pretty obvious and and online Code Converter[^] can translate it to VB if you can't understand it.
 
Share this answer
 

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900