by Firstname Lastname, Another Person, Third Person
Early Draft
This SRFI lets users make connections to Transport Layer Security (TLS) servers. A TLS connection is essentially a bidirectional, encrypted pipe over which arbitrary binary data can be sent. TLS was formerly known as Secure Sockets Layer (SSL).
One crucial requirement for such an API is to provide a way to do server certificate verification, or to specify how it should be done by the underlying software. Clients that don't check servers' certificates are surprisingly common, and put their users at risk. I encountered another such unfixed project just yesterday.
Another requirement is to allow control of exactly what crypto algorithms and TLS/SSL versions will be accepted. There are well-known vulnerabilities in earlier versions, and it's important that users who want to can avoid accepting connections using those versions.
Ideally, the API should support sending client certificates.
Chibi-Scheme -- (chibi ssl)
-- Basic bindings for establishing SSL connections -- http://snow-fort.org/s/gmail.com/alexshinn/chibi/ssl/0.1/
Chicken -- openssl
-- Bindings to the OpenSSL SSL/TLS library -- https://wiki.call-cc.org/eggref/5/openssl
Chicken -- TerribleTLS
-- Inadvisible pure-Scheme TLS client -- https://akkuscm.org/packages/TerribleTLS/
Gambit -- (make-tls-context [options]) http://www.iro.umontreal.ca/~gambit/doc/gambit.html#Network-devices
Gauche
Guile -- gnutls
(tls-implementation-name) -> string
(tls-implementation-version) -> string
(tls-version-list) -> string list
Return a list of all TLS/SSL protocol versions supported by the implementation.
Sorted from older to newer. [What does this mean precisely?]
(tls-cipher-list) -> string list
Returns a list of all cipher algorithms supported by the implementation.
(tls-open host port options) -> port
Recognizes at least the following options:
network-interface string, or #f
for default
allowed-ip-versions 4
or 6
, or #f
for both.
Whether to allow connections over IPv4 and/or IPv6.
allowed-tls-versions string list
'("1.3")
allowed-tls-chipers string list
client-certificate-filename string, or #f
for none
client-certificate-password string, or #f
for none
check-server-certificate #t
or #f
check-server-certificate-stapling #t
or #f
Arthur Gleckler suggested the features to send client certificates, force server certificate verification, and select algorithms and TLS versions.
The SSL options were inspired by the curl
program.
Copyright (C) Firstname Lastname (20XY).
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.