1
0
mirror of https://github.com/Yubico/yubikey-val.git synced 2024-12-01 15:24:16 +01:00
Commit Graph

643 Commits

Author SHA1 Message Date
Jean Paul Galea
90b6511301 Cosmetic changes. 2015-07-17 22:04:09 +02:00
Jean Paul Galea
175dca8755 Refactor.
- $id never used.
2015-07-17 22:03:49 +02:00
Jean Paul Galea
4080adef81 Refactor.
- use string substitution rather than concatenation.
2015-07-17 22:00:11 +02:00
Jean Paul Galea
0bbb2e2a5e Cosmetic changes. 2015-07-17 21:57:16 +02:00
Jean Paul Galea
890a446063 Refactor.
- $mrc never used.
2015-07-17 21:55:46 +02:00
Jean Paul Galea
73943ba807 Cosmetic changes. 2015-07-17 21:54:51 +02:00
Jean Paul Galea
a28ad6df69 Refactor.
- enable strict comparison for sscanf result.

- use single quotes where possible.

- styling.
2015-07-17 21:50:28 +02:00
Jean Paul Galea
45ea62445c Cosmetic changes. 2015-07-17 21:38:00 +02:00
Jean Paul Galea
8edf9ba465 Cosmetic changes. 2015-07-17 21:32:09 +02:00
Jean Paul Galea
ac3b4978b8 Cosmetic changes. 2015-07-17 21:30:30 +02:00
Jean Paul Galea
d9194c854d Cosmetic changes. 2015-07-17 21:25:15 +02:00
Jean Paul Galea
a66322754d Cosmetic changes. 2015-07-17 21:23:00 +02:00
Jean Paul Galea
2170247166 Cosmetic changes. 2015-07-17 21:20:14 +02:00
Jean Paul Galea
38c048b833 Cosmetic changes. 2015-07-17 21:17:29 +02:00
Jean Paul Galea
be27f62236 Cosmetic changes. 2015-07-17 21:16:40 +02:00
Jean Paul Galea
f3fc957431 Fix.
- introduced bug in 0d03c2be29.
2015-07-17 10:11:43 +02:00
Jean Paul Galea
069660e4ef Refactor.
- gmdate(, $x) already defaults to time()
2015-07-17 00:43:11 +02:00
Jean Paul Galea
b1df4deaf1 Refactor.
- unwrap getUTCTimeStamp()

- use gmdate() instead of
	date_default_timezone_set('UTC') + date()
2015-07-17 00:42:42 +02:00
Jean Paul Galea
ba82acf79b Refactor.
- $status is always set in invocation, and never to null.
2015-07-17 00:34:14 +02:00
Jean Paul Galea
c258997f51 Cosmetic changes.
- readability.
2015-07-17 00:33:53 +02:00
Jean Paul Galea
d502b644c0 Refactor.
- improve readability.
2015-07-17 00:29:22 +02:00
Jean Paul Galea
d61acc2a71 Remove broken link. 2015-07-17 00:22:38 +02:00
Jean Paul Galea
c09908f111 Cosmetic changes.
- brackets, comment blocks.
2015-07-17 00:21:16 +02:00
Jean Paul Galea
cc4eba8a56 Cosmetic changes. 2015-07-17 00:11:07 +02:00
Jean Paul Galea
f4bb4d317e Refactor.
- use variable substitution rather than concatenation.

- use single quotes where possible.
2015-07-17 00:10:28 +02:00
Jean Paul Galea
7d4a2940d6 Refactor.
- parse request before opening up a database connection
	and init'ing synclib.
2015-07-17 00:03:41 +02:00
Jean Paul Galea
552c3f8939 Cosmetic changes.
- more consistency with comment style.
2015-07-16 23:56:12 +02:00
Jean Paul Galea
365636e34a Cosmetic changes.
- spaces -> tabs
2015-07-16 23:53:08 +02:00
Jean Paul Galea
f5099b682d Cosmetic changes. 2015-07-16 23:49:59 +02:00
Jean Paul Galea
3a344668d0 Refactor.
- move further down, easier to read, but no real benefit resource wise.
2015-07-16 23:46:59 +02:00
Jean Paul Galea
d8e5a1324b Refactor.
- check for empty request first,
	before opening up syslog.
2015-07-16 23:44:35 +02:00
Jean Paul Galea
ea97dbf73d Refactor.
- before opening up a database connection (and init synclib),
	verify request comes from whitelisted address first.
2015-07-16 23:41:22 +02:00
Jean Paul Galea
2196310a0b Refactor.
- $apiKey is always '' and sendResp() $apiKey argument defaults to ''
2015-07-16 23:34:35 +02:00
Jean Paul Galea
dd4cb68b41 Refactor.
- $allowed is easier on the eyes.

- enabled in_array(, , TRUE) for strict comparision.
2015-07-16 23:29:11 +02:00
Jean Paul Galea
1d331555c5 Cosmetic changes.
- readability at the expense of long lines.
2015-07-16 23:28:20 +02:00
Jean Paul Galea
12e58b1dd0 Refactor.
- merge validation into one block.
2015-07-16 23:17:29 +02:00
Jean Paul Galea
742a0d73c2 Refactor.
- use simple comparisons and ctype for validation,
	less resource intensive than regex.
2015-07-16 23:10:48 +02:00
Jean Paul Galea
dedfa0a149 Refactor.
- $ipaddr is easier on the eyes.
2015-07-16 23:00:29 +02:00
Jean Paul Galea
43e3585a49 Cosmetic changes. 2015-07-16 22:54:31 +02:00
Jean Paul Galea
291bd32bae Refactor.
- after each sendResp() we had an exit;

- move exit; inside sendResp() function instead.
2015-07-16 22:47:16 +02:00
Jean Paul Galea
bc5319327b Unwrap function. 2015-07-16 22:35:34 +02:00
Jean Paul Galea
731eed8fa9 Refactor.
- syncServers was mostly always an array.

- change init value from NULL to array().

- simplify getNumberOfServers.
2015-07-16 22:31:51 +02:00
Jean Paul Galea
adb7a49608 Prettify. 2015-07-16 22:26:10 +02:00
Jean Paul Galea
6c0b62f77e Prettify hash_equals. 2015-07-16 22:19:47 +02:00
Jean Paul Galea
0d03c2be29 Unwrap, only used here. 2015-07-16 22:14:36 +02:00
Jean Paul Galea
057eb0b563 Removed dead code, second try.
- grep with -i switch.

- left UnixToDbTime...
	will refactor later and unwrap to plain date()

- left timestamp* methods in ykval-db,
	not used but might be useful while refactoring other code.
2015-07-16 22:07:39 +02:00
Jean Paul Galea
b4f9bd4939 Revert "Removed dead code."
This reverts commit 29deb6007d.

PHP functions are __not__ case-sensitive!
2015-07-16 15:44:35 +02:00
Jean Paul Galea
6e4b89048e Refactor.
- better grouping for validation.
2015-07-16 15:39:42 +02:00
Jean Paul Galea
29deb6007d Removed dead code. 2015-07-16 14:26:14 +02:00
Jean Paul Galea
3de52c3a7c Cosmetic changes. 2015-07-15 18:03:47 +02:00