File: logout.php

package info (click to toggle)
libapache2-mod-auth-pubtkt 0.13-1
  • links: PTS
  • area: main
  • in suites: bookworm, bullseye, buster, forky, sid, trixie
  • size: 372 kB
  • sloc: ansic: 1,218; perl: 340; php: 268; sh: 143; makefile: 30
file content (41 lines) | stat: -rwxr-xr-x 787 bytes parent folder | download | duplicates (4)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
<?php
/*
	Example logout page for mod_auth_pubtkt
	(https://neon1.net/mod_auth_pubtkt)
	
	written by Manuel Kasper <mk@neon1.net>
*/

$domain = ".example.com";

if ($_POST['logout']) {
	/* only do this if there really has been a POST; otherwise we could
	   be fooled by pre-caching browsers etc. */
	setcookie("auth_pubtkt", "", time() - 86400, "/", $domain, true);
} else {
	header("Location: login.php");
	exit;
}

?>
<html>
<head>
<title>mod_auth_pubtkt Single Sign-On</title>
<link rel="stylesheet" type="text/css" href="style.css">
</head>

<body>

<table width="100%" height="100%">
<tr><td align="center" valign="middle">

<img src="logo.gif">
<h2>Single Sign-On</h2>

<p>You are now logged out.</p>

</tr></td>
</table>

</body>
</html>