snprintf(buf, sizeof(buf), "%Y", id);
query = this->db->query(this->db,
- "select rand, sres, kc from triplets where id = ? order by use",
+ "select rand, sres, kc from triplets where id = ? order by used",
DB_TEXT, buf, DB_BLOB, DB_BLOB, DB_BLOB);
if (query)
{
else
{
this->db->execute(this->db, NULL,
- "update triplets set use = ? where id = ? and rand = ?",
+ "update triplets set used = ? where id = ? and rand = ?",
DB_UINT, time(NULL), DB_TEXT, buf,
DB_BLOB, chunk_create(rand, SIM_RAND_LEN));
}
snprintf(buf, sizeof(buf), "%Y", id);
query = this->db->query(this->db, "select rand, res, ck, ik, autn "
- "from quintuplets where id = ? order by use", DB_TEXT, buf,
+ "from quintuplets where id = ? order by used", DB_TEXT, buf,
DB_BLOB, DB_BLOB, DB_BLOB, DB_BLOB, DB_BLOB);
if (query)
{
else
{
this->db->execute(this->db, NULL,
- "update quintuplets set use = ? where id = ? and rand = ?",
+ "update quintuplets set used = ? where id = ? and rand = ?",
DB_UINT, time(NULL), DB_TEXT, buf,
DB_BLOB, chunk_create(rand, AKA_RAND_LEN));
}
DELETE FROM quintuplets;
INSERT INTO triplets
- (id, use, rand, sres, kc) VALUES
+ (id, used, rand, sres, kc) VALUES
('moon@strongswan.org', 0,
X'00112233445566778899AABBCCDDEEFF', X'01234567', X'0123456789ABCDEF'
);
INSERT INTO triplets
- (id, use, rand, sres, kc) VALUES
+ (id, used, rand, sres, kc) VALUES
('moon@strongswan.org', 0,
X'112233445566778899AABBCCDDEEFF00', X'12345678', X'123456789ABCDEF0'
);
INSERT INTO triplets
- (id, use, rand, sres, kc) VALUES
+ (id, used, rand, sres, kc) VALUES
('moon@strongswan.org', 0,
X'2233445566778899AABBCCDDEEFF0011', X'23456789', X'23456789ABCDEF01'
);
INSERT INTO quintuplets
- (id, use, rand, autn, ck, ik, res) VALUES
+ (id, used, rand, autn, ck, ik, res) VALUES
('moon@strongswan.org', 0,
X'00112233445566778899AABBCCDDEEFF',
X'112233445566778899AABBCCDDEEFF00',