@@ -174,11 +174,13 @@ mod _ssl {
174174 parse_version_info ( openssl_api_version)
175175 }
176176
177+ /// An error occurred in the SSL implementation.
177178 #[ pyattr( name = "SSLError" , once) ]
178179 fn ssl_error ( vm : & VirtualMachine ) -> PyTypeRef {
179180 PyType :: new_simple_ref ( "ssl.SSLError" , & vm. ctx . exceptions . os_error ) . unwrap ( )
180181 }
181182
183+ /// A certificate could not be verified.
182184 #[ pyattr( name = "SSLCertVerificationError" , once) ]
183185 fn ssl_cert_verification_error ( vm : & VirtualMachine ) -> PyTypeRef {
184186 let ssl_error = ssl_error ( vm) ;
@@ -192,26 +194,31 @@ mod _ssl {
192194 . unwrap ( )
193195 }
194196
197+ /// SSL/TLS session closed cleanly.
195198 #[ pyattr( name = "SSLZeroReturnError" , once) ]
196199 fn ssl_zero_return_error ( vm : & VirtualMachine ) -> PyTypeRef {
197200 PyType :: new_simple_ref ( "ssl.SSLZeroReturnError" , & ssl_error ( vm) ) . unwrap ( )
198201 }
199202
203+ /// Non-blocking SSL socket needs to read more data before the requested operation can be completed.
200204 #[ pyattr( name = "SSLWantReadError" , once) ]
201205 fn ssl_want_read_error ( vm : & VirtualMachine ) -> PyTypeRef {
202206 PyType :: new_simple_ref ( "ssl.SSLWantReadError" , & ssl_error ( vm) ) . unwrap ( )
203207 }
204208
209+ /// Non-blocking SSL socket needs to write more data before the requested operation can be completed.
205210 #[ pyattr( name = "SSLWantWriteError" , once) ]
206211 fn ssl_want_write_error ( vm : & VirtualMachine ) -> PyTypeRef {
207212 PyType :: new_simple_ref ( "ssl.SSLWantWriteError" , & ssl_error ( vm) ) . unwrap ( )
208213 }
209214
215+ /// System error when attempting SSL operation.
210216 #[ pyattr( name = "SSLSyscallError" , once) ]
211217 fn ssl_syscall_error ( vm : & VirtualMachine ) -> PyTypeRef {
212218 PyType :: new_simple_ref ( "ssl.SSLSyscallError" , & ssl_error ( vm) ) . unwrap ( )
213219 }
214220
221+ /// SSL/TLS connection terminated abruptly.
215222 #[ pyattr( name = "SSLEOFError" , once) ]
216223 fn ssl_eof_error ( vm : & VirtualMachine ) -> PyTypeRef {
217224 PyType :: new_simple_ref ( "ssl.SSLEOFError" , & ssl_error ( vm) ) . unwrap ( )
0 commit comments