Hi there,
On Mon, 10 Mar 2008 20:53:22 +0900
Mitsuru Chinen <mitch@linux.vnet.ibm.com> wrote:
> I think the following tests have a bug.
>
> rfc3315/
> #32 Part D : Maximum Retransmission Time of solicit message
> #37 Part C : Maximum Retransmission Time of Request messages
> #41 Part C : Maximum Retransmission Time of Request messages
> #46 Part C : Maximum Retransmission Time of Renew message, T1 and T2 non-zero
> #50 Part C : Maximum Retransmission Time of Rebind message, T1 and T2 non-zero
> rfc3736/
> #13 Part C : Maximum Retransmission Time of Information-request message
>
> Regarding RT, Section 14 in RFC3315 says:
>
> > RT for each subsequent message transmission is based on the previous
> > value of RT:
> >
> > RT = 2*RTprev + RAND*RTprev
> >
> > MRT specifies an upper bound on the value of RT (disregarding the
> > randomization added by the use of RAND). If MRT has a value of 0,
> > there is no upper limit on the value of RT. Otherwise:
> >
> > if (RT > MRT)
> > RT = MRT + RAND*MRT
>
> However, the test doesn't recalculate $timeout, expected RT, when
> timeout is bigger than MRT.
Excuse me, I sent wrong patch in previous mail.
Here's the correct one.
Best Regards,
----
Mitsuru Chinen <mitch@linux.vnet.ibm.com>
diff --git a/rfc3315/C_RFC3315_17_1_2_SolRetransMRT.seq b/rfc3315/C_RFC3315_17_1_2_SolRetransMRT.seq
index 26183e7..658aa4c 100755
--- a/rfc3315/C_RFC3315_17_1_2_SolRetransMRT.seq
+++ b/rfc3315/C_RFC3315_17_1_2_SolRetransMRT.seq
@@ -126,6 +126,11 @@ while($mrtflag < $MAXCOUNT){
}
$initflag=1;
+ # If $timeout is bigger than MRT, expected RT is MRT + RAND * MRT
+ if($timeout > $MRT){
+ $timeout = (1 + $RAND) * $MRT;
+ }
+
#
#----------- Wait for next retransmission
#
diff --git a/rfc3315/C_RFC3315_18_1_1_ReqRetransMRT.seq b/rfc3315/C_RFC3315_18_1_1_ReqRetransMRT.seq
index a0d25ce..41df69f 100755
--- a/rfc3315/C_RFC3315_18_1_1_ReqRetransMRT.seq
+++ b/rfc3315/C_RFC3315_18_1_1_ReqRetransMRT.seq
@@ -141,6 +141,11 @@ while($mrtflag < $MAXCOUNT){
}
$initflag=1;
+ # If $timeout is bigger than MRT, expected RT is MRT + RAND * MRT
+ if($timeout > $MRT){
+ $timeout = (1 + $RAND) * $MRT;
+ }
+
#
#----------- Wait for next retransmission
#
diff --git a/rfc3315/C_RFC3315_18_1_2_CnfRetransMRT.seq b/rfc3315/C_RFC3315_18_1_2_CnfRetransMRT.seq
index 279248c..4d449d4 100755
--- a/rfc3315/C_RFC3315_18_1_2_CnfRetransMRT.seq
+++ b/rfc3315/C_RFC3315_18_1_2_CnfRetransMRT.seq
@@ -193,6 +193,11 @@ while($mrtflag < $MAXCOUNT){
}
$initflag=1;
+ # If $timeout is bigger than MRT, expected RT is MRT + RAND * MRT
+ if($timeout > $MRT){
+ $timeout = (1 + $RAND) * $MRT;
+ }
+
#
#----------- Wait for next retransmission
#
diff --git a/rfc3315/C_RFC3315_18_1_3_RenRetransMRT.seq b/rfc3315/C_RFC3315_18_1_3_RenRetransMRT.seq
index fcced3a..dd56be9 100755
--- a/rfc3315/C_RFC3315_18_1_3_RenRetransMRT.seq
+++ b/rfc3315/C_RFC3315_18_1_3_RenRetransMRT.seq
@@ -186,6 +186,11 @@ while($mrtflag < $MAXCOUNT){
}
$initflag=1;
+ # If $timeout is bigger than MRT, expected RT is MRT + RAND * MRT
+ if($timeout > $MRT){
+ $timeout = (1 + $RAND) * $MRT;
+ }
+
#
#----------- Wait for next retransmission
#
diff --git a/rfc3315/C_RFC3315_18_1_4_RebRetransMRT.seq b/rfc3315/C_RFC3315_18_1_4_RebRetransMRT.seq
index 617351c..0947e4c 100755
--- a/rfc3315/C_RFC3315_18_1_4_RebRetransMRT.seq
+++ b/rfc3315/C_RFC3315_18_1_4_RebRetransMRT.seq
@@ -183,6 +183,11 @@ while($mrtflag < $MAXCOUNT){
}
$initflag = 1;
+ # If $timeout is bigger than MRT, expected RT is MRT + RAND * MRT
+ if($timeout > $MRT){
+ $timeout = (1 + $RAND) * $MRT;
+ }
+
#
#----------- Wait for next retransmission
#
diff --git a/rfc3736/C_RFC3736_INfoRetransMRT.seq b/rfc3736/C_RFC3736_INfoRetransMRT.seq
index c532a4f..0f9cd4c 100755
--- a/rfc3736/C_RFC3736_INfoRetransMRT.seq
+++ b/rfc3736/C_RFC3736_INfoRetransMRT.seq
@@ -106,6 +106,12 @@ while(check_equal($interval,$INF_MAX_RT,$RAND)){
}else{
$timeout = (1 + $RAND) * $IRT;
}
+
+ # If $timeout is bigger than MRT, expected RT is MRT + RAND * MRT
+ if($timeout > $INF_MAX_RT){
+ $timeout = (1 + $RAND) * $INF_MAX_RT;
+ }
+
($retinf2,%inf2) = wait_for_information_request($IF0, $timeout + 1);
$nextime = getReceivedtime(\%inf2);
if($retinf2 != 0){