You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
// The user has a valid token BUT someone else beat them to using it.
100
+
$client->appdata["respcode"] = 403;
101
+
$client->appdata["respmsg"] = "Forbidden - Token Reused<br><br>See error log for details.";
102
+
103
+
WriteErrorLog("403 Forbidden - Token reused", $client->ipaddr, $client->request, array("success" => false, "error" => "A valid PAS security token was reused. A PAS security token may only be used precisely one time per server instance. Seeing this message in this log file may be an indicator of a serious security problem.", "errorcode" => "pas_sec_token_reused", "server_ext" => "security_token"));
// Prevent browsers and proxies from doing bad things.
108
+
$client->SetResponseNoCache();
109
+
110
+
ob_start();
111
+
?>
112
+
<!DOCTYPE html>
113
+
<html>
114
+
<head><title>403 Forbidden</title></head>
115
+
<body>
116
+
<h2>403 Forbidden - PAS Security Token Reused</h2>
117
+
118
+
<p>Your PAS security token is valid (i.e. the 'pas_sec_token' part of the URL). However, a PAS security token may only be used precisely one time.</p>
119
+
120
+
<p><span style="color: #A94442; font-size: 1.1em;">This message can appear if another user is on your system and stole your PAS security token before your web browser got a chance to use it.</span></p>
121
+
122
+
<p><span style="color: #A94442; font-size: 1.1em; font-weight: bold;">It is highly recommended that you reboot your computer immediately to prevent any significant damage to your user account on this system.</span></p>
123
+
124
+
<p>This message can also appear when attempting to reuse a PAS security token across multiple web browsers. To use another web browser with this application, change your default web browser and start the application again. This is a much rarer reason than the one above.</p>
125
+
126
+
</body>
127
+
</html>
128
+
<?php
129
+
$content = ob_get_contents();
130
+
ob_end_clean();
131
+
132
+
$client->AddResponseContent($content);
133
+
$client->FinalizeResponse();
134
+
}
135
+
else
136
+
{
137
+
// The user has probably just attempted to switch browsers with a plain URL (or an attacker).
138
+
$client->appdata["respcode"] = 403;
139
+
$client->appdata["respmsg"] = "Forbidden<br><br>See error log for details.";
140
+
141
+
WriteErrorLog("403 Forbidden - Missing cookie", $client->ipaddr, $client->request, array("success" => false, "error" => "The expected PAS security cookie is missing. A PAS security cookie is required for all requests.", "errorcode" => "pas_rst_missing", "server_ext" => "security_token"));
This directory contains a packaging program (package.php) and a configuration file (package.json) for preparing tar-gzipped (.tar.gz) installable packages for Linux.
5
+
6
+
Open `install-support/php-nix-install.sh` in a text editor and adjust the system dependencies as needed (e.g. add any extra PHP extensions that are required by the application).
7
+
8
+
Open `package.json` in a text editor and fill out the various values. Most of the fields should be obvious as to what they are for. However, the following keys are less obvious:
9
+
10
+
* vendor - May only contain A-Z, a-z, and hyphens. Required by the `xdg-utils` package to avoid name conflicts.
11
+
* app_categories - A semicolon separated list from the standard categories in the [freedesktop.org category registry](https://specifications.freedesktop.org/menu-spec/menu-spec-latest.html#category-registry).
12
+
* app_keywords - A semicolon separated list of additional keywords that a user might use to search for the application (e.g. acronyms).
13
+
* user_desktop_icon - A boolean indicating whether or not an icon should also be placed on the user's desktop. Users tend to prefer clean desktops, so setting this to true is generally inadvisable.
14
+
15
+
Once the package information file has been filled out, save it and run (from Linux or Mac OSX is recommended):
16
+
17
+
```
18
+
php package.php
19
+
```
20
+
21
+
Assuming all the required pieces exist, the `.tar.gz` package will be generated and made ready for deployment. The recommended icon size for the PNG icon is 512x512. All additional sizes are generated during installation.
22
+
23
+
Don't forget to test the installation to verify that it works as expected. The installer is run via the command `./install.sh` and the uninstaller via `./uninstall.sh`. Use `sudo ./install.sh` to install for all users.
0 commit comments