Network Working Group                                      J. Rosenberg
Request for Comments: 2762                                  dynamicsoft
Category: Experimental                                   H. Schulzrinne
                                                            Columbia U.
                                                          February 2000
        
Network Working Group                                      J. Rosenberg
Request for Comments: 2762                                  dynamicsoft
Category: Experimental                                   H. Schulzrinne
                                                            Columbia U.
                                                          February 2000
        

Sampling of the Group Membership in RTP

RTP中组成员的抽样

Status of this Memo

本备忘录的状况

This memo defines an Experimental Protocol for the Internet community. It does not specify an Internet standard of any kind. Discussion and suggestions for improvement are requested. Distribution of this memo is unlimited.

这份备忘录为互联网社区定义了一个实验性协议。它没有规定任何类型的互联网标准。要求进行讨论并提出改进建议。本备忘录的分发不受限制。

Copyright Notice

版权公告

Copyright (C) The Internet Society (2000). All Rights Reserved.

版权所有(C)互联网协会(2000年)。版权所有。

Abstract

摘要

In large multicast groups, the size of the group membership table maintained by RTP (Real Time Transport Protocol) participants may become unwieldy, particularly for embedded devices with limited memory and processing power. This document discusses mechanisms for sampling of this group membership table in order to reduce the memory requirements. Several mechanisms are proposed, and the performance of each is considered.

在大型多播组中,由RTP(实时传输协议)参与者维护的组成员表的大小可能会变得难以控制,特别是对于内存和处理能力有限的嵌入式设备。本文档讨论此组成员资格表的采样机制,以减少内存需求。提出了几种机制,并考虑了每种机制的性能。

1 Introduction

1导言

RTP, the Real Time Transport Protocol [1], mandates that RTCP packets be transmitted from each participant with a period roughly proportional to the group size. The group size is obtained by storing a table, containing an entry for each unique SSRC seen in RTP and RTCP packets. As members leave or time out, entries are deleted, and as new members join, entries are added. The table is thus highly dynamic.

RTP,即实时传输协议[1],要求从每个参与者传输RTCP数据包,传输周期大致与组大小成比例。通过存储一个表来获得组大小,该表包含RTP和RTCP数据包中每个唯一SSRC的条目。当成员离开或超时时,条目将被删除,而当新成员加入时,条目将被添加。因此,表格是高度动态的。

For large multicast sessions, such as an mbone broadcast or IP-based TV distribution, group sizes can be extremely large, on the order of hundreds of thousands to millions of participants. In these environments, RTCP may not always be used, and thus the group membership table isn't needed. However, it is highly desirable for RTP to scale well for groups with one member to groups with one million members, without human intervention to "turn off" RTCP when it's no longer appropriate. This means that the same tools and

对于大型多播会话,例如mbone广播或基于IP的电视分发,组大小可能非常大,大约有几十万到数百万参与者。在这些环境中,可能并不总是使用RTCP,因此不需要组成员表。然而,RTP在一个成员组到一百万成员组之间具有良好的扩展性是非常可取的,在RTP不再合适时,无需人为干预即可“关闭”RTP。这意味着相同的工具和

systems can be used for both small conferences and TV broadcasts in a smooth, scalable fashion.

该系统可用于小型会议和电视广播,具有平滑、可扩展的特点。

Previous work [2] has identified three major scalability problems with RTP. These are:

以前的工作[2]已经确定了RTP的三个主要可伸缩性问题。这些是:

1. Congestion due to floods of RTCP packets in highly dynamic groups;

1. 由于RTCP数据包在高动态组中泛滥而导致的拥塞;

2. Large delays between receipt of RTCP packets from a single user;

2. 从单个用户接收RTCP数据包之间的大延迟;

3. Large size of the group membership table.

3. 组成员资格表的大小较大。

The reconsideration algorithm [2] helps to alleviate the first of these. This document addresses the third, that of large group size tables.

重新考虑算法[2]有助于缓解第一个问题。本文档讨论了第三个问题,即大组大小的表。

Storage of an SSRC table with one million members, for example, requires at least four megabytes. As a result, embedded devices with small memory capacity may have difficulty under these conditions. To solve this problem, SSRC sampling has been proposed. SSRC sampling uses statistical sampling to obtain a stochastic estimate of the group membership. There are many issues that arise when this is done. This document reviews these issues and discusses the mechanisms which can be applied by implementors. In particular, it focuses on three methods for adapting the sampling probability as the group membership varies. It is important to note that the IETF has been notified of intellectual property rights claimed in regard to some or all of the specification contained in this document, and in particular to one of the three mechanisms: the binning algorithm described below. For more information consult the online list of claimed rights. The two other approaches presented are inferior to the binning algorithm, but are included as they are believed to be unencumbered by IPR.

例如,存储一个有一百万成员的SSRC表至少需要4兆字节。因此,在这些条件下,内存容量小的嵌入式设备可能会遇到困难。为了解决这个问题,提出了SSRC采样。SSRC抽样使用统计抽样来获得组成员的随机估计。这样做时会出现许多问题。本文档回顾了这些问题,并讨论了实施者可以应用的机制。特别是,它着重于三种方法,以适应抽样概率作为组成员的变化。需要注意的是,IETF已收到关于本文件所含部分或全部规范的知识产权申请通知,特别是关于以下三种机制之一:装箱算法。有关更多信息,请查阅在线权利主张列表。所提出的另外两种方法不如装箱算法,但被包括在内,因为它们被认为不受IPR的影响。

2 Basic Operation

2基本操作

The basic idea behind SSRC sampling is simple. Each participant maintains a key K of 32 bits, and a mask M of 32 bits. Assume that m of the bits in the mask are 1, and the remainder are zero. When an RTCP packet arrives with some SSRC S, rather than placing it in the table, it is first sampled. The sampling is performed by ANDing the key and the mask, and also ANDing the SSRC and the mask. The resulting values are compared. If equal, the SSRC is stored in the table. If not equal, the SSRC is rejected, and the packet is treated as if it has never been received.

SSRC采样背后的基本思想很简单。每个参与者维护一个32位的密钥K和一个32位的掩码M。假设掩码中的m位为1,其余为0。当RTCP数据包与一些SSRC一起到达时,首先对其进行采样,而不是将其放入表中。通过对密钥和掩码以及SSRC和掩码进行ANDing来执行采样。将比较结果值。如果相等,则SSRC存储在表中。如果不相等,SSRC将被拒绝,数据包将被视为从未收到过。

The key can be anything, but is usually derived from the SSRC of the user who is performing the sampling.

密钥可以是任何内容,但通常来自执行采样的用户的SSRC。

This sampling process can be described mathematically as:

该取样过程可以用数学方法描述为:

   D = (K*M == S*M)
        
   D = (K*M == S*M)
        

Where the * operator denotes AND and the == operator denotes a test for equality. D represents the sampling decision.

其中*运算符表示和,==运算符表示相等性测试。D表示抽样决定。

According to the RTP specification, the SSRC's used by session participants are chosen randomly. If the distribution is also uniform, it is easy to see that the above filtering will cause 1 out of 2**m SSRC's to be placed in the table, where m is the number of bits in the mask, M, which are one. Thus, the sampling probability p is 2**-m.

根据RTP规范,会话参与者使用的SSRC是随机选择的。如果分布也是均匀的,则很容易看出上述过滤将导致表中2**m SSRC中的1个被放入表中,其中m是掩码中的位数m,即1。因此,抽样概率p为2**-m。

Then, to obtain an actual group size estimate, L, the number of entries in the table N is multiplied by 2**m:

然后,为了获得实际的组大小估计值L,将表N中的条目数乘以2**m:

   L = N * 2**m
        
   L = N * 2**m
        

Care must be taken when choosing which bits to set to 1 in the mask. Although the RTP specification mandates randomly chosen SSRC, there are many known implementations which do not conform to this. In particular, the ITU H.323 [3] series of recommendations allows the central control element, the gatekeeper, to assign the least significant 8 bits of the SSRC, while the most significant are randomly chosen by RTP participants.

在选择掩码中设置为1的位时必须小心。尽管RTP规范要求随机选择SSRC,但有许多已知的实现不符合此要求。特别是,ITU H.323[3]系列建议允许中央控制元件(网守)分配SSRC的最低有效8位,而最高有效位由RTP参与者随机选择。

The safest way to handle this problem is to first hash the SSRC using a cryptographically secure hash, such as MD5 [4], and then choose 32 of the bits in the result as the SSRC used in the above computation. This provides much better randomness, and doesn't require detailed knowledge about how various implementations actually set the SSRC.

处理此问题最安全的方法是首先使用加密安全哈希(如MD5[4])对SSRC进行哈希,然后选择结果中的32位作为上述计算中使用的SSRC。这提供了更好的随机性,并且不需要详细了解各种实现如何实际设置SSRC。

2.1 Performance
2.1 表演

The estimate is more accurate as the value of m decreases, less accurate as it increases. This can be demonstrated analytically. If the actual group size is G, the ratio of the standard deviation to mean of the estimate L (coefficient of variation) is:

随着m值的减小,估计值更准确,而随着m值的增大,估计值更不准确。这可以通过分析来证明。如果实际组大小为G,则标准偏差与估计值L(变异系数)平均值的比率为:

   sqrt((2**m - 1)/G)
        
   sqrt((2**m - 1)/G)
        

This equation can be used as a guide for selecting the thresholds for when to change the sampling factor, as discussed below. For example, if the target is a 1% standard deviation to mean, the sampling

如下文所述,该方程可作为选择何时更改采样因子的阈值的指南。例如,如果目标是1%的平均标准偏差,则采样

probability p=2**-m should be no smaller than .5 when there are ten thousand group members. More generally, to achieve a desired standard deviation to mean ratio of T, the sampling probability should be no less than:

当有一万个组成员时,概率p=2**-m应不小于.5。更一般地说,为了达到期望的标准偏差与平均值之比T,抽样概率应不小于:

   p > 1 / (1 + G*(T**2))
        
   p > 1 / (1 + G*(T**2))
        

3 Increasing the Sampling Probability

3增加抽样概率

The above simple sampling procedure would work fine if the group size was static. However, it is not. A participant joining an RTP session will initially see just one participant (themselves). As packets are received, the group size as seen by that participant will increase. To handle this, the sampling probability must be made dynamic, and will need to increase and decrease as group sizes vary.

如果组大小是静态的,则上述简单的抽样程序可以正常工作。然而,事实并非如此。参加RTP会话的参与者最初只会看到一个参与者(他们自己)。当收到数据包时,该参与者看到的组大小将增加。为了处理这个问题,抽样概率必须是动态的,并且需要随着组大小的变化而增减。

The procedure for increasing the sampling probability is easy. A participant starts with a mask with m=0. Under these conditions, every received SSRC will be stored in the table, so there is effectively no sampling. At some point, the value of m is increased by one. This implies that approximately half of the SSRC already in the table will no longer match the key under the masking operation. In order to maintain a correct estimate, these SSRC must be discarded from the table. New SSRC are only added if they match the key under the new mask.

增加抽样概率的步骤很简单。参与者以m=0的面具开始。在这些条件下,每个接收到的SSRC都将存储在表中,因此实际上没有采样。在某一点上,m的值增加1。这意味着表中已有大约一半的SSRC将不再匹配掩蔽操作下的键。为了保持正确的估计,必须从表中删除这些SSRC。仅当新SSRC与新掩码下的密钥匹配时,才会添加新SSRC。

The decision about when to increase the number of bits in the mask is also simple. Let's say an RTP participant has a memory with enough capacity to store C entries in the table. The best estimate of the group is obtained by the largest sampling probability. This also means that the best estimate is obtained the fuller the table is. A reasonable approach is therefore to increase the number of bits in the mask just as the table fills to C. This will generally cause its contents to be reduced by half on average. Once the table fills again, the number of bits in the mask is further increased.

关于何时增加掩码中的位数的决定也很简单。假设一个RTP参与者有足够容量的内存来存储表中的C项。该组的最佳估计是通过最大抽样概率获得的。这也意味着表格越完整,得到的估计值就越高。因此,一种合理的方法是在表填充到C时增加掩码中的位数。这通常会导致其内容平均减少一半。一旦表格再次填充,掩码中的位数将进一步增加。

4 Reducing the Sampling Probability

4降低抽样概率

If the group size begins to decrease, it may be necessary to reduce the number of one bits in the mask. Not doing so will result in extremely poor estimates of the group size. Unfortunately, reducing the number of bits in the mask is more difficult than increasing them.

如果组大小开始减少,则可能需要减少掩码中的一位数。不这样做将导致对集团规模的估计极为糟糕。不幸的是,减少掩码中的位数比增加它们更困难。

When the number of bits in the mask increases, the user compensates by removing those SSRC which no longer match. When the number of bits decreases, the user should theoretically add back those users whose SSRC now match. However, these SSRC are not known, since the whole

当掩码中的位数增加时,用户通过移除不再匹配的SSRC进行补偿。当比特数减少时,理论上用户应该将SSRC现在匹配的用户加回去。然而,这些SSRC是未知的,因为

point of sampling was to not have to remember them. Therefore, if the number of bits in the mask is just reduced without any changes in the membership table, the group estimate will instantly drop by exactly half.

取样的目的是不必记住它们。因此,如果掩码中的位数刚刚减少,而成员表中没有任何更改,则组估计值将立即减少一半。

To compensate for this, some kind of algorithm is needed. Two approaches are presented here: a corrective-factor solution, and a binning solution. The binning solution is simpler to understand and performs better. However, we include a discussion of the corrective-factor solution for completeness and comparison, and also because it is believed to be unencumbered by IPR.

为了弥补这一点,需要某种算法。这里介绍了两种方法:校正因子解决方案和分箱解决方案。装箱解决方案更易于理解,性能更好。然而,为了完整性和比较,我们还讨论了校正因子解决方案,这也是因为我们认为校正因子解决方案不受IPR的影响。

4.1 Corrective Factors
4.1 纠正因素

The idea with the corrective factors is to take one of two approaches. In the first, a corrective factor is added to the group size estimate, and in the second, the group size estimate is multiplied by a corrective factor. In both cases, the purpose is to compensate for the change in sample mask. The corrective factors should decay as the "fudged" members are eventually learned about and actually placed in the membership list.

关于纠正因素的想法是采取两种方法之一。在第一种情况下,将校正因子添加到组大小估计值中,在第二种情况下,将组大小估计值乘以校正因子。在这两种情况下,目的都是补偿样品掩模的变化。随着“捏造”的成员最终被了解并实际列入成员名单,纠正因素应该逐渐消失。

The additive factor starts at the difference between the group size estimate before and after the number of bits in the mask is reduced, and decays to 0 (this is not always half the group size estimate, as the corrective factors can be compounded, see below). The multiplicative corrective factor starts at 2, and gradually decays to one. Both factors decay over a time of cL(ts-), where c is the average RTCP packet size divided by the RTCP bandwidth for receivers, and L(ts-) is the group size estimate just before the change in the number of bits in the mask at time ts. The reason for this constant is as follows. In the case where the actual group membership has not changed, those members which were forgotten will still be sending RTCP packets. The amount of time it will take to hear an RTCP packet from each of them is the average RTCP interval, which is cL(ts-). Therefore, by cL(ts-) seconds after the change in the mask, those users who were fudged by the corrective factor should have sent a packet and thus appear in the table. We chose to decay both functions linearly. This is because the rate of arrival of RTCP packets is linear.

相加因子从掩码中位数减少前后的组大小估计值之间的差值开始,并衰减为0(这并不总是组大小估计值的一半,因为校正因子可以合成,见下文)。乘法校正因子从2开始,逐渐衰减为1。这两个因素都会在cL(ts-)的时间内衰减,其中c是平均RTCP数据包大小除以接收机的RTCP带宽,L(ts-)是在ts时间掩码中的位数发生变化之前的组大小估计值。该常数的原因如下。在实际组成员身份未更改的情况下,被遗忘的成员仍将发送RTCP数据包。从他们每个人那里听到RTCP数据包所需的时间是平均RTCP间隔,即cL(ts-)。因此,在掩码更改后的cL(ts-)秒,那些被纠正因子欺骗的用户应该已经发送了一个数据包,因此出现在表中。我们选择线性衰减这两个函数。这是因为RTCP数据包的到达率是线性的。

What happens if the number of bits in the mask is reduced once again before the previous corrective factor has expired? In that case, we compound the factors by using yet another one. Let fi() represent the ith additive correction function, and gi() the ith multiplicative correction function. If ts is the time when the number of bits in the mask is reduced, we can describe the additive correction factor as:

如果掩码中的位数在上一个校正因子到期之前再次减少,会发生什么情况?在这种情况下,我们通过使用另一个因子来复合这些因子。设fi()表示第i个加法校正函数,gi()表示第i个乘法校正函数。如果ts是掩码中位数减少的时间,我们可以将相加校正因子描述为:

            / 0                                  ,   t < ts
            |                   ts + cL(ts-) - t
  fi(t)  =  |( L(ts-) - L(ts+)) ---------------- ,   ts < t < ts+cL(ts-)
            |                        cL(ts-)
            | 0                                  ,   t > ts + cL(ts-)
            \
        
            / 0                                  ,   t < ts
            |                   ts + cL(ts-) - t
  fi(t)  =  |( L(ts-) - L(ts+)) ---------------- ,   ts < t < ts+cL(ts-)
            |                        cL(ts-)
            | 0                                  ,   t > ts + cL(ts-)
            \
        

and the multiplicative factor as:

乘法因子为:

            /  1                      , t < ts
            |
            |  ts + 2cL(ts-) - t
  gi(t)     |  -----------------      , ts < t < ts + cL(ts-)
            |       cL(ts-)
            |
            \  1                      , t > ts + cL(ts-)
        
            /  1                      , t < ts
            |
            |  ts + 2cL(ts-) - t
  gi(t)     |  -----------------      , ts < t < ts + cL(ts-)
            |       cL(ts-)
            |
            \  1                      , t > ts + cL(ts-)
        

Note that in these equations, L(t) denotes the group size estimate obtained including the corrective factors except for the new factor. ts- is the time right before the reduction in the number of bits, and ts+ the time after. As a result, L(ts-) represents the group size estimate before the reduction, and L(ts+) the estimate right after, but not including the new factor.

注意,在这些等式中,L(t)表示获得的组大小估计,包括除新因子外的校正因子。ts-是位数减少前的时间,ts+是位数减少后的时间。因此,L(ts-)表示缩减前的组大小估计,L(ts+)表示缩减后的估计,但不包括新因子。

Finally, the actual group size estimate L(t) is given by:

最后,实际组大小估计值L(t)由下式得出:

          -----
          \
   L(t) = /      fi(t) + N*(2**m)
          -----
            i
        
          -----
          \
   L(t) = /      fi(t) + N*(2**m)
          -----
            i
        

for the additive factor, and:

对于相加系数,以及:

          ------
           |  |
           |  |
   L(t)=   |  |  N*(2**m)*gi(t)
        
          ------
           |  |
           |  |
   L(t)=   |  |  N*(2**m)*gi(t)
        

for the multiplicative factor.

对于乘法因子。

Simulations showed that both algorithms performed equally well, but both tended to seriously underestimate the group size when the group membership was rapidly declining [5]. This is demonstrated in the performance data below.

仿真表明,这两种算法的性能都相当好,但当组成员迅速减少时,这两种算法都严重低估了组的大小[5]。下面的性能数据说明了这一点。

As an example, consider computation of the additive factor. The group size is 1000, c is 1 second, and m is two. With a mask of this size, a participant will, on average, observe 250 (N = 250) users. At t=0, the user decides to reduce the number of bits in the mask to 1. As a result, L(0-) is 1000, and L(0+) is 500. The additive factor therefore starts at 500, and decays to zero at time ts + cL(ts-) = 1000. At time 500, lets assume N has increased to 375 (this will, on average, be the case if the actual group size has not changed). At time 500, the additive factor is 250. This is added to 2**m times N, which is 750, resulting in a group size estimate of 1000. Now, the user decides to reduce the number of bits in the mask again, so that m=0. Another additive factor is computed. This factor starts at L(ts-) (which is 1000), minus L(ts+). L(ts+) is computed without the new factor; it is the first additive factor at this time (250) plus 2**m (1) times N (375). This is 625. As a result, the new additive factor starts at 1000 - 625 (375), and decays to 0 in 1000 seconds.

作为一个例子,考虑加法因子的计算。组大小为1000,c为1秒,m为2。使用这种尺寸的面具,参与者平均将观察250(N=250)个用户。在t=0时,用户决定将掩码中的位数减少到1。因此,L(0-)为1000,L(0+)为500。因此,相加因子从500开始,并在ts+cL(ts-)=1000时衰减为零。在时间500时,假设N增加到375(如果实际组大小没有改变,则平均情况将是这样)。在时间500时,相加因子为250。这加上2**m乘以N,即750,导致组大小估计为1000。现在,用户决定再次减少掩码中的位数,以便m=0。计算了另一个加性因子。该系数从L(ts-)开始(即1000),减去L(ts+)。L(ts+)在不使用新因子的情况下计算;它是此时(250)加上2**m(1)乘以N(375)的第一个相加因子。这是625。因此,新的相加因子从1000-625(375)开始,并在1000秒内衰减为0。

4.2 Binning Algorithm
4.2 装箱算法

In order to more correctly estimate the group size even when it is rapidly decreasing, a binning algorithm can be used. The algorithm works as follows. There are 32 bins, same as the number of bits in the sample mask. When an RTCP packet from a new user arrives whose SSRC matches the key under the masking operation, it is placed in the mth bin (where m is the number of ones in the mask) otherwise it is discarded.

为了更准确地估计组大小,即使组大小正在快速减小,也可以使用分组算法。该算法的工作原理如下。共有32个存储箱,与样本掩码中的位数相同。当来自新用户的RTCP数据包到达时,其SSRC与屏蔽操作下的密钥相匹配,该数据包将被放入mth bin(其中m是屏蔽中的数字),否则将被丢弃。

When the number of bits in the mask is to be increased, those members in the bin who still match after the new mask are moved into the next higher bin. Those who don't match are discarded. When the number of bits in the mask is to be decreased, nothing is done. Users in the various bins stay where they are. However, when an RTCP packet for a user shows up, and the user is in a bin with a higher value than the current number of bits in the mask, it is moved into the bin corresponding to the current number of bits in the mask. Finally, the group size estimate L(t) is obtained by:

当掩码中的位数要增加时,在新掩码后仍匹配的bin中的那些成员将移动到下一个更高的bin中。不匹配的将被丢弃。当掩码中的位数要减少时,什么也不做。各种垃圾箱中的用户呆在原地。但是,当用户的RTCP数据包出现时,并且用户所在的bin的值高于掩码中的当前位数,则该数据包将移动到与掩码中的当前位数相对应的bin中。最后,通过以下方式获得组大小估计值L(t):

           31
          ----
          \
   L(t) = /    B(i) * 2**i
          ----
           i=0
        
           31
          ----
          \
   L(t) = /    B(i) * 2**i
          ----
           i=0
        

Where B(i) are the number of users in the ith bin.

其中B(i)是第i个bin中的用户数。

The algorithm works by basically keeping the old estimate when the number of bits in the mask drops. As users arrive, they are gradually moved into the lower bin, reducing the amount that the higher bin contributes to the total estimate. However, the old estimate is still updated in the sense that users which timeout are removed from the higher bin, and users who send BYE packets are also removed from the higher bin. This allows the older estimate to still adapt, while gradually phasing it out. It is this adaptation which makes it perform much better than the corrective algorithms. The algorithm is also extremely simple.

该算法的工作原理是,当掩码中的位数下降时,基本上保持原有的估计。随着用户的到来,他们逐渐被转移到较低的仓位,从而减少较高仓位对总估算的贡献。然而,旧的估计值仍在更新,即超时的用户将从较高的bin中删除,发送BYE数据包的用户也将从较高的bin中删除。这使得旧的估计仍然适用,同时逐渐淘汰。正是这种自适应使得它的性能比校正算法要好得多。算法也非常简单。

4.3 Comparison
4.3 比较

The algorithms are all compared via simulation in Table 1. In the simulation, 10,001 users join a group at t=0. At t=10,000, 5000 of them leave. At t=20,000, another 5000 leave. All implement an SSRC sampling algorithm, unconditional forward reconsideration and BYE reconsideration. The table depicts the group size estimate from time 20,000 to time 25,000 as seen by the single user present throughout the entire session. In the simulation, a memory size of 1000 SSRC was assumed. The performance without sampling, and with sampling with the additive, multiplicative, and bin-based correction are depicted.

通过表1中的仿真对所有算法进行了比较。在模拟中,10001个用户在t=0时加入一个组。t=10000时,其中5000人离开。当t=20000时,再离开5000人。它们都实现了SSRC采样算法、无条件前向重新考虑和BYE重新考虑。该表描述了整个会话中单个用户看到的从时间20000到时间25000的组大小估计。在模拟中,假定内存大小为1000 SSRC。描述了无采样情况下的性能,以及使用加法、乘法和基于单元的校正进行采样时的性能。

As the table shows, the bin based algorithm performs particularly well at capturing the group size estimate towards the tail end of the simulation.

如表所示,基于bin的算法在接近模拟尾声时捕获组大小估计值方面表现尤为出色。

   Time    No Sampling     Binned  Additive  Multiplicative
   ----    -----------     ------  --------  --------------
   20000   5001            5024    5024      5024
   20250   4379            4352    4352      4352
   20500   3881            3888    3900      3853
   20750   3420            3456    3508      3272
   21000   3018            2992    3100      2701
   21250   2677            2592    2724      2225
   21500   2322            2272    2389      1783
   21750   2034            2096    2125      1414
   22000   1756            1760    1795      1007
   22250   1476            1472    1459      582
   22500   1243            1232    1135      230
   22750   1047            1040    807       80
   23000   856             864     468       59
   23250   683             704     106       44
   23500   535             512     32        32
   23750   401             369     24        24
   24000   290             257     17        17
   24250   198             177     13        13
   24500   119             129     11        11
   24750   59              65      8         8
   25000   18              1       2         2
        
   Time    No Sampling     Binned  Additive  Multiplicative
   ----    -----------     ------  --------  --------------
   20000   5001            5024    5024      5024
   20250   4379            4352    4352      4352
   20500   3881            3888    3900      3853
   20750   3420            3456    3508      3272
   21000   3018            2992    3100      2701
   21250   2677            2592    2724      2225
   21500   2322            2272    2389      1783
   21750   2034            2096    2125      1414
   22000   1756            1760    1795      1007
   22250   1476            1472    1459      582
   22500   1243            1232    1135      230
   22750   1047            1040    807       80
   23000   856             864     468       59
   23250   683             704     106       44
   23500   535             512     32        32
   23750   401             369     24        24
   24000   290             257     17        17
   24250   198             177     13        13
   24500   119             129     11        11
   24750   59              65      8         8
   25000   18              1       2         2
        
4.4 Sender Sampling
4.4 发送方抽样

Care must be taken in handling senders when using SSRC sampling. Since the number of senders is generally small, and they contribute significantly to the computation of the RTCP interval, sampling should not be applied to them. However, they must be kept in a separate table, and not be "counted" as part of the general group membership. If they are counted as part of the general group membership, and are not sampled, the group size estimate will be inflated to overemphasize the senders.

使用SSRC采样时,在处理发送器时必须小心。由于发送方的数量通常很小,并且它们对RTCP间隔的计算有很大的贡献,因此不应对其应用采样。但是,它们必须保存在一个单独的表中,并且不能“计算”为一般集团成员的一部分。如果它们被计算为一般组成员的一部分,并且没有进行抽样,则组大小估计值将被夸大,从而过分强调发送者。

This is easily demonstrated analytically. Let Ns be the number of senders, and Nr be the number of receivers. The membership table will contain all Ns senders and (1/2)**m of the receivers. The total group size estimate in the current memo is obtained by 2**m times the number of entries in the table. Therefore, the group size estimate becomes:

这很容易通过分析来证明。设Ns为发送方的数量,Nr为接收方的数量。成员资格表将包含所有Ns发送方和(1/2)**m接收方。当前备忘录中的集团总规模估计值是表中条目数的2**m倍。因此,集团规模估计值变为:

   L(t) = (2**m) Ns + Nr
        
   L(t) = (2**m) Ns + Nr
        

which exponentially weights the senders.

它以指数方式加权发送者。

This is easily compensated for in the binning algorithm. A sender is always placed in the 0th bin. When a sender becomes a receiver, it is moved into the bin corresponding to the current value of m, if its SSRC matches the key under the masked comparison operation.

这在装箱算法中很容易得到补偿。发件人始终放在第0个箱中。当发送方成为接收方时,如果其SSRC与屏蔽比较操作下的密钥匹配,则将其移动到与当前值m对应的bin中。

5 Security Considerations

5安全考虑

The use of SSRC sampling does not appear to introduce any additional security considerations beyond those described in [1]. In fact, SSRC sampling, as described above, can help somewhat in reducing the effect of certain attacks.

除了[1]中所述的安全注意事项外,使用SSRC采样似乎不会引入任何其他安全注意事项。事实上,如上所述,SSRC采样可以在一定程度上帮助减少某些攻击的影响。

RTP, when used without authentication of RTCP packets, is susceptible to a spoofing attack. Attackers can inject many RTCP packets into the group, each with a different SSRC. This will cause RTP participants to believe the group membership is much higher than it actually is. The result is that each participant will end up transmitting RTCP packets very infrequently, if ever. When SSRC sampling is used, the problem can be amplified if a participant is not applying a hash to the SSRC before matching them against their key. This is because an attacker can send many packets, each with different SSRC, that match the key. This would cause the group size to inflate exponentially. However, with a random hash applied, an attacker cannot guess those SSRC which will match against the key. In fact, an attacker will have to send 2**m different SSRC before finding one that matches, on average. Of course, the effect of a match causes an increase of group membership by 2**m. But, the use of sampling means that an attacker will have to send many packets before an effect can be observed.

RTP在没有对RTCP数据包进行身份验证的情况下使用时,容易受到欺骗攻击。攻击者可以向组中注入许多RTCP数据包,每个数据包具有不同的SSRC。这将使RTP参与者相信团队成员比实际情况高得多。结果是,每个参与者最终都会很少发送RTCP数据包(如果有的话)。当使用SSRC采样时,如果参与者在将SSRC与密钥进行匹配之前未对SSRC应用哈希,则问题可能会扩大。这是因为攻击者可以发送许多与密钥匹配的数据包,每个数据包具有不同的SSRC。这将导致组大小呈指数级膨胀。但是,如果应用了随机散列,攻击者无法猜测将与密钥匹配的SSRC。事实上,平均而言,攻击者必须发送2**m不同的SSRC才能找到匹配的SSRC。当然,匹配的效果会导致组成员数增加2**m。但是,使用采样意味着攻击者必须发送许多数据包才能观察到效果。

6 Acknowledgements

6致谢

The authors wish to thank Bill Fenner and Vern Paxson for their comments.

作者希望感谢Bill Fenner和Vern Paxson的评论。

7 Bibliography

7参考书目

[1] Schulzrinne, H., Casner, S., Frederick, R. and V. Jacobson, "RTP: a transport protocol for real-time applications", RFC 1889, January 1996.

[1] Schulzrinne,H.,Casner,S.,Frederick,R.和V.Jacobson,“RTP:实时应用的传输协议”,RFC 1889,1996年1月。

[2] J. Rosenberg and H. Schulzrinne, "Timer reconsideration for enhanced RTP scalability", IEEE Infocom, (San Francisco, California), March/April 1998.

[2] J.Rosenberg和H.Schulzrinne,“增强RTP可扩展性的计时器重新考虑”,IEEE Infocom,(加利福尼亚州旧金山),1998年3月/4月。

[3] International Telecommunication Union, "Visual telephone systems and equipment for local area networks which provide a non-guaranteed quality of service," Recommendation H.323, Telecommunication Standardization Sector of ITU, Geneva, Switzerland, May 1996.

[3] 国际电信联盟,“提供非保证服务质量的局域网可视电话系统和设备”,建议H.323,国际电联电信标准化部门,瑞士日内瓦,1996年5月。

[4] Rivest, R., "The MD5 message-digest algorithm", RFC 1321, April 1992.

[4] Rivest,R.,“MD5消息摘要算法”,RFC1321,1992年4月。

[5] Rosenberg, J., "Protocols and Algorithms for Supporting Distributed Internet Telephony," PhD Thesis, Columbia University, Dec. 1999. Work in Progress.

[5] Rosenberg,J.,“支持分布式互联网电话的协议和算法”,哥伦比亚大学博士论文,1999年12月。正在进行的工作。

8 Authors' Addresses

8作者地址

Jonathan Rosenberg dynamicsoft 200 Executive Drive West Orange, NJ 07052 USA

Jonathan Rosenberg dynamicsoft 200行政大道西橙,新泽西州07052

   EMail: jdrosen@dynamicsoft.com
        
   EMail: jdrosen@dynamicsoft.com
        

Henning Schulzrinne Columbia University M/S 0401 1214 Amsterdam Ave. New York, NY 10027-7003 USA

Henning Schulzrinne哥伦比亚大学M/S 0401 1214美国纽约州阿姆斯特丹大道10027-7003号

   EMail: schulzrinne@cs.columbia.edu
        
   EMail: schulzrinne@cs.columbia.edu
        

9 Full Copyright Statement

9完整版权声明

Copyright (C) The Internet Society (2000). All Rights Reserved.

版权所有(C)互联网协会(2000年)。版权所有。

This document and translations of it may be copied and furnished to others, and derivative works that comment on or otherwise explain it or assist in its implementation may be prepared, copied, published and distributed, in whole or in part, without restriction of any kind, provided that the above copyright notice and this paragraph are included on all such copies and derivative works. However, this document itself may not be modified in any way, such as by removing the copyright notice or references to the Internet Society or other Internet organizations, except as needed for the purpose of developing Internet standards in which case the procedures for copyrights defined in the Internet Standards process must be followed, or as required to translate it into languages other than English.

本文件及其译本可复制并提供给他人,对其进行评论或解释或协助其实施的衍生作品可全部或部分编制、复制、出版和分发,不受任何限制,前提是上述版权声明和本段包含在所有此类副本和衍生作品中。但是,不得以任何方式修改本文件本身,例如删除版权通知或对互联网协会或其他互联网组织的引用,除非出于制定互联网标准的需要,在这种情况下,必须遵循互联网标准过程中定义的版权程序,或根据需要将其翻译成英语以外的其他语言。

The limited permissions granted above are perpetual and will not be revoked by the Internet Society or its successors or assigns.

上述授予的有限许可是永久性的,互联网协会或其继承人或受让人不会撤销。

This document and the information contained herein is provided on an "AS IS" basis and THE INTERNET SOCIETY AND THE INTERNET ENGINEERING TASK FORCE DISCLAIMS ALL WARRANTIES, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO ANY WARRANTY THAT THE USE OF THE INFORMATION HEREIN WILL NOT INFRINGE ANY RIGHTS OR ANY IMPLIED WARRANTIES OF MERCHANTABILITY OR FITNESS FOR A PARTICULAR PURPOSE.

本文件和其中包含的信息是按“原样”提供的,互联网协会和互联网工程任务组否认所有明示或暗示的保证,包括但不限于任何保证,即使用本文中的信息不会侵犯任何权利,或对适销性或特定用途适用性的任何默示保证。

Acknowledgement

确认

Funding for the RFC Editor function is currently provided by the Internet Society.

RFC编辑功能的资金目前由互联网协会提供。