如何解决Mule 4版本:Mule 4.3中的Mule SFTP Kerberos用户名和密码提示



我面临SFTP Kerberos用户名和首次运行服务的提示。服务的后续运行正常。当SFTP位置在网络中时,Kerberos不会提示。如果是不同的网络,则会要求提供Kerberos用户名和密码。

启动Bean:org.mule.runtime.module.extension.internal.runtime.config.ConfigurationProviderToolingAdapter-Database_config信息2020-07-29 14:21:42151[WrapperListener_start_runner][processor:;event:]org.mule.runtime.core.privileged.lifecycle.AbstractLifecycleManager:启动Bean:org.mule.untime.module.extension.internal.runtime.config.ConfigurationProviderToolingAdapter-SFTP_configKerberos用户名[nmarathe]:

nmarathe:的Kerberos密码

信息2020-07-29 14:21:55531[WrapperListener_start_runner][processor:;event:]org.mule.runtime.core.privileged.lifecycle.AbstractLifecycleManager:启动Bean:org.mule.untime.module.extension.internal.runtime.config.ConfigurationProviderToolingAdapter-Java_config

关键提示:preferredAuthenticationMethods="公钥、密码、键盘交互";这是部署应用程序失败。

<sftp:config name="SFTP_Config" doc:name="SFTP Config"
doc:id="b5762201-a868-4a1a-ab96-9b7669451708">
<sftp:connection
workingDir="${sftp.path}"
host="${sftp.host}" username="${sftp.user}"
password="${sftp.password}" port="${sftp.port}" connectionTimeout="120" preferredAuthenticationMethods="publickey,password,keyboard-interactive">
<reconnection>
<reconnect frequency="30000" count="20" />
</reconnection>
</sftp:connection>
<expiration-policy maxIdleTime="2" timeUnit="MINUTES" />
</sftp:config>

错误:Mule Registry 中未定义元素"公钥、密码、键盘交互">

在对这个问题进行了大量挖掘之后。我只从文档中找到了一个解决方案。参考:https://docs.mulesoft.com/sftp-connector/1.3/sftp-documentation#parameters-2

我刚刚在SFTP连接中添加了以下代码。preferredAuthenticationMethods="#[['PUBLI_KEY','KEYBOARD_INTERACTIVE','PASSWORD']]";

PFB详细代码解决了我的问题。

<sftp:config name="SFTP_Config" doc:name="SFTP Config">
<sftp:connection
workingDir="${sftp.path}"
host="${sftp.host}" username="${sftp.user}"
password="${sftp.wms.password}" port="${sftp.port}" connectionTimeout="120" preferredAuthenticationMethods="#[['PUBLIC_KEY','KEYBOARD_INTERACTIVE','PASSWORD']]">
<reconnection>
<reconnect frequency="30000" count="20" />
</reconnection>
</sftp:connection>
<expiration-policy maxIdleTime="2" timeUnit="MINUTES" />
</sftp:config>

最新更新