Overview
Comment: | Adjust to ObjFW coding style |
---|---|
Downloads: | Tarball | ZIP archive | SQL archive |
Timelines: | family | ancestors | descendants | both | trunk |
Files: | files | file ages | folders |
SHA3-256: |
e5b470a14cfece6b58181af0cfe2d27c |
User & Date: | js on 2021-04-03 20:16:07 |
Other Links: | manifest | tags |
Context
2021-04-25
| ||
20:41 | Adjust to ObjFW changes check-in: a64206ee2e user: js tags: trunk | |
2021-04-03
| ||
20:16 | Adjust to ObjFW coding style check-in: e5b470a14c user: js tags: trunk | |
19:48 | Update buildsys check-in: 3f1ad168e1 user: js tags: trunk | |
Changes
Modified src/ObjOpenSSL.h from [be6adf410d] to [5a65d1c0e8].
︙ | |||
17 18 19 20 21 22 23 | 17 18 19 20 21 22 23 24 25 26 27 | + + + + | * INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN * CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE * POSSIBILITY OF SUCH DAMAGE. */ #import "SSLSocket.h" #import "X509Certificate.h" #import "SSLConnectionFailedException.h" #import "SSLInvalidCertificateException.h" |
Modified src/SSLConnectionFailedException.m from [7fa0a8e9f5] to [a49752ab3b].
︙ | |||
78 79 80 81 82 83 84 | 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 | - - - + + + - - - - + + + + - - - - + + + + - - - - - + + + + + - + - - - | return [[[self alloc] initWithHost: host port: port socket: socket SSLError: SSLError verifyResult: verifyResult] autorelease]; } |
︙ |
Modified src/SSLInvalidCertificateException.h from [5d12c58480] to [31c8be5e77].
︙ | |||
31 32 33 34 35 36 37 | 31 32 33 34 35 36 37 38 39 40 41 42 | - - + + | OFString *_reason; } @property (readonly, nonatomic) OFString *reason; + (instancetype)exception; + (instancetype)exceptionWithReason: (OFString *)reason; |
Modified src/SSLInvalidCertificateException.m from [53d49dda97] to [53b2485fef].
︙ | |||
36 37 38 39 40 41 42 | 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 | - + - + | } + (instancetype)exceptionWithReason: (OFString *)reason { return [[[self alloc] initWithReason: reason] autorelease]; } |
︙ |
Modified src/SSLSocket.m from [18992aefde] to [7d89379347].
︙ | |||
87 88 89 90 91 92 93 | 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 | - + - | if (mode & CRYPTO_LOCK) of_mutex_lock(&ssl_mutexes[n]); else of_mutex_unlock(&ssl_mutexes[n]); } @interface SSLSocket () |
︙ | |||
250 251 252 253 254 255 256 | 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 | - + - | [super dealloc]; if (SSL_ != NULL) SSL_free(SSL_); } |
︙ | |||
344 345 346 347 348 349 350 | 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 | - + - - + - - | socket: self SSLError: error]; } } - (void)startTLSWithExpectedHost: (OFString *)host { |
︙ | |||
438 439 440 441 442 443 444 | 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 | - + - - + - | } - (void)SSL_super_close { [super close]; } |
︙ | |||
479 480 481 482 483 484 485 | 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 | - + - - + - | if (ret == 0) _atEndOfStream = true; return ret; } |
︙ | |||
579 580 581 582 583 584 585 | 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 | - + - | */ length = SSL_get_finished(_SSL, buffer, 64); } else { /* peer sent the finished message */ length = SSL_get_peer_finished(_SSL, buffer, 64); } |
︙ |
Modified src/X509Certificate.h from [406cc0c045] to [020cde7269].
︙ | |||
44 45 46 47 48 49 50 | 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 | - - + + + - - - + + + | @class OFDictionary; @interface X509OID: OFObject <OFCopying> { OFString *_string; } |
Modified src/X509Certificate.m from [48c2a42784] to [adabc1fce4].
︙ | |||
61 62 63 64 65 66 67 | 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 | - + - + | - (X509OID *)X509_stringFromASN1Object: (ASN1_OBJECT *)obj; - (OFString *)X509_stringFromASN1String: (ASN1_STRING *)str; @end OF_ASSUME_NONNULL_END @implementation X509Certificate |
︙ | |||
89 90 91 92 93 94 95 | 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 | - + | [self release]; @throw e; } return self; } |
︙ | |||
209 210 211 212 213 214 215 | 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 | - + - | } key = [self X509_stringFromASN1Object: otherName->type_id]; list = [types objectForKey: key]; if (list == nil) { list = [OFList list]; |
︙ | |||
284 285 286 287 288 289 290 | 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 | - - + + - - - + + - - + | return ret; } - (bool)hasCommonNameMatchingDomain: (OFString *)domain { void *pool = objc_autoreleasePoolPush(); |
︙ | |||
373 374 375 376 377 378 379 | 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 | - + - + - | firstDot = [domain rangeOfString: @"."].location; if (firstDot == OF_NOT_FOUND) return false; domain = [domain substringWithRange: of_range(firstDot + 1, domain.length - firstDot - 1)]; |
︙ | |||
449 450 451 452 453 454 455 | 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 | - + - + | } return ret; } @end @implementation X509OID |
︙ | |||
500 501 502 503 504 505 506 | 496 497 498 499 500 501 502 503 504 505 506 507 | - + | } - (unsigned long)hash { return _string.hash; } |