1 |
<?php
|
2 |
//------------------------------------------------------------------------
|
3 |
//Marshall Aviation Center FBO Management Software
|
4 |
//Copyright (C)2005 David T. Ashley
|
5 |
//
|
6 |
//This program is free software; you can redistribute it and/or
|
7 |
//modify it under the terms of the GNU General Public License
|
8 |
//as published by the Free Software Foundation; either version 2
|
9 |
//of the License, or (at your option) any later version.
|
10 |
//
|
11 |
//This program is distributed in the hope that it will be useful,
|
12 |
//but WITHOUT ANY WARRANTY; without even the implied warranty of
|
13 |
//MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
14 |
//GNU General Public License for more details.
|
15 |
//
|
16 |
//You should have received a copy of the GNU General Public License
|
17 |
//along with this program; if not, write to the Free Software
|
18 |
//Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
|
19 |
//
|
20 |
//The author (David T. Ashley) may be contacted by e-mail at dta@e3ft.com
|
21 |
//and by postal mail at P.O. Box 918, Marshall MI 49068.
|
22 |
//------------------------------------------------------------------------
|
23 |
//Functions for generating MD5 hashes (the only type of hash used
|
24 |
//in this set of web pages).
|
25 |
//
|
26 |
//Generally, this file defines how hashes are implemented in the entire
|
27 |
//web site. These functions can't in general be changed after the site
|
28 |
//is in operation, because it will break functionality where hashes
|
29 |
//are already stored.
|
30 |
//------------------------------------------------------------------------
|
31 |
if (!$INCLUDED_HKEY_HASHKEY)
|
32 |
{
|
33 |
include("macntr01/hkey_hashkey.inc");
|
34 |
$INCLUDED_HKEY_HASHKEY = 1;
|
35 |
}
|
36 |
//------------------------------------------------------------------------
|
37 |
function hash_1($arg1)
|
38 |
{
|
39 |
$key = hkey_hkey();
|
40 |
|
41 |
return(
|
42 |
md5(
|
43 |
$key .
|
44 |
$arg1 .
|
45 |
$key .
|
46 |
$arg1 .
|
47 |
$key
|
48 |
)
|
49 |
);
|
50 |
}
|
51 |
//------------------------------------------------------------------------
|
52 |
function hash_2($arg1, $arg2)
|
53 |
{
|
54 |
$key = hkey_hkey();
|
55 |
|
56 |
return(
|
57 |
md5(
|
58 |
$key .
|
59 |
$arg1 .
|
60 |
$key .
|
61 |
$arg2 .
|
62 |
$key
|
63 |
)
|
64 |
);
|
65 |
}
|
66 |
//------------------------------------------------------------------------
|
67 |
function hash_3($arg1, $arg2, $arg3)
|
68 |
{
|
69 |
$key = hkey_hkey();
|
70 |
|
71 |
return(
|
72 |
md5(
|
73 |
$key .
|
74 |
$arg1 .
|
75 |
$key .
|
76 |
$arg2 .
|
77 |
$key .
|
78 |
$arg3 .
|
79 |
$key
|
80 |
)
|
81 |
);
|
82 |
}
|
83 |
//------------------------------------------------------------------------
|
84 |
function hash_4($arg1, $arg2, $arg3, $arg4)
|
85 |
{
|
86 |
$key = hkey_hkey();
|
87 |
|
88 |
return(
|
89 |
md5(
|
90 |
$key .
|
91 |
$arg1 .
|
92 |
$key .
|
93 |
$arg2 .
|
94 |
$key .
|
95 |
$arg3 .
|
96 |
$key .
|
97 |
$arg4 .
|
98 |
$key
|
99 |
)
|
100 |
);
|
101 |
}
|
102 |
//------------------------------------------------------------------------
|
103 |
function hash_5($arg1, $arg2, $arg3, $arg4, $arg5)
|
104 |
{
|
105 |
$key = hkey_hkey();
|
106 |
|
107 |
return(
|
108 |
md5(
|
109 |
$key .
|
110 |
$arg1 .
|
111 |
$key .
|
112 |
$arg2 .
|
113 |
$key .
|
114 |
$arg3 .
|
115 |
$key .
|
116 |
$arg4 .
|
117 |
$key .
|
118 |
$arg5 .
|
119 |
$key
|
120 |
)
|
121 |
);
|
122 |
}
|
123 |
//------------------------------------------------------------------------
|
124 |
function hash_6($arg1, $arg2, $arg3, $arg4, $arg5, $arg6)
|
125 |
{
|
126 |
$key = hkey_hkey();
|
127 |
|
128 |
return(
|
129 |
md5(
|
130 |
$key .
|
131 |
$arg1 .
|
132 |
$key .
|
133 |
$arg2 .
|
134 |
$key .
|
135 |
$arg3 .
|
136 |
$key .
|
137 |
$arg4 .
|
138 |
$key .
|
139 |
$arg5 .
|
140 |
$key .
|
141 |
$arg6 .
|
142 |
$key
|
143 |
)
|
144 |
);
|
145 |
}
|
146 |
//------------------------------------------------------------------------
|
147 |
function hash_7($arg1, $arg2, $arg3, $arg4, $arg5, $arg6, $arg7)
|
148 |
{
|
149 |
$key = hkey_hkey();
|
150 |
|
151 |
return(
|
152 |
md5(
|
153 |
$key .
|
154 |
$arg1 .
|
155 |
$key .
|
156 |
$arg2 .
|
157 |
$key .
|
158 |
$arg3 .
|
159 |
$key .
|
160 |
$arg4 .
|
161 |
$key .
|
162 |
$arg5 .
|
163 |
$key .
|
164 |
$arg6 .
|
165 |
$key .
|
166 |
$arg7 .
|
167 |
$key
|
168 |
)
|
169 |
);
|
170 |
}
|
171 |
//------------------------------------------------------------------------
|
172 |
function hash_8($arg1, $arg2, $arg3, $arg4, $arg5, $arg6, $arg7, $arg8)
|
173 |
{
|
174 |
$key = hkey_hkey();
|
175 |
|
176 |
return(
|
177 |
md5(
|
178 |
$key .
|
179 |
$arg1 .
|
180 |
$key .
|
181 |
$arg2 .
|
182 |
$key .
|
183 |
$arg3 .
|
184 |
$key .
|
185 |
$arg4 .
|
186 |
$key .
|
187 |
$arg5 .
|
188 |
$key .
|
189 |
$arg6 .
|
190 |
$key .
|
191 |
$arg7 .
|
192 |
$key .
|
193 |
$arg8 .
|
194 |
$key
|
195 |
)
|
196 |
);
|
197 |
}
|
198 |
//------------------------------------------------------------------------
|
199 |
function hash_9($arg1, $arg2, $arg3, $arg4, $arg5, $arg6, $arg7, $arg8, $arg9)
|
200 |
{
|
201 |
$key = hkey_hkey();
|
202 |
|
203 |
return(
|
204 |
md5(
|
205 |
$key .
|
206 |
$arg1 .
|
207 |
$key .
|
208 |
$arg2 .
|
209 |
$key .
|
210 |
$arg3 .
|
211 |
$key .
|
212 |
$arg4 .
|
213 |
$key .
|
214 |
$arg5 .
|
215 |
$key .
|
216 |
$arg6 .
|
217 |
$key .
|
218 |
$arg7 .
|
219 |
$key .
|
220 |
$arg8 .
|
221 |
$key .
|
222 |
$arg9 .
|
223 |
$key
|
224 |
)
|
225 |
);
|
226 |
}
|
227 |
//------------------------------------------------------------------------
|
228 |
function hash_10($arg1, $arg2, $arg3, $arg4, $arg5, $arg6, $arg7, $arg8, $arg9, $arg10)
|
229 |
{
|
230 |
$key = hkey_hkey();
|
231 |
|
232 |
return(
|
233 |
md5(
|
234 |
$key .
|
235 |
$arg1 .
|
236 |
$key .
|
237 |
$arg2 .
|
238 |
$key .
|
239 |
$arg3 .
|
240 |
$key .
|
241 |
$arg4 .
|
242 |
$key .
|
243 |
$arg5 .
|
244 |
$key .
|
245 |
$arg6 .
|
246 |
$key .
|
247 |
$arg7 .
|
248 |
$key .
|
249 |
$arg8 .
|
250 |
$key .
|
251 |
$arg9 .
|
252 |
$key .
|
253 |
$arg10 .
|
254 |
$key
|
255 |
)
|
256 |
);
|
257 |
}
|
258 |
//------------------------------------------------------------------------
|
259 |
?>
|