devtls: print the path of the underlying chan in status file
to figure out what network connection a particular tls conversation refers to, we add the path of the underlying we send the encrypted tls traffic over in the status file, example: term% grep -n '^Chan:' '#a'/tls/*/status #a/tls/0/status:7: Chan: /net/tcp/6/data #a/tls/1/status:7: Chan: /net/tcp/0/data
This commit is contained in:
parent
38a8af2d72
commit
89f9966aed
1 changed files with 3 additions and 1 deletions
|
@ -1197,7 +1197,9 @@ tlsread(Chan *c, void *a, long n, vlong off)
|
||||||
if(tr->out.sec != nil)
|
if(tr->out.sec != nil)
|
||||||
s = seprint(s, e, "EncOut: %s\nHashOut: %s\n", tr->out.sec->encalg, tr->out.sec->hashalg);
|
s = seprint(s, e, "EncOut: %s\nHashOut: %s\n", tr->out.sec->encalg, tr->out.sec->hashalg);
|
||||||
if(tr->out.new != nil)
|
if(tr->out.new != nil)
|
||||||
seprint(s, e, "NewEncOut: %s\nNewHashOut: %s\n", tr->out.new->encalg, tr->out.new->hashalg);
|
s = seprint(s, e, "NewEncOut: %s\nNewHashOut: %s\n", tr->out.new->encalg, tr->out.new->hashalg);
|
||||||
|
if(tr->c != nil)
|
||||||
|
seprint(s, e, "Chan: %s\n", chanpath(tr->c));
|
||||||
qunlock(&tr->in.seclock);
|
qunlock(&tr->in.seclock);
|
||||||
qunlock(&tr->out.seclock);
|
qunlock(&tr->out.seclock);
|
||||||
n = readstr(offset, a, n, buf);
|
n = readstr(offset, a, n, buf);
|
||||||
|
|
Loading…
Reference in a new issue