rfc3552.Guidelines for Writing RFC Text on Security Considerations
imap rfc标准
Internet Message Access Protocol (IMAP) is an email retrieval protocol. It stores email messages on a mail server and enables the recipient to view and manipulate them as though they were stored locally on their device. IMAP was developed in the late 1980s and has since become one of the most widely used email retrieval protocols.The IMAP standard is defined in RFC 3501, which was published in 2003. This document provides a detailed description of the protocol's functionality, including its data formats, commands, and responses. The standard specifies how IMAP clients and servers should communicate with each other to enable the retrieval and manipulation of email messages.One of the key features of IMAP is its support for multiple clients accessing the same mailbox simultaneously. This is achieved through the use of a "shared" storage model, where all clients see the same set of messages and folders stored on the server. This allows users to access their email from different devices without having to worry about synchronizing their messages manually.Another important aspect of IMAP is its support for message organization and management. Clients can create, delete, and rename folders, as well as move messages between folders. They can also search for specific messages based on various criteria, such as sender, subject, or date.IMAP also provides a range of features for managing individual messages. Clients can mark messages as read or unread, flag them for follow-up, and even move them to a specific folder. They can also reply to messages, forward them to others, and generate replies or forwards with attachments.Overall, the IMAP standard provides a powerful and flexible framework for managing email messages. Its support for shared storage, message organization, and advanced message management features make it a popular choice for both personal and business email users.。
东进多媒体交换机、东进交换机技术交流
第三部分、Keygoe 3G视频 第三部分、 视频 第四部分、 第四部分、Keygoe 大容量坐席和多路接入方案
深圳市讯呼信息技术有限公司 呼叫中心系统 电话销售系统
Keygoe 产品介绍 第一部分 Keygoe 产品介绍
1、 Keygoe 准确定义 、 2、 Keygoe 应用模型 、 3、 Keygoe 设计要点 、 4、 Keygoe 系统架构 、 5、 Keygoe 性能参数 、
创新通讯 服务全球
Innovative Communication global Services
多媒体交换机技术交流
深圳市东进通讯技术股份有限公司 营销中心
深圳市讯呼信息技术有限公司 呼叫中心系统 电话销售系统
主要内容
第一部分、 第一部分、Keygoe 产品介绍 第二部分、 第二部分、Keygoe VOIP
3插槽 插槽 48E1 16 96 24 48 1440 768 360 360 360
6插槽 插槽 64E1 16 128 32 64 1920 1024 480 480 480
14插槽 插槽 128E1 16 256 64 128 3840 2048 960 960 960
深圳市讯呼信息技术有限公司 呼叫中心系统 电话销售系统
深圳市讯呼信息技术有限公司 呼叫中心系统 电话销售系统
Keygoe 大容量坐席和多路接入方案
根据客户系统需求,我们推荐组网方式如下: 根据客户系统需求,我们推荐组网方式如下:
1、5000线方案
。
55E1
IVR服务器 服务器 6E1 7E1
55E1
座席服务器
座席 员
PSTN
Keygoe 大容量坐席和接入方案
SMTP协议RFC文档中文版
RFC821 简单邮件传输协议(SMTP)(RFC821 SIMPLE MAIL TRANSFER PROTOCOL)目录1. 介绍 22. SMTP模型 33. SMTP过程 43.1. MAIL 43.2. 转发 53.3. 确认和扩展 63.4. 发送信件(mailing)和获得信件(sending) 7 3.5. 打开和关闭73.6. 转发 83.7. 域93.8. 改变角色94. SMTP说明94.1. SMTP命令94.1.1. 命令语法94.1.2. COMMAND语法格式134.2. SMTP响应154.3. 命令和应答序列164.4. 状态图174.5. 详细内容184.5.1. 最小实现184.5.2. 透明性194.5.3. 大小19附录 A TCP传输服务19附录 B NCP传输服务20附录 C NITS 20附录 D X.25传输服务 20附录 E 应答码构成方法20附录 F 一些例子22参考资料361. 介绍简单邮件传输协议(SMTP)的目标是可靠高效地传送邮件,它独立于传送子系统而且仅要求一条可以保证传送数据单元顺序的通道。
附录A,B,C和D描述了不同传送服务下SMTP的使用。
在名词表中还定义了本文档中使用的术语。
SMTP的一个重要特点是它能够在传送中接力传送邮件,传送服务提供了进程间通信环境(IPCE),此环境可以包括一个网络,几个网络或一个网络的子网。
理解到传送系统(或IPCE)不是一对一的是很重要的。
进程可能直接和其它进程通过已知的IPCE通信。
邮件是一个应用程序或进程间通信。
邮件可以通过连接在不同IPCE上的进程跨网络进行邮件传送。
更特别的是,邮件可以通过不同网络上的主机接力式传送。
2. SMTP模型SMTP设计基于以下通信模型:针对用户的邮件请求,发送SMTP建立与接收SMTP之间建立一个双向传送通道。
接收SMTP可以是最终接收者也可以是中间传送者。
SMTP命令由发送SMTP发出,由接收SMTP接收,而应答则反方面传送。
rfc相关设置及使用
rfc相关设置及使用RFC(Request for Comments)是一种用于定义互联网协议、标准和相关问题的文档。
RFC的格式由互联网工程任务组(IETF)统一规定,它们记录了网络技术的发展和演进过程。
在本文中,我们将介绍RFC相关的设置和使用。
1. 了解RFC的作用和历史:RFC是由IETF组织制定的一种标准化文档,它记录了互联网协议的设计、开发和演化过程。
RFC起源于20世纪60年代的ARPANET,是一种社区驱动的文档,通过共享和讨论来推动互联网技术的发展。
RFC文档旨在提供指南、建议和最佳实践,帮助网络技术人员解决问题。
2. 寻找和阅读RFC文档:RFC文档可以在互联网上免费获取,IETF的官方网站和其他资源库都有存档。
这些文档按照顺序编号,并且以RFC开头,比如RFC 791定义了IPv4协议。
通过搜索引擎或在IETF网站上使用关键词搜索,可以找到特定主题的RFC文档。
阅读RFC文档时,应该注意文档的状态,有一些可能已经被更新或废弃。
3. 使用RFC文档:RFC文档在网络技术的发展过程中起着重要的指导作用。
它们提供了协议规范、算法实现、安全性和隐私等方面的建议。
网络管理员、网络工程师和开发人员可以使用RFC文档来了解和理解特定协议或标准的设计原理和要求。
此外,RFC文档还常用于进行互联网协议的实现、编程和配置。
4. 参与RFC的制定过程:RFC并不是静止的文件,而是一个持续演进的过程。
任何人都可以参与到RFC的制定过程中。
要参与RFC的制定,可以加入IETF并参与相关的工作组或邮件列表。
通过这种方式,个人可以提出改进建议,参与讨论和标准化的制定。
5. 遵循RFC的指导原则:在网络技术领域,遵循RFC的指导原则是至关重要的。
这些指导原则包括设计原则、协议分层、安全性和互操作性等要求。
遵循RFC的指导原则可以确保网络协议的正确性、稳定性和可靠性,同时也可以促进网络技术的发展和创新。
总结起来,RFC在互联网技术领域起着重要的作用,它们记录了互联网协议的发展历程和指导原则。
rfc5531.RPC Remote Procedure Call Protocol Specification Version 2
Network Working Group R. Thurlow Request for Comments: 5531 Sun Microsystems Obsoletes: 1831 May 2009 Category: Standards TrackRPC: Remote Procedure Call Protocol Specification Version 2Status of This MemoThis document specifies an Internet standards track protocol for the Internet community, and requests discussion and suggestions forimprovements. Please refer to the current edition of the "InternetOfficial Protocol Standards" (STD 1) for the standardization stateand status of this protocol. Distribution of this memo is unlimited. Copyright NoticeCopyright (c) 2009 IETF Trust and the persons identified as thedocument authors. All rights reserved.This document is subject to BCP 78 and the IETF Trust’s LegalProvisions Relating to IETF Documents in effect on the date ofpublication of this document (/license-info). Please review these documents carefully, as they describe your rights and restrictions with respect to this document.AbstractThis document describes the Open Network Computing (ONC) RemoteProcedure Call (RPC) version 2 protocol as it is currently deployedand accepted. This document obsoletes RFC 1831.Thurlow Standards Track [Page 1]Table of Contents1. Introduction (3)1.1. Requirements Language (3)2. Changes since RFC 1831 (3)3. Terminology (3)4. The RPC Model (4)5. Transports and Semantics (5)6. Binding and Rendezvous Independence (7)7. Authentication (7)8. RPC Protocol Requirements (7)8.1. RPC Programs and Procedures (8)8.2. Authentication, Integrity, and Privacy (9)8.3. Program Number Assignment (10)8.4. Other Uses of the RPC Protocol (10)8.4.1. Batching (10)8.4.2. Broadcast Remote Procedure Calls (11)9. The RPC Message Protocol (11)10. Authentication Protocols (15)10.1. Null Authentication (15)11. Record Marking Standard (16)12. The RPC Language (16)12.1. An Example Service Described in the RPC Language (17)12.2. The RPC Language Specification (18)12.3. Syntax Notes (18)13. IANA Considerations (19)13.1. Numbering Requests to IANA (19)13.2. Protecting Past Assignments (19)13.3. RPC Number Assignment (19)13.3.1. To be assigned by IANA (20)13.3.2. Defined by Local Administrator (20)13.3.3. Transient Block (20)13.3.4. Reserved Block (21)13.3.5. RPC Number Sub-Blocks (21)13.4. RPC Authentication Flavor Number Assignment (22)13.4.1. Assignment Policy (22)13.4.2. Auth Flavors vs. Pseudo-Flavors (23)13.5. Authentication Status Number Assignment (23)13.5.1. Assignment Policy (23)14. Security Considerations (24)Appendix A: System Authentication (25)Appendix B: Requesting RPC-Related Numbers from IANA (26)Appendix C: Current Number Assignments (27)Normative References (62)Informative References (62)Thurlow Standards Track [Page 2]1. IntroductionThis document specifies version 2 of the message protocol used in ONC Remote Procedure Call (RPC). The message protocol is specified with the eXternal Data Representation (XDR) language [RFC4506]. Thisdocument assumes that the reader is familiar with XDR. It does notattempt to justify remote procedure call systems or describe theiruse. The paper by Birrell and Nelson [XRPC] is recommended as anexcellent background for the remote procedure call concept.1.1. Requirements LanguageThe key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT","SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this document are to be interpreted as described in [RFC2119].2. Changes since RFC 1831This document obsoletes [RFC1831] as the authoritative documentdescribing RPC, without introducing any over-the-wire protocolchanges. The main changes from RFC 1831 are:o Addition of an Appendix that describes how an implementor canrequest new RPC program numbers, authentication flavor numbers,and authentication status numbers from IANA, rather than from Sun Microsystemso Addition of an "IANA Considerations" section that describes pastnumber assignment policy and how IANA is intended to assign themin the futureo Clarification of the RPC Language Specification to match currentusageo Enhancement of the "Security Considerations" section to reflectexperience with strong security flavorso Specification of new authentication errors that are in common use in modern RPC implementationso Updates for the latest IETF intellectual property statements3. TerminologyThis document discusses clients, calls, servers, replies, services,programs, procedures, and versions. Each remote procedure call hastwo sides: an active client side that makes the call to a serverside, which sends back a reply. A network service is a collection of Thurlow Standards Track [Page 3]one or more remote programs. A remote program implements one or more remote procedures; the procedures, their parameters, and results are documented in the specific program’s protocol specification. Aserver may support more than one version of a remote program in order to be compatible with changing protocols.For example, a network file service may be composed of two programs. One program may deal with high-level applications such as file system access control and locking. The other may deal with low-level fileinput and output and have procedures like "read" and "write". Aclient of the network file service would call the proceduresassociated with the two programs of the service on behalf of theclient.The terms "client" and "server" only apply to a particulartransaction; a particular hardware entity (host) or software entity(process or program) could operate in both roles at different times. For example, a program that supplies remote execution service couldalso be a client of a network file service.4. The RPC ModelThe ONC RPC protocol is based on the remote procedure call model,which is similar to the local procedure call model. In the localcase, the caller places arguments to a procedure in some well-specified location (such as a register window). It then transferscontrol to the procedure, and eventually regains control. At thatpoint, the results of the procedure are extracted from the well-specified location, and the caller continues execution.The remote procedure call model is similar. One thread of controllogically winds through two processes: the caller’s process and aserver’s process. The caller first sends a call message to theserver process and waits (blocks) for a reply message. The callmessage includes the procedure’s parameters, and the reply messageincludes the procedure’s results. Once the reply message isreceived, the results of the procedure are extracted, and thecaller’s execution is resumed.On the server side, a process is dormant awaiting the arrival of acall message. When one arrives, the server process extracts theprocedure’s parameters, computes the results, sends a reply message, and then awaits the next call message.In this model, only one of the two processes is active at any giventime. However, this model is only given as an example. The ONC RPC protocol makes no restrictions on the concurrency model implemented, and others are possible. For example, an implementation may choose Thurlow Standards Track [Page 4]to have RPC calls be asynchronous so that the client may do usefulwork while waiting for the reply from the server. Anotherpossibility is to have the server create a separate task to processan incoming call so that the original server can be free to receiveother requests.There are a few important ways in which remote procedure calls differ from local procedure calls.o Error handling: failures of the remote server or network must behandled when using remote procedure calls.o Global variables and side effects: since the server does not have access to the client’s address space, hidden arguments cannot bepassed as global variables or returned as side effects.o Performance: remote procedures usually operate at one or moreorders of magnitude slower than local procedure calls.o Authentication: since remote procedure calls can be transportedover unsecured networks, authentication may be necessary.Authentication prevents one entity from masquerading as some other entity.The conclusion is that even though there are tools to automaticallygenerate client and server libraries for a given service, protocolsmust still be designed carefully.5. Transports and SemanticsThe RPC protocol can be implemented on several different transportprotocols. The scope of the definition of the RPC protocol excludes how a message is passed from one process to another, and includesonly the specification and interpretation of messages. However, the application may wish to obtain information about (and perhaps control over) the transport layer through an interface not specified in this document. For example, the transport protocol may impose arestriction on the maximum size of RPC messages, or it may bestream-oriented like TCP [RFC0793] with no size limit. The clientand server must agree on their transport protocol choices.It is important to point out that RPC does not try to implement anykind of reliability and that the application may need to be aware of the type of transport protocol underneath RPC. If it knows it isrunning on top of a reliable transport such as TCP, then most of the work is already done for it. On the other hand, if it is running on Thurlow Standards Track [Page 5]top of an unreliable transport such as UDP [RFC0768], it mustimplement its own time-out, retransmission, and duplicate detectionpolicies as the RPC protocol does not provide these services.Because of transport independence, the RPC protocol does not attachspecific semantics to the remote procedures or their executionrequirements. Semantics can be inferred from (but should beexplicitly specified by) the underlying transport protocol. Forexample, consider RPC running on top of an unreliable transport such as UDP. If an application retransmits RPC call messages after time- outs, and does not receive a reply, it cannot infer anything aboutthe number of times the procedure was executed. If it does receive a reply, then it can infer that the procedure was executed at leastonce.A server may wish to remember previously granted requests from aclient and not regrant them, in order to insure some degree ofexecute-at-most-once semantics. A server can do this by takingadvantage of the transaction ID that is packaged with every RPCmessage. The main use of this transaction ID is by the client RPCentity in matching replies to calls. However, a client applicationmay choose to reuse its previous transaction ID when retransmitting a call. The server may choose to remember this ID after executing acall and not execute calls with the same ID, in order to achieve some degree of execute-at-most-once semantics. The server is not allowed to examine this ID in any other way except as a test for equality.On the other hand, if using a "reliable" transport such as TCP, theapplication can infer from a reply message that the procedure wasexecuted exactly once, but if it receives no reply message, it cannot assume that the remote procedure was not executed. Note that even if a connection-oriented protocol like TCP is used, an application still needs time-outs and reconnections to handle server crashes.There are other possibilities for transports besides datagram- orconnection-oriented protocols. For example, a request-reply protocol such as [VMTP] is perhaps a natural transport for RPC. ONC RPCcurrently uses both TCP and UDP transport protocols. Section 11("Record Marking Standard") describes the mechanism employed by ONCRPC to utilize a connection-oriented, stream-oriented transport such as TCP. The mechanism by which future transports having differentstructural characteristics should be used to transfer ONC RPCmessages should be specified by means of a Standards Track RFC, once such additional transports are defined.Thurlow Standards Track [Page 6]6. Binding and Rendezvous IndependenceThe act of binding a particular client to a particular service andtransport parameters is NOT part of this RPC protocol specification. This important and necessary function is left up to some higher-level software.Implementors could think of the RPC protocol as the jump-subroutineinstruction (JSR) of a network; the loader (binder) makes JSR useful, and the loader itself uses JSR to accomplish its task. Likewise, the binding software makes RPC useful, possibly using RPC to accomplishthis task.7. AuthenticationThe RPC protocol provides the fields necessary for a client toidentify itself to a service, and vice-versa, in each call and reply message. Security and access control mechanisms can be built on top of this message authentication. Several different authenticationprotocols can be supported. A field in the RPC header indicateswhich protocol is being used. More information on specificauthentication protocols is in Section 8.2, "Authentication,Integrity and Privacy".8. RPC Protocol RequirementsThe RPC protocol must provide for the following:o Unique specification of a procedure to be calledo Provisions for matching response messages to request messageso Provisions for authenticating the caller to service and vice-versa Besides these requirements, features that detect the following areworth supporting because of protocol roll-over errors, implementation bugs, user error, and network administration:o RPC protocol mismatcheso Remote program protocol version mismatcheso Protocol errors (such as misspecification of a procedure’sparameters)o Reasons why remote authentication failedo Any other reasons why the desired procedure was not calledThurlow Standards Track [Page 7]8.1. RPC Programs and ProceduresThe RPC call message has three unsigned-integer fields -- remoteprogram number, remote program version number, and remote procedurenumber -- that uniquely identify the procedure to be called. Program numbers are administered by a central authority (IANA). Onceimplementors have a program number, they can implement their remoteprogram; the first implementation would most likely have the version number 1 but MUST NOT be the number zero. Because most new protocols evolve, a "version" field of the call message identifies whichversion of the protocol the caller is using. Version numbers enable support of both old and new protocols through the same serverprocess.The procedure number identifies the procedure to be called. Thesenumbers are documented in the specific program’s protocolspecification. For example, a file service’s protocol specification may state that its procedure number 5 is "read" and procedure number 12 is "write".Just as remote program protocols may change over several versions,the actual RPC message protocol could also change. Therefore, thecall message also has in it the RPC version number, which is alwaysequal to 2 for the version of RPC described here.The reply message to a request message has enough information todistinguish the following error conditions:o The remote implementation of RPC does not support protocol version 2. The lowest and highest supported RPC version numbers arereturned.o The remote program is not available on the remote system.o The remote program does not support the requested version number. The lowest and highest supported remote program version numbersare returned.o The requested procedure number does not exist. (This is usually a client-side protocol or programming error.)o The parameters to the remote procedure appear to be garbage fromthe server’s point of view. (Again, this is usually caused by adisagreement about the protocol between client and service.) Thurlow Standards Track [Page 8]8.2. Authentication, Integrity, and PrivacyProvisions for authentication of caller to service and vice-versa are provided as a part of the RPC protocol. The call message has twoauthentication fields: the credential and the verifier. The replymessage has one authentication field: the response verifier. The RPC protocol specification defines all three fields to be the followingopaque type (in the eXternal Data Representation (XDR) language[RFC4506]):enum auth_flavor {AUTH_NONE = 0,AUTH_SYS = 1,AUTH_SHORT = 2,AUTH_DH = 3,RPCSEC_GSS = 6/* and more to be defined */};struct opaque_auth {auth_flavor flavor;opaque body<400>;};In other words, any "opaque_auth" structure is an "auth_flavor"enumeration followed by up to 400 bytes that are opaque to(uninterpreted by) the RPC protocol implementation.The interpretation and semantics of the data contained within theauthentication fields are specified by individual, independentauthentication protocol specifications.If authentication parameters were rejected, the reply messagecontains information stating why they were rejected.As demonstrated by RPCSEC_GSS, it is possible for an "auth_flavor" to also support integrity and privacy.Thurlow Standards Track [Page 9]8.3. Program Number AssignmentProgram numbers are given out in groups according to the followingchart:0x00000000 Reserved0x00000001 - 0x1fffffff To be assigned by IANA0x20000000 - 0x3fffffff Defined by local administrator(some blocks assigned here)0x40000000 - 0x5fffffff Transient0x60000000 - 0x7effffff Reserved0x7f000000 - 0x7fffffff Assignment outstanding0x80000000 - 0xffffffff ReservedThe first group is a range of numbers administered by IANA and should be identical for all sites. The second range is for applicationspeculiar to a particular site. This range is intended primarily for debugging new programs. When a site develops an application thatmight be of general interest, that application should be given anassigned number in the first range. Application developers may apply for blocks of RPC program numbers in the first range by methodsdescribed in Appendix B. The third group is for applications thatgenerate program numbers dynamically. The final groups are reserved for future use, and should not be used.8.4. Other Uses of the RPC ProtocolThe intended use of this protocol is for calling remote procedures.Normally, each call message is matched with a reply message.However, the protocol itself is a message-passing protocol with which other (non-procedure-call) protocols can be implemented.8.4.1. BatchingBatching is useful when a client wishes to send an arbitrarily large sequence of call messages to a server. Batching typically usesreliable byte stream protocols (like TCP) for its transport. In the case of batching, the client never waits for a reply from the server, and the server does not send replies to batch calls. A sequence ofbatch calls is usually terminated by a legitimate remote procedurecall operation in order to flush the pipeline and get positiveacknowledgement.Thurlow Standards Track [Page 10]8.4.2. Broadcast Remote Procedure CallsIn broadcast protocols, the client sends a broadcast call to thenetwork and waits for numerous replies. This requires the use ofpacket-based protocols (like UDP) as its transport protocol. Servers that support broadcast protocols usually respond only when the callis successfully processed and are silent in the face of errors, butthis varies with the application.The principles of broadcast RPC also apply to multicasting -- an RPC request can be sent to a multicast address.9. The RPC Message ProtocolThis section defines the RPC message protocol in the XDR datadescription language [RFC4506].enum msg_type {CALL = 0,REPLY = 1};A reply to a call message can take on two forms: the message waseither accepted or rejected.enum reply_stat {MSG_ACCEPTED = 0,MSG_DENIED = 1};Given that a call message was accepted, the following is the statusof an attempt to call a remote procedure.enum accept_stat {SUCCESS = 0, /* RPC executed successfully */PROG_UNAVAIL = 1, /* remote hasn’t exported program */PROG_MISMATCH = 2, /* remote can’t support version # */PROC_UNAVAIL = 3, /* program can’t support procedure */GARBAGE_ARGS = 4, /* procedure can’t decode params */SYSTEM_ERR = 5 /* e.g. memory allocation failure */};Reasons why a call message was rejected:enum reject_stat {RPC_MISMATCH = 0, /* RPC version number != 2 */AUTH_ERROR = 1 /* remote can’t authenticate caller */};Thurlow Standards Track [Page 11]Why authentication failed:enum auth_stat {AUTH_OK = 0, /* success *//** failed at remote end*/AUTH_BADCRED = 1, /* bad credential (seal broken) */AUTH_REJECTEDCRED = 2, /* client must begin new session */AUTH_BADVERF = 3, /* bad verifier (seal broken) */AUTH_REJECTEDVERF = 4, /* verifier expired or replayed */AUTH_TOOWEAK = 5, /* rejected for security reasons *//** failed locally*/AUTH_INVALIDRESP = 6, /* bogus response verifier */AUTH_FAILED = 7, /* reason unknown *//** AUTH_KERB errors; deprecated. See [RFC2695]*/AUTH_KERB_GENERIC = 8, /* kerberos generic error */AUTH_TIMEEXPIRE = 9, /* time of credential expired */AUTH_TKT_FILE = 10, /* problem with ticket file */AUTH_DECODE = 11, /* can’t decode authenticator */AUTH_NET_ADDR = 12, /* wrong net address in ticket *//** RPCSEC_GSS GSS related errors*/RPCSEC_GSS_CREDPROBLEM = 13, /* no credentials for user */RPCSEC_GSS_CTXPROBLEM = 14 /* problem with context */};As new authentication mechanisms are added, there may be a need formore status codes to support them. IANA will hand out new auth_stat numbers on a simple First Come First Served basis as defined in the"IANA Considerations" and Appendix B.The RPC message:All messages start with a transaction identifier, xid, followed by a two-armed discriminated union. The union’s discriminant is amsg_type that switches to one of the two types of the message. Thexid of a REPLY message always matches that of the initiating CALLmessage. NB: The "xid" field is only used for clients matching reply messages with call messages or for servers detecting retransmissions; the service side cannot treat this id as any type of sequence number. Thurlow Standards Track [Page 12]struct rpc_msg {unsigned int xid;union switch (msg_type mtype) {case CALL:call_body cbody;case REPLY:reply_body rbody;} body;};Body of an RPC call:In version 2 of the RPC protocol specification, rpcvers MUST be equal to 2. The fields "prog", "vers", and "proc" specify the remoteprogram, its version number, and the procedure within the remoteprogram to be called. After these fields are two authenticationparameters: cred (authentication credential) and verf (authentication verifier). The two authentication parameters are followed by theparameters to the remote procedure, which are specified by thespecific program protocol.The purpose of the authentication verifier is to validate theauthentication credential. Note that these two items arehistorically separate, but are always used together as one logicalentity.struct call_body {unsigned int rpcvers; /* must be equal to two (2) */unsigned int prog;unsigned int vers;unsigned int proc;opaque_auth cred;opaque_auth verf;/* procedure-specific parameters start here */};Body of a reply to an RPC call:union reply_body switch (reply_stat stat) {case MSG_ACCEPTED:accepted_reply areply;case MSG_DENIED:rejected_reply rreply;} reply;Thurlow Standards Track [Page 13]Reply to an RPC call that was accepted by the server:There could be an error even though the call was accepted. The first field is an authentication verifier that the server generates inorder to validate itself to the client. It is followed by a unionwhose discriminant is an enum accept_stat. The SUCCESS arm of theunion is protocol-specific. The PROG_UNAVAIL, PROC_UNAVAIL,GARBAGE_ARGS, and SYSTEM_ERR arms of the union are void. ThePROG_MISMATCH arm specifies the lowest and highest version numbers of the remote program supported by the server.struct accepted_reply {opaque_auth verf;union switch (accept_stat stat) {case SUCCESS:opaque results[0];/** procedure-specific results start here*/case PROG_MISMATCH:struct {unsigned int low;unsigned int high;} mismatch_info;default:/** Void. Cases include PROG_UNAVAIL, PROC_UNAVAIL,* GARBAGE_ARGS, and SYSTEM_ERR.*/void;} reply_data;};Reply to an RPC call that was rejected by the server:The call can be rejected for two reasons: either the server is notrunning a compatible version of the RPC protocol (RPC_MISMATCH) orthe server rejects the identity of the caller (AUTH_ERROR). In case of an RPC version mismatch, the server returns the lowest and highest supported RPC version numbers. In case of invalid authentication,failure status is returned.Thurlow Standards Track [Page 14]union rejected_reply switch (reject_stat stat) {case RPC_MISMATCH:struct {unsigned int low;unsigned int high;} mismatch_info;case AUTH_ERROR:auth_stat stat;};10. Authentication ProtocolsAs previously stated, authentication parameters are opaque, butopen-ended to the rest of the RPC protocol. This section defines two standard flavors of authentication. Implementors are free to invent new authentication types, with the same rules of flavor numberassignment as there are for program number assignment. The flavor of a credential or verifier refers to the value of the "flavor" field in the opaque_auth structure. Flavor numbers, like RPC program numbers, are also administered centrally, and developers may assign new flavor numbers by methods described in Appendix B. Credentials andverifiers are represented as variable-length opaque data (the "body" field in the opaque_auth structure).In this document, two flavors of authentication are described. Ofthese, Null authentication (described in the next subsection) ismandatory -- it MUST be available in all implementations. Systemauthentication (AUTH_SYS) is described in Appendix A. ImplementorsMAY include AUTH_SYS in their implementations to support existingapplications. See "Security Considerations" for information aboutother, more secure, authentication flavors.10.1. Null AuthenticationOften, calls must be made where the client does not care about itsidentity or the server does not care who the client is. In thiscase, the flavor of the RPC message’s credential, verifier, and reply verifier is "AUTH_NONE". Opaque data associated with "AUTH_NONE" is undefined. It is recommended that the length of the opaque data bezero.Thurlow Standards Track [Page 15]。
基于 rfc 定义的 分类
RFC(Request for Comments)是一系列以编号形式发布的互联网标准草案,由互联网工程任务组(IETF)发布和管理。
基于RFC定义,我们可以将RFC文档分为以下几类:标准轨道RFC(Standards Track RFC):这类RFC定义了互联网的标准协议,经过严格的审查和测试,被认为是成熟、稳定和广泛接受的标准。
它们被分为不同的成熟度级别,如提议标准(Proposed Standard)、草案标准(Draft Standard)和互联网标准 Internet Standard)。
实验性RFC Experimental RFC):这类RFC描述了一些新的、实验性的协议、技术或想法,它们可能还未经过广泛的实际测试和部署。
实验性RFC提供了一种探索和尝试新想法的方式,但并不保证它们最终会成为标准。
信息性RFC(Informational RFC):这类RFC提供了一些有用的信息,如最佳实践、建议、指南或描述性的文档。
它们并不定义互联网标准,而是提供了一些与互联网相关的有用信息。
历史性RFC Historic RFC):这类RFC记录了已经被取代或废弃的协议、技术或想法。
它们被保留下来主要是为了历史记录和参考,而不是作为当前的标准或实践。
BCP(Best Current Practice)RFC:这类RFC描述了一些被广泛接受的最佳实践或指南,它们通常与互联网操作、管理和安全相关。
BCP RFC提供了一些建议和指导,以帮助网络管理员和工程师更好地运营和管理他们的网络。
需要注意的是,RFC文档的分类并不是绝对的,有些RFC可能同时属于多个分类。
此外,RFC文档也可以被更新、修订或废弃,因此分类也可能随着时间而变化。
1。
网络安全的参考文献
网络安全的参考文献抱歉,由于我是一个语言模型,我不能直接提供或引用参考文献的正文。
然而,以下是一些关于网络安全的常见参考文献和出版物,你可以自行查找相关资料:1. Anderson, R. (2001). Security Engineering: A Guide to Building Dependable Distributed Systems.2. Pfleeger, C. P., & Pfleeger, S. L. (2015). Security in Computing (5th ed.).3. Schneier, B. (2012). Liars and Outliers: Enabling the Trust That Society Needs to Thrive.4. Shostack, A. (2014). Threat Modeling: Designing for Security.5. Bishop, M. (2003). Computer Security: Art and Science.6. Whitman, M. E., & Mattord, H. J. (2011). Principles of Information Security (4th ed.).7. NIST Special Publication 800-53: Security and Privacy Controls for Federal Information Systems and Organizations.8. ISO/IEC 27001: Information Security Management Systems - Requirements.9. RFC 3552: Guidelines for Writing RFC Text on Security Considerations.10. Symantec Internet Security Threat Report (Annual publication).这些文献和出版物涵盖了各个方面的网络安全,包括基本原理、系统设计、威胁建模、控制措施、安全管理和行业报告等。
rfc3551
Network Working Group H. Schulzrinne Request for Comments: 3551 Columbia University Obsoletes: 1890 S. Casner Category: Standards Track Packet DesignJuly 2003RTP Profile for Audio and Video Conferenceswith Minimal ControlStatus of this MemoThis document specifies an Internet standards track protocol for theInternet community, and requests discussion and suggestions forimprovements. Please refer to the current edition of the "InternetOfficial Protocol Standards" (STD 1) for the standardization stateand status of this protocol. Distribution of this memo is unlimited.Network Communication Protocol Map. To order: /map.html Easy to use sniffing tool: /packet.htmlCopyright Notice Copyright (C) The Internet Society (2003). All Rights Reserved.AbstractThis document describes a profile called "RTP/AVP" for the use of thereal-time transport protocol (RTP), version 2, and the associatedcontrol protocol, RTCP, within audio and video multiparticipantconferences with minimal control. It provides interpretations ofgeneric fields within the RTP specification suitable for audio andvideo conferences. In particular, this document defines a set ofdefault mappings from payload type numbers to encodings.This document also describes how audio and video data may be carriedwithin RTP. It defines a set of standard encodings and their nameswhen used within RTP. The descriptions provide pointers to referenceimplementations and the detailed standards. This document is meantas an aid for implementors of audio, video and other real-timemultimedia applications.This memorandum obsoletes RFC 1890. It is mostly backwards-compatible except for functions removed because two interoperableimplementations were not found. The additions to RFC 1890 codifyexisting practice in the use of payload formats under this profileand include new payload formats defined since RFC 1890 was published.Table of Contents1. Introduction (3)1.1 Terminology (3)2. RTP and RTCP Packet Forms and Protocol Behavior (4)3. Registering Additional Encodings (6)4. Audio (8)4.1 Encoding-Independent Rules (8)4.2 Operating Recommendations (9)4.3 Guidelines for Sample-Based Audio Encodings (10)4.4 Guidelines for Frame-Based Audio Encodings (11)4.5 Audio Encodings (12)4.5.1 DVI4 (13)4.5.2 G722 (14)4.5.3 G723 (14)4.5.4 G726-40, G726-32, G726-24, and G726-16 (18)4.5.5 G728 (19)4.5.6 G729 (20)4.5.7 G729D and G729E (22)4.5.8 GSM (24)4.5.9 GSM-EFR (27)4.5.10 L8 (27)4.5.11 L16 (27)4.5.12 LPC (27)4.5.13 MPA (28)4.5.14 PCMA and PCMU (28)4.5.15 QCELP (28)4.5.16 RED (29)4.5.17 VDVI (29)5. Video (30)5.1 CelB (30)5.2 JPEG (30)5.3 H261 (30)5.4 H263 (31)5.5 H263-1998 (31)5.6 MPV (31)5.7 MP2T (31)5.8 nv (32)6. Payload Type Definitions (32)7. RTP over TCP and Similar Byte Stream Protocols (34)8. Port Assignment (34)9. Changes from RFC 1890 (35)10. Security Considerations (38)11. IANA Considerations (39)12. References (39)12.1 Normative References (39)12.2 Informative References (39)13. Current Locations of Related Resources (41)14. Acknowledgments (42)15. Intellectual Property Rights Statement (43)16. Authors' Addresses (43)17. Full Copyright Statement (44)1. IntroductionThis profile defines aspects of RTP left unspecified in the RTPVersion 2 protocol definition (RFC 3550) [1]. This profile isintended for the use within audio and video conferences with minimal session control. In particular, no support for the negotiation ofparameters or membership control is provided. The profile isexpected to be useful in sessions where no negotiation or membership control are used (e.g., using the static payload types and themembership indications provided by RTCP), but this profile may also be useful in conjunction with a higher-level control protocol.Use of this profile may be implicit in the use of the appropriateapplications; there may be no explicit indication by port number,protocol identifier or the like. Applications such as sessiondirectories may use the name for this profile specified in Section11.Other profiles may make different choices for the items specifiedhere.This document also defines a set of encodings and payload formats for audio and video. These payload format descriptions are included here only as a matter of convenience since they are too small to warrant separate documents. Use of these payload formats is NOT REQUIRED to use this profile. Only the binding of some of the payload formats to static payload type numbers in Tables 4 and 5 is normative.1.1 TerminologyThe key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", "SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this document are to be interpreted as described in RFC 2119 [2] andindicate requirement levels for implementations compliant with this RTP profile.This document defines the term media type as dividing encodings ofaudio and video content into three classes: audio, video andaudio/video (interleaved).2. RTP and RTCP Packet Forms and Protocol BehaviorThe section "RTP Profiles and Payload Format Specifications" of RFC 3550 enumerates a number of items that can be specified or modified in a profile. This section addresses these items. Generally, this profile follows the default and/or recommended aspects of the RTPspecification.RTP data header: The standard format of the fixed RTP dataheader is used (one marker bit).Payload types: Static payload types are defined in Section 6.RTP data header additions: No additional fixed fields areappended to the RTP data header.RTP data header extensions: No RTP header extensions aredefined, but applications operating under this profile MAY usesuch extensions. Thus, applications SHOULD NOT assume that theRTP header X bit is always zero and SHOULD be prepared to ignore the header extension. If a header extension is defined in thefuture, that definition MUST specify the contents of the first 16 bits in such a way that multiple different extensions can beidentified.RTCP packet types: No additional RTCP packet types are definedby this profile specification.RTCP report interval: The suggested constants are to be used forthe RTCP report interval calculation. Sessions operating underthis profile MAY specify a separate parameter for the RTCP traffic bandwidth rather than using the default fraction of the sessionbandwidth. The RTCP traffic bandwidth MAY be divided into twoseparate session parameters for those participants which areactive data senders and those which are not. Following therecommendation in the RTP specification [1] that 1/4 of the RTCP bandwidth be dedicated to data senders, the RECOMMENDED defaultvalues for these two parameters would be 1.25% and 3.75%,respectively. For a particular session, the RTCP bandwidth fornon-data-senders MAY be set to zero when operating onunidirectional links or for sessions that don't require feedback on the quality of reception. The RTCP bandwidth for data senders SHOULD be kept non-zero so that sender reports can still be sent for inter-media synchronization and to identify the source byCNAME. The means by which the one or two session parameters for RTCP bandwidth are specified is beyond the scope of this memo.SR/RR extension: No extension section is defined for the RTCP SRor RR packet.SDES use: Applications MAY use any of the SDES items describedin the RTP specification. While CNAME information MUST be sentevery reporting interval, other items SHOULD only be sent everythird reporting interval, with NAME sent seven out of eight times within that slot and the remaining SDES items cyclically taking up the eighth slot, as defined in Section 6.2.2 of the RTPspecification. In other words, NAME is sent in RTCP packets 1, 4, 7, 10, 13, 16, 19, while, say, EMAIL is used in RTCP packet 22.Security: The RTP default security services are also the defaultunder this profile.String-to-key mapping: No mapping is specified by this profile.Congestion: RTP and this profile may be used in the context ofenhanced network service, for example, through Integrated Services (RFC 1633) [4] or Differentiated Services (RFC 2475) [5], or they may be used with best effort service.If enhanced service is being used, RTP receivers SHOULD monitorpacket loss to ensure that the service that was requested isactually being delivered. If it is not, then they SHOULD assume that they are receiving best-effort service and behaveaccordingly.If best-effort service is being used, RTP receivers SHOULD monitor packet loss to ensure that the packet loss rate is withinacceptable parameters. Packet loss is considered acceptable if a TCP flow across the same network path and experiencing the samenetwork conditions would achieve an average throughput, measured on a reasonable timescale, that is not less than the RTP flow is achieving. This condition can be satisfied by implementingcongestion control mechanisms to adapt the transmission rate (or the number of layers subscribed for a layered multicast session), or by arranging for a receiver to leave the session if the lossrate is unacceptably high.The comparison to TCP cannot be specified exactly, but is intended as an "order-of-magnitude" comparison in timescale and throughput. The timescale on which TCP throughput is measured is the round-trip time of the connection. In essence, this requirement states that it is not acceptable to deploy an application (using RTP or any other transport protocol) on the best-effort Internet whichconsumes bandwidth arbitrarily and does not compete fairly withTCP within an order of magnitude.Underlying protocol: The profile specifies the use of RTP overunicast and multicast UDP as well as TCP. (This does not preclude the use of these definitions when RTP is carried by other lower- layer protocols.)Transport mapping: The standard mapping of RTP and RTCP totransport-level addresses is used.Encapsulation: This profile leaves to applications thespecification of RTP encapsulation in protocols other than UDP.3. Registering Additional EncodingsThis profile lists a set of encodings, each of which is comprised of a particular media data compression or representation plus a payload format for encapsulation within RTP. Some of those payload formats are specified here, while others are specified in separate RFCs. It is expected that additional encodings beyond the set listed here will be created in the future and specified in additional payload format RFCs.This profile also assigns to each encoding a short name which MAY be used by higher-level control protocols, such as the SessionDescription Protocol (SDP), RFC 2327 [6], to identify encodingsselected for a particular RTP session.In some contexts it may be useful to refer to these encodings in the form of a MIME content-type. To facilitate this, RFC 3555 [7]provides registrations for all of the encodings names listed here as MIME subtype names under the "audio" and "video" MIME types through the MIME registration procedure as specified in RFC 2048 [8].Any additional encodings specified for use under this profile (orothers) may also be assigned names registered as MIME subtypes with the Internet Assigned Numbers Authority (IANA). This registryprovides a means to insure that the names assigned to the additional encodings are kept unique. RFC 3555 specifies the information that is required for the registration of RTP encodings.In addition to assigning names to encodings, this profile alsoassigns static RTP payload type numbers to some of them. However,the payload type number space is relatively small and cannotaccommodate assignments for all existing and future encodings.During the early stages of RTP development, it was necessary to use statically assigned payload types because no other mechanism had been specified to bind encodings to payload types. It was anticipatedthat non-RTP means beyond the scope of this memo (such as directory services or invitation protocols) would be specified to establish adynamic mapping between a payload type and an encoding. Now,mechanisms for defining dynamic payload type bindings have beenspecified in the Session Description Protocol (SDP) and in otherprotocols such as ITU-T Recommendation H.323/H.245. These mechanisms associate the registered name of the encoding/payload format, along with any additional required parameters, such as the RTP timestampclock rate and number of channels, with a payload type number. This association is effective only for the duration of the RTP session in which the dynamic payload type binding is made. This associationapplies only to the RTP session for which it is made, thus thenumbers can be re-used for different encodings in different sessions so the number space limitation is avoided.This profile reserves payload type numbers in the range 96-127exclusively for dynamic assignment. Applications SHOULD first usevalues in this range for dynamic payload types. Those applications which need to define more than 32 dynamic payload types MAY bindcodes below 96, in which case it is RECOMMENDED that unassignedpayload type numbers be used first. However, the statically assigned payload types are default bindings and MAY be dynamically bound tonew encodings if needed. Redefining payload types below 96 may cause incorrect operation if an attempt is made to join a session without obtaining session description information that defines the dynamicpayload types.Dynamic payload types SHOULD NOT be used without a well-definedmechanism to indicate the mapping. Systems that expect tointeroperate with others operating under this profile SHOULD NOT make their own assignments of proprietary encodings to particular, fixed payload types.This specification establishes the policy that no additional static payload types will be assigned beyond the ones defined in thisdocument. Establishing this policy avoids the problem of trying to create a set of criteria for accepting static assignments andencourages the implementation and deployment of the dynamic payload type mechanisms.The final set of static payload type assignments is provided inTables 4 and 5.4. Audio4.1 Encoding-Independent RulesSince the ability to suppress silence is one of the primarymotivations for using packets to transmit voice, the RTP headercarries both a sequence number and a timestamp to allow a receiver to distinguish between lost packets and periods of time when no data was transmitted. Discontiguous transmission (silence suppression) MAY be used with any audio payload format. Receivers MUST assume thatsenders may suppress silence unless this is restricted by signaling specified elsewhere. (Even if the transmitter does not suppresssilence, the receiver should be prepared to handle periods when nodata is present since packets may be lost.)Some payload formats (see Sections 4.5.3 and 4.5.6) define a "silence insertion descriptor" or "comfort noise" frame to specify parameters for artificial noise that may be generated during a period of silence to approximate the background noise at the source. For other payload formats, a generic Comfort Noise (CN) payload format is specified in RFC 3389 [9]. When the CN payload format is used with anotherpayload format, different values in the RTP payload type fielddistinguish comfort-noise packets from those of the selected payload format.For applications which send either no packets or occasional comfort- noise packets during silence, the first packet of a talkspurt, that is, the first packet after a silence period during which packets have not been transmitted contiguously, SHOULD be distinguished by setting the marker bit in the RTP data header to one. The marker bit in all other packets is zero. The beginning of a talkspurt MAY be used to adjust the playout delay to reflect changing network delays.Applications without silence suppression MUST set the marker bit to zero.The RTP clock rate used for generating the RTP timestamp isindependent of the number of channels and the encoding; it usuallyequals the number of sampling periods per second. For N-channelencodings, each sampling period (say, 1/8,000 of a second) generates N samples. (This terminology is standard, but somewhat confusing, as the total number of samples generated per second is then the sampling rate times the channel count.)If multiple audio channels are used, channels are numbered left-to- right, starting at one. In RTP audio packets, information fromlower-numbered channels precedes that from higher-numbered channels.For more than two channels, the convention followed by the AIFF-Caudio interchange format SHOULD be followed [3], using the following notation, unless some other convention is specified for a particular encoding or payload format:l leftr rightc centerS surroundF frontR rearchannels description channel1 2 3 4 5 6_________________________________________________2 stereo l r3 l r c4 l c r S5 Fl Fr Fc Sl Sr6 l lc c r rc SNote: RFC 1890 defined two conventions for the ordering of four audio channels. Since the ordering is indicated implicitly by the number of channels, this was ambiguous. In this revision, the order described as "quadrophonic" has been eliminated toremove the ambiguity. This choice was based on the observation that quadrophonic consumer audio format did not become popular whereas surround-sound subsequently has.Samples for all channels belonging to a single sampling instant MUST be within the same packet. The interleaving of samples fromdifferent channels depends on the encoding. General guidelines are given in Section 4.3 and 4.4.The sampling frequency SHOULD be drawn from the set: 8,000, 11,025, 16,000, 22,050, 24,000, 32,000, 44,100 and 48,000 Hz. (Older Apple Macintosh computers had a native sample rate of 22,254.54 Hz, which can be converted to 22,050 with acceptable quality by dropping 4samples in a 20 ms frame.) However, most audio encodings are defined for a more restricted set of sampling frequencies. Receivers SHOULD be prepared to accept multi-channel audio, but MAY choose to onlyplay a single channel.4.2 Operating RecommendationsThe following recommendations are default operating parameters.Applications SHOULD be prepared to handle other values. The ranges given are meant to give guidance to application writers, allowing aset of applications conforming to these guidelines to interoperatewithout additional negotiation. These guidelines are not intended to restrict operating parameters for applications that can negotiate a set of interoperable parameters, e.g., through a conference control protocol.For packetized audio, the default packetization interval SHOULD have a duration of 20 ms or one frame, whichever is longer, unlessotherwise noted in Table 1 (column "ms/packet"). The packetization interval determines the minimum end-to-end delay; longer packetsintroduce less header overhead but higher delay and make packet loss more noticeable. For non-interactive applications such as lectures or for links with severe bandwidth constraints, a higherpacketization delay MAY be used. A receiver SHOULD accept packetsrepresenting between 0 and 200 ms of audio data. (For framed audio encodings, a receiver SHOULD accept packets with a number of frames equal to 200 ms divided by the frame duration, rounded up.) Thisrestriction allows reasonable buffer sizing for the receiver.4.3 Guidelines for Sample-Based Audio EncodingsIn sample-based encodings, each audio sample is represented by afixed number of bits. Within the compressed audio data, codes forindividual samples may span octet boundaries. An RTP audio packetmay contain any number of audio samples, subject to the constraintthat the number of bits per sample times the number of samples perpacket yields an integral octet count. Fractional encodings produce less than one octet per sample.The duration of an audio packet is determined by the number ofsamples in the packet.For sample-based encodings producing one or more octets per sample, samples from different channels sampled at the same sampling instant SHOULD be packed in consecutive octets. For example, for a two-channel encoding, the octet sequence is (left channel, first sample), (right channel, first sample), (left channel, second sample), (right channel, second sample), .... For multi-octet encodings, octetsSHOULD be transmitted in network byte order (i.e., most significant octet first).The packing of sample-based encodings producing less than one octet per sample is encoding-specific.The RTP timestamp reflects the instant at which the first sample in the packet was sampled, that is, the oldest information in thepacket.4.4 Guidelines for Frame-Based Audio EncodingsFrame-based encodings encode a fixed-length block of audio intoanother block of compressed data, typically also of fixed length.For frame-based encodings, the sender MAY choose to combine several such frames into a single RTP packet. The receiver can tell thenumber of frames contained in an RTP packet, if all the frames have the same length, by dividing the RTP payload length by the audioframe size which is defined as part of the encoding. This does not work when carrying frames of different sizes unless the frame sizes are relatively prime. If not, the frames MUST indicate their size.For frame-based codecs, the channel order is defined for the wholeblock. That is, for two-channel audio, right and left samples SHOULD be coded independently, with the encoded frame for the left channel preceding that for the right channel.All frame-oriented audio codecs SHOULD be able to encode and decode several consecutive frames within a single packet. Since the frame size for the frame-oriented codecs is given, there is no need to use a separate designation for the same encoding, but with differentnumber of frames per packet.RTP packets SHALL contain a whole number of frames, with framesinserted according to age within a packet, so that the oldest frame (to be played first) occurs immediately after the RTP packet header. The RTP timestamp reflects the instant at which the first sample in the first frame was sampled, that is, the oldest information in the packet.4.5 Audio Encodingsname of sampling defaultencoding sample/frame bits/sample rate ms/frame ms/packet__________________________________________________________________DVI4 sample 4 var. 20G722 sample 8 16,000 20G723 frame N/A 8,000 30 30G726-40 sample 5 8,000 20G726-32 sample 4 8,000 20G726-24 sample 3 8,000 20G726-16 sample 2 8,000 20G728 frame N/A 8,000 2.5 20G729 frame N/A 8,000 10 20G729D frame N/A 8,000 10 20G729E frame N/A 8,000 10 20GSM frame N/A 8,000 20 20GSM-EFR frame N/A 8,000 20 20L8 sample 8 var. 20L16 sample 16 var. 20LPC frame N/A 8,000 20 20MPA frame N/A var. var.PCMA sample 8 var. 20PCMU sample 8 var. 20QCELP frame N/A 8,000 20 20VDVI sample var. var. 20Table 1: Properties of Audio Encodings (N/A: not applicable; var.:variable)The characteristics of the audio encodings described in this document are shown in Table 1; they are listed in order of their payload type in Table 4. While most audio codecs are only specified for a fixed sampling rate, some sample-based algorithms (indicated by an entry of "var." in the sampling rate column of Table 1) may be used withdifferent sampling rates, resulting in different coded bit rates.When used with a sampling rate other than that for which a staticpayload type is defined, non-RTP means beyond the scope of this memo MUST be used to define a dynamic payload type and MUST indicate the selected RTP timestamp clock rate, which is usually the same as the sampling rate for audio.4.5.1 DVI4DVI4 uses an adaptive delta pulse code modulation (ADPCM) encodingscheme that was specified by the Interactive Multimedia Association (IMA) as the "IMA ADPCM wave type". However, the encoding definedhere as DVI4 differs in three respects from the IMA specification:o The RTP DVI4 header contains the predicted value rather than the first sample value contained the IMA ADPCM block header.o IMA ADPCM blocks contain an odd number of samples, since the first sample of a block is contained just in the header (uncompressed), followed by an even number of compressed samples. DVI4 has aneven number of compressed samples only, using the `predict' word from the header to decode the first sample.o For DVI4, the 4-bit samples are packed with the first sample inthe four most significant bits and the second sample in the four least significant bits. In the IMA ADPCM codec, the samples are packed in the opposite order.Each packet contains a single DVI block. This profile only defines the 4-bit-per-sample version, while IMA also specified a 3-bit-per- sample encoding.The "header" word for each channel has the following structure:int16 predict; /* predicted value of first samplefrom the previous block (L16 format) */u_int8 index; /* current index into stepsize table */u_int8 reserved; /* set to zero by sender, ignored by receiver */Each octet following the header contains two 4-bit samples, thus the number of samples per packet MUST be even because there is no means to indicate a partially filled last octet.Packing of samples for multiple channels is for further study.The IMA ADPCM algorithm was described in the document IMA Recommended Practices for Enhancing Digital Audio Compatibility in MultimediaSystems (version 3.0). However, the Interactive MultimediaAssociation ceased operations in 1997. Resources for an archivedcopy of that document and a software implementation of the RTP DVI4 encoding are listed in Section 13.4.5.2 G722G722 is specified in ITU-T Recommendation G.722, "7 kHz audio-coding within 64 kbit/s". The G.722 encoder produces a stream of octets,each of which SHALL be octet-aligned in an RTP packet. The first bit transmitted in the G.722 octet, which is the most significant bit of the higher sub-band sample, SHALL correspond to the most significant bit of the octet in the RTP packet.Even though the actual sampling rate for G.722 audio is 16,000 Hz,the RTP clock rate for the G722 payload format is 8,000 Hz becausethat value was erroneously assigned in RFC 1890 and must remainunchanged for backward compatibility. The octet rate or sample-pair rate is 8,000 Hz.4.5.3 G723G723 is specified in ITU Recommendation G.723.1, "Dual-rate speechcoder for multimedia communications transmitting at 5.3 and 6.3kbit/s". The G.723.1 5.3/6.3 kbit/s codec was defined by the ITU-T as a mandatory codec for ITU-T H.324 GSTN videophone terminalapplications. The algorithm has a floating point specification inAnnex B to G.723.1, a silence compression algorithm in Annex A toG.723.1 and a scalable channel coding scheme for wirelessapplications in G.723.1 Annex C.This Recommendation specifies a coded representation that can be used for compressing the speech signal component of multi-media services at a very low bit rate. Audio is encoded in 30 ms frames, with anadditional delay of 7.5 ms due to look-ahead. A G.723.1 frame can be one of three sizes: 24 octets (6.3 kb/s frame), 20 octets (5.3 kb/s frame), or 4 octets. These 4-octet frames are called SID frames(Silence Insertion Descriptor) and are used to specify comfort noise parameters. There is no restriction on how 4, 20, and 24 octetframes are intermixed. The least significant two bits of the first octet in the frame determine the frame size and codec type:bits content octets/frame00 high-rate speech (6.3 kb/s) 2401 low-rate speech (5.3 kb/s) 2010 SID frame 411 reserved。
rfc中常用的测试协议
rfc中常用的测试协议引言在计算机网络领域中,为了确保网络协议的正确性和稳定性,测试协议起到了至关重要的作用。
RFC(Request for Comments)是一系列文件,用于描述互联网相关协议、过程和技术。
在RFC中,也包含了一些常用的测试协议,用于验证和评估网络协议的功能和性能。
本文将介绍RFC中常用的测试协议,并深入探讨其原理和应用。
二级标题1:PING协议三级标题1.1:概述PING协议是一种常用的网络测试协议,用于测试主机之间的连通性。
它基于ICMP (Internet Control Message Protocol)协议,通过发送ICMP Echo Request报文并等待目标主机的ICMP Echo Reply报文来判断目标主机是否可达。
三级标题1.2:工作原理PING协议的工作原理如下: 1. 发送方主机生成一个ICMP Echo Request报文,并将目标主机的IP地址作为目的地。
2. 发送方主机将报文发送到网络中。
3.中间路由器收到报文后,将报文转发到下一跳路由器。
4. 目标主机收到ICMP Echo Request报文后,生成一个ICMP Echo Reply报文,并将其发送回发送方主机。
5. 发送方主机收到ICMP Echo Reply报文后,通过比较报文中的标识符和序列号等字段,判断目标主机是否可达。
三级标题1.3:应用场景PING协议在网络中的应用非常广泛,常用于以下场景: - 测试主机之间的连通性,判断网络是否正常工作。
- 测试网络延迟,通过计算ICMP Echo Request报文的往返时间来评估网络质量。
- 排查网络故障,通过检查ICMP Echo Reply报文中的错误码来定位故障原因。
二级标题2:Traceroute协议三级标题2.1:概述Traceroute协议用于跟踪数据包从源主机到目标主机经过的路径。
它通过发送一系列的UDP报文,并在每个报文中设置不同的TTL(Time to Live)值来实现。
rfc方案
简介RFC(Request for Comments)是一种用于标准化互联网协议、技术规范和相关主题的文件。
RFC文件通过RFC编辑流程进行创建、讨论和最终批准,并成为互联网工程任务组(IETF)的正式发布文档。
本文档旨在阐述RFC方案的具体流程和要求。
RFC流程提案阶段1.问题提出:提案者针对某个问题或需求,提交RFC提案。
提案内容应包括详细的问题描述、解决方案构想及关键技术要点。
2.讨论和修订:社区成员对提案进行讨论和评审,并提出修改建议。
提案者需要根据反馈进行修订,以完善提案内容。
草案阶段1.版权申明:提案者需要提供版权申明以确保合法使用RFC文档。
2.创建草案:根据修订后的提案内容,创建初始草案。
3.社区讨论:草案将在社区内进行广泛讨论,社区成员将提供反馈、意见和建议。
4.修改和完善:提案者根据社区的反馈和建议,对草案进行修订和完善。
审核阶段1.提交审核:提案者将修订后的草案提交给RFC编辑,申请审核。
2.技术审核:RFC编辑会对草案进行技术上的审核,包括协议规范的严谨性、一致性和可行性等方面的评估。
3.编辑评审:RFC编辑将草案分发给一组编辑,对草案进行详细的评审,包括文法规范、风格和结构等方面。
4.回复和修改:提案者接收到审核和评审结果后,可以对提案进行回复和修改。
批准阶段1.批准流程:一旦通过审核和评审,并经过提案者的修订,RFC编辑将提交给IETF主席审核。
2.IETF主席审核:IETF主席将对RFC进行最终的审核,确保其符合IETF标准。
3.正式发布:一旦IETF主席批准通过,RFC将被正式发布并分发给相关社群。
RFC编写要求1.清晰明了:RFC文档应清晰地表达问题、目标和解决方案,避免含糊不清或难以理解的描述。
2.准确性:文档中的技术细节和规范应准确无误,并且需要根据依赖的协议或标准进行引用和解释。
3.语法规范:RFC文档应遵循一致的语法规范,具备良好的可读性和易于理解的结构。
rfc相关设置及使用
rfc相关设置及使用摘要:一、RFC简介1.RFC的含义2.RFC的作用二、RFC相关设置1.RFC文件的存放位置2.RFC文件的命名规则3.RFC文件的权限设置三、RFC的使用方法1.RFC文件的查看2.RFC文件的编辑3.RFC文件的导入导出四、RFC的高级应用1.RFC模板的使用2.RFC文件的版本控制3.RFC与其他软件的协同工作正文:RFC(Request for Comments)是一种广泛应用于计算机领域的文档格式,它主要用于记录和共享各种计算机网络协议和技术规范。
作为一个重要的知识库,RFC对于网络工程师、程序员等IT从业者来说具有很高的参考价值。
本文将为您详细介绍RFC的相关设置及使用方法。
首先,我们需要了解RFC的基本概念。
RFC(Request for Comments)意为“请求评论”,是一种用于记录和共享计算机网络协议和技术规范的文档格式。
它起源于20世纪60年代的美国,如今已成为互联网领域最重要的知识库之一。
RFC文件通常由网络工程师、程序员等IT从业者编写,并经过专家评审和公开讨论,以确保其内容的准确性和可靠性。
接下来,我们来了解RFC相关设置。
RFC文件的存放位置通常在系统的“/etc/rfc”目录下。
文件的命名规则一般采用“RFC”加数字的形式,如“RFC1925”。
此外,文件的权限设置也很重要,一般来说,RFC文件应具有可读、可写和可执行的权限,以便于用户查看、编辑和执行。
在了解RFC的相关设置后,我们来学习RFC的使用方法。
首先,可以通过命令行或图形界面查看RFC文件的内容。
编辑RFC文件时,可以使用文本编辑器或专门的RFC编辑工具。
此外,RFC文件还可以导入导出,方便与其他软件协同工作。
在掌握RFC的基本使用方法后,我们可以进一步探索RFC的高级应用。
RFC模板可以帮助用户快速创建和编辑RFC文件。
此外,RFC文件还支持版本控制,可以方便地追踪文件的变更历史。
rfc中常用的测试协议
rfc中常用的测试协议摘要:1.RFC 简介2.RFC 中常用的测试协议a.网络协议测试1.网络数据包抓取和分析2.网络仿真和测试工具b.应用层协议测试1.HTTP 和HTTPS 测试2.FTP 和FTPS 测试3.SMTP 和SMTPS 测试c.安全协议测试1.TLS 和SSL 测试2.IPsec 测试d.传输协议测试1.TCP 和UDP 测试e.无线网络协议测试1.802.11 无线网络测试正文:RFC(Request for Comments)是一个用于讨论和记录互联网协议的标准文档系列。
在RFC 中,有许多常用的测试协议,这些协议用于确保互联网协议在实际应用中能够正常工作。
本文将详细介绍这些测试协议。
首先,RFC 中包含了大量的网络协议测试。
网络数据包抓取和分析是网络协议测试的基础,这对于诊断网络问题和优化网络性能至关重要。
此外,网络仿真和测试工具也是必不可少的,例如,网络模拟器(如NS-3)和测试平台(如Ixia)可以帮助工程师在实验室环境中模拟实际网络状况,从而对协议进行更严格的测试。
其次,应用层协议测试在RFC 中也占据重要地位。
HTTP 和HTTPS 是Web 应用中最常用的协议,有许多测试工具可以对它们的性能和安全性进行测试,例如,JMeter 和Locust 等负载测试工具。
此外,FTP 和FTPS、SMTP 和SMTPS 等传输协议也是常用的测试对象。
在安全协议方面,RFC 中包含了TLS 和SSL、IPsec 等协议的测试方法。
这些协议对于保护互联网数据传输的安全至关重要,因此需要进行严格的测试以确保其性能和安全性。
传输协议方面,TCP 和UDP 是互联网中最常用的传输协议,它们的测试方法也是RFC 中的重要内容。
TCP 测试关注可靠性和流量控制等方面,而UDP 测试则更注重数据传输速率和丢包率等指标。
最后,无线网络协议测试在RFC 中也有一定的比重。
例如,802.11 无线网络测试是评估无线局域网性能的关键。
RFC教程
Get ALE Customer Model Table CALL FUNCTION 'ALE_MODEL_INFO_GET ' EXPORTING
MESSAGE_TYPE
VALIDDATE TABLES MODEL_DATA EXCEPTIONS
= MYMSGTYP
= SY-DATUM
= ALEMODEL
This exception reports all failures and system problems on the remote machine.
•COMMUNICATION_FAILURE
CALL FUNCTION RemoteFunction DESTINATION ‘C00DG065’ EXPORTING... IMPORTING... TABLES... EXCEPTIONS SYSTEM_FAILURE = 1 MESSAGE msg COMMUNICATION_FAILURE = 2 MESSAGE msg
NO_MODEL_INFO_FOUND
= 01
OWN_SYSTEM_NOT_DEFINED = 02.
SAP Standard Function DEMO
‘Enable’- Receiving multiple system data through ALE customer model
Add-on ABAP Program DEMO
Calling Remote Function Modules in ABAP
CALL FUNCTION <RemoteFunctionModule> DESTINATION <RFCDest>
EXPORTING f1 =... f2 =... IMPORTING TABLES f3 =... t1 =...
rfc1555.Hebrew Character Encoding for Internet Messages
Network Working Group H. Nussbacher Request for Comments: 1555 Israeli Inter-University Category: Informational Computer Center Y. Bourvine Hebrew University December 1993 Hebrew Character Encoding for Internet MessagesStatus of this MemoThis memo provides information for the Internet community. This memo does not specify an Internet standard of any kind. Distribution ofthis memo is unlimited.AbstractThis document describes the encoding used in electronic mail [RFC822] for transferring Hebrew. The standard devised makes use of MIME[RFC1521] and ISO-8859-8.DescriptionAll Hebrew text when transferred via e-mail must first be translated into ISO-8859-8, and then encoded using either Quoted-Printable(preferable) or Base64, as defined in MIME.The following table provides the four most common Hebrew encodings:PC IBM PC ISOHebrew 8859-8letter 8-bit 7-bit 8-bitAscii EBCDIC Ascii Ascii---------- ----- ------ ----- ------alef 128 41 96 224bet 129 42 97 225gimel 130 43 98 226dalet 131 44 99 227he 132 45 100 228vav 133 46 101 229zayin 134 47 102 230het 135 48 103 231tet 136 49 104 232yod 137 51 105 233kaf sofit 138 52 106 234kaf 139 53 107 235lamed 140 54 108 236Nussbacher & Bourvine [Page 1]mem sofit 141 55 109 237mem 142 56 110 238nun sofit 143 57 111 239nun 144 58 112 240samekh 145 59 113 241ayin 146 62 114 242pe sofit 147 63 115 243pe 148 64 116 244tsadi sofit 149 65 117 245tsadi 150 66 118 246qof 151 67 119 247resh 152 68 120 248shin 153 69 121 249tav 154 71 122 250Note: All values are in decimal ASCII except for the EBCDIC columnwhich is in hexadecimal.ISO 8859-8 8-bit ASCII is also known as IBM Codepage 862.The default directionality of the text is visual. This means thatthe Hebrew text is encoded from left to right (even though Hebrewtext is entered right to left) and is transmitted from left to right via the standard MIME mechanisms. Other methods to controldirectionality are supported and are covered in the complementary RFC 1556, "Handling of Bi-directional Texts in MIME".All discussion regarding Hebrew in email, as well as discussions ofHebrew in other TCP/IP protocols, is discussed in the ilan-h@vm.tau.ac.il list. To subscribe send mail to listserv@vm.tau.ac.il with one line of text as follows:subscribe ilan-h firstname lastnameMIME ConsiderationsMail that is sent that contains Hebrew must contain the followingminimum amount of MIME headers:MIME-Version: 1.0Content-type: text/plain; charset=ISO-8859-8Content-transfer-encoding: BASE64 | Quoted-PrintableUsers should keep their text to within 72 columns so as to allowemail quoting via the prefixing of each line with a ">". Usersshould also realize that not all MIME implementations handle emailquoting properly, so quoting email that contains Hebrew text may lead to problems.Nussbacher & Bourvine [Page 2]In the future, when all email systems implement fully transparent 8- bit email as defined in RFC 1425 and RFC 1426 this standard willbecome partially obsolete. The "Content-type:" field will still benecessary, as well as directionality (which might be implicit for8BIT, but is something for future discussion), but the "Content-transfer-encoding" will be altered to use 8BIT rather than Base64 or Quoted-Printable.OptionalIt is recommended, although not required, to support Hebrew encoding in mail headers as specified in RFC 1522. Specifically, the Q-encoding format is to be the default method used for encoding Hebrew in Internet mail headers and not the B-encoding method.CaveatsWithin Israel there are in excess of 40 Listserv lists which will now start using Hebrew for part of their conversations. Normally,Listserv will deliver mail from a distribution list with a"shortened" header, one that does not include the extra MIME headers. This will cause the MIME encoding to be left intact and the useragent decoding software will not be able to interpret the mail. Each user is able to customize how Listserv delivers mail. For lists that contain Hebrew, users should send mail to Listserv with the following command:set listname fullwhere listname is the name of the list which the user wants full,unabridged headers to appear. This will update their private entryand all subsequent mail from that list will be with full RFC822headers, including MIME headers.In addition, Listserv usually maintains automatic archives of allpostings to a list. These archives, contained in the file "listname LOGyymm", do not contain the MIME headers, so all encodinginformation will be lost. This is a limitation of the Listservsoftware.Nussbacher & Bourvine [Page 3]ExampleBelow is a short example of Quoted-Printable encoded Hebrew email:Date: Sun, 06 Jun 93 15:25:35 IDTFrom: Hank Nussbacher <HANK@VM.BIU.AC.IL>Subject: Sample Hebrew mailTo: Hank Nussbacher <Hank@BARILVM>,Yehavi Bourvine <yehavi@hujivms>MIME-Version: 1.0Content-Type: Text/plain; charset=ISO-8859-8Content-Transfer-Encoding: QUOTED-PRINTABLEThe end of this line contains Hebrew .=EC=E0=F8=F9=E9 =F5= =F8=E0=EE =ED=E5=EC=F9Hank Nussbacher =F8=EB=E1=F1=E5==F0 =F7=F0=E4AcknowledgementsMany thanks to Rafi Sadowsky and Nathaniel Borenstein for all theirhelp.References[ISO-8859] Information Processing -- 8-bit Single-Byte CodedGraphic Character Sets, Part 8: Latin/Hebrew alphabet,ISO 8859-8, 1988.[RFC822] Crocker, D., "Standard for the Format of ARPA InternetText Messages", STD 11, RFC 822, UDEL, August 1982.[RFC1425] Klensin, J., Freed N., Rose M., Stefferud E., andD. Crocker, "SMTP Service Extensions", RFC 1425,United Nations University, Innosoft International, Inc.,Dover Beach Consulting, Inc., Network ManagementAssociates, Inc., The Branch Office, February 1993.[RFC1426] Klensin, J., Freed N., Rose M., Stefferud E., andD. Crocker, "SMTP Service Extension for 8bit-MIMETransport", RFC 1426, United Nations University, Innosoft International, Inc., Dover Beach Consulting, Inc., Network Management Associates, Inc., The Branch Office, February1993.Nussbacher & Bourvine [Page 4][RFC1521] Borenstein N., and N. Freed, "MIME (MultipurposeInternet Mail Extensions) Part One: Mechanisms forSpecifying and Describing the Format of Internet MessageBodies", Bellcore, Innosoft, September 1993.[RFC1522] Moore K., "MIME Part Two: Message Header Extensions forNon-ASCII Text", University of Tennessee, September 1993. Security ConsiderationsSecurity issues are not discussed in this memo.Authors’ AddressesHank NussbacherComputer CenterTel Aviv UniversityRamat AvivIsraelFax: +972 3 6409118Phone: +972 3 6408309EMail: hank@vm.tau.ac.ilYehavi BourvineComputer CenterHebrew UniversityJerusalemIsraelPhone: +972 2 585684Fax: +972 2 527349EMail: yehavi@vms.huji.ac.ilNussbacher & Bourvine [Page 5]。
RFC3312中文版
技术文件技术文件名称:资源管理和SIP的集成目录1 引论 (3)2 术语 (4)3 概要 (4)4 SDP参数 (4)5 OFFER/ANSWER中预置条件的使用 (7)5.1生成一个OFFER (7)5.1.1 SDP 编码 (8)5.2生成一ANSWER (9)6 挂起和恢复会话的建立 (10)7 状态确认 (10)8 拒绝一个OFFER (11)8.1拒绝一个媒体流 (12)9 未知的预置条件类型 (12)10 每个媒体流的多个预置条件处理 (12)11 预置条件的可选标志 (13)12 能力指示 (13)13 应用实例 (13)13.1端到端状态类型 (13)13.2分段状态类型 (17)13.3SIP响应中的O FFER (18)14 安全性考虑 (21)15 IANA的考虑 (21)16 感谢 (21)17 参考文献 (21)18 -- 21 (22)Integration of Resource Managementand Session Initiation Protocol (SIP)资源管理和SIP的集成AbstractThis document defines a generic framework for preconditions, which are extensible through IANA registration. This document also discusses how network quality of service can be made a precondition for establishment of sessions initiated by the Session Initiation Protocol (SIP). These preconditions require that the participant reserve network resources before continuing with the session. We do not define new quality of service reservation mechanisms; these preconditions simply require a participant to use existing resource reservation mechanisms before beginning the session.摘要本文定义了一种通用的预置条件处理(已在IANA中注册的扩展属性)架构.本文也论述了SIP 中建立会话时,网络服务质量怎样进行预置条件处理的。
rfc355
was provide whereby the concentrator could provide local (to the
terminal) echoing when deemed appropriate. (A character input/output
[ into the online RFC archives by BBN Corp. under the ]
[ direction of Alex McKenzie. 1/97 ]
[Page 3]
Network Working Group John Davidson
Request for Comments #355 UH-ALOHA SYSTEM
NIC # 10597 9 June 72
the partioning of echoing were solved for the BCC 500, but are not
immediately extensible to the asynchronous message transmissions of
the ARPANET - especially with the introduction of satellite delays.
with an eye toward their implementation
[Page 2]
on the net. I would appreciate hearing of any other research being
June 9, 1972
rfc4032.Updateto...
rfc4032.Updateto...Network Working Group G. Camarillo Request for Comments: 4032 Ericsson Updates: 3312 P. Kyzivat Category: Standards Track Cisco Systems March 2005 Update to the Session Initiation Protocol (SIP)Preconditions FrameworkStatus of This MemoThis document specifies an Internet standards track protocol for the Internet community, and requests discussion and suggestions forimprovements. Please refer to the current edition of the "InternetOfficial Protocol Standards" (STD 1) for the standardization stateand status of this protocol. Distribution of this memo is unlimited. Copyright NoticeCopyright (C) The Internet Society (2005).AbstractThis document updates RFC 3312, which defines the framework forpreconditions in SIP. We provide guidelines for authors of newprecondition types and describe how to use SIP preconditions insituations that involve session mobility.Table of Contents1. Introduction . . . . . . . . . . . . . . . . . . . . . . . . . 22. Terminology . . . . . . . . . . . . . . . . . . . . . . . . . 23. Defining New Precondition Types . . . . . . . . . . . . . . . 3 3.1.Precondition Type Tag . . . . . . . . . . . . . . . . . 3 3.2. Status Type . . . . . . . . . . . . . . . . . . . . . . 3 3.3. Precondition Strength . . . . . . . . . . . . . . . . . 33.4. Suspending and Resuming Session Establishment . . . . . 34. Issues Related to Session Mobility . . . . . . . . . . . . . . 4 4.1. Update to RFC 3312 . . . . . . . . . . . . . . . . . . . 54.2. Desired Status . . . . . . . . . . . . . . . . . . . . . 75. Security Considerations . . . . . . . . . . . . . . . . . . . 76. IANA Considerations . . . . . . . . . . . . . . . . . . . . . 77. Acknowledgements . . . . . . . . . . . . . . . . . . . . . . . 88. References . . . . . . . . . . . . . . . . . . . . . . . . . . 8 8.1. Normative References . . . . . . . . . . . . . . . . . . 8 Camarillo & Kyzivat Standards Track [Page 1]8.2. Informational References . . . . . . . . . . . . . . . . 8 Authors’ Addresses . . . . . . . . . . . . . . . . . . . . . . . . 9 Full Copyright Statement . . . . . . . . . . . . . . . . . . . . . 101. IntroductionRFC 3312 [3] defines the framework for SIP [2] preconditions, whichis a generic framework that allows SIP UAs (User Agents) to suspendthe establishment of a session until a set of preconditions are met. Although only Quality of Service (QoS) preconditions have beendefined so far, this framework supports different types ofpreconditions. (QoS preconditions are defined by RFC 3312 as well).This document updates RFC 3312, provides guidelines for authors ofnew precondition types and explains which topics they need to discuss when defining them. In addition, it updates some of the proceduresin RFC 3312 for using SIP preconditions in situations that involvesession mobility as described below.RFC 3312 focuses on media sessions that do not move around. That is, media is sent between the same end-points throughout the duration of the session. Nevertheless, media sessions established by SIP are not always static.SIP offers mechanisms to provide session mobility, namely re-INVITEs and UPDATEs [5]. While existing implementations of RFC 3312 canprobably handle session mobility, there is a need to explicitly point out the issues involved and make a slight update on some of theprocedures defined there in. With the updated procedures defined in this document, messages carrying precondition information become more explicit about the current status of the preconditions.Specifically, we now allow answers to downgrade current status values (this was disallowed by RFC 3312). We consider moving an existingstream to a new location as equivalent to establishing a new stream. Therefore, answers moving streams to new locations set all thecurrent status values in their answers to "No" and start a new precondition negotiation from scratch.2. TerminologyIn this document, the key words "MUST", "MUST NOT","REQUIRED","SHALL", "SHALL NOT", "SHOULD", "SHOULD NOT", "RECOMMENDED", "NOTRECOMMENDED", "MAY", and "OPTIONAL" are to be interpreted asdescribed in BCP 14, RFC 2119 [1] and indicate requirement levels for compliant implementations.Camarillo & Kyzivat Standards Track [Page 2]3. Defining New Precondition TypesSpecifications defining new precondition types need to discuss thetopics described in this section. Having clear definitions of newprecondition types is essential to ensure interoperability amongdifferent implementations.3.1. Precondition Type TagNew precondition types MUST have an associated precondition type tag (e.g., "qos" is the tag for QoS preconditions). Authors of newpreconditions MUST register new precondition types and their tagswith the IANA by following the instructions in Section 15 of RFC3312.3.2. Status TypeRFC 3312 defines two status types: end-to-end and segmented.Specifications defining new precondition types MUST indicate whichstatus applies to the new precondition. New preconditions can useonly one status type or both. For example, the QoS preconditionsdefined in RFC 3312 can use both.3.3. Precondition StrengthRFC 3312 defines optional and mandatory preconditions.Specifications defining new precondition types MUST describe whether or not optional preconditions are applicable, and in case they are,what is the expected behavior of a UA on reception of optionalpreconditions.3.4. Suspending and Resuming Session EstablishmentSection 6 of RFC 3312 describes the behavior of UAs from the momentsession establishment is suspended, due to a set of preconditions,until it is resumed when these preconditions are met. In general,the called user is not alerted until the preconditions are met.In addition to not alerting the user, each precondition type MUSTdefine any extra actions UAs should perform or refrain from performing when session establishment is suspended. The behavior of media streams during session suspension is therefore part of thedefinition of a particular precondition type. Some precondition Camarillo & Kyzivat Standards Track [Page 3] types may allow media streams to send and receive packetssession suspension; others may not. Consequently, the followingparagraph from RFC 3312 only applies to QoS preconditions: While session establishment is suspended, user agents SHOULD notsend any data over any media stream. In the case of RTP, neither RTP nor RTCP packets are sent.To clarify the previous paragraph, the control messages used toestablish connections in connection-oriented transport protocols(e.g., TCP SYNs) are not affected by the previous rule. So, useragents follow standard rules (e.g., the SDP ’setup’ attribute [7]) to decide when to establish the connection, regardless of QoSpreconditions.New precondition types MUST also describe the behaviour of UAs onreception of a re-INVITE or an UPDATE with preconditions for anongoing session.4. Issues Related to Session MobilitySection 5 of RFC 3312 describes how to use SIP [2] preconditions with the offer/answer model [4]. RFC 3312 gives a set of rules that allow a user agent to communicate changes in the current status of thepreconditions to the remote user agent.The idea is that a given user agent knows about the current status of some part of the preconditions (e.g., send direction ofprecondition) through local information (e.g., an RSVP RESV isreceived indicating that resource reservation was successful). TheUAC (User Agent Client) informs the UAS (User Agent Server) aboutchanges in the current status by sending an offer to the UAS. TheUAS, in turn, could (if needed) send an offer to the UAC informing it about the status of the part of the preconditions the UAS has localinformation about.Note, however, that UASs do not usually send updates about thecurrent status to the UAC because UASs are the ones resumingsession establishment when all the preconditions are met.Therefore, rather than performing an offer/answer exchange toinform the UAC that all the preconditions are met, they simplysend a 180 (Ringing) response indicating that sessionestablishment has been resumed.Camarillo & Kyzivat Standards Track [Page 4]While RFC 3312 allows updating current status information using themethods described above, it does not allow downgrading current status values in answers, as shown in the third row of Table 3 of RFC 3312. Figure 1 shows how performing such adowngrade in an answer wouldsometimes be needed.3pccA ControllerB C| | | ||<-dialog 1->|<-dialog 2->| || | | || *********************** | ||* MEDIA *| || *********************** | || | | || | | ||<-dialog 1->|<------dialog 3----->|| | | || ******************************** ||* MEDIA *|| ******************************** || | | || | | |Figure 1: Session mobility using 3pccThe 3pcc (Third Party Call Control) [6] controller in Figure 1 hasestablished a session between A and B using dialog 1 towards A anddialog 2 towards B. At that point, the controller wants A to have a session with C instead of B. To transfer A to C (configuration shown at the bottom of Figure 1), the controller sends an empty (no offer) re-INVITE to A. Since A does not know that the session will bemoved, its offer in the 200 OK states that the current status of the media stream in the send direction is "Yes". After contacting Cestablishing dialog 3, the controller sends back an answer to A.This answer contains a new destination for the media (C) and shouldhave downgraded the current status of the media stream to "No", since there is no reservation of resources between A and C.4.1. Update to RFC 3312Below is a set of new rules that update RFC 3312 to address theissues above.Camarillo & Kyzivat Standards Track [Page 5]The rule below applies to offerers moving a media stream to a newaddress:When a stream is being moved to a new transport address, the offerer MUST set all current status values about which it does not have local information about to "No".Note that for streams using segmented status (as opposed to end-to-end status), the fact that the address for the media stream at thelocal segment changes may or may not affect the status of preconditions at the remote segment. However, moving an existingstream to a new location, from the preconditions point of view, islike establishing a new stream. Therefore, it is appropriate toset all the current status values to "No" and start a new preconditionnegotiation from scratch.The updated table and rules below apply to an answerer that is moving a media stream. The offerer was not aware of the move when itgenerated the offer.Table 3 of RFC 3312 needs to be updated to allow answerers todowngrade current status values. The following table shows theresult.Transac status table Local status table New values transac./local________________________________________________________________ ____ no no no/noyes yes yes/yesyes no depends on local infono yes depends on local infoAn answerer MUST downgrade the current status values received in the offer if it has local information about them or if the media streamis being moved to a new transport address.Note that for streams using segmented status, the address change atthe answerer may or may not affect the status of the preconditions at the offerer’s segment. However, as stated above, moving an existing stream to a new location, from the preconditions point of view, islike establishing a new stream. Therefore, it is appropriate toset all the current status values to "No" and start a new preconditionnegotiation from scratch.The new table below applies to an offerer that receives an answerthat updates or downgrades its local status tables.Camarillo & Kyzivat Standards Track [Page 6]Offerers should update their local status tables when they receive an answer as shown in the following table.Transac. status table Local status table New value Local Status________________________________________________________________ _no no noyes yes yesyes no yesno yes no4.2. Desired StatusThe desired status that a UA wants for a media stream after thestream is moved to a new transport address may be different than the desired status negotiated for the stream originally. A UA, forinstance, may require mandatory QoS over a low bandwidth link but be satisfied with optional QoS when the stream is moved to a highbandwidth link.If the new desired status is higher than the previous one (e.g., optional to mandatory), the UA, following RFC 3312 procedures, mayupgrade its desired status in an offer or in an answer. If the newdesired status is lower that the previous one (i.e., mandatory tooptional), the UA, following RFC 3312 procedures as well, maydowngrade its desired status only in an offer (i.e., not in an answer.)5. Security ConsiderationsAn attacker adding preconditions to a session description or modifying existing preconditions could prevent establishment ofsessions. An attacker removing preconditions from a session description could force sessions to be established without meetingmandatory preconditions.Thus, it is strongly RECOMMENDED that integrity protection be applied to the SDP session descriptions. S/MIME is the natural choice toprovide such end-to-end integrity protection, as described in RFC3261 [2].6. IANA ConsiderationsThe IANA registration requirements for the preconditions frameworkare defined in RFC 3312. Any new preconditions are governed by theIANA Considerations there.Camarillo & Kyzivat Standards Track [Page 7]7. AcknowledgementDave Oran and Allison Mankin provided useful comments on thisdocument.8. References8.1. Normative References[1] Bradner, S., "Key words for use in RFCs to Indicate Requirement Levels", BCP 14, RFC 2119, March 1997.[2] Rosenberg, J., Schulzrinne, H., Camarillo, G., Johnston, A.,Peterson, J., Sparks, R., Handley, M., and E. Schooler, "SIP:Session Initiation Protocol", RFC 3261, June 2002.[3] Camarillo, G., Marshall, W., and J. Rosenberg, "Integration ofResource Management and Session Initiation Protocol (SIP)", RFC 3312, October 2002.8.2. Informational References[4] Rosenberg, J. and H. Schulzrinne, "An Offer/Answer Model withSession Description Protocol (SDP)", RFC 3264, June 2002.[5] Rosenberg, J., "The Session Initiation Protocol (SIP) UPDATEMethod", RFC 3311, October 2002.[6] Rosenberg, J., Peterson, J., Schulzrinne, H., and G. Camarillo, "Best Current Practices for Third Party Call Control (3pcc) inthe Session Initiation Protocol (SIP)", BCP 85, RFC 3725, April 2004.[7] Yon, D. and Camarillo, G., "TCP-Based Media Transport in theSession Description Protocol (SDP)", Work In Progress, November 2004.Camarillo & Kyzivat Standards Track [Page 8]Authors’ AddressesGonzalo CamarilloEricssonHirsalantie 11Jorvas 02420FinlandEMail:Gonzalo.Camarillo@/doc/4714675199.html Paul KyzivatCisco Systems1414 Massachusetts Avenue, BXB500 C2-2Boxborough, MA 01719USAEMail: pkyzivat@/doc/4714675199.htmlCamarillo & Kyzivat Standards Track [Page 9]Full Copyright StatementCopyright (C) The Internet Society (2005).This document is subject to the rights, licenses and restrictionscontained in BCP 78, and except as set forth therein, the authorsretain all their rights.This document and the information contained herein are provided on an "AS IS" basis and THE CONTRIBUTOR, THE ORGANIZATION HE/SHE REPRESENTS OR IS SPONSORED BY (IF ANY), THE INTERNET SOCIETY AND THE INTERNETENGINEERING TASK FORCE DISCLAIM ALL WARRANTIES, EXPRESS OR IMPLIED,INCLUDING BUT NOT LIMITED TO ANY WARRANTY THATTHE USE OF THEINFORMATION HEREIN WILL NOT INFRINGE ANY RIGHTS OR ANY IMPLIEDWARRANTIES OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE. Intellectual PropertyThe IETF takes no position regarding the validity or scope of anyIntellectual Property Rights or other rights that might be claimed to pertain to the implementation or use of the technology described inthis document or the extent to which any license under such rightsmight or might not be available; nor does it represent that it hasmade any independent effort to identify any such rights. Information on the procedures with respect to rights in RFC documents can befound in BCP 78 and BCP 79.Copies of IPR disclosures made to the IETF Secretariat and anyassurances of licenses to be made available, or the result of anattempt made to obtain a general license or permission for the use of such proprietary rights by implementers or users of thisspecification can be obtained from the IETF on-line IPR repository at /doc/4714675199.html /ipr.The IETF invites any interested party to bring to its attention anycopyrights, patents or patent applications, or other proprietaryrights that may cover technology that may be required to implementthis standard. Please address the information to the IETF at ietf-ipr@/doc/4714675199.html.AcknowledgementFunding for the RFC Editor function is currently provided by theInternet Society.Camarillo & Kyzivat Standards Track [Page 10]。
rfc3551[1]
Network Working Group H.Schulzrinne Request for Comments:3551Columbia University Obsoletes:1890S.Casner Category:Standards Track Packet DesignJuly2003 RTP Profile for Audio and Video Conferences with Minimal Control Status of this MemoThis document specifies an Internet standards track protocol for the Internet community,and requests discussion and suggestions for improvements.Please refer to the current edition of the “Internet Official Protocol Standards”(STD1)for the standardization state and status of this protocol.Distribution of this memo is unlimited.Copyright NoticeCopyright(C)The Internet Society(2003).All Rights Reserved.AbstractThis document describes a profile called“RTP/AVP”for the use of the real-time transport protocol (RTP),version2,and the associated control protocol,RTCP,within audio and video multipartici-pant conferences with minimal control.It provides interpretations of genericfields within the RTP specification suitable for audio and video conferences.In particular,this document defines a set of default mappings from payload type numbers to encodings.This document also describes how audio and video data may be carried within RTP.It defines a set of standard encodings and their names when used within RTP.The descriptions provide pointers to reference implementations and the detailed standards.This document is meant as an aid for implementors of audio,video and other real-time multimedia applications.This memorandum obsoletes RFC1890.It is mostly backwards-compatible except for functions removed because two interoperable implementations were not found.The additions to RFC1890 codify existing practice in the use of payload formats under this profile and include new payload formats defined since RFC1890was published.Table of Contents1.Introduction41.1Terminology (4)2.RTP and RTCP Packet Forms and Protocol Behavior43.Registering Additional Encodings64.Audio74.1Encoding-Independent Rules (7)4.2Operating Recommendations (9)4.3Guidelines for Sample-Based Audio Encodings (9)4.4Guidelines for Frame-Based Audio Encodings (9)4.5Audio Encodings (10)4.5.1DVI4 (11)4.5.2G722 (12)4.5.3G723 (12)4.5.4G726-40,G726-32,G726-24,and G726-16 (15)4.5.5G728 (16)4.5.6G729 (16)4.5.7G729D and G729E (18)4.5.8GSM (20)4.5.9GSM-EFR (23)4.5.10L8 (23)4.5.11L16 (23)4.5.12LPC (23)4.5.13MPA (23)4.5.14PCMA and PCMU (24)4.5.15QCELP (24)4.5.16RED (24)4.5.17VDVI (24)5.Video255.1CelB (26)5.2JPEG (26)5.3H261 (26)5.4H263 (26)5.5H263-1998 (26)5.6MPV (26)5.7MP2T (27)5.8nv (27)6.Payload Type Definitions277.RTP over TCP and Similar Byte Stream Protocols298.Port Assignment299.Changes from RFC18903010.Security Considerations3211.IANA Considerations3312.References3312.1Normative References (33)12.2Informative References (33)13.Current Locations of Related Resources3414.Acknowledgments3615.Intellectual Property Rights Statement3616.Authors’Addresses3717.Full Copyright Statement381.IntroductionThis profile defines aspects of RTP left unspecified in the RTP Version2protocol definition (RFC3550)[1].This profile is intended for the use within audio and video conferences with minimal session control.In particular,no support for the negotiation of parameters or member-ship control is provided.The profile is expected to be useful in sessions where no negotiation or membership control are used(e.g.,using the static payload types and the membership indications provided by RTCP),but this profile may also be useful in conjunction with a higher-level control protocol.Use of this profile may be implicit in the use of the appropriate applications;there may be no explicit indication by port number,protocol identifier or the like.Applications such as session directories may use the name for this profile specified in Section11.Other profiles may make different choices for the items specified here.This document also defines a set of encodings and payload formats for audio and video.These payload format descriptions are included here only as a matter of convenience since they are too small to warrant separate e of these payload formats is NOT REQUIRED to use this profile.Only the binding of some of the payload formats to static payload type numbers in Tables4and5is normative.1.1TerminologyThe key words“must”,“must not”,“required”,“shall”,“shall not”,“should”,“should not”,“recommended”,“may”,and“optional”in this document are to be interpreted as de-scribed in RFC2119[2]and indicate requirement levels for implementations compliant with this RTP profile.This document defines the term media type as dividing encodings of audio and video content into three classes:audio,video and audio/video(interleaved).2.RTP and RTCP Packet Forms and Protocol BehaviorThe section“RTP Profiles and Payload Format Specifications”of RFC3550enumerates a number of items that can be specified or modified in a profile.This section addresses these items.Generally, this profile follows the default and/or recommended aspects of the RTP specification.RTP data header:The standard format of thefixed RTP data header is used(one marker bit). Payload types:Static payload types are defined in Section6.RTP data header additions:No additionalfixedfields are appended to the RTP data header. RTP data header extensions:No RTP header extensions are defined,but applications operat-ing under this profile may use such extensions.Thus,applications should not assume that the RTP header X bit is always zero and should be prepared to ignore the header extension.If a header extension is defined in the future,that definition must specify the contents of the first16bits in such a way that multiple different extensions can be identified.RTCP packet types:No additional RTCP packet types are defined by this profile specification. RTCP report interval:The suggested constants are to be used for the RTCP report interval calculation.Sessions operating under this profile may specify a separate parameter for the RTCP traffic bandwidth rather than using the default fraction of the session bandwidth.The RTCP traffic bandwidth may be divided into two separate session parameters for those participants which are active data senders and those which are not.Following the recom-mendation in the RTP specification[1]that1/4of the RTCP bandwidth be dedicated to data senders,the recommended default values for these two parameters would be1.25% and3.75%,respectively.For a particular session,the RTCP bandwidth for non-data-senders may be set to zero when operating on unidirectional links or for sessions that don’t require feedback on the quality of reception.The RTCP bandwidth for data senders should be kept non-zero so that sender reports can still be sent for inter-media synchronization and to identify the source by CNAME.The means by which the one or two session parameters for RTCP bandwidth are specified is beyond the scope of this memo.SR/RR extension:No extension section is defined for the RTCP SR or RR packet.SDES use:Applications may use any of the SDES items described in the RTP specification.While CNAME information must be sent every reporting interval,other items should only be sent every third reporting interval,with NAME sent seven out of eight times within that slot and the remaining SDES items cyclically taking up the eighth slot,as defined in Section6.2.2of the RTP specification.In other words,NAME is sent in RTCP packets1,4,7,10,13,16,19,while,say,EMAIL is used in RTCP packet22.Security:The RTP default security services are also the default under this profile.String-to-key mapping:No mapping is specified by this profile.Congestion:RTP and this profile may be used in the context of enhanced network service,for example,through Integrated Services(RFC1633)[4]or Differentiated Services(RFC2475)[5],or they may be used with best effort service.If enhanced service is being used,RTP receivers should monitor packet loss to ensure that the service that was requested is actually being delivered.If it is not,then they should assume that they are receiving best-effort service and behave accordingly.If best-effort service is being used,RTP receivers should monitor packet loss to ensure that the packet loss rate is within acceptable parameters.Packet loss is considered acceptable if a TCPflow across the same network path and experiencing the same network conditions would achieve an average throughput,measured on a reasonable timescale,that is not less than the RTPflow is achieving.This condition can be satisfied by implementing congestion control mechanisms to adapt the transmission rate(or the number of layers subscribed for a layered multicast session),or by arranging for a receiver to leave the session if the loss rate is unacceptably high.The comparison to TCP cannot be specified exactly,but is intended as an“order-of-magnitude”comparison in timescale and throughput.The timescale on which TCP throughput is mea-sured is the round-trip time of the connection.In essence,this requirement states that it is not acceptable to deploy an application(using RTP or any other transport protocol)on the best-effort Internet which consumes bandwidth arbitrarily and does not compete fairly with TCP within an order of magnitude.Underlying protocol:The profile specifies the use of RTP over unicast and multicast UDP as well as TCP.(This does not preclude the use of these definitions when RTP is carried by other lower-layer protocols.)Transport mapping:The standard mapping of RTP and RTCP to transport-level addresses is used.Encapsulation:This profile leaves to applications the specification of RTP encapsulation in pro-tocols other than UDP.3.Registering Additional EncodingsThis profile lists a set of encodings,each of which is comprised of a particular media data compres-sion or representation plus a payload format for encapsulation within RTP.Some of those payload formats are specified here,while others are specified in separate RFCs.It is expected that addi-tional encodings beyond the set listed here will be created in the future and specified in additional payload format RFCs.This profile also assigns to each encoding a short name which may be used by higher-level control protocols,such as the Session Description Protocol(SDP),RFC2327[6],to identify encodings selected for a particular RTP session.In some contexts it may be useful to refer to these encodings in the form of a MIME content-type. To facilitate this,RFC3555[7]provides registrations for all of the encodings names listed here as MIME subtype names under the“audio”and“video”MIME types through the MIME registration procedure as specified in RFC2048[8].Any additional encodings specified for use under this profile(or others)may also be assigned names registered as MIME subtypes with the Internet Assigned Numbers Authority(IANA).This registry provides a means to insure that the names assigned to the additional encodings are kept unique. RFC3555specifies the information that is required for the registration of RTP encodings.In addition to assigning names to encodings,this profile also assigns static RTP payload type numbers to some of them.However,the payload type number space is relatively small and cannot accommodate assignments for all existing and future encodings.During the early stages of RTP development,it was necessary to use statically assigned payload types because no other mechanism had been specified to bind encodings to payload types.It was anticipated that non-RTP means beyond the scope of this memo(such as directory services or invitation protocols)would be specified to establish a dynamic mapping between a payload type and an encoding.Now,mechanisms for defining dynamic payload type bindings have been specified in the Session Description Protocol (SDP)and in other protocols such as ITU-T Recommendation H.323/H.245.These mechanismsassociate the registered name of the encoding/payload format,along with any additional required parameters,such as the RTP timestamp clock rate and number of channels,with a payload type number.This association is effective only for the duration of the RTP session in which the dynamic payload type binding is made.This association applies only to the RTP session for which it is made, thus the numbers can be re-used for different encodings in different sessions so the number space limitation is avoided.This profile reserves payload type numbers in the range96-127exclusively for dynamic assignment. Applications shouldfirst use values in this range for dynamic payload types.Those applications which need to define more than32dynamic payload types may bind codes below96,in which case it is recommended that unassigned payload type numbers be usedfirst.However,the statically assigned payload types are default bindings and may be dynamically bound to new encodings if needed.Redefining payload types below96may cause incorrect operation if an attempt is made to join a session without obtaining session description information that defines the dynamic payload types.Dynamic payload types should not be used without a well-defined mechanism to indicate the mapping.Systems that expect to interoperate with others operating under this profile should not make their own assignments of proprietary encodings to particular,fixed payload types. This specification establishes the policy that no additional static payload types will be assigned beyond the ones defined in this document.Establishing this policy avoids the problem of trying to create a set of criteria for accepting static assignments and encourages the implementation and deployment of the dynamic payload type mechanisms.Thefinal set of static payload type assignments is provided in Tables4and5.4.Audio4.1Encoding-Independent RulesSince the ability to suppress silence is one of the primary motivations for using packets to transmit voice,the RTP header carries both a sequence number and a timestamp to allow a receiver to distinguish between lost packets and periods of time when no data was transmitted.Discontiguous transmission(silence suppression)may be used with any audio payload format.Receivers must assume that senders may suppress silence unless this is restricted by signaling specified elsewhere. (Even if the transmitter does not suppress silence,the receiver should be prepared to handle periods when no data is present since packets may be lost.)Some payload formats(see Sections4.5.3and4.5.6)define a“silence insertion descriptor”or“com-fort noise”frame to specify parameters for artificial noise that may be generated during a period of silence to approximate the background noise at the source.For other payload formats,a generic Comfort Noise(CN)payload format is specified in RFC3389[9].When the CN payload format is used with another payload format,different values in the RTP payload typefield distinguish comfort-noise packets from those of the selected payload format.For applications which send either no packets or occasional comfort-noise packets during silence, thefirst packet of a talkspurt,that is,thefirst packet after a silence period during which packetshave not been transmitted contiguously,should be distinguished by setting the marker bit in the RTP data header to one.The marker bit in all other packets is zero.The beginning of a talkspurt may be used to adjust the playout delay to reflect changing network delays.Applications without silence suppression must set the marker bit to zero.The RTP clock rate used for generating the RTP timestamp is independent of the number of channels and the encoding;it usually equals the number of sampling periods per second.For N-channel encodings,each sampling period(say,1/8,000of a second)generates N samples.(This terminology is standard,but somewhat confusing,as the total number of samples generated per second is then the sampling rate times the channel count.)If multiple audio channels are used,channels are numbered left-to-right,starting at one.In RTP audio packets,information from lower-numbered channels precedes that from higher-numbered channels.For more than two channels,the convention followed by the AIFF-C audio interchange format should be followed[3],using the following notation,unless some other convention is spec-ified for a particular encoding or payload format:l leftr rightc centerS surroundF frontR rearchannels description channel1234564.2Operating RecommendationsThe following recommendations are default operating parameters.Applications should be pre-pared to handle other values.The ranges given are meant to give guidance to application writers, allowing a set of applications conforming to these guidelines to interoperate without additional negotiation.These guidelines are not intended to restrict operating parameters for applications that can negotiate a set of interoperable parameters,e.g.,through a conference control protocol. For packetized audio,the default packetization interval should have a duration of20ms or one frame,whichever is longer,unless otherwise noted in Table1(column“ms/packet”).The pack-etization interval determines the minimum end-to-end delay;longer packets introduce less header overhead but higher delay and make packet loss more noticeable.For non-interactive applications such as lectures or for links with severe bandwidth constraints,a higher packetization delay may be used.A receiver should accept packets representing between0and200ms of audio data.(For framed audio encodings,a receiver should accept packets with a number of frames equal to200 ms divided by the frame duration,rounded up.)This restriction allows reasonable buffer sizing for the receiver.4.3Guidelines for Sample-Based Audio EncodingsIn sample-based encodings,each audio sample is represented by afixed number of bits.Within the compressed audio data,codes for individual samples may span octet boundaries.An RTP audio packet may contain any number of audio samples,subject to the constraint that the number of bits per sample times the number of samples per packet yields an integral octet count.Fractional encodings produce less than one octet per sample.The duration of an audio packet is determined by the number of samples in the packet.For sample-based encodings producing one or more octets per sample,samples from different chan-nels sampled at the same sampling instant should be packed in consecutive octets.For example, for a two-channel encoding,the octet sequence is(left channel,first sample),(right channel,first sample),(left channel,second sample),(right channel,second sample),....For multi-octet encod-ings,octets should be transmitted in network byte order(i.e.,most significant octetfirst).The packing of sample-based encodings producing less than one octet per sample is encoding-specific.The RTP timestamp reflects the instant at which thefirst sample in the packet was sampled,that is,the oldest information in the packet.4.4Guidelines for Frame-Based Audio EncodingsFrame-based encodings encode afixed-length block of audio into another block of compressed data, typically also offixed length.For frame-based encodings,the sender may choose to combine several such frames into a single RTP packet.The receiver can tell the number of frames contained in an RTP packet,if all the frames have the same length,by dividing the RTP payload length by the audio frame size which is defined as part of the encoding.This does not work when carrying frames of different sizes unless the frame sizes are relatively prime.If not,the frames must indicate their size.For frame-based codecs,the channel order is defined for the whole block.That is,for two-channel audio,right and left samples should be coded independently,with the encoded frame for the left channel preceding that for the right channel.All frame-oriented audio codecs should be able to encode and decode several consecutive frames within a single packet.Since the frame size for the frame-oriented codecs is given,there is no need to use a separate designation for the same encoding,but with different number of frames per packet.RTP packets shall contain a whole number of frames,with frames inserted according to age within a packet,so that the oldest frame(to be playedfirst)occurs immediately after the RTP packet header.The RTP timestamp reflects the instant at which thefirst sample in thefirst frame was sampled,that is,the oldest information in the packet.4.5Audio Encodingsname ofsample/frame bits/sample rate ms/frame ms/packetsample4var.20 G722frame N/A8,0003030 G726-40sample48,00020 G726-24sample28,00020 G728frame N/A8,0001020 G729Dframe N/A8,0001020 GSMframe N/A8,0002020 L8sample16var.20 LPCframe N/A var.var.PCMAsample8var.20 QCELPsample var.var.20 Table1:Properties of Audio Encodings(N/A:not applicable;var.:variable)The characteristics of the audio encodings described in this document are shown in Table1;they are listed in order of their payload type in Table4.While most audio codecs are only specified for afixed sampling rate,some sample-based algorithms(indicated by an entry of“var.”in thesampling rate column of Table1)may be used with different sampling rates,resulting in different coded bit rates.When used with a sampling rate other than that for which a static payload type is defined,non-RTP means beyond the scope of this memo must be used to define a dynamic payload type and must indicate the selected RTP timestamp clock rate,which is usually the same as the sampling rate for audio.4.5.1DVI4DVI4uses an adaptive delta pulse code modulation(ADPCM)encoding scheme that was specified by the Interactive Multimedia Association(IMA)as the“IMA ADPCM wave type”.However,the encoding defined here as DVI4differs in three respects from the IMA specification:•The RTP DVI4header contains the predicted value rather than thefirst sample value con-tained the IMA ADPCM block header.•IMA ADPCM blocks contain an odd number of samples,since thefirst sample of a block is contained just in the header(uncompressed),followed by an even number of compressed samples.DVI4has an even number of compressed samples only,using the‘predict’word from the header to decode thefirst sample.•For DVI4,the4-bit samples are packed with thefirst sample in the four most significant bits and the second sample in the four least significant bits.In the IMA ADPCM codec,the samples are packed in the opposite order.Each packet contains a single DVI block.This profile only defines the4-bit-per-sample version, while IMA also specified a3-bit-per-sample encoding.The“header”word for each channel has the following structure:int16predict;/*predicted value of first samplefrom the previous block(L16format)*/u_int8index;/*current index into stepsize table*/u_int8reserved;/*set to zero by sender,ignored by receiver*/Each octet following the header contains two4-bit samples,thus the number of samples per packet must be even because there is no means to indicate a partiallyfilled last octet.Packing of samples for multiple channels is for further study.The IMA ADPCM algorithm was described in the document IMA Recommended Practices for Enhancing Digital Audio Compatibility in Multimedia Systems(version3.0).However,the Inter-active Multimedia Association ceased operations in1997.Resources for an archived copy of that document and a software implementation of the RTP DVI4encoding are listed in Section13.4.5.2G722G722is specified in ITU-T Recommendation G.722,“7kHz audio-coding within64kbit/s”.The G.722encoder produces a stream of octets,each of which shall be octet-aligned in an RTP packet. Thefirst bit transmitted in the G.722octet,which is the most significant bit of the higher sub-band sample,shall correspond to the most significant bit of the octet in the RTP packet.Even though the actual sampling rate for G.722audio is16,000Hz,the RTP clock rate for the G722payload format is8,000Hz because that value was erroneously assigned in RFC1890and must remain unchanged for backward compatibility.The octet rate or sample-pair rate is8,000 Hz.4.5.3G723G723is specified in ITU Recommendation G.723.1,“Dual-rate speech coder for multimedia com-munications transmitting at5.3and6.3kbit/s”.The G.723.15.3/6.3kbit/s codec was defined by the ITU-T as a mandatory codec for ITU-T H.324GSTN videophone terminal applications.The algorithm has afloating point specification in Annex B to G.723.1,a silence compression algorithm in Annex A to G.723.1and a scalable channel coding scheme for wireless applications in G.723.1 Annex C.This Recommendation specifies a coded representation that can be used for compressing the speech signal component of multi-media services at a very low bit rate.Audio is encoded in30ms frames, with an additional delay of7.5ms due to look-ahead.A G.723.1frame can be one of three sizes: 24octets(6.3kb/s frame),20octets(5.3kb/s frame),or4octets.These4-octet frames are called SID frames(Silence Insertion Descriptor)and are used to specify comfort noise parameters.There is no restriction on how4,20,and24octet frames are intermixed.The least significant two bits of thefirst octet in the frame determine the frame size and codec type:bits content octets/frame00high-rate speech(6.3kb/s)2401low-rate speech(5.3kb/s)2010SID frame411reservedIt is possible to switch between the two rates at any30ms frame boundary.Both(5.3kb/s and6.3 kb/s)rates are a mandatory part of the encoder and decoder.Receivers must accept both data rates and must accept SID frames unless restriction of these capabilities has been signaled.The MIME registration for G723in RFC3555[7]specifies parameters that may be used with MIME or SDP to restrict to a single data rate or to restrict the use of SID frames.This coder was optimized to represent speech with near-toll quality at the above rates using a limited amount of complexity. The packing of the encoded bit stream into octets and the transmission order of the octets is specified in Rec.G.723.1and is the same as that produced by the G.723C code reference im-plementation.For the6.3kb/s data rate,this packing is illustrated as follows,where the header (HDR)bits are always“00”as shown in Fig.1to indicate operation at6.3kb/s,and the Z bit is always set to zero.The diagrams show the bit packing in“network byte order”,also known asbig-endian order.The bits of each32-bit word are numbered0to31,with the most significant bit on the left and numbered0.The octets(bytes)of each word are transmitted most significant octetfirst.The bits of each datafield are numbered in the order of the bit stream representation of the encoding(least significant bitfirst).The vertical bars indicate the boundaries betweenfield fragments.012301234567890123456789012345678901+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+|LPC|HDR|LPC|LPC|ACL0|LPC|||||||||000000|00|11110000|22111111|000000|22||543210||32109876|10987654|543210|32|+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+|ACL2|ACL|A|GAIN0|ACL|ACL|GAIN0|GAIN1|||1|C||3|2||||00000|00|0|0000|00|00|11000000|00000000||43210|10|6|3210|10|65|10987654|76543210|+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+|GAIN2|GAIN1|GAIN2|GAIN3|GRID|GAIN3|||||||||0000|1100|11000000|00000000|0000|1100||3210|1098|10987654|76543210|3210|1098|+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+|MSBPOS|Z|POS|MSBPOS|POS0|POS|POS0||||0|||1|||0000000|0|00|111000|00000000|00|111111||6543210||10|210987|98765432|10|543210|+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+|POS1|POS2|POS1|POS2|POS3|POS2|||||||||00000000|0000|1111|11000000|0000|1111||98765432|3210|3210|10987654|3210|5432|+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+|POS3|PSIG0|POS|PSIG2|PSIG1|PSIG3|PSIG2||||3||||||11000000|000000|11|000|00000|00000|000||10987654|543210|32|210|43210|43210|543|+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+-+Figure1:G.723(6.3kb/s)bit packingFor the5.3kb/s data rate,the header(HDR)bits are always“01”,as shown in Fig.2,to indicate operation at5.3kb/s.。
网络安全技术英文习题集_网络安全技术
网络安全技术英文习题集_网络安全技术精品管理制度、管理方案、合同、协议、一起学习进步《网络安全技术》英文习题集Chapter 1 IntroductionANSWERS NSWERS TO QUESTIONS1.1 What is the OSI security architecture?The OSI Security Architecture is a framework that provides a systematic way of defining the requirements for security and characterizing the approaches to satisfying those requirements. The document defines security attacks, mechanisms, and services, and the relationships among these categories.1.2 What is the difference between passive and active security threats? Passive attacks have to do with eavesdropping on, or monitoring, transmissions. Electronic mail, file transfers, and client/server exchanges are examples of transmissions that can be monitored. Active attacks include the modification of transmitted data and attempts to gain unauthorized access to computer systems.1.3 Lists and briefly define categories of passive and active security attacks?Passive attacks: release of message contents and traffic analysis. Active attacks: masquerade, replay, modification of messages, and denial of service.1.4 Lists and briefly define categories of security service? Authentication: The assurance that the communicating entity is the one that it claims to be.Access contr ol: The prevention of unauthorized use of a resource (i.e., this service controls who can have access to a resource, under what conditions access can occur, and what those accessing the resource are allowed to do). Data confidentiality: The protection of data from unauthorized disclosure. Data integrity: The assurance that data received are exactly as sent by an authorized entity (i.e., contain no modification, insertion, deletion, or replay). Nonrepudiation: Provides protection against denial by one of the entities involved in a communication of having participated in all or part of the communication.Availability service: The property of a system or a system resource being accessible and usable upon demand by an authorized system entity, according to performance specifications for the system (i.e., a system is available if it provides services according to the system design whenever users request them).Chapter2 Symmetric Encryptionand Message ConfidentialityANSWERS NSWERS TO QUESTIONS2.1 What are the essential ingredients of a symmetric cipher? Plaintext, encryption algorithm, secret key, ciphertext, decryption algorithm.2.2 What are the two basic functions used in encryption algorithms? Permutation and substitution.2.3 How many keys are required for two people to communicate via a symmetric cipher?One secret key.2.4 What is the difference between a block cipher and a stream cipher?A stream cipher is one that encrypts a digital data stream one bit or one byte at a time. A block cipher is one in which a block of plaintext is treated as a whole and used to produce a ciphertext block of equal length.2.5 What are the two general approaches to attacking a cipher? Cryptanalysis and brute force.2.6 Why do some block cipher modes of operation only use encryption while others use both encryption and decryption?In some modes, the plaintext does not pass through the encryption function, but is XORed with the output of the encryption function. The math works out that for decryption in these cases, the encryption function must also be used.2.7 What is triple encryption?With triple encryption, a plaintext block is encrypted by passing it through an encryption algorithm; the result is then passed through the same encryption algorithm again; the result of the second encryption is passed through the same encryption algorithm a third time. Typically, the second stage uses the decryption algorithm rather than the encryption algorithm.2.8 Why is the middle portion of 3DES a decryption rather than an encryption?There is no cryptographic significance to the use of decryption for the second stage. Its only advantage is that it allows users of 3DES to decrypt data encrypted by users of the older single DES by repeating the key.2.9 What is the difference between link and end-to-end encryption?With link encryption, each vulnerable communications link is equipped on both ends with an encryption device. With end-to-end encryption, the encryption process is carried out at the two end systems. The source host or terminal encrypts the data; the data in encrypted form are then transmitted unaltered across the network to the destination terminal or host.2.10 List ways in which secret keys can be distributed to two communicating parties.For two parties A and B, key distribution can be achieved in a number of ways, as follows:(1)A can select a key and physically deliver it to B.(2)A third party can select the key and physically deliver it to A and B.(3)If A and B have previously and recently used a key, one party can transmit the new key to the other, encrypted using the old key.(4)If A and B each has an encrypted connection to a third party C, C can deliver a key on the encrypted links to A and B.2.11 What is the difference between a session key and a master key?A session key is a temporary encryption key used between two principals. A master key is a long-lasting key that is used between a key distribution center and a principal for the purpose of encoding the transmission of session keys. Typically, the master keys are distributed by noncryptographic means.2.12 What is a key distribution center?A key distribution center is a system that is authorized to transmit temporary session keys to principals. Each session key is transmitted in encrypted form, using a master key that the key distribution center shares with the target principal.ANSWERS NSWERS TO PROBLEMS2.1 What RC4 key value will leave S unchanged during initialization? That is, after the initial permutation of S, the entries of S will be equal to the values from 0 through 255 in ascending order.Use a key of length 255 bytes. The first two bytes are zero; that is K[0] = K[1] = 0. Thereafter, we have: K[2] = 255; K[3] = 254; … K[255]= 2.2.2 If a bit error occurs in the transmission of a ciphertext character in 8-bit CFB mode, how far does the error propagate?Nine plaintext characters are affected. The plaintext character corresponding to the ciphertext character is obviously altered. In addition, the altered ciphertext character enters the shift register and is not removed until the next eight characters are processed.2.3 Key distribution schemes using an access control center and/or a key distribution center have central points vulnerable to attack. Discuss the security implications of such centralization.The central points should be highly fault-tolerant, should be physically secured, and should use trusted hardware/software.Chapter 3 Public-Key Cryptography and Message AuthenticationANSWERS NSWERS TO QUESTIONS3.1 List three approaches to message authentication.Message encryption, message authentication code, hash function.3.2 What is message authentication code?An authenticator that is a cryptographic function of both the data to be authenticated and a secret key.3.3 Briefly describe the three schemes illustrated in Figture3.2.(a) A hash code is computed from the source message, encrypted using symmetric encryption and a secret key, and appended to the message. At the receiver, the same hash code is computed. The incoming code is decrypted using the same key and compared with the computed hash code. (b) This is the same procedure as in (a) except that public-key encryption is used; the sender encrypts the hash code with the sender's private key, and the receiver decrypts the hash code with the sender's public key. (c) A secret value is appended to a message and then a hash code is calculated using the message plus secret value as input. Then the message (without the secret value) and the hash code are transmitted. The receiver appends the same secret value to the message and computes the hash value over the message plus secret value. This is then compared to the received hash code.3.4 What properties must a hash function have to be useful for message authentication?(1)H can be applied to a block of data of any size.(2)H produces a fixed-length output.(3)H(x) is relatively easy to compute for any given x, making both hardware and software implementations practical.(4)For any given value h, it is computationally infeasible to find x such that H(x) = h. This is sometimes referred to in the literature as the one-way property. (5)For any given block x, it is computationally infeasible to find y ≠ x with H(y) =H(x).(6)It is computationally infeasible to find any pair (x, y) such that H(x) = H(y).3.5 In the context of a hash function, what is a compression function? The compression function is the fundamental module, or basic building block, of a hash function. The hash function consists of iterated application of the compression function.3.6 What are the principal ingredients of a public-key cryptosystem? Plaintext: This is the readable message or data that is fed into the algorithmas input. Encryption algorithm: The encryption algorithm performs varioustransformations on the plaintext. Public and private keys: This is a pair of keys that have been selected so that if one is used for encryption, the other is used for decryption. The exact transformations performed by the encryption algorithm depend on the public or private key that is provided as input. Ciphertext: This is the scrambled message produced as output. It depends on the plaintext and the key. For a given message, two different keys will produce two different ciphertexts. Decryption algorithm: This algorithm accepts the ciphertext and the matching key and produces the original plaintext.3.7 List and briefly define three uses of a public-key cryptosystem. Encryption/decryption: The sender encrypts a message with the recipient's public key. Digital signature: The sender "signs" a message with its private key. Signing is achieved by a cryptographic algorithm applied to the message or to a small block of data that is a function of the message. Key exchange: Two sides cooperate to exchange a session key. Several different approaches are possible, involving the private key(s) of one or both parties.3.8 What is the difference between a private key and a secret key?The key used in conventional encryption is typically referred to as a secret key. The two keys used for public-key encryption are referred to as the public key and the private key.3.9 What is digital signature?A digital signature is an authentication mechanism that enables the creator of a message to attach a code that acts as a signature. The signature is formed by taking the hash of the message and encrypting the message with the creator's private key. The signature guarantees the source and integrity of the message.3.10 What is a public-key certificate?A pubic-key certificate consists of a public key plus a User ID of the key owner, with the whole block signed by a trusted third party. Typically, the third party is a certificate authority (CA) that is trusted by the user community, such as a government agency or a financial institution.3.11 How can public-key encryption be used to distribute a secret key?Several different approaches are possible, involving the private key(s) of one or both parties. One approach is Diffie-Hellman key exchange. Another approach is for the sender to encrypt a secret key with the recipient's public key.ANSWERS NSWERS TO PROBLEMS3.1 Consider a 32-bit hash function defined as the concatenation of two 16-bit functions: XOR and RXOR, defined in Section 3.2 as “two simple hash function.”a. Will this checksum detect all errors caused by an odd number of error bits? Explain.b. Will this checksum detect all errors caused by an even number of error bits? If not, characterize the error patterns that will cause the checksum to fail.c. Comments on the effectiveness of this function for use a hash functions for authentication.a. Yes. The XOR function is simply a vertical parity check. If there is an odd number of errors, then there must be at least one column that contains an odd number of errors, and the parity bit for that column will detect the error. Note that the RXOR function also catches all errors caused by an odd number of error bits. Each RXOR bit is a function of a unique "spiral" of bits in the block of data. If there is an odd number of errors, then there must be at least one spiral that contains an odd number of errors, and the parity bit for that spiral will detect the error.b. No. The checksum will fail to detect an even number of errors when both the XOR and RXOR functions fail. In order for both to fail, the pattern of error bits must be at intersection points between parity spirals and parity columns such that there is an even number of error bits in each parity column and an even number of error bits in each spiral.c. It is too simple to be used as a secure hash function; finding multiple messages with the same hash function would be too easy.3.2 Suppose H (m) is a collision resistant hash function that maps a message of arbitrary bit length into an n-bit hash value. Is it true that, for all messages x, x’ with x≠x’,we have H(x)≠H(x’)?Explain your answer.The statement is false. Such a function cannot be one-to-one because the number of inputs to the function is of arbitrary, but the number of unique outputs is 2n. Thus, there are multiple inputs that map into the same output.3.3 Perform encryption and decryption using the RSA algorithm, as in Figture3.9, for the following:a. p=3;q=11;e=7;M=5b. p=5;q=11;e=3;M=9c. p=7;q=11;e=17;M=8d. p=11;q=13;e=11;M=7e. p=17;q=31;e=7;M=2.Hint: D ecryption is not as hard as you think; use some finesse.a. n = 33; ⎫(n) = 20; d = 3; C = 26.b. n = 55; ⎫(n) = 40; d = 27; C = 14.c. n = 77; ⎫(n) = 60; d = 53; C = 57.d. n = 143; ⎫(n) = 120; d = 11; C = 106.e. n = 527; ⎫(n) = 480; d = 343; C = 128. For decryption, we have128343 mod 527 = 128256 ⋅ 12864 ⋅ 12816 ⋅ 1284 ⋅ 1282 ⋅ 1281 mod 527= 35 ⋅ 256 ⋅ 35 ⋅ 101 ⋅ 47 ⋅ 128 = 2 mod 527= 2 mod 2573.4 In a public-key system using RSA, you intercept the cipher text C=10 sent to a user whose public key is e=5, n=35.What is the plaintext M?M = 53.5 In an RSA system, the public key of a given user is e=31,n=3599.What is the private key of this user?d = 30313.6 Suppose we have a set of blocks encoded with the RSA algorithm and we don’t have the private key, Assume n=pq, e is the public key. Suppose also someone tells us they know one of the plaintext blocks has a common factor with n. Does this help us in any way?Yes. If a plaintext block has a common factor with n modulo n then the encoded block will also have a common factor with n modulo n. Because we encode blocks that are smaller than pq, the factor must be p or q and the plaintext block must be a multiple of p or q. We can test each block for primality. If prime, it is p or q. In this case we divide into n to find the other factor. If not prime, we factor it and try the factors as divisors of n.3.7 Consider a Diffie-Hellman scheme with a common prime q=11 and a primitive root a=2.a. If user A has public key YA=9, what is A’s private key XA?b. If user B has public key YB=3, what is the shared secret key K?a. XA = 6b. K = 3Chapter 4 Authentication ApplicationsANSWERS NSWERS TO QUESTIONS4.1 What problem was Kerberos designed to address?The problem that Kerberos addresses is this: Assume an open distributed environment in which users at workstations wish to access services on servers distributed throughout the network. We would like for servers to be able to restrict access to authorized users and to be able to authenticate requests for service. In this environment, a workstation cannot be trusted to identify its users correctly to network services.4.2 What are three threats associated with user authentication over a network or Internet?A user may gain access to a particular workstation and pretend to be another user operating from that workstation. 2. A user may alter the network address of a workstation so that the requests sent from the altered workstation appear to come from the impersonated workstation. 3. A user may eavesdrop on exchanges and use a replay attack to gain entrance to a server or to disrupt operations.4.3 List three approaches to secure user authentication in a distributed environment.Rely on each individual client workstation to assure the identity of its user or users and rely on each server to enforce a security policy based on user identification (ID). 2. Require that client systems authenticate themselves to servers, but trust the client system concerning the identity of its user. 3. Require the user to prove identity for each service invoked. Also require that servers prove their identity to clients.4.4 What four requirements are defined for Kerberos?Secure: A network eavesdropper should not be able to obtain the necessary information to impersonate a user. More generally, Kerberos should be strong enough that a potential opponent does not find it to be the weak link. Reliable: For all services that rely on Kerberos for access control, lack of availability of the Kerberos service means lack of availability of the supported services. Hence, Kerberos should be highly reliable and should employ a distributed server architecture, with one system able to back up another. Transparent: Ideally, the user should not be aware that authentication is taking place, beyond the requirement to enter a password. Scalable: The system should be capable of supporting large numbers of clients and servers. This suggests a modular, distributed architecture.4.5 What entities constitute a full-service Kerberos environment?A full-service Kerberos environment consists of a Kerberos server, a number of clients, and a number of application servers.4.6 In the context of Kerberos, what is a realm?A realm is an environment in which: 1. The Kerberos server must have the user ID (UID) and hashed password of all participating users in its database. All users are registered with the Kerberos server. 2. The Kerberos server must share a secret key with each server. All servers are registered with the Kerberos server.4.7 What are the principal difference between version 4 and version 5 of Kerberos?Version 5 overcomes some environmental shortcomings and some technical deficiencies in Version 4.4.8 What is the purpose of the X.509 standard?X.509 defines a framework for the provision of authentication services by the X.500 directory to its users. The directory may serve as a repository of public-key certificates. Each certificate contains the public key of a user and is signed with the private key of a trusted certification authority. In addition,X.509 defines alternative authentication protocols based on the use of public-key certificates.4.9 What is a chain of certificates?A chain of certificates consists of a sequence of certificates created by different certification authorities (CAs) in which each successive certificate is a certificate by one CA that certifies the public key of the next CA in the chain.4.10 How is an X.509 certificate revoked?The owner of a public-key can issue a certificate revocation list that revokes one or more certificates.ANSWERS NSWERS TO PROBLEMS4.1 Show that a random error in block of cipher text is propagated to all subsequent blocks of plaintext in PCBC mode (Figure 4.9).An error in C1 affects P1 because the encryption of C1 is XORed with IV to produceP1. Both C1 and P1 affect P2, which is the XOR of the encryption of C2 with the XOR of C1 and P1. Beyond that, P N–1 is one of the XORed inputs to forming P N.4.2 The 1988 version of X.509 lists properties that PSA keys must satisfy to be secure, given current knowledge about the difficulty of factoring large numbers. The discussion concludes with a constraint on the public exponent and the modulus n: It must be ensured that e>log2 (n) to prevent attack by taking the eth root mod n to disclose the plaintext. Although the constraint is correct, the reason given for requiring it is incorrect. What is wrong with the reason given and what is the correct reason?Taking the eth root mod n of a ciphertext block will always reveal the plaintext, no matter what the values of e and n are. In general this is a very difficult problem, and indeed is the reason why RSA is secure. The point is that, if e istoo small, then taking the normal integer eth root will be the same as taking the eth root mod n, and taking integer eth roots is relatively easy.Chapter 5 Electronic Mail SecurityANSWERS NSWERS TO QUESTIONS5.1 What are the five principal services provided by PGP? Authentication, confidentiality, compression, e-mail compatibility, and segmentation5.2 What is the utility of a detached signature?A detached signature is useful in several contexts. A user may wish to maintain a separate signature log of all messages sent or received. A detached signature of an executable program can detect subsequent virus infection. Finally, detached signatures can be used when more than one party must sign a document, such as a legal contract. Each person's signature is independent and therefore is applied only to the document. Otherwise, signatures would have to be nested, with the second signer signing both the document and the first signature, and so on.5.3 Why does PGP generate a signature before applying compression?a. It is preferable to sign an uncompressed message so that one can store only the uncompressed message together with the signature for future verification. If one signed a compressed document, then it would be necessary either to store a compressed version of the message for later verification or to recompress the message when verification is required.b. Even if one were willing to generate dynamically a recompressed message for verification, PGP's compression algorithm presents a difficulty. The algorithm is not deterministic; various implementations of the algorithm achieve different tradeoffs in running speed versus compression ratio and, as a result, produce different compressed forms. However, these different compression algorithms are interoperable because any version of the algorithm can correctly decompress the output of any other version. Applying the hash function and signature after compression would constrain all PGP implementations to the same version of the compression algorithm.5.4 What is R64conversion?R64 converts a raw 8-bit binary stream to a stream of printable ASCII characters. Each group of three octets of binary data is mapped into four ASCII characters.5.5 Why is R64 conversion useful for an e-mail application?When PGP is used, at least part of the block to be transmitted is encrypted. If only the signature service is used, then the message digest is encrypted (with the sender's private key). If the confidentiality service is used, the message plus signature (if present) are encrypted (with a one-time symmetric key). Thus, part or all of the resulting block consists of a stream of arbitrary 8-bit octets. However, many electronic mail systems only permit the use of blocks consisting of ASCII text.5.6 Why is the segmentation and reassembly function in PGP needed? E-mail facilities often are restricted to a maximum message length.5.7 How does PGP use the concept of trust?PGP includes a facility for assigning a level of trust to individual signers and to keys.5.8 What is RFC822?RFC 822 defines a format for text messages that are sent using electronic mail.5.9 What is MIME?MIME is an extension to the RFC 822 framework that is intended to address some of the problems and limitations of the use of SMTP (Simple Mail Transfer Protocol) or some other mail transfer protocol and RFC 822 for electronic mail.5.10 What is S/MIME?S/MIME (Secure/Multipurpose Internet Mail Extension) is a security enhancement to the MIME Internet e-mail format standard, based on technology from RSA Data Security.ANSWERS NSWERS TO PROBLEMS5.1 In the PGP scheme, what is the expected number of session keys generated before a previously created key is produced?This is just another form of the birthday paradox discussed in Appendix 11A. Let us state the problem as one of determining what number of session keys must be generated so that the probability of a duplicate is greater than 0.5. From Equation (11.6) in Appendix 11A, we have the approximation:k =1.18 ⋅ nFor a 128-bit key, there are 2128 possible keys. Thereforek =1.18 ⋅ 2128 =1.18 ⋅ 2645.2 The first 16 bits of the message digest in a PGP signature are translated in the clear.a. To what extent does this compromise the security of the hash algorithm?b. To what extent does it in fact perform its intended function, namely, to help determine if the correct RSA key was used to decrypt the digest?a. Not at all. The message digest is encrypted with the sender's private key. Therefore, anyone in possession of the public key can decrypt it and recover the entire message digest.b. The probability that a message digest decrypted with the wrong key would have an exact match in the first 16 bits with the original message digest is 2–16.5.3 In Figure 5.4, each entry in the public-key ring contains an owner trust field that indicates the degree of trust associated with this public-key owner. Why is that not enough? That is, if this owner is trusted and this is supposed to be the owner’s public key, why is no t that trust enough to permit PGP to use this public key?We trust this owner, but that does not necessarily mean that we can trust that we are in possession of that owner's public key.5.4 Consider radix-64 conversion as a form of encryption. In this case, there is no key. But suppose that an opponent knew only that some form of substitution algorithm was being used to encrypt English textand did not guess it was R64. How effective would this algorithm be against cryptanalysis?It certainly provides more security than a monoalphabetic substitution. Because we are treating the plaintext as a string of bits and encrypting 6 bitsat a time, we are not encrypting individual characters. Therefore, the frequency information is lost, or at least significantly obscured.5.5 Phil Zimmermann chose IDEA, three-key triple DES, and CAST-128as symmetric encryption algorithms for PGP.Give reasons why each of the following symmetric encryption algorithms for described in thisbook is suitable or unsuitable for PGP: DES, two-key triple DES, and AES.DES is unsuitable because of its short key size. Two-key triple DES, which has a key length of 112 bits, is suitable. AES is also suitable.Chapter 6 IP SecurityANSWERS NSWERS TO QUESTIONS6.1 Give examples of applications of IPSec.Secure branch office connectivity over the Internet: A company can build a secure virtual private network over the Internet or over a public WAN. This enables a business to rely heavily on the Internet and reduce its need for private networks, saving costs and network management overhead. Secure remote access over the Internet: An end user whose system is equipped with IP security protocols can make a local call to an Internet service provider (ISP) and gain secure access to a company network. This reduces the cost of toll charges for traveling employees and telecommuters. Establishing extranetand intranet connectivity with partners: IPSec can be used to secure communication with other organizations, ensuring authentication and confidentiality and providing a key exchange mechanism. Enhancing electronic commerce security: Even though some Web and electronic commerce applications have built-in security protocols, the use of IPSec enhances that security.6.2 What service are provided by IPSec?。
邮件格式不符合rfc标准。
邮件格式不符合rfc标准。
RFC(Request for Comments)是一系列文件,定义了互联网协议和相关标准。
RFC标准旨在确保互联网技术和协议的互操作性和一致性。
当说一个邮件格式不符合RFC标准时,通常是指该邮件的结构、标头、内容或其他方面存在不符合RFC标准的问题。
这可能包括以下一些常见的问题:
1. 缺少或错误的邮件标头字段:RFC标准规定了一组必需的和可选的邮件标头字段,如"From"、"To"、"Subject"等。
如果邮件缺少必需的字段或者字段的格式不正确,就不符合RFC标准。
2. 邮件内容格式错误:RFC标准还定义了邮件内容的格式规范,如纯文本格式、HTML格式等。
如果邮件内容格式不符合规范,可能导致解析或显示问题。
3. 邮件大小限制:RFC标准对于邮件的大小有一定的限制,超过限制可能导致邮件被拒收或传输过程中出现问题。
4. 邮件编码问题:RFC标准规定了邮件的编码方式,如ASCII 编码、UTF-8编码等。
如果邮件的编码方式与标准不符,可能导致乱码或无法正确解析邮件内容。
总之,符合RFC标准的邮件格式是确保邮件能够在各个邮件系统之间正确传递和解析的重要因素。
如果邮件格式不符合RFC标准,可能会导致邮件无法正常发送、被拒收或无法正确显示。
因此,在编写和发送邮件时,遵循RFC标准是十分重要的。
- 1、下载文档前请自行甄别文档内容的完整性,平台不提供额外的编辑、内容补充、找答案等附加服务。
- 2、"仅部分预览"的文档,不可在线预览部分如存在完整性等问题,可反馈申请退款(可完整预览的文档不适用该条件!)。
- 3、如文档侵犯您的权益,请联系客服反馈,我们会尽快为您处理(人工客服工作时间:9:00-18:30)。
Network Working Group E. Rescorla Request for Comments: 3552 RTFM, Inc. BCP: 72 B. Korver Category: Best Current Practice Xythos Software Internet Architecture Board IAB July 2003 Guidelines for Writing RFC Text on Security ConsiderationsStatus of this MemoThis document specifies an Internet Best Current Practices for theInternet Community, and requests discussion and suggestions forimprovements. Distribution of this memo is unlimited.Copyright NoticeCopyright (C) The Internet Society (2003). All Rights Reserved.AbstractAll RFCs are required to have a Security Considerations section.Historically, such sections have been relatively weak. This document provides guidelines to RFC authors on how to write a good SecurityConsiderations section.Table of Contents1. Introduction . . . . . . . . . . . . . . . . . . . . . . . 31.1. Requirements. . . . . . . . . . . . . . . . . . . . . 32. The Goals of Security. . . . . . . . . . . . . . . . . . . 32.1. Communication Security. . . . . . . . . . . . . . . . 32.1.1. Confidentiality. . . . . . . . . . . . . . . . 42.1.2. Data Integrity . . . . . . . . . . . . . . . . 42.1.3. Peer Entity authentication . . . . . . . . . . 42.2. Non-Repudiation . . . . . . . . . . . . . . . . . . . 52.3. Systems Security. . . . . . . . . . . . . . . . . . . 52.3.1. Unauthorized Usage . . . . . . . . . . . . . . 62.3.2. Inappropriate Usage. . . . . . . . . . . . . . 62.3.3. Denial of Service. . . . . . . . . . . . . . . 63. The Internet Threat Model. . . . . . . . . . . . . . . . . 63.1. Limited Threat Models . . . . . . . . . . . . . . . . 73.2. Passive Attacks . . . . . . . . . . . . . . . . . . . 73.2.1. Confidentiality Violations . . . . . . . . . . 83.2.2. Password Sniffing. . . . . . . . . . . . . . . 83.2.3. Offline Cryptographic Attacks. . . . . . . . . 9 Rescorla & Korver Best Current Practice [Page 1]3.3. Active Attacks. . . . . . . . . . . . . . . . . . . . 93.3.1. Replay Attacks . . . . . . . . . . . . . . . . 103.3.2. Message Insertion. . . . . . . . . . . . . . . 103.3.3. Message Deletion . . . . . . . . . . . . . . . 113.3.4. Message Modification . . . . . . . . . . . . . 113.3.5. Man-In-The-Middle. . . . . . . . . . . . . . . 123.4. Topological Issues. . . . . . . . . . . . . . . . . . 123.5. On-path versus off-path . . . . . . . . . . . . . . . 133.6. Link-local. . . . . . . . . . . . . . . . . . . . . . 134. Common Issues. . . . . . . . . . . . . . . . . . . . . . . 134.1. User Authentication . . . . . . . . . . . . . . . . . 144.1.1. Username/Password. . . . . . . . . . . . . . . 144.1.2. Challenge Response and One Time Passwords. . . 144.1.3. Shared Keys. . . . . . . . . . . . . . . . . . 154.1.4. Key Distribution Centers . . . . . . . . . . . 154.1.5. Certificates . . . . . . . . . . . . . . . . . 154.1.6. Some Uncommon Systems. . . . . . . . . . . . . 154.1.7. Host Authentication. . . . . . . . . . . . . . 164.2. Generic Security Frameworks . . . . . . . . . . . . . 164.3. Non-repudiation . . . . . . . . . . . . . . . . . . . 174.4. Authorization vs. Authentication. . . . . . . . . . . 184.4.1. Access Control Lists . . . . . . . . . . . . . 184.4.2. Certificate Based Systems. . . . . . . . . . . 184.5. Providing Traffic Security. . . . . . . . . . . . . . 194.5.1. IPsec. . . . . . . . . . . . . . . . . . . . . 194.5.2. SSL/TLS. . . . . . . . . . . . . . . . . . . . 204.5.3. Remote Login . . . . . . . . . . . . . . . . . 224.6. Denial of Service Attacks and Countermeasures . . . . 224.6.1. Blind Denial of Service. . . . . . . . . . . . 234.6.2. Distributed Denial of Service. . . . . . . . . 234.6.3. Avoiding Denial of Service . . . . . . . . . . 244.6.4. Example: TCP SYN Floods. . . . . . . . . . . . 244.6.5. Example: Photuris. . . . . . . . . . . . . . . 254.7. Object vs. Channel Security . . . . . . . . . . . . . 254.8. Firewalls and Network Topology. . . . . . . . . . . . 265. Writing Security Considerations Sections . . . . . . . . . 266. Examples . . . . . . . . . . . . . . . . . . . . . . . . . 286.1. SMTP. . . . . . . . . . . . . . . . . . . . . . . . . 296.1.1. Security Considerations. . . . . . . . . . . . 296.1.2. Communications security issues . . . . . . . . 346.1.3. Denial of Service. . . . . . . . . . . . . . . 366.2. VRRP. . . . . . . . . . . . . . . . . . . . . . . . . .366.2.1. Security Considerations. . . . . . . . . . . . 367. Acknowledgments. . . . . . . . . . . . . . . . . . . . . . 388. Normative References . . . . . . . . . . . . . . . . . . . 399. Informative References . . . . . . . . . . . . . . . . . . 4110.Security Considerations. . . . . . . . . . . . . . . . . . 42Appendix A. . . . . . . . . . . . . . . . . . . . . . . . . . 43 Rescorla & Korver Best Current Practice [Page 2]Authors’ Addresses. . . . . . . . . . . . . . . . . . . . . . 43Full Copyright Statement. . . . . . . . . . . . . . . . . . . 441. IntroductionAll RFCs are required by RFC 2223 to contain a SecurityConsiderations section. The purpose of this is both to encouragedocument authors to consider security in their designs and to inform the reader of relevant security issues. This memo is intended toprovide guidance to RFC authors in service of both ends.This document is structured in three parts. The first is acombination security tutorial and definition of common terms; thesecond is a series of guidelines for writing Security Considerations; the third is a series of examples.1.1. RequirementsThe key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT","SHOULD", "SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this document are to be interpreted as described in BCP 14, RFC 2119[KEYWORDS].2. The Goals of SecurityMost people speak of security as if it were a single monolithicproperty of a protocol or system, however, upon reflection, onerealizes that it is clearly not true. Rather, security is a seriesof related but somewhat independent properties. Not all of theseproperties are required for every application.We can loosely divide security goals into those related to protecting communications (COMMUNICATION SECURITY, also known as COMSEC) andthose relating to protecting systems (ADMINISTRATIVE SECURITY orSYSTEM SECURITY). Since communications are carried out by systemsand access to systems is through communications channels, these goals obviously interlock, but they can also be independently provided.2.1. Communication SecurityDifferent authors partition the goals of communication securitydifferently. The partitioning we’ve found most useful is to dividethem into three major categories: CONFIDENTIALITY, DATA INTEGRITY and PEER ENTITY AUTHENTICATION.Rescorla & Korver Best Current Practice [Page 3]2.1.1. ConfidentialityWhen most people think of security, they think of CONFIDENTIALITY.Confidentiality means that your data is kept secret from unintendedlisteners. Usually, these listeners are simply eavesdroppers. When an adversary taps your phone, it poses a risk to yourconfidentiality.Obviously, if you have secrets, then you are probably concerned about others discovering them. Thus, at the very least, you want tomaintain confidentiality. When you see spies in the movies go intothe bathroom and turn on all the water to foil bugging, the property they’re looking for is confidentiality.2.1.2. Data IntegrityThe second primary goal is DATA INTEGRITY. The basic idea here isthat we want to make sure that the data we receive is the same datathat the sender has sent. In paper-based systems, some dataintegrity comes automatically. When you receive a letter written in pen you can be fairly certain that no words have been removed by anattacker because pen marks are difficult to remove from paper.However, an attacker could have easily added some marks to the paper and completely changed the meaning of the message. Similarly, it’seasy to shorten the page to truncate the message.On the other hand, in the electronic world, since all bits lookalike, it’s trivial to tamper with messages in transit. You simplyremove the message from the wire, copy out the parts you like, addwhatever data you want, and generate a new message of your choosing, and the recipient is no wiser. This is the moral equivalent of theattacker taking a letter you wrote, buying some new paper andrecopying the message, changing it as he does it. It’s just a loteasier to do electronically since all bits look alike.2.1.3. Peer Entity authenticationThe third property we’re concerned with is PEER ENTITYAUTHENTICATION. What we mean by this is that we know that one of the endpoints in the communication is the one we intended. Without peer entity authentication, it’s very difficult to provide eitherconfidentiality or data integrity. For instance, if we receive amessage from Alice, the property of data integrity doesn’t do us much good unless we know that it was in fact sent by Alice and not theattacker. Similarly, if we want to send a confidential message toBob, it’s not of much value to us if we’re actually sending aconfidential message to the attacker.Rescorla & Korver Best Current Practice [Page 4]Note that peer entity authentication can be provided asymmetrically. When you call someone on the phone, you can be fairly certain thatyou have the right person -- or at least that you got a person who’s actually at the phone number you called. On the other hand, if they don’t have caller ID, then the receiver of a phone call has no ideawho’s calling them. Calling someone on the phone is an example ofrecipient authentication, since you know who the recipient of thecall is, but they don’t know anything about the sender.In messaging situations, you often wish to use peer entityauthentication to establish the identity of the sender of a certainmessage. In such contexts, this property is called DATA ORIGINAUTHENTICATION.2.2. Non-RepudiationA system that provides endpoint authentication allows one party to be certain of the identity of someone with whom he is communicating.When the system provides data integrity a receiver can be sure ofboth the sender’s identity and that he is receiving the data thatthat sender meant to send. However, he cannot necessarilydemonstrate this fact to a third party. The ability to make thisdemonstration is called NON-REPUDIATION.There are many situations in which non-repudiation is desirable.Consider the situation in which two parties have signed a contractwhich one party wishes to unilaterally abrogate. He might simplyclaim that he had never signed it in the first place. Non-repudiation prevents him from doing so, thus protecting thecounterparty.Unfortunately, non-repudiation can be very difficult to achieve inpractice and naive approaches are generally inadequate. Section 4.3 describes some of the difficulties, which generally stem from thefact that the interests of the two parties are not aligned -- oneparty wishes to prove something that the other party wishes to deny.2.3. Systems SecurityIn general, systems security is concerned with protecting one’smachines and data. The intent is that machines should be used onlyby authorized users and for the purposes that the owners intend.Furthermore, they should be available for those purposes. Attackers should not be able to deprive legitimate users of resources.Rescorla & Korver Best Current Practice [Page 5]2.3.1. Unauthorized UsageMost systems are not intended to be completely accessible to thepublic. Rather, they are intended to be used only by certainauthorized individuals. Although many Internet services areavailable to all Internet users, even those servers generally offer a larger subset of services to specific users. For instance, WebServers often will serve data to any user, but restrict the abilityto modify pages to specific users. Such modifications by the general public would be UNAUTHORIZED USAGE.2.3.2. Inappropriate UsageBeing an authorized user does not mean that you have free run of the system. As we said above, some activities are restricted toauthorized users, some to specific users, and some activities aregenerally forbidden to all but administrators. Moreover, evenactivities which are in general permitted might be forbidden in some cases. For instance, users may be permitted to send email butforbidden from sending files above a certain size, or files whichcontain viruses. These are examples of INAPPROPRIATE USAGE.2.3.3. Denial of ServiceRecall that our third goal was that the system should be available to legitimate users. A broad variety of attacks are possible whichthreaten such usage. Such attacks are collectively referred to asDENIAL OF SERVICE attacks. Denial of service attacks are often very easy to mount and difficult to stop. Many such attacks are designed to consume machine resources, making it difficult or impossible toserve legitimate users. Other attacks cause the target machine tocrash, completely denying service to users.3. The Internet Threat ModelA THREAT MODEL describes the capabilities that an attacker is assumed to be able to deploy against a resource. It should contain suchinformation as the resources available to an attacker in terms ofinformation, computing capability, and control of the system. Thepurpose of a threat model is twofold. First, we wish to identify the threats we are concerned with. Second, we wish to rule some threats explicitly out of scope. Nearly every security system is vulnerable to a sufficiently dedicated and resourceful attacker.The Internet environment has a fairly well understood threat model.In general, we assume that the end-systems engaging in a protocolexchange have not themselves been compromised. Protecting against an attack when one of the end-systems has been compromised isRescorla & Korver Best Current Practice [Page 6]extraordinarily difficult. It is, however, possible to designprotocols which minimize the extent of the damage done under thesecircumstances.By contrast, we assume that the attacker has nearly complete control of the communications channel over which the end-systems communicate. This means that the attacker can read any PDU (Protocol Data Unit) on the network and undetectably remove, change, or inject forged packets onto the wire. This includes being able to generate packets thatappear to be from a trusted machine. Thus, even if the end-systemwith which you wish to communicate is itself secure, the Internetenvironment provides no assurance that packets which claim to be from that system in fact are.It’s important to realize that the meaning of a PDU is different atdifferent levels. At the IP level, a PDU means an IP packet. At the TCP level, it means a TCP segment. At the application layer, itmeans some kind of application PDU. For instance, at the level ofemail, it might either mean an RFC-822 message or a single SMTPcommand. At the HTTP level, it might mean a request or response.3.1. Limited Threat ModelsAs we’ve said, a resourceful and dedicated attacker can control theentire communications channel. However, a large number of attackscan be mounted by an attacker with fewer resources. A number ofcurrently known attacks can be mounted by an attacker with limitedcontrol of the network. For instance, password sniffing attacks can be mounted by an attacker who can only read arbitrary packets. This is generally referred to as a PASSIVE ATTACK [INTAUTH].By contrast, Morris’ sequence number guessing attack [SEQNUM] can be mounted by an attacker who can write but not read arbitrary packets. Any attack which requires the attacker to write to the network isknown as an ACTIVE ATTACK.Thus, a useful way of organizing attacks is to divide them based onthe capabilities required to mount the attack. The rest of thissection describes these categories and provides some examples of each category.3.2. Passive AttacksIn a passive attack, the attacker reads packets off the network butdoes not write them. The simplest way to mount such an attack is to simply be on the same LAN as the victim. On most common LANconfigurations, including Ethernet, 802.3, and FDDI, any machine onthe wire can read all traffic destined for any other machine on the Rescorla & Korver Best Current Practice [Page 7]same LAN. Note that switching hubs make this sort of sniffingsubstantially more difficult, since traffic destined for a machineonly goes to the network segment which that machine is on.Similarly, an attacker who has control of a host in thecommunications path between two victim machines is able to mount apassive attack on their communications. It is also possible tocompromise the routing infrastructure to specifically arrange thattraffic passes through a compromised machine. This might involve an active attack on the routing infrastructure to facilitate a passiveattack on a victim machine.Wireless communications channels deserve special consideration,especially with the recent and growing popularity of wireless-basedLANs, such as those using 802.11. Since the data is simply broadcast on well known radio frequencies, an attacker simply needs to be able to receive those transmissions. Such channels are especiallyvulnerable to passive attacks. Although many such channels includecryptographic protection, it is often of such poor quality as to benearly useless [WEP].In general, the goal of a passive attack is to obtain informationwhich the sender and receiver would prefer to remain private. Thisprivate information may include credentials useful in the electronic world and/or passwords or credentials useful in the outside world,such as confidential business information.3.2.1. Confidentiality ViolationsThe classic example of passive attack is sniffing some inherentlyprivate data off of the wire. For instance, despite the wideavailability of SSL, many credit card transactions still traverse the Internet in the clear. An attacker could sniff such a message andrecover the credit card number, which can then be used to makefraudulent transactions. Moreover, confidential business information is routinely transmitted over the network in the clear in email.3.2.2. Password SniffingAnother example of a passive attack is PASSWORD SNIFFING. Passwordsniffing is directed towards obtaining unauthorized use of resources. Many protocols, including [TELNET], [POP], and [NNTP] use a sharedpassword to authenticate the client to the server. Frequently, this password is transmitted from the client to the server in the clearover the communications channel. An attacker who can read thistraffic can therefore capture the password and REPLAY it. In otherwords, the attacker can initiate a connection to the server and pose as the client and login using the captured password.Rescorla & Korver Best Current Practice [Page 8]Note that although the login phase of the attack is active, theactual password capture phase is passive. Moreover, unless theserver checks the originating address of connections, the login phase does not require any special control of the network.3.2.3. Offline Cryptographic AttacksMany cryptographic protocols are subject to OFFLINE ATTACKS. In such a protocol, the attacker recovers data which has been processed using the victim’s secret key and then mounts a cryptanalytic attack onthat key. Passwords make a particularly vulnerable target becausethey are typically low entropy. A number of popular password-basedchallenge response protocols are vulnerable to DICTIONARY ATTACK.The attacker captures a challenge-response pair and then proceeds to try entries from a list of common words (such as a dictionary file)until he finds a password that produces the right response.A similar such attack can be mounted on a local network when NIS isused. The Unix password is crypted using a one-way function, buttools exist to break such crypted passwords [KLEIN]. When NIS isused, the crypted password is transmitted over the local network and an attacker can thus sniff the password and attack it.Historically, it has also been possible to exploit small operatingsystem security holes to recover the password file using an activeattack. These holes can then be bootstrapped into an actual account by using the aforementioned offline password recovery techniques.Thus we combine a low-level active attack with an offline passiveattack.3.3. Active AttacksWhen an attack involves writing data to the network, we refer to this as an ACTIVE ATTACK. When IP is used without IPsec, there is noauthentication for the sender address. As a consequence, it’sstraightforward for an attacker to create a packet with a sourceaddress of his choosing. We’ll refer to this as a SPOOFING ATTACK.Under certain circumstances, such a packet may be screened out by the network. For instance, many packet filtering firewalls screen outall packets with source addresses on the INTERNAL network that arrive on the EXTERNAL interface. Note, however, that this provides noprotection against an attacker who is inside the firewall. Ingeneral, designers should assume that attackers can forge packets. Rescorla & Korver Best Current Practice [Page 9]However, the ability to forge packets does not go hand in hand withthe ability to receive arbitrary packets. In fact, there are active attacks that involve being able to send forged packets but notreceive the responses. We’ll refer to these as BLIND ATTACKS.Note that not all active attacks require forging addresses. Forinstance, the TCP SYN denial of service attack [TCPSYN] can bemounted successfully without disguising the sender’s address.However, it is common practice to disguise one’s address in order to conceal one’s identity if an attack is discovered.Each protocol is susceptible to specific active attacks, butexperience shows that a number of common patterns of attack can beadapted to any given protocol. The next sections describe a numberof these patterns and give specific examples of them as applied toknown protocols.3.3.1. Replay AttacksIn a REPLAY ATTACK, the attacker records a sequence of messages offof the wire and plays them back to the party which originallyreceived them. Note that the attacker does not need to be able tounderstand the messages. He merely needs to capture and retransmitthem.For example, consider the case where an S/MIME message is being used to request some service, such as a credit card purchase or a stocktrade. An attacker might wish to have the service executed twice, if only to inconvenience the victim. He could capture the message andreplay it, even though he can’t read it, causing the transaction tobe executed twice.3.3.2. Message InsertionIn a MESSAGE INSERTION attack, the attacker forges a message withsome chosen set of properties and injects it into the network. Often this message will have a forged source address in order to disguisethe identity of the attacker.For example, a denial-of-service attack can be mounted by inserting a series of spurious TCP SYN packets directed towards the target host. The target host responds with its own SYN and allocates kernel datastructures for the new connection. The attacker never completes the 3-way handshake, so the allocated connection endpoints just sit there taking up kernel memory. Typical TCP stack implementations only Rescorla & Korver Best Current Practice [Page 10]allow some limited number of connections in this "half-open" stateand when this limit is reached, no more connections can be initiated, even from legitimate hosts. Note that this attack is a blind attack, since the attacker does not need to process the victim’s SYNs.3.3.3. Message DeletionIn a MESSAGE DELETION attack, the attacker removes a message from the wire. Morris’ sequence number guessing attack [SEQNUM] oftenrequires a message deletion attack to be performed successfully. In this blind attack, the host whose address is being forged willreceive a spurious TCP SYN packet from the host being attacked.Receipt of this SYN packet generates a RST, which would tear theillegitimate connection down. In order to prevent this host fromsending a RST so that the attack can be carried out successfully,Morris describes flooding this host to create queue overflows suchthat the SYN packet is lost and thus never responded to.3.3.4. Message ModificationIn a MESSAGE MODIFICATION attack, the attacker removes a message from the wire, modifies it, and reinjects it into the network. This sort of attack is particularly useful if the attacker wants to send someof the data in the message but also wants to change some of it.Consider the case where the attacker wants to attack an order forgoods placed over the Internet. He doesn’t have the victim’s credit card number so he waits for the victim to place the order and thenreplaces the delivery address (and possibly the goods description)with his own. Note that this particular attack is known as a CUT-AND-PASTE attack since the attacker cuts the credit card number outof the original message and pastes it into the new message.Another interesting example of a cut-and-paste attack is provided by [IPSPPROB]. If IPsec ESP is used without any MAC then it is possible for the attacker to read traffic encrypted for a victim on the samemachine. The attacker attaches an IP header corresponding to a port he controls onto the encrypted IP packet. When the packet isreceived by the host it will automatically be decrypted and forwarded to the attacker’s port. Similar techniques can be used to mount asession hijacking attack. Both of these attacks can be avoided byalways using message authentication when you use encryption. Notethat this attack only works if (1) no MAC check is being used, since this attack generates damaged packets (2) a host-to-host SA is being used, since a user-to-user SA will result in an inconsistency between the port associated with the SA and the target port. If thereceiving machine is single-user than this attack is infeasible. Rescorla & Korver Best Current Practice [Page 11]3.3.5. Man-In-The-MiddleA MAN-IN-THE-MIDDLE attack combines the above techniques in a special form: The attacker subverts the communication stream in order to pose as the sender to receiver and the receiver to the sender:What Alice and Bob think:Alice <----------------------------------------------> BobWhat’s happening:Alice <----------------> Attacker <----------------> BobThis differs fundamentally from the above forms of attack because it attacks the identity of the communicating parties, rather than thedata stream itself. Consequently, many techniques which provideintegrity of the communications stream are insufficient to protectagainst man-in-the-middle attacks.Man-in-the-middle attacks are possible whenever a protocol lacks PEER ENTITY AUTHENTICATION. For instance, if an attacker can hijack theclient TCP connection during the TCP handshake (perhaps by responding to the client’s SYN before the server does), then the attacker canopen another connection to the server and begin a man-in-the-middleattack. It is also trivial to mount man-in-the-middle attacks onlocal networks via ARP spoofing -- the attacker forges an ARP withthe victim’s IP address and his own MAC address. Tools to mount this sort of attack are readily available.Note that it is only necessary to authenticate one side of thetransaction in order to prevent man-in-the-middle attacks. In such a situation the the peers can establish an association in which onlyone peer is authenticated. In such a system, an attacker caninitiate an association posing as the unauthenticated peer but cannot transmit or access data being sent on a legitimate connection. This is an acceptable situation in contexts such as Web e-commerce whereonly the server needs to be authenticated (or the client isindependently authenticated via some non-cryptographic mechanism such as a credit card number).3.4. Topological IssuesIn practice, the assumption that it’s equally easy for an attacker to read and generate all packets is false, since the Internet is notfully connected. This has two primary implications.Rescorla & Korver Best Current Practice [Page 12]。