aboutsummaryrefslogtreecommitdiffstats
path: root/src/net/sourceforge/jsocks/UDPEncapsulation.java
diff options
context:
space:
mode:
Diffstat (limited to 'src/net/sourceforge/jsocks/UDPEncapsulation.java')
-rw-r--r--src/net/sourceforge/jsocks/UDPEncapsulation.java58
1 files changed, 29 insertions, 29 deletions
diff --git a/src/net/sourceforge/jsocks/UDPEncapsulation.java b/src/net/sourceforge/jsocks/UDPEncapsulation.java
index efeb0ed..e965942 100644
--- a/src/net/sourceforge/jsocks/UDPEncapsulation.java
+++ b/src/net/sourceforge/jsocks/UDPEncapsulation.java
@@ -1,29 +1,29 @@
-package net.sourceforge.jsocks;
-/**
- This interface provides for datagram encapsulation for SOCKSv5 protocol.
- <p>
- SOCKSv5 allows for datagrams to be encapsulated for purposes of integrity
- and/or authenticity. How it should be done is aggreed during the
- authentication stage, and is authentication dependent. This interface is
- provided to allow this encapsulation.
- @see Authentication
-*/
-public interface UDPEncapsulation{
-
- /**
- This method should provide any authentication depended transformation
- on datagrams being send from/to the client.
-
- @param data Datagram data (including any SOCKS related bytes), to be
- encapsulated/decapsulated.
- @param out Wether the data is being send out. If true method should
- encapsulate/encrypt data, otherwise it should decapsulate/
- decrypt data.
- @throw IOException if for some reason data can be transformed correctly.
- @return Should return byte array containing data after transformation.
- It is possible to return same array as input, if transformation
- only involves bit mangling, and no additional data is being
- added or removed.
- */
- byte[] udpEncapsulate(byte[] data, boolean out) throws java.io.IOException;
-}
+package net.sourceforge.jsocks;
+/**
+ This interface provides for datagram encapsulation for SOCKSv5 protocol.
+ <p>
+ SOCKSv5 allows for datagrams to be encapsulated for purposes of integrity
+ and/or authenticity. How it should be done is aggreed during the
+ authentication stage, and is authentication dependent. This interface is
+ provided to allow this encapsulation.
+ @see Authentication
+*/
+public interface UDPEncapsulation{
+
+ /**
+ This method should provide any authentication depended transformation
+ on datagrams being send from/to the client.
+
+ @param data Datagram data (including any SOCKS related bytes), to be
+ encapsulated/decapsulated.
+ @param out Wether the data is being send out. If true method should
+ encapsulate/encrypt data, otherwise it should decapsulate/
+ decrypt data.
+ @throw IOException if for some reason data can be transformed correctly.
+ @return Should return byte array containing data after transformation.
+ It is possible to return same array as input, if transformation
+ only involves bit mangling, and no additional data is being
+ added or removed.
+ */
+ byte[] udpEncapsulate(byte[] data, boolean out) throws java.io.IOException;
+}