Coverage report: /home/ellis/.stash/lisp/cl-plus-ssl/src/package.lisp

KindCoveredAll%
expression06 0.0
branch00nil
Key
Not instrumented
Conditionalized out
Executed
Not executed
 
Both branches taken
One branch taken
Neither branch taken
1
 ;;;; -*- Mode: LISP; Syntax: COMMON-LISP; indent-tabs-mode: nil; coding: utf-8; show-trailing-whitespace: t -*-
2
 ;;;
3
 ;;; Copyright (C) 2001, 2003  Eric Marsden
4
 ;;; Copyright (C) 2005  David Lichteblau
5
 ;;; "the conditions and ENSURE-SSL-FUNCALL are by Jochen Schmidt."
6
 ;;; Copyright (C) contributors as per cl+ssl git history
7
 ;;;
8
 ;;; See LICENSE for details.
9
 
10
 (defpackage :cl+ssl
11
   (:use :common-lisp :trivial-gray-streams))
12
 
13
 (in-package :cl+ssl)
14
 
15
 (export
16
  '(
17
    ;;; Create TLS stream over TCP stream
18
    make-ssl-client-stream
19
    make-ssl-server-stream
20
 
21
    ;;; Custom binding for the global SSL_CTX
22
    with-global-context
23
 
24
    ;;; Custom SSL_CTX creation
25
    make-context
26
    ssl-ctx-free
27
 
28
    ;;; Configure the global SSL_CTX
29
    use-certificate-chain-file
30
    ssl-load-global-verify-locations
31
    ssl-set-global-default-verify-paths
32
 
33
    ;;; PEM file reading
34
    with-pem-password
35
 
36
    ;;; Properties of an established TLS session
37
    get-selected-alpn-protocol
38
 
39
    ;;; x509 Certificates
40
    ;;; Obtain
41
    decode-certificate-from-file
42
    decode-certificate
43
    ssl-stream-x509-certificate
44
    ;;; Release
45
    x509-free
46
    ;;; Accessors
47
    certificate-not-after-time
48
    certificate-not-before-time
49
    certificate-subject-common-names
50
    certificate-fingerprint
51
    ;; (low level function, already
52
    ;; employed by make-ssl-client-stream
53
    ;; if verification is enabled and hostname
54
    ;; is passed in)
55
    verify-hostname
56
 
57
    ;;; Saving / loading Lisp image
58
    reload
59
 
60
    ;;; Various
61
    stream-fd
62
    random-bytes
63
    ensure-initialized
64
 
65
    ;;; Default values
66
    *default-cipher-list*
67
    *default-buffer-size*
68
    *make-ssl-client-stream-verify-default*
69
    *default-unwrap-stream-p*
70
 
71
    ;;; Error conditions.
72
    ;;; Not full list, there are more non-exported,
73
    ;;; including the base classes.
74
    ;;; Should we export them all?
75
    ssl-error-verify
76
    ssl-error-initialize
77
    ;;; accessors of ssl-error-verify
78
    ssl-error-stream
79
    ssl-error-code
80
 
81
    ;;; OpenSSL API constants
82
    +ssl-verify-none+
83
    +ssl-verify-peer+
84
    +ssl-verify-fail-if-no-peer-cert+
85
    +ssl-verify-client-once+
86
 
87
    +ssl-op-no-sslv2+
88
    +ssl-op-no-sslv3+
89
    +ssl-op-no-tlsv1+
90
    +ssl-op-no-tlsv1-1+
91
    +ssl-op-no-tlsv1-2+
92
 
93
    +ssl-sess-cache-off+
94
    +ssl-sess-cache-client+
95
    +ssl-sess-cache-server+
96
    +ssl-sess-cache-both+
97
    +ssl-sess-cache-no-auto-clear+
98
    +ssl-sess-cache-no-internal-lookup+
99
    +ssl-sess-cache-no-internal-store+
100
    +ssl-sess-cache-no-internal+
101
 
102
    ;;; DEPRECATED.
103
 
104
    ;; Use the (MAKE-SSL-CLIENT-STREAM .. :VERIFY ?) to enable/disable verification.
105
    ;; MAKE-CONTEXT also allows to enab/disable verification.
106
    ssl-check-verify-p
107
    ))
108
 
109
 (import '(cl+ssl/config::libssl
110
           cl+ssl/config::libcrypto))