[jira] [Commented] (SSHD-700) SSHD does not suppot agent forwarding for XShell and XAgent

2016-09-28 Thread Li Fangning (JIRA)

[ 
https://issues.apache.org/jira/browse/SSHD-700?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15531615#comment-15531615
 ] 

Li Fangning commented on SSHD-700:
--

I have pulled the latest code in "SSHD-700" branch, compile and test.
The problem is the same as before.

I have uploaded the new debug.log.
Thanks.

> SSHD does not suppot agent forwarding for XShell and XAgent
> ---
>
> Key: SSHD-700
> URL: https://issues.apache.org/jira/browse/SSHD-700
> Project: MINA SSHD
>  Issue Type: New Feature
>Affects Versions: 1.2.0
> Environment: Windows 10 and CentOS 7
> XShell 5.0
>Reporter: Li Fangning
>Priority: Minor
> Attachments: SshdTest2.java, SshdTest3.java, debug.log, 
> environment.png
>
>
> I use MINA SSHD for both server side and client side:
> SSH client  --> MINA SSHD Server - MINA SSHD Client --> Target Linux Server
> I use XShell (http://www.netsarang.com/) as SSH client, and use XAgent with 
> XShell for target server authentication (Public Key Access with Agent 
> Forwarding).
> I have tried PuTTY (with pagent), SecureCRT, and openssh client in linux, 
> they are all passed. But when I try XShell with XAgent, the agent forwarding 
> phase is failed.
> When I check the debug log and source code of MINA SSHD, I find that SSHD 
> only handle the "auth-agent-...@openssh.com" request type (in 
> org.apache.sshd.server.channel.ChannelSession#handleInternalRequest), which 
> is OK for PuTTY, SecureCRT and openssh client. But XShell send a 
> "auth-agent-req" request (without "@openssh.com"), so SSHD not handle the 
> request.
> I have try to change the source code, add "auth-agent-req" to the 
> "switch-case" in handleInternalRequest, but the authentication is blocked.
> I have attached my code, please help me solve the problem.
> Thanks a lot.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Updated] (SSHD-700) SSHD does not suppot agent forwarding for XShell and XAgent

2016-09-28 Thread Li Fangning (JIRA)

 [ 
https://issues.apache.org/jira/browse/SSHD-700?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Li Fangning updated SSHD-700:
-
Attachment: debug.log

> SSHD does not suppot agent forwarding for XShell and XAgent
> ---
>
> Key: SSHD-700
> URL: https://issues.apache.org/jira/browse/SSHD-700
> Project: MINA SSHD
>  Issue Type: New Feature
>Affects Versions: 1.2.0
> Environment: Windows 10 and CentOS 7
> XShell 5.0
>Reporter: Li Fangning
>Priority: Minor
> Attachments: SshdTest2.java, SshdTest3.java, debug.log, 
> environment.png
>
>
> I use MINA SSHD for both server side and client side:
> SSH client  --> MINA SSHD Server - MINA SSHD Client --> Target Linux Server
> I use XShell (http://www.netsarang.com/) as SSH client, and use XAgent with 
> XShell for target server authentication (Public Key Access with Agent 
> Forwarding).
> I have tried PuTTY (with pagent), SecureCRT, and openssh client in linux, 
> they are all passed. But when I try XShell with XAgent, the agent forwarding 
> phase is failed.
> When I check the debug log and source code of MINA SSHD, I find that SSHD 
> only handle the "auth-agent-...@openssh.com" request type (in 
> org.apache.sshd.server.channel.ChannelSession#handleInternalRequest), which 
> is OK for PuTTY, SecureCRT and openssh client. But XShell send a 
> "auth-agent-req" request (without "@openssh.com"), so SSHD not handle the 
> request.
> I have try to change the source code, add "auth-agent-req" to the 
> "switch-case" in handleInternalRequest, but the authentication is blocked.
> I have attached my code, please help me solve the problem.
> Thanks a lot.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Updated] (SSHD-700) SSHD does not suppot agent forwarding for XShell and XAgent

2016-09-28 Thread Li Fangning (JIRA)

 [ 
https://issues.apache.org/jira/browse/SSHD-700?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Li Fangning updated SSHD-700:
-
Attachment: (was: debug.log)

> SSHD does not suppot agent forwarding for XShell and XAgent
> ---
>
> Key: SSHD-700
> URL: https://issues.apache.org/jira/browse/SSHD-700
> Project: MINA SSHD
>  Issue Type: New Feature
>Affects Versions: 1.2.0
> Environment: Windows 10 and CentOS 7
> XShell 5.0
>Reporter: Li Fangning
>Priority: Minor
> Attachments: SshdTest2.java, SshdTest3.java, debug.log, 
> environment.png
>
>
> I use MINA SSHD for both server side and client side:
> SSH client  --> MINA SSHD Server - MINA SSHD Client --> Target Linux Server
> I use XShell (http://www.netsarang.com/) as SSH client, and use XAgent with 
> XShell for target server authentication (Public Key Access with Agent 
> Forwarding).
> I have tried PuTTY (with pagent), SecureCRT, and openssh client in linux, 
> they are all passed. But when I try XShell with XAgent, the agent forwarding 
> phase is failed.
> When I check the debug log and source code of MINA SSHD, I find that SSHD 
> only handle the "auth-agent-...@openssh.com" request type (in 
> org.apache.sshd.server.channel.ChannelSession#handleInternalRequest), which 
> is OK for PuTTY, SecureCRT and openssh client. But XShell send a 
> "auth-agent-req" request (without "@openssh.com"), so SSHD not handle the 
> request.
> I have try to change the source code, add "auth-agent-req" to the 
> "switch-case" in handleInternalRequest, but the authentication is blocked.
> I have attached my code, please help me solve the problem.
> Thanks a lot.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (SSHD-700) SSHD does not suppot agent forwarding for XShell and XAgent

2016-09-28 Thread Li Fangning (JIRA)

[ 
https://issues.apache.org/jira/browse/SSHD-700?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15531610#comment-15531610
 ] 

Li Fangning commented on SSHD-700:
--

Thanks for your advice.

> SSHD does not suppot agent forwarding for XShell and XAgent
> ---
>
> Key: SSHD-700
> URL: https://issues.apache.org/jira/browse/SSHD-700
> Project: MINA SSHD
>  Issue Type: New Feature
>Affects Versions: 1.2.0
> Environment: Windows 10 and CentOS 7
> XShell 5.0
>Reporter: Li Fangning
>Priority: Minor
> Attachments: SshdTest2.java, SshdTest3.java, debug.log, 
> environment.png
>
>
> I use MINA SSHD for both server side and client side:
> SSH client  --> MINA SSHD Server - MINA SSHD Client --> Target Linux Server
> I use XShell (http://www.netsarang.com/) as SSH client, and use XAgent with 
> XShell for target server authentication (Public Key Access with Agent 
> Forwarding).
> I have tried PuTTY (with pagent), SecureCRT, and openssh client in linux, 
> they are all passed. But when I try XShell with XAgent, the agent forwarding 
> phase is failed.
> When I check the debug log and source code of MINA SSHD, I find that SSHD 
> only handle the "auth-agent-...@openssh.com" request type (in 
> org.apache.sshd.server.channel.ChannelSession#handleInternalRequest), which 
> is OK for PuTTY, SecureCRT and openssh client. But XShell send a 
> "auth-agent-req" request (without "@openssh.com"), so SSHD not handle the 
> request.
> I have try to change the source code, add "auth-agent-req" to the 
> "switch-case" in handleInternalRequest, but the authentication is blocked.
> I have attached my code, please help me solve the problem.
> Thanks a lot.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (SSHD-700) SSHD does not suppot agent forwarding for XShell and XAgent

2016-09-28 Thread Goldstein Lyor (JIRA)

[ 
https://issues.apache.org/jira/browse/SSHD-700?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15529984#comment-15529984
 ] 

Goldstein Lyor commented on SSHD-700:
-

Please get latest https://github.com/lgoldstein/mina-sshd/tree/SSHD-700 - I 
have not merged the changes in the master 1.4 branch so no wonder your code 
still does not work...

> SSHD does not suppot agent forwarding for XShell and XAgent
> ---
>
> Key: SSHD-700
> URL: https://issues.apache.org/jira/browse/SSHD-700
> Project: MINA SSHD
>  Issue Type: New Feature
>Affects Versions: 1.2.0
> Environment: Windows 10 and CentOS 7
> XShell 5.0
>Reporter: Li Fangning
>Priority: Minor
> Attachments: SshdTest2.java, SshdTest3.java, debug.log, 
> environment.png
>
>
> I use MINA SSHD for both server side and client side:
> SSH client  --> MINA SSHD Server - MINA SSHD Client --> Target Linux Server
> I use XShell (http://www.netsarang.com/) as SSH client, and use XAgent with 
> XShell for target server authentication (Public Key Access with Agent 
> Forwarding).
> I have tried PuTTY (with pagent), SecureCRT, and openssh client in linux, 
> they are all passed. But when I try XShell with XAgent, the agent forwarding 
> phase is failed.
> When I check the debug log and source code of MINA SSHD, I find that SSHD 
> only handle the "auth-agent-...@openssh.com" request type (in 
> org.apache.sshd.server.channel.ChannelSession#handleInternalRequest), which 
> is OK for PuTTY, SecureCRT and openssh client. But XShell send a 
> "auth-agent-req" request (without "@openssh.com"), so SSHD not handle the 
> request.
> I have try to change the source code, add "auth-agent-req" to the 
> "switch-case" in handleInternalRequest, but the authentication is blocked.
> I have attached my code, please help me solve the problem.
> Thanks a lot.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (SSHD-700) SSHD does not suppot agent forwarding for XShell and XAgent

2016-09-28 Thread Goldstein Lyor (JIRA)

[ 
https://issues.apache.org/jira/browse/SSHD-700?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15529971#comment-15529971
 ] 

Goldstein Lyor commented on SSHD-700:
-

Hi Li,

To answer some of your issues:

- The SSH client should be a singleton - there are no multi threading issues.
- The SSH_AUTH_SOCK property is not mixed - each command gets its own 
environment instance
- I have never used agent forwarding code so cannot advise you

Lyor

> SSHD does not suppot agent forwarding for XShell and XAgent
> ---
>
> Key: SSHD-700
> URL: https://issues.apache.org/jira/browse/SSHD-700
> Project: MINA SSHD
>  Issue Type: New Feature
>Affects Versions: 1.2.0
> Environment: Windows 10 and CentOS 7
> XShell 5.0
>Reporter: Li Fangning
>Priority: Minor
> Attachments: SshdTest2.java, SshdTest3.java, debug.log, 
> environment.png
>
>
> I use MINA SSHD for both server side and client side:
> SSH client  --> MINA SSHD Server - MINA SSHD Client --> Target Linux Server
> I use XShell (http://www.netsarang.com/) as SSH client, and use XAgent with 
> XShell for target server authentication (Public Key Access with Agent 
> Forwarding).
> I have tried PuTTY (with pagent), SecureCRT, and openssh client in linux, 
> they are all passed. But when I try XShell with XAgent, the agent forwarding 
> phase is failed.
> When I check the debug log and source code of MINA SSHD, I find that SSHD 
> only handle the "auth-agent-...@openssh.com" request type (in 
> org.apache.sshd.server.channel.ChannelSession#handleInternalRequest), which 
> is OK for PuTTY, SecureCRT and openssh client. But XShell send a 
> "auth-agent-req" request (without "@openssh.com"), so SSHD not handle the 
> request.
> I have try to change the source code, add "auth-agent-req" to the 
> "switch-case" in handleInternalRequest, but the authentication is blocked.
> I have attached my code, please help me solve the problem.
> Thanks a lot.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


Re: Apache Mina sharing Session in UDP

2016-09-28 Thread Emmanuel Lécharny
Le 28/09/16 à 15:13, rafrl a écrit :
> Dears,
>
> I have a problem using apache mina UDP server. I receive two connections are
> two sources with different ip but leaving the same port. The mina it is not
> creat a new sessions for each connection and is differentiating sessions and
> mixing the defined attributes. Someone passed a similar problem ?
>
> Thank's

Please don't cross post. This mailing list is for discussion related to
the MINA project development, not for MINA users problems.



Apache Mina sharing Session in UDP

2016-09-28 Thread rafrl
Dears,

I have a problem using apache mina UDP server. I receive two connections are
two sources with different ip but leaving the same port. The mina it is not
creat a new sessions for each connection and is differentiating sessions and
mixing the defined attributes. Someone passed a similar problem ?

Thank's



--
View this message in context: 
http://apache-mina.10907.n7.nabble.com/Apache-Mina-sharing-Session-in-UDP-tp51329.html
Sent from the Apache MINA Developer Forum mailing list archive at Nabble.com.


[jira] [Updated] (SSHD-700) SSHD does not suppot agent forwarding for XShell and XAgent

2016-09-28 Thread Li Fangning (JIRA)

 [ 
https://issues.apache.org/jira/browse/SSHD-700?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Li Fangning updated SSHD-700:
-
Attachment: environment.png
debug.log
SshdTest3.java

> SSHD does not suppot agent forwarding for XShell and XAgent
> ---
>
> Key: SSHD-700
> URL: https://issues.apache.org/jira/browse/SSHD-700
> Project: MINA SSHD
>  Issue Type: New Feature
>Affects Versions: 1.2.0
> Environment: Windows 10 and CentOS 7
> XShell 5.0
>Reporter: Li Fangning
>Priority: Minor
> Attachments: SshdTest2.java, SshdTest3.java, debug.log, 
> environment.png
>
>
> I use MINA SSHD for both server side and client side:
> SSH client  --> MINA SSHD Server - MINA SSHD Client --> Target Linux Server
> I use XShell (http://www.netsarang.com/) as SSH client, and use XAgent with 
> XShell for target server authentication (Public Key Access with Agent 
> Forwarding).
> I have tried PuTTY (with pagent), SecureCRT, and openssh client in linux, 
> they are all passed. But when I try XShell with XAgent, the agent forwarding 
> phase is failed.
> When I check the debug log and source code of MINA SSHD, I find that SSHD 
> only handle the "auth-agent-...@openssh.com" request type (in 
> org.apache.sshd.server.channel.ChannelSession#handleInternalRequest), which 
> is OK for PuTTY, SecureCRT and openssh client. But XShell send a 
> "auth-agent-req" request (without "@openssh.com"), so SSHD not handle the 
> request.
> I have try to change the source code, add "auth-agent-req" to the 
> "switch-case" in handleInternalRequest, but the authentication is blocked.
> I have attached my code, please help me solve the problem.
> Thanks a lot.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Updated] (SSHD-700) SSHD does not suppot agent forwarding for XShell and XAgent

2016-09-28 Thread Li Fangning (JIRA)

 [ 
https://issues.apache.org/jira/browse/SSHD-700?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Li Fangning updated SSHD-700:
-
Attachment: (was: debug.log)

> SSHD does not suppot agent forwarding for XShell and XAgent
> ---
>
> Key: SSHD-700
> URL: https://issues.apache.org/jira/browse/SSHD-700
> Project: MINA SSHD
>  Issue Type: New Feature
>Affects Versions: 1.2.0
> Environment: Windows 10 and CentOS 7
> XShell 5.0
>Reporter: Li Fangning
>Priority: Minor
> Attachments: SshdTest2.java
>
>
> I use MINA SSHD for both server side and client side:
> SSH client  --> MINA SSHD Server - MINA SSHD Client --> Target Linux Server
> I use XShell (http://www.netsarang.com/) as SSH client, and use XAgent with 
> XShell for target server authentication (Public Key Access with Agent 
> Forwarding).
> I have tried PuTTY (with pagent), SecureCRT, and openssh client in linux, 
> they are all passed. But when I try XShell with XAgent, the agent forwarding 
> phase is failed.
> When I check the debug log and source code of MINA SSHD, I find that SSHD 
> only handle the "auth-agent-...@openssh.com" request type (in 
> org.apache.sshd.server.channel.ChannelSession#handleInternalRequest), which 
> is OK for PuTTY, SecureCRT and openssh client. But XShell send a 
> "auth-agent-req" request (without "@openssh.com"), so SSHD not handle the 
> request.
> I have try to change the source code, add "auth-agent-req" to the 
> "switch-case" in handleInternalRequest, but the authentication is blocked.
> I have attached my code, please help me solve the problem.
> Thanks a lot.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Updated] (SSHD-700) SSHD does not suppot agent forwarding for XShell and XAgent

2016-09-28 Thread Li Fangning (JIRA)

 [ 
https://issues.apache.org/jira/browse/SSHD-700?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Li Fangning updated SSHD-700:
-
Attachment: (was: SshdTest3.java)

> SSHD does not suppot agent forwarding for XShell and XAgent
> ---
>
> Key: SSHD-700
> URL: https://issues.apache.org/jira/browse/SSHD-700
> Project: MINA SSHD
>  Issue Type: New Feature
>Affects Versions: 1.2.0
> Environment: Windows 10 and CentOS 7
> XShell 5.0
>Reporter: Li Fangning
>Priority: Minor
> Attachments: SshdTest2.java
>
>
> I use MINA SSHD for both server side and client side:
> SSH client  --> MINA SSHD Server - MINA SSHD Client --> Target Linux Server
> I use XShell (http://www.netsarang.com/) as SSH client, and use XAgent with 
> XShell for target server authentication (Public Key Access with Agent 
> Forwarding).
> I have tried PuTTY (with pagent), SecureCRT, and openssh client in linux, 
> they are all passed. But when I try XShell with XAgent, the agent forwarding 
> phase is failed.
> When I check the debug log and source code of MINA SSHD, I find that SSHD 
> only handle the "auth-agent-...@openssh.com" request type (in 
> org.apache.sshd.server.channel.ChannelSession#handleInternalRequest), which 
> is OK for PuTTY, SecureCRT and openssh client. But XShell send a 
> "auth-agent-req" request (without "@openssh.com"), so SSHD not handle the 
> request.
> I have try to change the source code, add "auth-agent-req" to the 
> "switch-case" in handleInternalRequest, but the authentication is blocked.
> I have attached my code, please help me solve the problem.
> Thanks a lot.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (SSHD-700) SSHD does not suppot agent forwarding for XShell and XAgent

2016-09-28 Thread Li Fangning (JIRA)

[ 
https://issues.apache.org/jira/browse/SSHD-700?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15529805#comment-15529805
 ] 

Li Fangning commented on SSHD-700:
--

Hi, Goldstein

Thank you very much for reviewing my code.
I really appreciate it.

When I started using Apache SSHD a few months ago, due to a lack of 
documentation, I could only use it by learning test cases and constant attempts.
Today I found the professional guidance document has been provided, and 
sincerely happy. Thanks for all your efforts.

I made modifications to my code based on your comments, and re-run it with SSHD 
1.4.0-snapshot, the problem remains.
And I have some questions:
1. I would have liked to use the SSH Client singleton, but some configurations 
may not share for different server shells. If I configure the agentFactory for 
the client instance, but the user do not provide agent forward  property within 
server connection, an exception may throw. In addition, I also worry about 
thread safety for the client object, the "SSH_AUTH_SOCK" property must not be 
mixed for different users. So I prefer to use different SshClient object for 
each server shell, and close it after the client session is closed.
2. If the "channel.setAgentForwarding(true)" is not invoked, the keys won't be 
forwarded to the next host when I use "ssh -A nextHost" (The "SSH_AUTH_SOCK" 
system environment variable won't be set).
3. I have tried the UnixAgentFactory with tomcat jni and APR library in Linux 
server, but the problem is still there. I usually coding on Windows, and the 
ProxyAgentFactory indeed work for the standard agent forwarding 
(auth-agent-...@openssh.com).
The attached file "environment.png" is my environment to reproduce the problem. 
I use Mina SSHD to develop a SSH jump server.
If it is not clear enough, please let me know.

Thanks a lot.

> SSHD does not suppot agent forwarding for XShell and XAgent
> ---
>
> Key: SSHD-700
> URL: https://issues.apache.org/jira/browse/SSHD-700
> Project: MINA SSHD
>  Issue Type: New Feature
>Affects Versions: 1.2.0
> Environment: Windows 10 and CentOS 7
> XShell 5.0
>Reporter: Li Fangning
>Priority: Minor
> Attachments: SshdTest2.java, SshdTest3.java, debug.log
>
>
> I use MINA SSHD for both server side and client side:
> SSH client  --> MINA SSHD Server - MINA SSHD Client --> Target Linux Server
> I use XShell (http://www.netsarang.com/) as SSH client, and use XAgent with 
> XShell for target server authentication (Public Key Access with Agent 
> Forwarding).
> I have tried PuTTY (with pagent), SecureCRT, and openssh client in linux, 
> they are all passed. But when I try XShell with XAgent, the agent forwarding 
> phase is failed.
> When I check the debug log and source code of MINA SSHD, I find that SSHD 
> only handle the "auth-agent-...@openssh.com" request type (in 
> org.apache.sshd.server.channel.ChannelSession#handleInternalRequest), which 
> is OK for PuTTY, SecureCRT and openssh client. But XShell send a 
> "auth-agent-req" request (without "@openssh.com"), so SSHD not handle the 
> request.
> I have try to change the source code, add "auth-agent-req" to the 
> "switch-case" in handleInternalRequest, but the authentication is blocked.
> I have attached my code, please help me solve the problem.
> Thanks a lot.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)


[jira] [Commented] (SSHD-700) SSHD does not suppot agent forwarding for XShell and XAgent

2016-09-28 Thread Goldstein Lyor (JIRA)

[ 
https://issues.apache.org/jira/browse/SSHD-700?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15528735#comment-15528735
 ] 

Goldstein Lyor commented on SSHD-700:
-

Hi Li,

I have not yet been able to set up the test environment (like I said, it will 
take some time), but I do have a few preliminary remarks after reviewing the 
code you posted.

# The code creates a new client instance every time {{startShell}} is called. 
This is *wrong* (please read the documentation). The idea is to create *one* 
client instance during the _main_ initialization and re-use it again and again 
to create sessions. The client should be stopped when the application exits 
(not really 100% necessary, but highly recommended). The code you posted 
creates lots of thread, pools, etc. where they are not needed.
# The code does not register a {{ForwardingFilter}} at the client or the server 
- this means that *no forwarding may occur* - again, please read the 
documentation that was recently posted on the [Github MINA 
site|https://github.com/apache/mina-sshd].
# The authentication process is *wrong*- if will always fail the 1st time and 
require the password since you do not provide a key-pair identity - again, 
please read the documentation how to properly execute the authentication.
# Please don't 2nd guess the API - if you need a {{ChannelShell}} call the 
appropriate API:
{code:java}
ChannelShell channel = session.createShellChannel();
{code}
# Your code checks
{code:java}
if (env.getEnv().containsKey("SSH_AUTH_SOCK")) {
channel.setAgentForwarding(true);
}
{code}
you actually already checked this in:
{code:java}
if (env.getEnv().containsKey(SshAgent.SSH_AUTHSOCKET_ENV_NAME))
{code}
# you are setting up the server to use the {{ProxyAgentFactory}} - which 
actually uses {{UnixAgentFactory}} and this requires the [Apache Portable 
Runtime Library|https://apr.apache.org/] - have you installed it ? configured 
it ? Made sure it is available for loading in the {{LD_LIBRARY_PATH}} (see 
{{AprLibrary}} class) ?
In this context, I have never seen this kind of agent proxy run on _Windows_ - 
it's not impossible, just much more complicated than _Unix_. I mention this 
because _XShell_ and _XAgent_ are _Windows_ application and I am not clear as 
to the set-up you are trying to test (see further below).
# Finally, in order to correctly debug this issue, please describe *exactly* 
the setup your are trying to use - who is the client (_XShell_?) ? Who is the 
server ? Who is the agent (_XAgent ?) ? How are they set up, etc... I recommend 
you attach some text or PDF document that explains this - perhaps some drawing 
of the set up environment

> SSHD does not suppot agent forwarding for XShell and XAgent
> ---
>
> Key: SSHD-700
> URL: https://issues.apache.org/jira/browse/SSHD-700
> Project: MINA SSHD
>  Issue Type: New Feature
>Affects Versions: 1.2.0
> Environment: Windows 10 and CentOS 7
> XShell 5.0
>Reporter: Li Fangning
>Priority: Minor
> Attachments: SshdTest2.java, SshdTest3.java, debug.log
>
>
> I use MINA SSHD for both server side and client side:
> SSH client  --> MINA SSHD Server - MINA SSHD Client --> Target Linux Server
> I use XShell (http://www.netsarang.com/) as SSH client, and use XAgent with 
> XShell for target server authentication (Public Key Access with Agent 
> Forwarding).
> I have tried PuTTY (with pagent), SecureCRT, and openssh client in linux, 
> they are all passed. But when I try XShell with XAgent, the agent forwarding 
> phase is failed.
> When I check the debug log and source code of MINA SSHD, I find that SSHD 
> only handle the "auth-agent-...@openssh.com" request type (in 
> org.apache.sshd.server.channel.ChannelSession#handleInternalRequest), which 
> is OK for PuTTY, SecureCRT and openssh client. But XShell send a 
> "auth-agent-req" request (without "@openssh.com"), so SSHD not handle the 
> request.
> I have try to change the source code, add "auth-agent-req" to the 
> "switch-case" in handleInternalRequest, but the authentication is blocked.
> I have attached my code, please help me solve the problem.
> Thanks a lot.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)