162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
...
384
385
386
387
388
389
390
391
392
393
394
395
396
397
...
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
|
end
-- TODO validate fully
return true
end
terra m.actor.methods.mk(kbuf: &uint8)
var newkp = lib.crypt.genkp()
var privsz = lib.crypt.der(false,&newkp,kbuf)
return m.actor {
id = 0; nym = nil; handle = nil;
origin = 0; bio = nil; avatar = nil;
knownsince = lib.osclock.time(nil);
rights = m.rights_default();
avatarid = 0;
epithet = nil, key = [lib.mem.ptr(uint8)] {
ptr = &kbuf[0], ct = privsz
};
}
end
struct m.actor_stats {
posts: intptr
follows: intptr
followers: intptr
................................................................................
-> {uint64, uint64, pstr}
actor_auth_pw: {&m.source, m.inet, lib.mem.ptr(int8), lib.mem.ptr(int8) }
-> {uint64, uint64, pstr}
-- handles password-based logins against hashed passwords
-- origin: inet
-- handle: rawstring
-- token: rawstring
actor_auth_tls: {&m.source, m.inet, rawstring}
-> {uint64, uint64, pstr}
-- handles implicit authentication performed as part of an TLS connection
-- origin: inet
-- fingerprint: rawstring
actor_auth_api: {&m.source, m.inet, rawstring, rawstring} -> uint64
-> {uint64, uint64, pstr}
................................................................................
actor_rel_create: {&m.source, uint16, uint64, uint64} -> {}
actor_rel_destroy: {&m.source, uint16, uint64, uint64} -> {}
actor_rel_calc: {&m.source, uint64, uint64} -> m.relationship
auth_enum_uid: {&m.source, uint64} -> lib.mem.lstptr(m.auth)
auth_enum_handle: {&m.source, rawstring} -> lib.mem.lstptr(m.auth)
auth_attach_pw: {&m.source, uint64, bool, pstr, pstr} -> uint64
auth_attach_key: {&m.source, uint64, bool, pstr, pstr} -> {}
-- uid: uint64
-- reset: bool (delete other passwords?)
-- pw: pstring
-- comment: pstring
auth_privs_set: {&m.source, uint64, m.privset} -> {}
auth_purge_pw: {&m.source, uint64, rawstring} -> {}
auth_purge_otp: {&m.source, uint64, rawstring} -> {}
|
|
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
...
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
...
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
|
end
-- TODO validate fully
return true
end
terra m.actor.methods.mk(kbuf: &uint8)
var newkp = lib.crypt.genkp()
var derkey = lib.crypt.der(false,&newkp,kbuf)
return m.actor {
id = 0; nym = nil; handle = nil;
origin = 0; bio = nil; avatar = nil;
knownsince = lib.osclock.time(nil);
rights = m.rights_default();
avatarid = 0;
epithet = nil, key = derkey;
}
end
struct m.actor_stats {
posts: intptr
follows: intptr
followers: intptr
................................................................................
-> {uint64, uint64, pstr}
actor_auth_pw: {&m.source, m.inet, lib.mem.ptr(int8), lib.mem.ptr(int8) }
-> {uint64, uint64, pstr}
-- handles password-based logins against hashed passwords
-- origin: inet
-- handle: rawstring
-- token: rawstring
actor_auth_challenge: {&m.source, m.inet, pstr, lib.mem.ptr(uint8), pstr }
-> {uint64, uint64, pstr}
-- origin: inet
-- handle: rawstring
-- response: rawstring
-- challenge token: pstring
actor_auth_tls: {&m.source, m.inet, rawstring}
-> {uint64, uint64, pstr}
-- handles implicit authentication performed as part of an TLS connection
-- origin: inet
-- fingerprint: rawstring
actor_auth_api: {&m.source, m.inet, rawstring, rawstring} -> uint64
-> {uint64, uint64, pstr}
................................................................................
actor_rel_create: {&m.source, uint16, uint64, uint64} -> {}
actor_rel_destroy: {&m.source, uint16, uint64, uint64} -> {}
actor_rel_calc: {&m.source, uint64, uint64} -> m.relationship
auth_enum_uid: {&m.source, uint64} -> lib.mem.lstptr(m.auth)
auth_enum_handle: {&m.source, rawstring} -> lib.mem.lstptr(m.auth)
auth_attach_pw: {&m.source, uint64, bool, pstr, pstr} -> uint64
auth_attach_rsa: {&m.source, uint64, bool, lib.mem.ptr(uint8), pstr} -> uint64
-- uid: uint64
-- reset: bool (delete other passwords?)
-- pw: pstring
-- comment: pstring
auth_privs_set: {&m.source, uint64, m.privset} -> {}
auth_purge_pw: {&m.source, uint64, rawstring} -> {}
auth_purge_otp: {&m.source, uint64, rawstring} -> {}
|