升级到 ThingWorx Navigate 1.9 > 就地升级 > Windchill 身份验证的所需配置步骤
  
Windchill 身份验证的所需配置步骤
使用 Windchill 身份验证时,用户打开 ThingWorx Navigate 后将被转至 Windchill 进行身份验证。然后,用户被转回 ThingWorx Navigate。有关技术详细信息,请参阅Windchill 身份验证的体系结构
每个用户必须在 ThingWorxWindchill 中都有帐户。一旦用户在 Windchill 中完成身份验证,就可以自动在 ThingWorx 中创建这些用户。在 ThingWorx 中创建用户后,管理员需要将用户添加到指定的 ThingWorx 组中,以支持访问 ThingWorx Navigate 任务。
Windchill 身份验证的先决条件:
必须配置 Windchill 使用 SSL。
必须用 SSL 必需的 Trustore 和 Keystore 文件更新 ThingWorx Integration Runtime。
必须配置 ThingWorx 使用 SSL。(推荐)
双向 SSL 已配置。有关详细信息,请参阅使用 SSL 进行安全连接
将 servlet 筛选器添加到 Apache Tomcat 配置
可使用 Windchill IdP 验证筛选器,将 ThingWorx 未验证的用户重定向到 Windchill 登录表单以获取身份验证凭据。成功完成身份验证后,ThingWorx 应用程序会接收到密钥和用户名。
您可以在 <Tomcat 安装目录>\webapps\Thingworx\WEB-INF\web.xmlThingWorx 侧配置筛选器。
1. 停止 Apache Tomcat 和 ThingWorx Integration Runtime。
2. 将 JAR 文件复制到 Tomcat 安装目录,如下所示:
a. 浏览至 ThingWorx-Navigate-Upgrade-<版本>-bundle\idp\
b. 将文件 ptc-identity-provider-authentication-filter-<版本>.jar 复制到此位置:
<Tomcat 安装位置>\webapps\Thingworx\WEB-INF\lib
3. 替换 Tomcat 安装目录中的 web.xml,如下所示:
a. 浏览到 <Tomcat 安装位置>\webapp\Thingworx\WEB-INF\
b. 复制 web.xml 并将该副本保存到其他位置。
c. 浏览至 ThingWorx-Navigate-Upgrade-<版本>-bundle\idp\twx-8.4.x\
d. 将文件 web.xml 复制到此位置:
<Tomcat 安装位置>\webapps\Thingworx\WEB-INF
4. 在文本编辑器中打开 <Tomcat 安装位置>\webapps\Thingworx\WEB-INF\web.xml
5. IdentityProviderAuthenticationFilterIdentityProviderKeyValidationFilter 筛选器的 [httphttps]://[windchill-host]:[windchill-port]/windchill-web-app] 中添加 Windchill 服务器详细信息。
6. 启动 Apache Tomcat 和 Integration Runtime。
7. ThingWorx Composer 中,打开 ptc-windchill-integration-connector-proxy
8. 单击“配置”
9. “内容源连接信息”下的“测试连接 URL”中输入 https://<Windchill 主机名>/Windchill/sslClientAuth/servlet/WindchillAuthGW/wt.httpgw.HTTPServer/echo
10. 单击“保存”
11. 搜索 ptc-identity-provider-authenticator,并将其打开。
12. 单击“配置”
13. 确保选中 CreateUserDynamically 复选框。
14. 单击“保存”
验证配置
管理员必须在 WindchillThingWorx 中具有相同的用户名。
如果您未在 Windchill 中进行更改,则名为 "Administrator" 的管理员用户已在安装 Windchill 时创建。使用配置的 ThingWorx 系统时,您可以作为该用户进行身份验证并具有像 ThingWorx 中的管理员用户一样的完全访问权限。
如果更改了管理员的用户名,则选择在 WindchillThingWorx 中通用的用户名,然后将该用户添加到 ThingWorx 和管理员用户组。
要验证 Windchill 身份验证配置:
1. 打开 ThingWorx URL。您将被转至 Windchill 进行身份验证。
2. 请提供 Windchill 管理员 (或配置为 ThingWorx 管理员的其他用户) 的登录凭据。浏览器转回 ThingWorx,随后 ThingWorx Composer 打开。
3. 请确认您现在以管理员身份运行 ThingWorx
成功!ThingWorx 正确配置为使用 Windchill 身份验证。
如果将身份验证器设置为自动创建用户,请测试下一项:
1. 打开浏览器访问 ThingWorx URL。您将被转至 Windchill 进行身份验证。
2. ThingWorx 中不存在的用户提供 Windchill 登录凭据。
3. 您的浏览器被转回 ThingWorx 主混搭页面。
4. 验证您当前正在以正确的用户身份运行 ThingWorx。用户已自动创建。
* 
如果定制选项和搜索结果无法如预期一样工作,请重新启动 Apache Tomcat 和 ThingWorx Integration Runtime。