简体   繁体   English

Citrix XenApp - 通过CMD / DLL / Something注销

[英]Citrix XenApp - Logoff via CMD/DLL/Something

I need your support. 我需要你的支持。

Following case: I created a script for performance measure (AutoIT) which opens the Internet Explorer, loads a Citrix XenApp Page, logs in and starts an application from there. 以下情况:我创建了一个性能测量脚本(AutoIT),用于打开Internet Explorer,加载Citrix XenApp页面,登录并从那里启动应用程序。

My Problem is the Logout/Disconnect/Closing of the Session. 我的问题是会话的注销/断开/关闭。

Using the URL behind the Logoff Button 使用注销按钮后面的URL

In the upper right corner is a Logoff and a disconnect Button. 右上角是Logoff和断开按钮。 These both calls a Javascript function which rewrites the URL 这两个都调用一个重写URL的Javascript函数

Logoff (Logoff in the Web GUI and logoff in the Citrix Session. Closes all open Windows from Citrix) javascript:location.replace('../site/logout.aspx?CTX_Token=F692CFB5C3282DDEFE1084DAB381EAF4') 注销(Web GUI中的注销和Citrix会话中的注销。从Citrix关闭所有打开的Windows) javascript:location.replace('../site/logout.aspx?CTX_Token=F692CFB5C3282DDEFE1084DAB381EAF4')

disconnect (Logoff in the GUI, closes the session. In the next login it reopens all citrix windows) javascript:location.replace('../site/disconnect.aspx?CTX_Token=F692CFB5C3282DDEFE1084DAB381EAF4') 断开连接(在GUI中注销,关闭会话。在下次登录时,它会重新打开所有Citrix窗口) javascript:location.replace('../site/disconnect.aspx?CTX_Token=F692CFB5C3282DDEFE1084DAB381EAF4')

The CTX_Token is not static. CTX_Token不是静态的。 After every logon I have a new token. 每次登录后我都有一个新令牌。

My goal is: To close, if there is one, the open session, before I open a new session. 我的目标是:在我打开新会话之前关闭(如果有的话)开放会话。

Call the URL without token, with token set to 0 and to complete F/0, 无令牌调用URL,令牌设置为0并完成F / 0,

  • ../site/logout.aspx ../site/logout.aspx
  • logout.aspx?CTX_Token=0 logout.aspx?CTX_Token = 0
  • logout.aspx?CTX_Token=00000000000000000000000000000000 logout.aspx?CTX_Token = 00000000000000000000000000000000
  • logout.aspx?CTX_Token=FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF logout.aspx?CTX_Token = FFFFFFFFFFFFFFFFFFFFFFFFFFFFFFFF

Every time I get only a State Error 每次我只得到一个状态错误

State Error 状态错误

There is a problem with your session. 您的会话存在问题。 For security reasons, you must close your browser window and log on again to continue accessing your resources. 出于安全原因,您必须关闭浏览器窗口并再次登录才能继续访问您的资源。

To log on again, you must restart your browser. 要再次登录,您必须重新启动浏览器。

No success on this way :/ 这样没有成功:/

A Parameter in the Citrix Connection Center Citrix连接中心中的参数

My next hope was a Parameter in the Receiver.exe to disconnect the session. 我的下一个希望是Receiver.exe中的参数断开会话。

In the GUI of the concentr.exe is a disconnect and logoff button. 在concentr.exe的GUI中是一个断开连接和注销按钮。 But the exe has no help in the cmd. 但是exe在cmd中没有任何帮助。 It seems, that this exe has parameters (Task Manager concentr.exe /startup I tried it with following parameters. Every time only the GUI starts... 看来,这个exe有参数(任务管理器concentr.exe /startup我尝试了以下参数。每次只有GUI启动...

  • ?
  • help 救命
  • logoff 注销
  • quit 放弃
  • kill
  • exit 出口
  • stop
  • shutdown 关掉
  • settings 设置

Maybe one of you have an idea... 也许你们其中一个人有想法......

Quit the Citrix Connection Center and the Citrix Receiver 退出Citrix连接中心和Citrix Receiver

These both ways are like disconnect in the Webgui. 这两种方式都像Webgui中的断开连接。

Not that what I wanted.. 不是我想要的..

Close the IE (logoff in the Browser) and kill the open Citrix Windows 关闭IE(在浏览器中注销)并终止打开的Citrix Windows

Not really the correct way. 不是真正的正确方法。 It is possible, that there is process which survives everything 有可能存在一切幸存的过程

Other ways? 其他方法?

I searched for DLL Calls, for APIs, CMD and other stuff. 我搜索了DLL调用,API,CMD和其他东西。 I found nothing. 我一无所获。

Maybe here is a Citrix Pro which is reading this and can deliver me an answer. 也许这是Citrix Pro正在阅读这个并且可以给我一个答案。

Have a nice day 祝你今天愉快

Nice regards 很好的问候

Hagen 哈根

You are automating/webscraping StoreFront but it's better to use the StoreFront SDK . 您正在自动化/ webscraping StoreFront,但最好使用StoreFront SDK Here is an example for Logoff taken from the documentation: 以下是从文档中获取Logoff的示例:

Example: LogOff Request 示例:LogOff请求

POST http://www.example.com/Store/sessions/v1/logoff HTTP/1.1
Host: www.example.com
Accept: application/vnd.citrix.sessionresults+xml
Content-Type: application/vnd.citrix.sessionparams+xml
Content-Length: xxx
Authorization: CitrixAuth ...

<?xml version="1.0"?>
<sessionparams xmlns="http://citrix.com/delivery-services/1-0/sessionparams">
<clientName>xxxxxxxxx</clientName>
<deviceId>xxxxxxxxx</deviceId>
<tickets>
<ticket>85EB92973D2C3804F93A99AAEC232D</ticket>
<ticket>85EB92973D2C3804F93A99AAEC232A</ticket>
</tickets>
</sessionparams>

Response 响应

HTTP/1.1 200 OK
Content-Type: application/vnd.citrix.sessionresults+xml
Content-Length: xxx
Cache-Control: no-cache

<?xml version="1.0"?>
<sessionResults xmlns="http://citrix.com/delivery-services/1-0/sessionresult" status="success" />

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM