Seminar Report On Kerberos
Seminar Report On Kerberos
&
TECHNOLOGY
Seminar Report
On
“KERBEROS”
done by
VIVEK SHUKLA
of the VIth semester, Computer Science and Engineering in the session 2010-
2011 in partial fulfillment of the
requirements to the award of Degree of Bachelor of Technology in Computer
Science and Engineering
of Gautam Buddha Technical University.
Mr.Ashok kr.Mishra
Idea cellular limited
Jabalpur (MP)
ACKNOWLEDGEMENT
At the outset, i thank the lord almighty for the grace, strength and hope to make
this endeavor a success. I express my deep felt gratitude to Mrs. Madhulika
Sharma, Head of the Department, Computer Science Engineering, Azad
Institute Of Engineering & Technology for her constant encouragement. I am
profoundly grateful to Mr. Ashok Mishra, Instructor, Idea Cellular Limited, for
his valuable guidance support, suggestions and encouragement. Furthermore I
would like to thank all others especially my numerous friends over here. This
training would not have been a success without the inspiration, valuable
suggestions and moral support from them throughout its course.
Vivek Shukla
Abstract
Introduction
Kerberos is an authentication system designed by Miller and Neuman for open
network computing environments, and describes our experience using it at
MIT’s Project Athena. First section explain why a new authentication model is
needed for open networks, and what its requirements are. The second section
lists the components of the Kerberos software and describes how they interact
in providing the authentication service. In Section 3, we describe the Kerberos
naming scheme. Section 4 presents the building blocks of Kerberos
authentication the ticket and the authenticator. This leads to a discussion of
the two authentication protocols: the initial authentication of a user to Kerberos
(analogous to logging in), and the protocol for mutual authentication of a
potential consumer and a potential producer of a network service. Kerberos
requires a database of information about its clients; Section 5 describes the
database, its management, and the protocol for its modification. Section 6
describes the Kerberos interface to its users, applications programmers, and
administrators. In Section 7, we describe how the Project Athena Kerberos fits
into the rest of the Athena environment. We also describe the interaction of
different Kerberos authentication domains, or realms; in our case, the relation
between the Project Athena Kerberos and the Kerberos running at MIT’s
Laboratory for Computer Science. In Section 8, we mention open issues and
problems as yet unsolved. The last section gives the current status of Kerberos
at Project Athena. In the appendix, we describe in detail how Kerberos is
applied to a network file service to authenticate users who wish to gain access to
remote file systems.
Conventions. Throughout this paper we use terms that may be ambiguous, new
to the reader, or used differently elsewhere. Below we state our use of those
terms. User, Client, Server. By user, we mean a human being who uses a
program or service. A client also uses something, but is not necessarily a
person; it can be a program. Often network applications consist of two parts;
one program which runs on one machine and requests a remote service, and
another program which runs on the remote machine and performs that service.
We call those the client side and server side of the application, respectively.
Often, a client will contact a server on behalf of a user. Each entity that uses the
Kerberos system, be it a user or a network server, is in one sense a client, since
it uses the Kerberos service. So to distinguish Kerberos clients from clients of
other services, we use the term principal to indicate such an entity. Note that a
Kerberos principal can be either a user or a server. (We describe the naming of
Kerberos principals in a later section.) Service vs. Server. We use service as an
abstract specification of some actions to be performed. A process which
performs those actions is called a server. At a given time, there may be several
servers (usually running on different machines) performing a given service . For
example, at Athena there is one BSD UNIX rlogin server running on each of
our timesharing machines. Key, Private Key, Password. Kerberos uses private
key encryption. Each Kerberos principal is assigned a large number, its private
key, known only to that principal and Kerberos. In the case of a user, the private
key is the result of a one-way function applied to the user’s password. We use
key as shorthand for private key. Credentials. Unfortunately, this word has a
special meaning for both the Sun Network File System and the Kerberos
system. We explicitly state whether we mean NFS credentials or Kerberos
credentials, therwise the term is used in the normal English language sense.
Master and Slave. It is possible to run Kerberos authentication software on
more than one machine. However, there is always only one definitive copy of
the Kerberos database. The machine which houses this database is called the
master machine, or just the master. Other machines may possess read-only
copies of the Kerberos database, and these are called slaves.
1. Motivation
2. What is Kerberos?
Kerberos is a trusted third-party authentication service based on the model
presented by Needham and chroeder.It is trusted in the sense that each of its
clients believes Kerberos’ judgement as to the identity of each of its other
clients to be accurate. Timestamps (large numbers representing the current date
and time) have been added to the original model to aid in the detection of
replay. Replay occurs when a message is stolen off the network and resent later.
For a more complete description of replay, and other issues of authentication,
see Voydock and Kent.
Kerberos keeps a database of its clients and their private keys. The private key
is a large number known only to Kerberos and the client it belongs to. In the
case that the client is a user, it is an encrypted password. Network services
requiring authentication register with Kerberos, as do clients wishing to use
those services. The private keys are negotiated at registration. Because Kerberos
knows these private keys, it can create messages which convince one client
that another is really who it claims to be. Kerberos also generates temporary
private keys, called session keys, which are given to two clients and no one else.
A session key can be used to encrypt messages between two parties. Kerberos
provides three distinct levels of protection. The application programmer
determines which is appropriate, according to the requirements of the
application. For example, some applications require only that authenticity be
established at the initiation of a network connection, and can assume that further
messages from a given network address originate from the authenticated party.
Our authenticated network file system uses this level of security. Other
applications require authentication of each message, but do not care whether the
content of the message is disclosed or not. For these, Kerberos provides safe
messages. Yet a higher level of security is provided by private messages, where
each message is not only authenticated, but also encrypted. Private messages are
used, for example, by the Kerberos server itself for sending passwords over the
network.
2.2.Theory
AS = Authentication Server
SS = Service Server
TGS = Ticket-Granting Server
TGT = Ticket Granting Ticket
The client authenticates to the AS once using a long-term shared secret (e.g. a
password) and receives a TGT from the AS. Later, when the client wants to
contact some SS, it can (re)use this ticket to get additional tickets from TGS,
for SS, without resorting to using the shared secret. These tickets can be used to
prove authentication to SS.
1. – The authentication service, or AS, receives the request by the client and
verifies that the client is indeed the computer it claims to be. This is usually just
a simple database lookup of the user’s ID.
3. – The key is sent back to the client in the form of a ticket-granting ticket, or
TGT. This is a simple ticket that is issued by the authentication service. It is
used for authenticating the client for future reference.
4. – The client submits the ticket-granting ticket to the ticket-granting server,
or TGS, to get authenticated.
5. – The TGS creates an encrypted key with a timestamp, and grants the client a
service ticket.
6. – The client decrypts the ticket, tells the TGS it has done so, and then sends
its own encrypted key to the service.
7. – The service decrypts the key, and makes sure the timestamp is still valid. If
it is, the service contacts the key distribution center to receive a session that is
returned to the client.
8. – The client decrypts the ticket. If the keys are still valid, communication is
initiated between client and server.
3. Kerberos Names
Part of authenticating an entity is naming it. The process of authentication is the
verification that the client is the one named in a request. What does a name
consist of? In Kerberos, both users and servers are named. As far as the
authentication server is concerned, they are equivalent. A name consists of a
primary name, an instance, and a realm, expressed as name.instance@realm
(see Figure 2).
bcn
treese.root
jis@LCS.MIT.EDU
rlogin.priam@ATHENA.MIT.EDU
The primary name is the name of the user or the service. The instance is used to
distinguish among variations on the primary name. For users, an instance may
entail special privileges, such as the ‘‘root’’ or ‘‘admin’’ instances. For services
in the Athena environment, the instance is usually the name of the machine on
which the server runs. For example, the rlogin service has different instances on
different hosts: rlogin.priam is the rlogin server on the host named priam. A
Kerberos ticket is only good for a single named server. As such, a separate
ticket is required to gain access to different instances of the same service. The
realm is the name of an administrative entity that maintains authentication data.
For example, different institutions may each have their own Kerberos machine,
housing a different database. They have different Kerberos realms. (Realms are
discussed further in section 8.2.)
4. How It Works
This section describes the Kerberos authentication protocols. The following
abbreviations are used in the figures.
c -> client
s -> server
addr -> client’s network address
life -> lifetime of ticket
tgs, TGS -> ticket-granting server
Kerberos -> authentication server
KDBM -> administration server
Kx -> x’s private key
Kx,y -> session key for x and y
{abc}Kx -> abc encrypted in x’s key
Tx,y -> x’s ticket to use y
Ax -> authenticator for x
WS -> workstation
4.1. Credentials
There are two types of credentials used in the Kerberos authentication model:
tickets and authenticators. Both are based on private key encryption, but they
are encrypted using different keys. A ticket is used to securely pass the identity
of the person to whom the ticket was issued between the authentication server
and the end server. A ticket also passes information that can be used to make
sure that the person using the ticket is the same person to which it was issued.
The authenticator contains the additional information which, when compared
against that in the ticket proves that the client presenting the ticket is the same
one to which the ticket was issued. A ticket is good for a single server and a
single client. It contains the name of the server, the name of the client, the
Internet address of the client, a timestamp, a lifetime, and a random session key.
This information is encrypted using the key of the server for which the ticket
will be used. Once the ticket has been issued, it may be used multiple times by
the named client to gain access to the named server, until the ticket expires.
Note that because the ticket is encrypted in the key of the server, it is safe to
allow the user to pass the ticket on to the server without having to worry about
the user modifying the ticket (see Figure 3).
Unlike the ticket, the authenticator can only be used once. A new one must be
generated each time a client wants to use a service. This does not present a
problem because the client is able to build the authenticator itself. An
authenticator contains the name of the client, the workstation’s IP address, and
the current workstation time. The authenticator is encrypted in the session key
that is part of the ticket (see Figure 4).
When the user walks up to a workstation, only one piece of information can
prove her/his identity: the user’s password. The initial exchange with the
authentication server is designed to minimize the chance that the password will
be compromised, while at the same time not allowing a user to properly
authenticate her/himself without knowledge of that password. The process of
logging in appears to the user to be the same as logging in to a timesharing
system. Behind the scenes, though, it is quite different (see Figure 5).
Figure 5. Getting the Initial Ticket.
The user is prompted for her/his username. Once it has been entered, a request
is sent to the authentication server containing the user’s name and the name of a
special service known as the ticket-granting service. The authentication server
checks that it knows about the client. If so, it generates a random session key
which will later be used between the client and the ticket-granting server. It then
creates a ticket for the ticket-granting server which contains the client’s name,
the name of the ticket-granting server, the current time, a lifetime for the ticket,
the client’s IP address, and the random session key just created. This is all
encrypted in a key known only to the ticket granting server and the
authentication server. The authentication server then sends the ticket, along with
a copy of the random session key and some additional information, back to the
client. This response is encrypted in the client’s private key, known only to
Kerberos and the client, which is derived from the user’s password. Once the
response has been received by the client, the user is asked for her/his password.
The password is converted to a DES key and used to decrypt the response from
the authentication server. The ticket and the session key, along with some of the
other information, are stored for future use, and the user’s password and DES
key are erased from memory. Once the exchange has been completed, the
workstation possesses information that it can use to prove the identity of its user
for the lifetime of the ticket-granting ticket. As long as the software on the
workstation had not been previously tampered with, no information exists that
will allow someone else to impersonate the user beyond the life of the ticket.
It is assumed that clocks are synchronized to within several minutes. If the time
in the request is too far in the future or the past, the server treats the request as
an attempt to replay a previous request. The server is also allowed to keep track
of all past requests with timestamps that are still valid. In order to further foil
replay attacks, a request received with the same ticket and timestamp as one
already received can be discarded. Finally, if the client specifies that it wants
the server to prove its identity too, the server adds one to the timestamp the
client sent in the authenticator, encrypts the result in the session key, and sends
the result back to the client (see Figure 7).
At the end of this exchange, the server is certain that, according to Kerberos, the
client is who it says it is. If mutual authentication occurs, the client is also
convinced that the server is authentic. Moreover, the client and server share a
key which no one else knows, and can safely assume that a reasonably recent
message encrypted in that key originated with the other party.
Note that, while authentication can still occur (on slaves), administration
requests cannot be serviced if the master machine is down. In our experience,
this has not presented a problem, as administration requests are infrequent. The
KDBM handles requests from users to change their passwords. The client side
of this program, which sends requests to the KDBM over the network, is the
kpasswd program. The KDBM also accepts requests from Kerberos
administrators, who may add principals to the database, as well as change
passwords for existing principals. The client side of the administration program,
which also sends requests to the KDBM over the network, is the kadmin
program.
Users may change their Kerberos passwords using the kpasswd program. They
are required to enter their old password when they invoke the program. This
password is used to fetch a ticket for the KDBM server.
5.3. Database Replication
Each Kerberos realm has a master Kerberos machine, which houses the master
copy of the authentication database. It is possible (although not necessary) to
have additional, read-only copies of the database on slave machines elsewhere
in the system. The advantages of having multiple copies of the database are
those usually cited for replication: higher availability and better performance. If
the master machine is down, authentication can still be achieved on one of the
slave machines. The ability to perform authentication on any one of several
machines reduces the probability of a bottleneck at the master machine.
Keeping multiple copies of the database introduces the problem of data
consistency. We have found that very simple methods suffice for dealing with
inconsistency. The master database is dumped every hour. The database is sent,
in its entirety, to the slave machines, which then update their own databases. A
program on the master host, called kprop, sends the update to a peer program,
called kpropd, running on each of the slave machines (see Figure 13). First
kprop sends a checksum of the new database it is about to send. The checksum
is encrypted in the Kerberos master database key, which both the master and
slave Kerberos machines possess. The data is then transferred over the network
to the kpropd on the slave machine. The slave propagation server calculates a
checksum of the data it has received, and if it matches the checksum sent by the master,
the new information is used to update the slave’s database.
All passwords in the Kerberos database are encrypted in the master database
key Therefore, the information passed from master to slave over the network is
not useful to an eavesdropper. However, it is essential that only information
from the master host be accepted by the slaves, and that tampering of data be
detected, thus the checksum.
6. Kerberos From the Outside Looking In
The section will describe Kerberos from the practical point of view, first as seen
by the user, then from the application programmer’s viewpoint, and finally,
through the tasks of the Kerberos administrator.
9. Status
A prototype version of Kerberos went into production in September of 1986.
Since January of 1987, Kerberos has been Project Athena’s sole means of
authenticating its 5,000 users, 650 workstations, and 65 servers. In addition,
Kerberos is now being used in place of .rhosts files for controlling access in
several of Athena’s timesharing systems.
Drawbacks
Refrence
www.wikipedia.com
www.scribd.com
www.seminarsonly.com