473,586 Members | 2,639 Online
Bytes | Software Development & Data Engineering Community
+ Post

Home Posts Topics Members FAQ

Unpack the Radius "User-Password" attribute

Hi, currently i am developing a Radius server application. Cananyone show me how can i unpack the "User-Password" attribute sothat i can get back the password in plain text so that i canverify it against my database.
For example, the user entered password "testpasswo rd". Assumethat the shared secret between the NAS and my radius server is"testshared ". I am totally unfamiliar with .NET encryption (MD5,XOR), so please provide some sample codes if possible. Thanks inadvance.

--------------------------------
From: twhan twhan

-----------------------
Posted by a user from .NET 247 (http://www.dotnet247.com/)

<Id>EqVsddrKg0S kMD4smy1Qlw==</Id>
Jul 21 '05 #1
1 3331
I would really suggest you seek someone with some cryptographic knowledge or
read a good book on security and cryptography BEFORE building a good radius
server application.
This is not meant to be hard on you, but really, when developing
applications for security, do it good!

It also is not specific to .NET, its used in general, everywhere.

Starting with some basics:
Secure Hash functions, such as MD5, SHA-1, SHA-256 have a single property,
they are one way. This means it is possible to easily derive h (hash code,
the output) from p (plaintext). So h = MD5(p) is simple.
For someone with only h, it should be impossible in practice to find a
(computionally unfeasable) p that satisfies h = MD5(p).

During an authentication process you don't want someone to actually read the
password, so if you are able to derive p from h, then anyone else can too.
So sending h will not provide any information about the password. Its still
vulnerable, since when I know h (which is send over the network) I can also
impersonate you. So this way should not be used.
Basically you do MD5(server_stor ed_p) = MD5(client_give n_p).

A challenge/response authentication works much better:
I send you 'r' being a random value.
You send me h = MD5(client_give n_p + r)
I compare MD5(server_stor ed_p + r) which must match.

Of course
I send you 'r' being a random value.
You send me h = MD5( MD5(client_give n_p) + r)
I compare MD5( MD5(server_stor ed_p) + r) which must match.
will work too.

Please, do youself a favor and get into security!
Always remember, encryption is only a tiny subset of security.

A second problem for you would be storing the passwords plain in a database.
This is very bad security practice. At least try to store hashes.

Books on cryptography.
http://www.google.nl/search?q=crypto...TF-8&hl=nl&lr=
http://www.youdzone.com/cryptobooks.html

Also try "Applied Cryptography", which gives a very mathematical approach
and is a very good book. Its freely available from the internet (use
google).

- Joris
Jul 21 '05 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

2
3709
by: jissay | last post by:
Hi, I use the following scrit in an Intranet with the user name = "" and the password = "" : <?php $ftp_server = "192.168.25.25"; $ftp_user = ""; $ftp_pass = "";
4
7366
by: Akhlaq Khan | last post by:
we are developing an intranet application (web based) which needs to detect the logged in user ID of the user hitting the website. the intranet is huge and based on win2k active directory (around 20-30 different domains) with 25K+ users. i dont want to use "NT challenge response" for this pupose. I am exploring ways using ADSI and WMI to...
2
1680
by: Netto | last post by:
**** Post for FREE via your newsreader at post.usenet.com **** When I try to use a created attribute for the tag "input", it works fine with IE 6, but it seems not to be recognized by Netscape 7.1... Are my thoughts right?? That's what I mean: I did that in a html code: <input type="text" name="inputname" required="true"> (Note: I...
4
2741
by: Guadala Harry | last post by:
Is there any way for one Session to remove and update objects in another Session? I seriously doubt it, but thought I'd ask. Here's why: I have some data that is unique per user (or per session - similar to "welcome back, Jim" after Jim logs in) and consumed across multiple pages. This "per user" data lives in a database, so toward improving...
1
2104
by: fl | last post by:
I am running ASPNET on my local machine. I have a problem when I try to connect to a SQL server database table. The data looks good when I right click SqlDataAdapter1 to preview the data. When F5 to run it, I get this error "Login failed for user '(null)'. Reason: Not associated with a trusted SQL Server connection..." Here is my code (they...
4
4388
by: Ying Lu | last post by:
Hello, I have a table named "USER" under MySQL database. When I am trying to move tables from MySQL to PostgreSQL, I found that I could not create a table namely "USER". I guess "USER" is a key string used by PostgreSQL system so that we could not create a table named "USER". Is that true? Thanks a lot, Emi Lu
5
1352
by: mabond | last post by:
Hi all This question is one of "theory" rather than a search for the specifics of a solution. I need some pointers as to how to proceed with my project. Here goes. My application allows the user to select from menu options. Some of the menus allow the user, via an options form, to select parameters for the display of reports. Those...
0
6685
by: godsmustbcrazy | last post by:
Here is my problem. Brand new SQL Server 2005 Installation 1. Create a database "Test" 2. Create a database user "Domain\user" and set user mapping to "Test" with datareader, datawriter permissions 3. Look at Test ->Properties->Permissions activate "Domain\user" and click effective permissions and I get this error message
6
6712
by: maanasa | last post by:
hi, i've one question. I'm supposed to create oracle user on click of a button using oracle forms. I'm calling a procedure which i've written in sql+ which is supposed to create the user. The problem is that i'm able to create user by writing execute immediate statement in the procedure, but i'm not able to grant connect to the user. Hence...
5
6914
by: WP | last post by:
Hello, I need to communicate with a db2 database from a java program and this java program needs to check which "user tables" there are. I came up with the following query which I tried in Control Center: select tabname, tabschema from syscat.tables where tabschema != 'SYSCAT' and tabschema != 'SYSIBM' and tabschema != 'SYSIBMADM' and...
0
7912
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main...
0
7839
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it. First, let's disable language...
0
8338
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven tapestry of website design and digital marketing. It's not merely about having a website; it's about crafting an immersive digital experience that...
1
7959
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For...
0
6614
agi2029
by: agi2029 | last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then...
0
5390
by: conductexam | last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one. At the time of converting from word file to html my equations which are in the word document file was convert...
0
3837
by: TSSRALBI | last post by:
Hello I'm a network technician in training and I need your help. I am currently learning how to create and manage the different types of VPNs and I have a question about LAN-to-LAN VPNs. The last exercise I practiced was to create a LAN-to-LAN VPN between two Pfsense firewalls, by using IPSEC protocols. I succeeded, with both firewalls in...
1
2345
by: 6302768590 | last post by:
Hai team i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
0
1180
bsmnconsultancy
by: bsmnconsultancy | last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.