ruby-tls 1.0.0 → 1.0.1
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +14 -6
- data/EM-LICENSE +60 -60
- data/README.md +69 -69
- data/Rakefile +19 -19
- data/ext/Rakefile +18 -18
- data/ext/tls/page.cpp +107 -107
- data/ext/tls/page.h +61 -62
- data/ext/tls/ssl.cpp +593 -591
- data/ext/tls/ssl.h +130 -130
- data/lib/ruby-tls/connection.rb +121 -121
- data/lib/ruby-tls/ext.rb +32 -32
- data/lib/ruby-tls/version.rb +3 -3
- data/lib/ruby-tls.rb +7 -7
- data/ruby-tls.gemspec +32 -32
- data/spec/client.crt +31 -31
- data/spec/client.key +51 -51
- data/spec/comms_spec.rb +147 -147
- data/spec/verify_spec.rb +118 -118
- metadata +18 -16
data/ext/tls/page.h
CHANGED
@@ -1,62 +1,61 @@
|
|
1
|
-
/*****************************************************************************
|
2
|
-
|
3
|
-
$Id$
|
4
|
-
|
5
|
-
File: page.h
|
6
|
-
Date: 30Apr06
|
7
|
-
|
8
|
-
Copyright (C) 2006-07 by Francis Cianfrocca. All Rights Reserved.
|
9
|
-
Gmail: blackhedd
|
10
|
-
|
11
|
-
This program is free software; you can redistribute it and/or modify
|
12
|
-
it under the terms of either: 1) the GNU General Public License
|
13
|
-
as published by the Free Software Foundation; either version 2 of the
|
14
|
-
License, or (at your option) any later version; or 2) Ruby's License.
|
15
|
-
|
16
|
-
See the file COPYING for complete licensing information.
|
17
|
-
|
18
|
-
*****************************************************************************/
|
19
|
-
|
20
|
-
|
21
|
-
#ifndef __PageManager__H_
|
22
|
-
#define __PageManager__H_
|
23
|
-
|
24
|
-
|
25
|
-
#include <deque>
|
26
|
-
#include <stdexcept>
|
27
|
-
#include <assert.h>
|
28
|
-
|
29
|
-
#
|
30
|
-
|
31
|
-
|
32
|
-
|
33
|
-
|
34
|
-
|
35
|
-
|
36
|
-
|
37
|
-
|
38
|
-
|
39
|
-
|
40
|
-
|
41
|
-
{
|
42
|
-
|
43
|
-
|
44
|
-
|
45
|
-
|
46
|
-
|
47
|
-
|
48
|
-
|
49
|
-
PageList();
|
50
|
-
|
51
|
-
|
52
|
-
|
53
|
-
|
54
|
-
void
|
55
|
-
|
56
|
-
|
57
|
-
|
58
|
-
|
59
|
-
|
60
|
-
|
61
|
-
|
62
|
-
#endif // __PageManager__H_
|
1
|
+
/*****************************************************************************
|
2
|
+
|
3
|
+
$Id$
|
4
|
+
|
5
|
+
File: page.h
|
6
|
+
Date: 30Apr06
|
7
|
+
|
8
|
+
Copyright (C) 2006-07 by Francis Cianfrocca. All Rights Reserved.
|
9
|
+
Gmail: blackhedd
|
10
|
+
|
11
|
+
This program is free software; you can redistribute it and/or modify
|
12
|
+
it under the terms of either: 1) the GNU General Public License
|
13
|
+
as published by the Free Software Foundation; either version 2 of the
|
14
|
+
License, or (at your option) any later version; or 2) Ruby's License.
|
15
|
+
|
16
|
+
See the file COPYING for complete licensing information.
|
17
|
+
|
18
|
+
*****************************************************************************/
|
19
|
+
|
20
|
+
|
21
|
+
#ifndef __PageManager__H_
|
22
|
+
#define __PageManager__H_
|
23
|
+
|
24
|
+
|
25
|
+
#include <deque>
|
26
|
+
#include <stdexcept>
|
27
|
+
#include <assert.h>
|
28
|
+
#include <stdlib.h>
|
29
|
+
#include <string.h>
|
30
|
+
|
31
|
+
|
32
|
+
using namespace std;
|
33
|
+
|
34
|
+
|
35
|
+
/**************
|
36
|
+
class PageList
|
37
|
+
**************/
|
38
|
+
|
39
|
+
class PageList
|
40
|
+
{
|
41
|
+
struct Page {
|
42
|
+
Page (const char *b, size_t s): Buffer(b), Size(s) {}
|
43
|
+
const char *Buffer;
|
44
|
+
size_t Size;
|
45
|
+
};
|
46
|
+
|
47
|
+
public:
|
48
|
+
PageList();
|
49
|
+
virtual ~PageList();
|
50
|
+
|
51
|
+
void Push (const char*, int);
|
52
|
+
bool HasPages();
|
53
|
+
void Front (const char**, int*);
|
54
|
+
void PopFront();
|
55
|
+
|
56
|
+
private:
|
57
|
+
deque<Page> Pages;
|
58
|
+
};
|
59
|
+
|
60
|
+
|
61
|
+
#endif // __PageManager__H_
|