Sponsored Content
Top Forums UNIX for Dummies Questions & Answers Carreer:Networking Programming in Unix (C programming Language) Post 302232999 by ovais245 on Friday 5th of September 2008 07:05:26 PM
Old 09-05-2008
Write or study a small program that mimics the most common login procedures in UNIX.
You have two options here. Either, you write it yourself according to the specification
below, or you copy the file
/cab/cestud/work/edu/course/EDA263_Computer_Security/
lib/login_linux/login_linux.c into your home directory. If you choose to write
it yourself the following should be implemented.
- The program begins with displaying ”login:” and takes the username as input.
7
- Then the program writes ”Password:” and waits for the password to be entered,
which should not be visible on the terminal (use the function getpass(3) that
among other things will see to that the text is not ”echoed” on the terminal).
- The program queries the system’s user database to see if the username exists. If
this is the case it encrypts the entered password (with a known algorithm) and
ensures it corresponds to the stored encrypted password belonging to the actual
user. Suitable library routines are getpwnam(3), crypt(3) and strncmp(3).
- If the username does not exist, or if the password is wrong, the program displays
”Login incorrect” and restarts from the beginning, otherwise it writes something
like ”Welcome to this System!” and terminates.
Test that your program works by compiling and running it.
This User Gave Thanks to ovais245 For This Post:
 

6 More Discussions You Might Find Interesting

1. UNIX for Dummies Questions & Answers

Does the programming language matters?

I see you guys encouraged people studied and used C while they were working on UNIX. Does C++ or JAVA matter? And in the past threads, Neo, PxT, and other members recommanded lots good books. I think those people who asked for the references, such as Dominic, had experiences on sys admin or... (8 Replies)
Discussion started by: HOUSCOUS
8 Replies

2. Programming

c programming language

Can someone enligten me on what below program does? I understand getchar and putchar.. but what is this program suppose to do? I try to put printf on it, but it shows nothing.. can someone explain to me what this program is suppose to do? It is reading something and assigning to c? so, if... (8 Replies)
Discussion started by: convenientstore
8 Replies

3. UNIX for Dummies Questions & Answers

Is PERL a programming language?

I need a small and simple clarification... Can someone tell me whether PERL is a programming language or not. Also, can shell scripts also considered as programming language or not. Also, please tell me the exact difference between programming language and scripting. Please help.... (3 Replies)
Discussion started by: Anjan1
3 Replies

4. Programming

What Programming language should I start learning first?

I want to create a computer program that will translate from English to Spanish and vice versa. So someone could type in a word, phrase, or paragraph and translate from one language to another. What programming language would I use to write up the code and then implement this program? I want to... (8 Replies)
Discussion started by: Anna Hussie
8 Replies

5. UNIX for Dummies Questions & Answers

How does unix system administration, unix programming, unix network programming differ?

How does unix system administration, unix programming, unix network programming differ? Please help. (0 Replies)
Discussion started by: thulasidharan2k
0 Replies

6. Programming

Whats the most in-demand programming language UNIX

I am interested in learning Programming Language to complement my UNIX. What language should I concentrate on to enhance my UNIX. What companies are seeking with UNIX. What languages are used with UNIX as for as there application. Are there any one here from DC (6 Replies)
Discussion started by: zbest1966
6 Replies
netconfig(8)						      System Manager's Manual						      netconfig(8)

NAME
netconfig - Launches the SysMan Menu to the Network Setup Wizard SYNOPSIS
/usr/sbin/netconfig /usr/sbin/sysman net_wizard DESCRIPTION
The Network Setup Wizard of the SysMan Menu can be used to configure and modify the configuration of a TCP/IP network on a Tru64 UNIX sys- tem. Use the Network Setup Wizard, netconfig, to do the following: Configure network interfaces, such as Ethernet, FDDI and Token Ring and existing ATM interfaces Enable and disable the following daemons: gated, joind, routed, and rwhod Configure the system as an IP router Add, modify, and delete entries in the following files: /etc/routes, /etc/gateways, etc/hosts, /etc/hosts.equiv, and /etc/networks Online help is available for the Network Management dialog boxes. To get help, click on any Help button. RESTRICTIONS
You must be root or have the appropriate privileges to run this application. FILES
Specifies the environment variables that define the netconfig configuration on your system Specifies Internet routing information Specifies the host name file Specifies the trusted hosts file Specifies the network name file Specifies Internet static routing information SEE ALSO
Commands: ifconfig(8), netsetup(8), rc.config(8), rcinet(8), sysman_menu(8) Files: gateways(4), hosts(4), hosts.equiv(4), networks(4), routes(4) Networking: network_manual_setup(7) netconfig(8)
All times are GMT -4. The time now is 04:50 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy