Skip to content

How can I authorize? #167

@MJ-Youn

Description

@MJ-Youn

Hi, i use jglobus in my pc.

package kr.co.ymtech;

import java.io.IOException;
import java.util.Vector;

import org.globus.ftp.GridFTPClient;
import org.globus.ftp.exception.ClientException;
import org.globus.ftp.exception.ServerException;

public class Main {
	
	public static String message;
	
	public static void main(String[] args) {
		
		try {
			GridFTPClient gridFTPClient = new GridFTPClient("192.168.56.123", 2811);
			
			Vector<?> vector = gridFTPClient.list();
			System.out.println(vector);
		} catch (ServerException | IOException | ClientException e) {
			e.printStackTrace();
		}
	}
	
}

Error

org.globus.ftp.exception.ClientException: Server authorization has not been performed. Custom message: Need to perform authorization first (error code 1)
	at org.globus.ftp.Session.compareTransferParams(Session.java:116)
	at org.globus.ftp.GridFTPSession.matches(GridFTPSession.java:106)
	at org.globus.ftp.GridFTPClient.checkTransferParamsGet(GridFTPClient.java:173)
	at org.globus.ftp.FTPClient.performTransfer(FTPClient.java:751)
	at org.globus.ftp.FTPClient.list(FTPClient.java:516)
	at org.globus.ftp.FTPClient.list(FTPClient.java:450)
	at org.globus.ftp.GridFTPClient.list(GridFTPClient.java:123)
	at org.globus.ftp.FTPClient.list(FTPClient.java:419)
	at org.globus.ftp.FTPClient.list(FTPClient.java:394)
	at kr.co.ymtech.Main.main(Main.java:31)

but i fase this error.
I think, because, this error have not authorization info.
I don't know to run gridftpclient with authorization.
please advice.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions