mirror of
https://github.com/hierynomus/sshj.git
synced 2025-12-08 08:10:55 +03:00
javadoc cleanup
This commit is contained in:
@@ -89,7 +89,7 @@ public class Buffer<T extends Buffer<T>> {
|
|||||||
protected int rpos;
|
protected int rpos;
|
||||||
protected int wpos;
|
protected int wpos;
|
||||||
|
|
||||||
/** @see {@link #DEFAULT_SIZE} */
|
/** @see #DEFAULT_SIZE */
|
||||||
public Buffer() {
|
public Buffer() {
|
||||||
this(DEFAULT_SIZE);
|
this(DEFAULT_SIZE);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -201,7 +201,7 @@ public class SecurityUtils {
|
|||||||
*
|
*
|
||||||
* @param algorithm MessageDigest algorithm name
|
* @param algorithm MessageDigest algorithm name
|
||||||
*
|
*
|
||||||
* @return
|
* @return new instance
|
||||||
*
|
*
|
||||||
* @throws NoSuchAlgorithmException
|
* @throws NoSuchAlgorithmException
|
||||||
* @throws NoSuchProviderException
|
* @throws NoSuchProviderException
|
||||||
|
|||||||
@@ -56,10 +56,10 @@ public interface Channel
|
|||||||
void confirm()
|
void confirm()
|
||||||
throws TransportException;
|
throws TransportException;
|
||||||
|
|
||||||
/** Returns the IP of where the forwarded connection originates. */
|
/** @return the IP of where the forwarded connection originates. */
|
||||||
String getOriginatorIP();
|
String getOriginatorIP();
|
||||||
|
|
||||||
/** Returns port from which the forwarded connection originates. */
|
/** @return port from which the forwarded connection originates. */
|
||||||
int getOriginatorPort();
|
int getOriginatorPort();
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -81,13 +81,13 @@ public interface Channel
|
|||||||
throws TransportException, ConnectionException;
|
throws TransportException, ConnectionException;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Returns whether auto-expansion of local window is set.
|
* @return whether auto-expansion of local window is set.
|
||||||
*
|
*
|
||||||
* @see #setAutoExpand(boolean)
|
* @see #setAutoExpand(boolean)
|
||||||
*/
|
*/
|
||||||
boolean getAutoExpand();
|
boolean getAutoExpand();
|
||||||
|
|
||||||
/** Returns the channel ID */
|
/** @return the channel ID */
|
||||||
int getID();
|
int getID();
|
||||||
|
|
||||||
/** @return the {@code InputStream} for this channel. */
|
/** @return the {@code InputStream} for this channel. */
|
||||||
@@ -121,7 +121,7 @@ public interface Channel
|
|||||||
* Sends an EOF message to the server for this channel; indicating that no more data will be sent by us. The {@code
|
* Sends an EOF message to the server for this channel; indicating that no more data will be sent by us. The {@code
|
||||||
* OutputStream} for this channel will be closed and no longer usable.
|
* OutputStream} for this channel will be closed and no longer usable.
|
||||||
*
|
*
|
||||||
* @throws TransportException
|
* @throws TransportException if there is an error sending the EOF message
|
||||||
*/
|
*/
|
||||||
void sendEOF()
|
void sendEOF()
|
||||||
throws TransportException;
|
throws TransportException;
|
||||||
@@ -131,7 +131,7 @@ public interface Channel
|
|||||||
* read from that stream. This is useful e.g. when a remote command produces a lot of output that would fill the
|
* read from that stream. This is useful e.g. when a remote command produces a lot of output that would fill the
|
||||||
* local window but you are not interested in reading from its {@code InputStream}.
|
* local window but you are not interested in reading from its {@code InputStream}.
|
||||||
*
|
*
|
||||||
* @param autoExpand
|
* @param autoExpand whether local windows should automatically expand
|
||||||
*/
|
*/
|
||||||
void setAutoExpand(boolean autoExpand);
|
void setAutoExpand(boolean autoExpand);
|
||||||
|
|
||||||
|
|||||||
@@ -28,7 +28,7 @@ public interface SessionFactory {
|
|||||||
* @return the opened {@code session} channel
|
* @return the opened {@code session} channel
|
||||||
*
|
*
|
||||||
* @throws SSHException
|
* @throws SSHException
|
||||||
* @see {@link Session}
|
* @see Session
|
||||||
*/
|
*/
|
||||||
Session startSession()
|
Session startSession()
|
||||||
throws SSHException;
|
throws SSHException;
|
||||||
|
|||||||
@@ -23,13 +23,12 @@ import java.io.IOException;
|
|||||||
public interface ConnectListener {
|
public interface ConnectListener {
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Notify this listener of a new forwarded channel. An implementation should firstly {@link
|
* Notify this listener of a new forwarded channel. An implementation should firstly confirm or reject that
|
||||||
* Channel.Forwarded#confirm() confirm} or {@link Channel.Forwarded#reject(net.schmizz.sshj.connection.channel.OpenFailException.Reason,
|
* channel.
|
||||||
* String)} reject} that channel.
|
|
||||||
*
|
*
|
||||||
* @param chan the {@link Channel.Forwarded forwarded channel}
|
* @param chan the forwarded channel
|
||||||
*
|
*
|
||||||
* @throws IOException
|
* @throws IOException if there is a problem handling the channel
|
||||||
*/
|
*/
|
||||||
void gotConnect(Channel.Forwarded chan)
|
void gotConnect(Channel.Forwarded chan)
|
||||||
throws IOException;
|
throws IOException;
|
||||||
|
|||||||
@@ -22,7 +22,7 @@ import net.schmizz.sshj.transport.TransportException;
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* Handles forwarded {@code x11} channels. The actual request to forward X11 should be made from the specific {@link
|
* Handles forwarded {@code x11} channels. The actual request to forward X11 should be made from the specific {@link
|
||||||
* Session}.
|
* net.schmizz.sshj.connection.channel.direct.Session Session}.
|
||||||
*/
|
*/
|
||||||
public class X11Forwarder
|
public class X11Forwarder
|
||||||
extends AbstractForwardedChannelOpener {
|
extends AbstractForwardedChannelOpener {
|
||||||
@@ -43,8 +43,6 @@ public class X11Forwarder
|
|||||||
private final ConnectListener listener;
|
private final ConnectListener listener;
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Creates and registers itself with {@code conn}.
|
|
||||||
*
|
|
||||||
* @param conn connection layer
|
* @param conn connection layer
|
||||||
* @param listener listener which will be delegated {@link X11Channel}'s to next
|
* @param listener listener which will be delegated {@link X11Channel}'s to next
|
||||||
*/
|
*/
|
||||||
|
|||||||
@@ -12,26 +12,6 @@
|
|||||||
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
* See the License for the specific language governing permissions and
|
* See the License for the specific language governing permissions and
|
||||||
* limitations under the License.
|
* limitations under the License.
|
||||||
*
|
|
||||||
* This file may incorporate work covered by the following copyright and
|
|
||||||
* permission notice:
|
|
||||||
*
|
|
||||||
* Licensed to the Apache Software Foundation (ASF) under one
|
|
||||||
* or more contributor license agreements. See the NOTICE file
|
|
||||||
* distributed with this work for additional information
|
|
||||||
* regarding copyright ownership. The ASF licenses this file
|
|
||||||
* to you under the Apache License, Version 2.0 (the
|
|
||||||
* "License"); you may not use this file except in compliance
|
|
||||||
* with the License. You may obtain a copy of the License at
|
|
||||||
*
|
|
||||||
* http://www.apache.org/licenses/LICENSE-2.0
|
|
||||||
*
|
|
||||||
* Unless required by applicable law or agreed to in writing,
|
|
||||||
* software distributed under the License is distributed on an
|
|
||||||
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
|
|
||||||
* KIND, either express or implied. See the License for the
|
|
||||||
* specific language governing permissions and limitations
|
|
||||||
* under the License.
|
|
||||||
*/
|
*/
|
||||||
package net.schmizz.sshj.transport;
|
package net.schmizz.sshj.transport;
|
||||||
|
|
||||||
@@ -43,7 +23,7 @@ import net.schmizz.sshj.common.SSHException;
|
|||||||
public class TransportException
|
public class TransportException
|
||||||
extends SSHException {
|
extends SSHException {
|
||||||
|
|
||||||
/** @see {@link net.schmizz.concurrent.ExceptionChainer} */
|
/** @see ExceptionChainer */
|
||||||
public static final ExceptionChainer<TransportException> chainer = new ExceptionChainer<TransportException>() {
|
public static final ExceptionChainer<TransportException> chainer = new ExceptionChainer<TransportException>() {
|
||||||
public TransportException chain(Throwable t) {
|
public TransportException chain(Throwable t) {
|
||||||
if (t instanceof TransportException)
|
if (t instanceof TransportException)
|
||||||
|
|||||||
@@ -46,11 +46,7 @@ import java.security.PublicKey;
|
|||||||
/** Key exchange algorithm. */
|
/** Key exchange algorithm. */
|
||||||
public interface KeyExchange {
|
public interface KeyExchange {
|
||||||
|
|
||||||
/**
|
/** @return the computed H parameter */
|
||||||
* Retrieves the computed H parameter
|
|
||||||
*
|
|
||||||
* @return
|
|
||||||
*/
|
|
||||||
byte[] getH();
|
byte[] getH();
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@@ -60,18 +56,22 @@ public interface KeyExchange {
|
|||||||
*/
|
*/
|
||||||
Digest getHash();
|
Digest getHash();
|
||||||
|
|
||||||
|
/** @return the host key determined from server's response packets */
|
||||||
PublicKey getHostKey();
|
PublicKey getHostKey();
|
||||||
|
|
||||||
/** Retrieves the computed K parameter */
|
/** @return the computed K parameter */
|
||||||
byte[] getK();
|
byte[] getK();
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Initialize the key exchange algorithm.
|
* Initialize the key exchange algorithm.
|
||||||
*
|
*
|
||||||
|
* @param trans the transport
|
||||||
* @param V_S the server identification string
|
* @param V_S the server identification string
|
||||||
* @param V_C the client identification string
|
* @param V_C the client identification string
|
||||||
* @param I_S the server key init packet
|
* @param I_S the server key init packet
|
||||||
* @param I_C the client key init packet
|
* @param I_C the client key init packet
|
||||||
|
*
|
||||||
|
* @throws TransportException if there is an error sending a packet
|
||||||
*/
|
*/
|
||||||
void init(Transport trans, byte[] V_S, byte[] V_C, byte[] I_S, byte[] I_C)
|
void init(Transport trans, byte[] V_S, byte[] V_C, byte[] I_S, byte[] I_C)
|
||||||
throws TransportException;
|
throws TransportException;
|
||||||
@@ -79,9 +79,12 @@ public interface KeyExchange {
|
|||||||
/**
|
/**
|
||||||
* Process the next packet
|
* Process the next packet
|
||||||
*
|
*
|
||||||
|
* @param msg message identifier
|
||||||
* @param buffer the packet
|
* @param buffer the packet
|
||||||
*
|
*
|
||||||
* @return a boolean indicating if the processing is complete or if more packets are to be received
|
* @return a boolean indicating if the processing is complete or if more packets are to be received
|
||||||
|
*
|
||||||
|
* @throws TransportException if there is an error sending a packet
|
||||||
*/
|
*/
|
||||||
boolean next(Message msg, SSHPacket buffer)
|
boolean next(Message msg, SSHPacket buffer)
|
||||||
throws TransportException;
|
throws TransportException;
|
||||||
|
|||||||
Reference in New Issue
Block a user