Reverting infoprint that wrongly suggests a bug
authorRick van Rein <rick@openfortress.nl>
Thu, 2 May 2019 11:13:01 +0000 (11:13 +0000)
committerRick van Rein <rick@openfortress.nl>
Thu, 2 May 2019 11:13:01 +0000 (11:13 +0000)
The localid information is never documented to return another value
when it is called with an empty string.  This could be a feature to
desire, especially for handling SNI and wildcards on servers, but
now it looks like a bug and that is not intentional.  The proper
way to get a localid out of the TLS Pool is to process callbacks.
LOCALID_CHECK is early, NAMED_CONNECT is later.  The former will
avoid presenting certificates for non-services, which is the
preferred line of work.

tool/chatcli.c
tool/chatsrv.c

index abaefc8..c2adeeb 100644 (file)
@@ -266,7 +266,7 @@ reconnect:
        } else {
                printf ("SIGCONT will trigger renegotiation of the TLS handshake\n");
        }
-       printf ("DEBUG: Local plainfd = %d, localid = %s, remoteid = %s\n", plainfd, tlsdata_cli.localid, tlsdata_cli.remoteid);
+       printf ("DEBUG: Local plainfd = %d\n", plainfd);
        runterminal (plainfd, &sigcont, &tlsdata_cli,
                        PIOF_STARTTLS_LOCALROLE_CLIENT | PIOF_STARTTLS_REMOTEROLE_SERVER | PIOF_STARTTLS_RENEGOTIATE,
                        "testcli@tlspool.arpa2.lab",
index 10918b1..5287cd6 100644 (file)
@@ -321,7 +321,7 @@ reconnect:
                } else {
                        printf ("SIGCONT will trigger renegotiation of the TLS handshake during a connection\n");
                }
-               printf ("DEBUG: Local plainfd = %d, localid = %s, remoteid = %s\n", plainfd, tlsdata_now.localid, tlsdata_now.remoteid);
+               printf ("DEBUG: Local plainfd = %d\n", plainfd);
                runterminal (plainfd, &sigcont, &tlsdata_now,
                                PIOF_STARTTLS_LOCALROLE_SERVER | PIOF_STARTTLS_REMOTEROLE_CLIENT | PIOF_STARTTLS_RENEGOTIATE,
                                "testsrv@tlspool.arpa2.lab",