gio2 1.1.4-x86-mingw32 → 1.1.5-x86-mingw32

Sign up to get free protection for your applications and to get access to all the features.
data/Rakefile CHANGED
@@ -1,6 +1,7 @@
1
1
  # -*- ruby -*-
2
2
 
3
- require './../glib2/lib/gnome2-raketask'
3
+ $LOAD_PATH.unshift("./../glib2/lib")
4
+ require 'gnome2-raketask'
4
5
 
5
6
  package = GNOME2Package.new do |_package|
6
7
  _package.summary = "Ruby/GIO2 is a Ruby binding of gio-2.x."
@@ -113,6 +113,7 @@ Init_gio(void)
113
113
  Init_gtcpconnection(RG_TARGET_NAMESPACE);
114
114
  Init_gthemedicon(RG_TARGET_NAMESPACE);
115
115
  Init_gthreadedsocketservice(RG_TARGET_NAMESPACE);
116
+ Init_gtlscertificate(RG_TARGET_NAMESPACE);
116
117
  Init_gunixconnection(RG_TARGET_NAMESPACE);
117
118
  Init_gunixfdlist(RG_TARGET_NAMESPACE);
118
119
  Init_gunixfdmessage(RG_TARGET_NAMESPACE);
@@ -56,92 +56,93 @@ G_GNUC_INTERNAL void rbgio_async_ready_callback(GObject *source,
56
56
  G_GNUC_INTERNAL VALUE rbgio_child_remove_and_return(VALUE parent, VALUE child);
57
57
 
58
58
  G_GNUC_INTERNAL void Init_gio(void);
59
- G_GNUC_INTERNAL void Init_gappinfo(VALUE glib);
60
- G_GNUC_INTERNAL void Init_gapplaunchcontext(VALUE glib);
61
- G_GNUC_INTERNAL void Init_gasyncinitable(VALUE glib);
62
- G_GNUC_INTERNAL void Init_gasyncresult(VALUE glib);
63
- G_GNUC_INTERNAL void Init_gbufferedinputstream(VALUE glib);
64
- G_GNUC_INTERNAL void Init_gbufferedoutputstream(VALUE glib);
65
- G_GNUC_INTERNAL void Init_gcancellable(VALUE glib);
66
- G_GNUC_INTERNAL void Init_gcharsetconverter(VALUE glib);
67
- G_GNUC_INTERNAL void Init_gcontenttype(VALUE glib);
68
- G_GNUC_INTERNAL void Init_gconverter(VALUE glib);
69
- G_GNUC_INTERNAL void Init_gconverterinputstream(VALUE glib);
70
- G_GNUC_INTERNAL void Init_gconverteroutputstream(VALUE glib);
71
- G_GNUC_INTERNAL void Init_gdatainputstream(VALUE glib);
72
- G_GNUC_INTERNAL void Init_gdataoutputstream(VALUE glib);
73
- G_GNUC_INTERNAL void Init_gdesktopappinfo(VALUE glib);
74
- G_GNUC_INTERNAL void Init_gdrive(VALUE glib);
75
- G_GNUC_INTERNAL void Init_gemblem(VALUE glib);
76
- G_GNUC_INTERNAL void Init_gemblemedicon(VALUE glib);
77
- G_GNUC_INTERNAL void Init_gfile(VALUE glib);
78
- G_GNUC_INTERNAL void Init_gfileattribute(VALUE glib);
79
- G_GNUC_INTERNAL void Init_gfileattributeinfo(VALUE glib);
80
- G_GNUC_INTERNAL void Init_fileattributeinfolist(VALUE glib);
81
- G_GNUC_INTERNAL void Init_gfileattributematcher(VALUE glib);
82
- G_GNUC_INTERNAL void Init_gfiledescriptorbased(VALUE glib);
83
- G_GNUC_INTERNAL void Init_gfileenumerator(VALUE glib);
84
- G_GNUC_INTERNAL void Init_gfileicon(VALUE glib);
85
- G_GNUC_INTERNAL void Init_gfileinfo(VALUE glib);
86
- G_GNUC_INTERNAL void Init_gfileinputstream(VALUE glib);
87
- G_GNUC_INTERNAL void Init_gfileiostream(VALUE glib);
88
- G_GNUC_INTERNAL void Init_gfilemonitor(VALUE glib);
89
- G_GNUC_INTERNAL void Init_gfilenamecompleter(VALUE glib);
90
- G_GNUC_INTERNAL void Init_gfileoutputstream(VALUE glib);
91
- G_GNUC_INTERNAL void Init_gfilterinputstream(VALUE glib);
92
- G_GNUC_INTERNAL void Init_gfilteroutputstream(VALUE glib);
93
- G_GNUC_INTERNAL void Init_gicon(VALUE glib);
94
- G_GNUC_INTERNAL void Init_ginetaddress(VALUE glib);
95
- G_GNUC_INTERNAL void Init_ginetsocketaddress(VALUE glib);
96
- G_GNUC_INTERNAL void Init_ginitable(VALUE glib);
97
- G_GNUC_INTERNAL void Init_ginputstream(VALUE glib);
98
- G_GNUC_INTERNAL void Init_gioerror(VALUE glib);
99
- G_GNUC_INTERNAL void Init_giomodule(VALUE glib);
100
- G_GNUC_INTERNAL void Init_giomodules(VALUE glib);
101
- G_GNUC_INTERNAL void Init_gioscheduler(VALUE glib);
102
- G_GNUC_INTERNAL void Init_gioschedulerjob(VALUE glib);
103
- G_GNUC_INTERNAL void Init_giostream(VALUE glib);
104
- G_GNUC_INTERNAL void Init_gloadableicon(VALUE glib);
105
- G_GNUC_INTERNAL void Init_gmemoryinputstream(VALUE glib);
106
- G_GNUC_INTERNAL void Init_gmemoryoutputstream(VALUE glib);
107
- G_GNUC_INTERNAL void Init_gmount(VALUE glib);
108
- G_GNUC_INTERNAL void Init_gmountoperation(VALUE glib);
109
- G_GNUC_INTERNAL void Init_gnetworkaddress(VALUE glib);
110
- G_GNUC_INTERNAL void Init_gnetworkservice(VALUE glib);
111
- G_GNUC_INTERNAL void Init_goutputstream(VALUE glib);
112
- G_GNUC_INTERNAL void Init_gresolver(VALUE glib);
113
- G_GNUC_INTERNAL void Init_gseekable(VALUE glib);
114
- G_GNUC_INTERNAL void Init_gsimpleasyncresult(VALUE glib);
115
- G_GNUC_INTERNAL void Init_gsocket(VALUE glib);
116
- G_GNUC_INTERNAL void Init_gsocketaddress(VALUE glib);
117
- G_GNUC_INTERNAL void Init_gsocketclient(VALUE glib);
118
- G_GNUC_INTERNAL void Init_gsocketconnectable(VALUE glib);
119
- G_GNUC_INTERNAL void Init_gsocketaddressenumerator(VALUE glib);
120
- G_GNUC_INTERNAL void Init_gsocketconnection(VALUE glib);
121
- G_GNUC_INTERNAL void Init_gsocketconnectionfactory(VALUE glib);
122
- G_GNUC_INTERNAL void Init_gsocketcontrolmessage(VALUE glib);
123
- G_GNUC_INTERNAL void Init_gsocketlistener(VALUE glib);
124
- G_GNUC_INTERNAL void Init_gsocketservice(VALUE glib);
125
- G_GNUC_INTERNAL void Init_gsrvtarget(VALUE glib);
126
- G_GNUC_INTERNAL void Init_gtcpconnection(VALUE glib);
127
- G_GNUC_INTERNAL void Init_gthreadedsocketservice(VALUE glib);
128
- G_GNUC_INTERNAL void Init_gthemedicon(VALUE glib);
129
- G_GNUC_INTERNAL void Init_gunixconnection(VALUE glib);
130
- G_GNUC_INTERNAL void Init_gunixfdlist(VALUE glib);
131
- G_GNUC_INTERNAL void Init_gunixfdmessage(VALUE glib);
132
- G_GNUC_INTERNAL void Init_gunixinputstream(VALUE glib);
133
- G_GNUC_INTERNAL void Init_gunixmount(VALUE glib);
134
- G_GNUC_INTERNAL void Init_gunixmounts(VALUE glib);
135
- G_GNUC_INTERNAL void Init_gunixmountpoint(VALUE glib);
136
- G_GNUC_INTERNAL void Init_gunixmountpoints(VALUE glib);
137
- G_GNUC_INTERNAL void Init_gunixmountmonitor(VALUE glib);
138
- G_GNUC_INTERNAL void Init_gunixoutputstream(VALUE glib);
139
- G_GNUC_INTERNAL void Init_gunixsocketaddress(VALUE glib);
140
- G_GNUC_INTERNAL void Init_gvfs(VALUE glib);
141
- G_GNUC_INTERNAL void Init_gvolume(VALUE glib);
142
- G_GNUC_INTERNAL void Init_gvolumemonitor(VALUE glib);
143
- G_GNUC_INTERNAL void Init_gzlibcompressor(VALUE glib);
144
- G_GNUC_INTERNAL void Init_gzlibdecompressor(VALUE glib);
59
+ G_GNUC_INTERNAL void Init_gappinfo(VALUE mGio);
60
+ G_GNUC_INTERNAL void Init_gapplaunchcontext(VALUE mGio);
61
+ G_GNUC_INTERNAL void Init_gasyncinitable(VALUE mGio);
62
+ G_GNUC_INTERNAL void Init_gasyncresult(VALUE mGio);
63
+ G_GNUC_INTERNAL void Init_gbufferedinputstream(VALUE mGio);
64
+ G_GNUC_INTERNAL void Init_gbufferedoutputstream(VALUE mGio);
65
+ G_GNUC_INTERNAL void Init_gcancellable(VALUE mGio);
66
+ G_GNUC_INTERNAL void Init_gcharsetconverter(VALUE mGio);
67
+ G_GNUC_INTERNAL void Init_gcontenttype(VALUE mGio);
68
+ G_GNUC_INTERNAL void Init_gconverter(VALUE mGio);
69
+ G_GNUC_INTERNAL void Init_gconverterinputstream(VALUE mGio);
70
+ G_GNUC_INTERNAL void Init_gconverteroutputstream(VALUE mGio);
71
+ G_GNUC_INTERNAL void Init_gdatainputstream(VALUE mGio);
72
+ G_GNUC_INTERNAL void Init_gdataoutputstream(VALUE mGio);
73
+ G_GNUC_INTERNAL void Init_gdesktopappinfo(VALUE mGio);
74
+ G_GNUC_INTERNAL void Init_gdrive(VALUE mGio);
75
+ G_GNUC_INTERNAL void Init_gemblem(VALUE mGio);
76
+ G_GNUC_INTERNAL void Init_gemblemedicon(VALUE mGio);
77
+ G_GNUC_INTERNAL void Init_gfile(VALUE mGio);
78
+ G_GNUC_INTERNAL void Init_gfileattribute(VALUE mGio);
79
+ G_GNUC_INTERNAL void Init_gfileattributeinfo(VALUE mGio);
80
+ G_GNUC_INTERNAL void Init_fileattributeinfolist(VALUE mGio);
81
+ G_GNUC_INTERNAL void Init_gfileattributematcher(VALUE mGio);
82
+ G_GNUC_INTERNAL void Init_gfiledescriptorbased(VALUE mGio);
83
+ G_GNUC_INTERNAL void Init_gfileenumerator(VALUE mGio);
84
+ G_GNUC_INTERNAL void Init_gfileicon(VALUE mGio);
85
+ G_GNUC_INTERNAL void Init_gfileinfo(VALUE mGio);
86
+ G_GNUC_INTERNAL void Init_gfileinputstream(VALUE mGio);
87
+ G_GNUC_INTERNAL void Init_gfileiostream(VALUE mGio);
88
+ G_GNUC_INTERNAL void Init_gfilemonitor(VALUE mGio);
89
+ G_GNUC_INTERNAL void Init_gfilenamecompleter(VALUE mGio);
90
+ G_GNUC_INTERNAL void Init_gfileoutputstream(VALUE mGio);
91
+ G_GNUC_INTERNAL void Init_gfilterinputstream(VALUE mGio);
92
+ G_GNUC_INTERNAL void Init_gfilteroutputstream(VALUE mGio);
93
+ G_GNUC_INTERNAL void Init_gicon(VALUE mGio);
94
+ G_GNUC_INTERNAL void Init_ginetaddress(VALUE mGio);
95
+ G_GNUC_INTERNAL void Init_ginetsocketaddress(VALUE mGio);
96
+ G_GNUC_INTERNAL void Init_ginitable(VALUE mGio);
97
+ G_GNUC_INTERNAL void Init_ginputstream(VALUE mGio);
98
+ G_GNUC_INTERNAL void Init_gioerror(VALUE mGio);
99
+ G_GNUC_INTERNAL void Init_giomodule(VALUE mGio);
100
+ G_GNUC_INTERNAL void Init_giomodules(VALUE mGio);
101
+ G_GNUC_INTERNAL void Init_gioscheduler(VALUE mGio);
102
+ G_GNUC_INTERNAL void Init_gioschedulerjob(VALUE mGio);
103
+ G_GNUC_INTERNAL void Init_giostream(VALUE mGio);
104
+ G_GNUC_INTERNAL void Init_gloadableicon(VALUE mGio);
105
+ G_GNUC_INTERNAL void Init_gmemoryinputstream(VALUE mGio);
106
+ G_GNUC_INTERNAL void Init_gmemoryoutputstream(VALUE mGio);
107
+ G_GNUC_INTERNAL void Init_gmount(VALUE mGio);
108
+ G_GNUC_INTERNAL void Init_gmountoperation(VALUE mGio);
109
+ G_GNUC_INTERNAL void Init_gnetworkaddress(VALUE mGio);
110
+ G_GNUC_INTERNAL void Init_gnetworkservice(VALUE mGio);
111
+ G_GNUC_INTERNAL void Init_goutputstream(VALUE mGio);
112
+ G_GNUC_INTERNAL void Init_gresolver(VALUE mGio);
113
+ G_GNUC_INTERNAL void Init_gseekable(VALUE mGio);
114
+ G_GNUC_INTERNAL void Init_gsimpleasyncresult(VALUE mGio);
115
+ G_GNUC_INTERNAL void Init_gsocket(VALUE mGio);
116
+ G_GNUC_INTERNAL void Init_gsocketaddress(VALUE mGio);
117
+ G_GNUC_INTERNAL void Init_gsocketclient(VALUE mGio);
118
+ G_GNUC_INTERNAL void Init_gsocketconnectable(VALUE mGio);
119
+ G_GNUC_INTERNAL void Init_gsocketaddressenumerator(VALUE mGio);
120
+ G_GNUC_INTERNAL void Init_gsocketconnection(VALUE mGio);
121
+ G_GNUC_INTERNAL void Init_gsocketconnectionfactory(VALUE mGio);
122
+ G_GNUC_INTERNAL void Init_gsocketcontrolmessage(VALUE mGio);
123
+ G_GNUC_INTERNAL void Init_gsocketlistener(VALUE mGio);
124
+ G_GNUC_INTERNAL void Init_gsocketservice(VALUE mGio);
125
+ G_GNUC_INTERNAL void Init_gsrvtarget(VALUE mGio);
126
+ G_GNUC_INTERNAL void Init_gtcpconnection(VALUE mGio);
127
+ G_GNUC_INTERNAL void Init_gthreadedsocketservice(VALUE mGio);
128
+ G_GNUC_INTERNAL void Init_gthemedicon(VALUE mGio);
129
+ G_GNUC_INTERNAL void Init_gtlscertificate(VALUE mGio);
130
+ G_GNUC_INTERNAL void Init_gunixconnection(VALUE mGio);
131
+ G_GNUC_INTERNAL void Init_gunixfdlist(VALUE mGio);
132
+ G_GNUC_INTERNAL void Init_gunixfdmessage(VALUE mGio);
133
+ G_GNUC_INTERNAL void Init_gunixinputstream(VALUE mGio);
134
+ G_GNUC_INTERNAL void Init_gunixmount(VALUE mGio);
135
+ G_GNUC_INTERNAL void Init_gunixmounts(VALUE mGio);
136
+ G_GNUC_INTERNAL void Init_gunixmountpoint(VALUE mGio);
137
+ G_GNUC_INTERNAL void Init_gunixmountpoints(VALUE mGio);
138
+ G_GNUC_INTERNAL void Init_gunixmountmonitor(VALUE mGio);
139
+ G_GNUC_INTERNAL void Init_gunixoutputstream(VALUE mGio);
140
+ G_GNUC_INTERNAL void Init_gunixsocketaddress(VALUE mGio);
141
+ G_GNUC_INTERNAL void Init_gvfs(VALUE mGio);
142
+ G_GNUC_INTERNAL void Init_gvolume(VALUE mGio);
143
+ G_GNUC_INTERNAL void Init_gvolumemonitor(VALUE mGio);
144
+ G_GNUC_INTERNAL void Init_gzlibcompressor(VALUE mGio);
145
+ G_GNUC_INTERNAL void Init_gzlibdecompressor(VALUE mGio);
145
146
  G_GNUC_INTERNAL void Init_util(void);
146
147
 
147
148
  #endif /* __RBGIO2PRIVATE_H__ */
@@ -0,0 +1,89 @@
1
+ /* -*- c-file-style: "ruby"; indent-tabs-mode: nil -*- */
2
+ /*
3
+ * Copyright (C) 2012 Ruby-GNOME2 Project Team
4
+ *
5
+ * This library is free software; you can redistribute it and/or
6
+ * modify it under the terms of the GNU Lesser General Public
7
+ * License as published by the Free Software Foundation; either
8
+ * version 2.1 of the License, or (at your option) any later version.
9
+ *
10
+ * This library is distributed in the hope that it will be useful,
11
+ * but WITHOUT ANY WARRANTY; without even the implied warranty of
12
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13
+ * Lesser General Public License for more details.
14
+ *
15
+ * You should have received a copy of the GNU Lesser General Public
16
+ * License along with this library; if not, write to the Free Software
17
+ * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston,
18
+ * MA 02110-1301 USA
19
+ */
20
+
21
+ #include "rbgio2private.h"
22
+
23
+ #define RG_TARGET_NAMESPACE cTlsCertificate
24
+ #define _SELF(value) RVAL2GOBJ(value)
25
+
26
+ static VALUE
27
+ rg_initialize(VALUE self, VALUE data)
28
+ {
29
+ GTlsCertificate *certificate;
30
+ GError *error = NULL;
31
+
32
+ certificate = g_tls_certificate_new_from_pem(StringValuePtr(data),
33
+ RSTRING_LEN(data),
34
+ &error);
35
+ if (error)
36
+ rbgio_raise_error(error);
37
+
38
+ G_INITIALIZE(self, certificate);
39
+
40
+ return Qnil;
41
+ }
42
+
43
+ static VALUE
44
+ rg_s_load(int argc, VALUE *argv, G_GNUC_UNUSED VALUE self)
45
+ {
46
+ VALUE cert_file, key_file;
47
+ GError *error = NULL;
48
+ GTlsCertificate *certificate;
49
+
50
+ rb_scan_args(argc, argv, "11", &cert_file, &key_file);
51
+ if (NIL_P(key_file)) {
52
+ certificate = g_tls_certificate_new_from_file(StringValuePtr(cert_file),
53
+ &error);
54
+ } else {
55
+ certificate = g_tls_certificate_new_from_files(StringValuePtr(cert_file),
56
+ StringValuePtr(key_file),
57
+ &error);
58
+ }
59
+
60
+ if (error)
61
+ rbgio_raise_error(error);
62
+
63
+ return GOBJ2RVAL_UNREF(certificate);
64
+ }
65
+
66
+ static VALUE
67
+ rg_verify(VALUE self, VALUE identity, VALUE trusted_ca)
68
+ {
69
+ GTlsCertificateFlags flags;
70
+
71
+ flags = g_tls_certificate_verify(_SELF(self),
72
+ RVAL2GOBJ(identity),
73
+ RVAL2GOBJ(trusted_ca));
74
+ return GFLAGS2RVAL(flags, G_TYPE_TLS_CERTIFICATE_FLAGS);
75
+ }
76
+
77
+ void
78
+ Init_gtlscertificate(VALUE mGio)
79
+ {
80
+ VALUE RG_TARGET_NAMESPACE = G_DEF_CLASS(G_TYPE_TLS_CERTIFICATE,
81
+ "TlsCertificate", mGio);
82
+
83
+ G_DEF_CLASS(G_TYPE_TLS_CERTIFICATE_FLAGS, "TlsCertificateFlags", mGio);
84
+
85
+ RG_DEF_SMETHOD(load, -1);
86
+
87
+ RG_DEF_METHOD(initialize, 1);
88
+ RG_DEF_METHOD(verify, 2);
89
+ }
Binary file
Binary file
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: gio2
3
3
  version: !ruby/object:Gem::Version
4
- hash: 27
4
+ hash: 25
5
5
  prerelease:
6
6
  segments:
7
7
  - 1
8
8
  - 1
9
- - 4
10
- version: 1.1.4
9
+ - 5
10
+ version: 1.1.5
11
11
  platform: x86-mingw32
12
12
  authors:
13
13
  - The Ruby-GNOME2 Project Team
@@ -15,7 +15,7 @@ autorequire:
15
15
  bindir: bin
16
16
  cert_chain: []
17
17
 
18
- date: 2012-07-21 00:00:00 Z
18
+ date: 2012-08-28 00:00:00 Z
19
19
  dependencies:
20
20
  - !ruby/object:Gem::Dependency
21
21
  name: glib2
@@ -25,12 +25,12 @@ dependencies:
25
25
  requirements:
26
26
  - - ">="
27
27
  - !ruby/object:Gem::Version
28
- hash: 27
28
+ hash: 25
29
29
  segments:
30
30
  - 1
31
31
  - 1
32
- - 4
33
- version: 1.1.4
32
+ - 5
33
+ version: 1.1.5
34
34
  type: :runtime
35
35
  version_requirements: *id001
36
36
  description: Ruby/GIO2 is a Ruby binding of gio-2.x.
@@ -132,6 +132,7 @@ files:
132
132
  - ext/gio2/rbgio.c
133
133
  - ext/gio2/rbgioseekable.c
134
134
  - ext/gio2/rbgiofilterinputstream.c
135
+ - ext/gio2/rbgiotlscertificate.c
135
136
  - ext/gio2/rbgiofileattributematcher.c
136
137
  - ext/gio2/depend
137
138
  - ext/gio2/gio2.def