directory-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Felix Knecht <fel...@apache.org>
Subject Re: Trunk failures : status
Date Sun, 14 Nov 2010 21:48:19 GMT
Latest working version I can find is r1033437 
(http://svn.apache.org/viewvc?rev=1033452&view=rev).

[1] shows results following results

Working version:
<snip>
Running 
org.apache.directory.server.kerberos.protocol.TicketGrantingPolicyTest
AbstractKerberosFlags super( '0','0','0','1','2', ) ... length=5
[0]=0
[1]=0
[2]=1
[3]=2
Tests run: 12, Failures: 0, Errors: 0, Skipped: 11, Time elapsed: 1.585 sec
</snip>

Trunk:
<snip>
Running 
org.apache.directory.server.kerberos.protocol.TicketGrantingPolicyTest
AbstractKerberosFlags super( '0','0','64','-128','0','0', ) ... length=6
[0]=0
[1]=0
[2]=64
[3]=-128
[4]=0
[5]=0
ticket.getEncTicketPart().getFlags().isInvalid()=true
Tests run: 12, Failures: 1, Errors: 0, Skipped: 11, Time elapsed: 1.059 
sec <<< FAILURE!
</snip>


To me it looks like either the code AbstractKerberosFlags C'tor is wrong 
or the fixes in r1033452 are wrong.
Any ideas (it may also be that I'm totally wrong after a sunny Sunday ....)

Regards
Felix

[1]
### Eclipse Workspace Patch 1.0
#P apacheds-kerberos-shared
Index: 
src/main/java/org/apache/directory/server/kerberos/shared/messages/value/flags/AbstractKerberosFlags.java
===================================================================
--- 
src/main/java/org/apache/directory/server/kerberos/shared/messages/value/flags/AbstractKerberosFlags.java

(revision 1034938)
+++ 
src/main/java/org/apache/directory/server/kerberos/shared/messages/value/flags/AbstractKerberosFlags.java

(working copy)
@@ -56,6 +56,13 @@
      public AbstractKerberosFlags( byte[] flags )
      {
          super( flags );
+        System.out.print("AbstractKerberosFlags super( ");
+        for(byte a:flags){
+            System.out.print( "'" + a +  "',");
+        }
+        System.out.println(" ) ... length=" + flags.length);
+        for(int i = 0; i < getBytes().length;i++)
+            System.out.println("[" + i + "]=" + getBytes()[i]);
          value = ( ( getBytes()[0] & 0x00F ) << 24 ) | ( ( 
getBytes()[1] & 0x00FF ) << 16 ) | ( ( getBytes()[2] & 0x00FF ) << 8 )
| 
( 0x00FF & getBytes()[3] );
      }




On 11/12/2010 05:46 PM, Emmanuel Lecharny wrote:
> On 11/12/10 5:30 PM, Felix Knecht wrote:
>> I'm trying to fix the some test failures I (I think so) introduced
>> switching some interface to enum.
>> I have 3 ErrorType classes in ApacheDS:
>> ./kerberos-codec/src/main/java/org/apache/directory/shared/kerberos/exceptions/ErrorType.java
>>
>> ./kerberos-shared/src/main/java/org/apache/directory/server/kerberos/shared/exceptions/ErrorType.java
>>
>> ./protocol-changepw/src/main/java/org/apache/directory/server/changepw/exceptions/ErrorType.java
>>
>>
>> Do they need to have an integer ErrorCode or would it be sufficient
>> transforming them to enums just having an error message like
>> KDC_ERR_NONE( "No error" ),
>> instead of
>> KDC_ERR_NONE( 0, "No error" ),
>
> IMO, having an error code could help in the future.
>


Mime
View raw message