Methods Summary |
---|
protected void | cryptoIn(java.nio.ByteBuffer source_buffer, java.nio.ByteBuffer target_buffer)
int rem = source_buffer.remaining();
for (int i=0;i<rem;i++){
byte b = source_buffer.get();
b = (byte)( b ^ mask[ read_position++ ]);
target_buffer.put( b );
if ( read_position == mask.length ){
read_position = 0;
}
}
|
protected void | cryptoOut(java.nio.ByteBuffer source_buffer, java.nio.ByteBuffer target_buffer)
int rem = source_buffer.remaining();
for (int i=0;i<rem;i++){
byte b = source_buffer.get();
b = (byte)( b ^ mask[ write_position++ ]);
target_buffer.put( b );
if ( write_position == mask.length ){
write_position = 0;
}
}
|
public java.lang.String | getName()
return( "XOR-" + mask.length*8 + getHelper().getName());
|
public boolean | isEncrypted()
return( true );
|