code: public static int openAndBindPortToLocal(Connector sshConn, String remoteHost, int remotePort) throws JschRuntimeException {
  		final Session session = openSession(sshConn.getHost(), sshConn.getPort(), sshConn.getUser(), sshConn.getPassword());
  		if (session == null) {
  			throw new JschRuntimeException("Error to create SSH Session！");
  		}
  		final int localPort = generateLocalPort();
  		bindPort(session, remoteHost, remotePort, localPort);
  		return localPort;
  	}
docs: 打开SSH会话，并绑定远程端口到本地的一个随机端口
  
  @param sshConn SSH连接信息对象
  @param remoteHost 远程主机
  @param remotePort 远程端口
  @return 映射后的本地端口
  @throws JschRuntimeException 连接异常