AuthenticationInformation QML Type

OPC UA 身份验证信息。更多

Import Statement: import QtOpcUa
Since: QtOpcUa 5.13
Status: Deprecated since 6.9

自 QtOpcUa 6.9 起,该类型已被弃用。我们强烈建议不要在新代码中使用它。

方法

详细说明

该类保存在服务器上进行登录所需的信息。

var authInfo = connection.authenticationInformation;
authInfo.setUsernameAuthentication("user1", "password");
connection.authenticationInformation = authInfo;

目前支持的身份验证方法有

  • 匿名
  • 用户名
  • 证书

另请参阅 setAnonymousAuthentication() 和setUsernameAuthentication()。

方法文档

setAnonymousAuthentication()

将身份验证方法设为匿名。


setUsernameAuthentication(string username, string password)

使用给定的usernamepassword 将身份验证方法设为用户名。


© 2025 The Qt Company Ltd. Documentation contributions included herein are the copyrights of their respective owners. The documentation provided herein is licensed under the terms of the GNU Free Documentation License version 1.3 as published by the Free Software Foundation. Qt and respective logos are trademarks of The Qt Company Ltd. in Finland and/or other countries worldwide. All other trademarks are property of their respective owners.