Kerberos 简介,举例,名词解释,相关文献

这是一篇简洁的 Kerberos 介绍。

举个例子

Kerberos 就像去食堂打饭,第一步先去收银台买饭票,第二步拿着饭票来到对应窗口取饭。


唯一的区别就是,现实生活里你可能是用钱买饭票,但是在 Kerberos 的世界吃饭是免费的,你只要出示学生卡证明身份,就能拿到饭票。


具体协议流程如图所示:

IMG_3158.JPG

RFC 链接:https://tools.ietf.org/html/rfc4120

The basic Kerberos authentication process proceeds as follows: A client sends a request to the authentication server (AS) for "credentials" for a given server.  The AS responds with these credentials, encrypted in the client's key.  The credentials consist of a "ticket" for the server and a temporary encryption key (often called a "session key").  The client transmits the ticket (which contains the client's identity and a copy of the session key, all encrypted in the server's key) to the server.  The session key (now shared by the client and server) is used to authenticate the client and may optionally be used to authenticate the server.  It may also be used to encrypt further communication between the two parties or to exchange a separate sub-session key to be used to encrypt further communication.  Note that many applications use Kerberos' functions only upon the initiation of a stream-based network connection. Unless an application performs encryption or integrity protection for the data stream, the identity verification applies only to the initiation of the connection, and it does not guarantee that subsequent messages on the connection originate from the same principal.


Implementation of the basic protocol consists of one or more authentication servers running on physically secure hosts.  The authentication servers maintain a database of principals (i.e., users and servers) and their secret keys.  Code libraries provide encryption and implement the Kerberos protocol.  In order to add authentication to its transactions, a typical network application adds calls to the Kerberos library directly or through the Generic Security Services Application Programming Interface (GSS-API) described in a separate document [RFC4121].  These calls result in the transmission of the messages necessary to achieve authentication. The Kerberos protocol consists of several sub-protocols (or exchanges).  There are two basic methods by which a client can ask a Kerberos server for credentials.  In the first approach, the client sends a cleartext request for a ticket for the desired server to the AS.  The reply is sent encrypted in the client's secret key.  Usually this request is for a ticket-granting ticket (TGT), which can later be used with the ticket-granting server (TGS).  In the second method, the client sends a request to the TGS.  The client uses the TGT to authenticate itself to the TGS in the same manner as if it were contacting any other application server that requires Kerberos authentication.  The reply is encrypted in the session key from the TGT.  Though the protocol specification describes the AS and the TGS as separate servers, in practice they are implemented as different protocol entry points within a single Kerberos server.


Once obtained, credentials may be used to verify the identity of the principals in a transaction, to ensure the integrity of messages exchanged between them, or to preserve privacy of the messages.  The application is free to choose whatever protection may be necessary.


To verify the identities of the principals in a transaction, the client transmits the ticket to the application server.  Because the ticket is sent "in the clear" (parts of it are encrypted, but this encryption doesn't thwart replay) and might be intercepted and reused by an attacker, additional information is sent to prove that the message originated with the principal to whom the ticket was issued. This information (called the authenticator) is encrypted in the session key and includes a timestamp.  The timestamp proves that the message was recently generated and is not a replay.  Encrypting the authenticator in the session key proves that it was generated by a party possessing the session key.  Since no one except the requesting principal and the server know the session key (it is never sent over the network in the clear), this guarantees the identity of the client.


The integrity of the messages exchanged between principals can also be guaranteed by using the session key (passed in the ticket and contained in the credentials).  This approach provides detection of both replay attacks and message stream modification attacks.  It is accomplished by generating and transmitting a collision-proof checksum (elsewhere called a hash or digest function) of the client's message, keyed with the session key.  Privacy and integrity of the messages exchanged between principals can be secured by encrypting the data to be passed by using the session key contained in the ticket or the sub-session key found in the authenticator.

名词解释

  • Client:就是吃饭的学生。

  • Server:就是打饭的大娘。

  • Authentication Server (AS)/ KDC:卖饭票的大姐。

  • Principal:就是指 Client 或者 Server 这样的参与网络通信的其中一方,有唯一标识符来表示。

  • Credentials:AS 返回给 Client 的信息,包含两部分:Ticket 和 SessionKey。被 Client 密钥加密,只有 Client 能看到内容。

  • Ticket:包含两部分:Client 的身份信息和 SessionKey。被 Server 的密钥加密,只有 Server 能看到内容。

  • TGT:如果有一个 Server 是认证服务器,,Kerberos 中的 Credentials 就可以被称为 TGT。此时整个过程主要是通过 Kerberos,免去用户名密码去 Server 那里拿一个登录状态。此时的 Server 称为 TGS。



参考资料:

英文:

https://tools.ietf.org/html/rfc4120

https://web.mit.edu/Kerberos/krb5-1.5/krb5-1.5.4/doc/krb5-user/Introduction.html

中文:

http://www.cnblogs.com/idior/archive/2006/03/20/354027.html


  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
YOLO高分设计资源源码,详情请查看资源内容中使用说明 YOLO高分设计资源源码,详情请查看资源内容中使用说明 YOLO高分设计资源源码,详情请查看资源内容中使用说明 YOLO高分设计资源源码,详情请查看资源内容中使用说明YOLO高分设计资源源码,详情请查看资源内容中使用说明YOLO高分设计资源源码,详情请查看资源内容中使用说明YOLO高分设计资源源码,详情请查看资源内容中使用说明YOLO高分设计资源源码,详情请查看资源内容中使用说明YOLO高分设计资源源码,详情请查看资源内容中使用说明YOLO高分设计资源源码,详情请查看资源内容中使用说明YOLO高分设计资源源码,详情请查看资源内容中使用说明YOLO高分设计资源源码,详情请查看资源内容中使用说明YOLO高分设计资源源码,详情请查看资源内容中使用说明YOLO高分设计资源源码,详情请查看资源内容中使用说明YOLO高分设计资源源码,详情请查看资源内容中使用说明YOLO高分设计资源源码,详情请查看资源内容中使用说明YOLO高分设计资源源码,详情请查看资源内容中使用说明YOLO高分设计资源源码,详情请查看资源内容中使用说明YOLO高分设计资源源码,详情请查看资源内容中使用说明YOLO高分设计资源源码,详情请查看资源内容中使用说明YOLO高分设计资源源码,详情请查看资源内容中使用说明YOLO高分设计资源源码,详情请查看资源内容中使用说明YOLO高分设计资源源码,详情请查看资源内容中使用说明YOLO高分设计资源源码,详情请查看资源内容中使用说明YOLO高分设计资源源码,详情请查看资源内容中使用说明YOLO高分设计资源源码,详情请查看资源内容中使用说明
### 回答1: Kerberos使用的是对称加密。 原因是Kerberos需要在客户端和服务器之间进行大量的加密和解密操作,而对称加密的计算量比非对称加密小得多,因此使用对称加密可以显著降低网络和计算负担。另外,Kerberos还使用了时间戳和序列号等机制来确保通信的安全性,从而弥补了对称加密可能存在的安全性问题。 ### 回答2: Kerberos使用对称加密。 Kerberos是一种网络身份验证协议,旨在提供安全的身份认证服务。在Kerberos中,对称加密被用于加密通信内容,确保通信的机密性。 对称加密是一种加密方式,其中使用相同的密钥来加密和解密数据。这种加密方式的优势在于速度快,适合加密大量数据。在Kerberos中,由于身份验证过程中的通信量通常不是很大,因此使用对称加密可以提供高效的加密和解密过程。 Kerberos的基本工作原理是通过TGT(Ticket Granting Ticket)和服务票证对用户进行身份认证。当用户登录后,Kerberos服务器会生成一个TGT并使用用户的密码对其进行加密,然后将加密后的TGT返回给用户。用户在随后的通信中,使用TGT向Kerberos服务器请求特定服务的票证。 对称加密在Kerberos的身份验证过程中发挥重要作用,因为用户对TGT数据进行解密以获得访问特定服务的票证。同时,服务票证也使用对称加密进行保护,确保只有具有正确密钥的服务才能够解密和验证票证。 所以,Kerberos使用对称加密,通过对TGT和服务票证的加密和解密,确保用户的身份验证和通信内容的机密性。 ### 回答3: Kerberos使用的是对称加密。 Kerberos是一个网络认证协议,其目的是通过域控制器(KDC)来验证用户的身份,并为用户在网络中访问资源提供安全的认证机制。在Kerberos中,包含了三个实体,即用户、服务和KDC。用户通过KDC获取访问资源所需的“票据”,然后将该票据提供给服务来获取资源访问权限。 Kerberos中的票据主要包括两个部分,即票据授权票(Ticket Granting Ticket,TGT)和服务票据(Service Ticket)。为了确保传输过程中的安全性,Kerberos使用了加密算法。而对称加密算法在Kerberos中被应用于票据的加密。 对称加密是一种加密方式,使用相同的密钥进行加密和解密操作。在Kerberos中,用户和KDC之间传输的TGT需要进行加密,以确保第三方无法窃取和篡改该票据。因此,对称加密算法被用来加密和解密TGT,保护其机密性。 相比之下,非对称加密算法则用于票据中的服务票据。服务票据是为了向服务提供方证明用户的身份,并获取相应资源的权限。这涉及到用户和服务之间的通信,因此需要更高级别的安全性。非对称加密算法通过使用一对密钥,即公钥和私钥,来实现加密和解密操作。用户使用服务提供方的公钥加密服务票据,而服务提供方使用自己的私钥解密该票据。 综上所述,Kerberos在票据传输过程中使用对称加密算法保护TGT的安全性,而使用非对称加密算法确保服务票据的安全性。这样可以保证Kerberos协议的安全性和可靠性,从而实现网络用户的身份认证和资源访问控制。

“相关推荐”对你有帮助么?

  • 非常没帮助
  • 没帮助
  • 一般
  • 有帮助
  • 非常有帮助
提交
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值