Mercurial > pidgin
annotate plugins/perl/common/Cipher.xs @ 13159:d03013fd39bf
[gaim-migrate @ 15522]
Fix the filename unescaping.
committer: Tailor Script <tailor@pidgin.im>
| author | Richard Laager <rlaager@wiktel.com> |
|---|---|
| date | Tue, 07 Feb 2006 16:02:25 +0000 |
| parents | 6911a971c97f |
| children |
| rev | line source |
|---|---|
| 11118 | 1 #include "module.h" |
| 2 | |
| 3 MODULE = Gaim::Cipher PACKAGE = Gaim::Cipher PREFIX = gaim_cipher_ | |
| 4 PROTOTYPES: ENABLE | |
| 5 | |
| 6 const gchar * | |
| 7 gaim_cipher_get_name(cipher) | |
| 8 Gaim::Cipher cipher | |
| 9 | |
|
12777
6911a971c97f
[gaim-migrate @ 15124]
Etan Reisner <pidgin@unreliablesource.net>
parents:
11290
diff
changeset
|
10 guint |
| 11118 | 11 gaim_cipher_get_capabilities(cipher) |
| 12 Gaim::Cipher cipher | |
| 13 | |
|
12777
6911a971c97f
[gaim-migrate @ 15124]
Etan Reisner <pidgin@unreliablesource.net>
parents:
11290
diff
changeset
|
14 gboolean |
| 11118 | 15 gaim_cipher_digest_region(name, data, data_len, in_len, digest, out_len) |
| 16 const gchar * name | |
|
12777
6911a971c97f
[gaim-migrate @ 15124]
Etan Reisner <pidgin@unreliablesource.net>
parents:
11290
diff
changeset
|
17 const guchar * data |
| 11130 | 18 size_t data_len |
| 19 size_t in_len | |
|
12777
6911a971c97f
[gaim-migrate @ 15124]
Etan Reisner <pidgin@unreliablesource.net>
parents:
11290
diff
changeset
|
20 guchar &digest |
| 11118 | 21 size_t * out_len |
| 22 | |
|
12777
6911a971c97f
[gaim-migrate @ 15124]
Etan Reisner <pidgin@unreliablesource.net>
parents:
11290
diff
changeset
|
23 MODULE = Gaim::Cipher PACKAGE = Gaim::Ciphers PREFIX = gaim_ciphers_ |
|
6911a971c97f
[gaim-migrate @ 15124]
Etan Reisner <pidgin@unreliablesource.net>
parents:
11290
diff
changeset
|
24 PROTOTYPES: ENABLE |
|
6911a971c97f
[gaim-migrate @ 15124]
Etan Reisner <pidgin@unreliablesource.net>
parents:
11290
diff
changeset
|
25 |
| 11118 | 26 Gaim::Cipher |
| 27 gaim_ciphers_find_cipher(name) | |
| 28 gchar * name | |
| 29 | |
| 30 Gaim::Cipher | |
| 31 gaim_ciphers_register_cipher(name, ops) | |
| 32 gchar * name | |
| 33 Gaim::Cipher::Ops ops | |
| 34 | |
|
12777
6911a971c97f
[gaim-migrate @ 15124]
Etan Reisner <pidgin@unreliablesource.net>
parents:
11290
diff
changeset
|
35 gboolean |
| 11118 | 36 gaim_ciphers_unregister_cipher(cipher) |
| 37 Gaim::Cipher cipher | |
| 38 | |
| 39 void | |
| 40 gaim_ciphers_get_ciphers() | |
| 41 PREINIT: | |
| 42 GList *l; | |
| 43 PPCODE: | |
| 44 for (l = gaim_ciphers_get_ciphers(); l != NULL; l = l->next) { | |
| 45 XPUSHs(sv_2mortal(gaim_perl_bless_object(l->data, "Gaim::Cipher"))); | |
| 46 } | |
| 47 | |
|
12777
6911a971c97f
[gaim-migrate @ 15124]
Etan Reisner <pidgin@unreliablesource.net>
parents:
11290
diff
changeset
|
48 gpointer |
| 11118 | 49 gaim_ciphers_get_handle() |
| 50 | |
|
12777
6911a971c97f
[gaim-migrate @ 15124]
Etan Reisner <pidgin@unreliablesource.net>
parents:
11290
diff
changeset
|
51 void |
| 11118 | 52 gaim_ciphers_init() |
| 53 | |
|
12777
6911a971c97f
[gaim-migrate @ 15124]
Etan Reisner <pidgin@unreliablesource.net>
parents:
11290
diff
changeset
|
54 void |
| 11118 | 55 gaim_ciphers_uninit() |
| 56 | |
|
12777
6911a971c97f
[gaim-migrate @ 15124]
Etan Reisner <pidgin@unreliablesource.net>
parents:
11290
diff
changeset
|
57 MODULE = Gaim::Cipher PACKAGE = Gaim::Cipher::Context PREFIX = gaim_cipher_context_ |
|
6911a971c97f
[gaim-migrate @ 15124]
Etan Reisner <pidgin@unreliablesource.net>
parents:
11290
diff
changeset
|
58 PROTOTYPES: ENABLE |
|
6911a971c97f
[gaim-migrate @ 15124]
Etan Reisner <pidgin@unreliablesource.net>
parents:
11290
diff
changeset
|
59 |
|
6911a971c97f
[gaim-migrate @ 15124]
Etan Reisner <pidgin@unreliablesource.net>
parents:
11290
diff
changeset
|
60 void |
| 11118 | 61 gaim_cipher_context_set_option(context, name, value) |
| 62 Gaim::Cipher::Context context | |
|
12777
6911a971c97f
[gaim-migrate @ 15124]
Etan Reisner <pidgin@unreliablesource.net>
parents:
11290
diff
changeset
|
63 gchar *name |
| 11118 | 64 gpointer value |
| 65 | |
|
12777
6911a971c97f
[gaim-migrate @ 15124]
Etan Reisner <pidgin@unreliablesource.net>
parents:
11290
diff
changeset
|
66 gpointer |
| 11118 | 67 gaim_cipher_context_get_option(context, name) |
| 68 Gaim::Cipher::Context context | |
| 69 gchar *name | |
| 70 | |
| 71 Gaim::Cipher::Context | |
| 72 gaim_cipher_context_new(cipher, extra) | |
|
12777
6911a971c97f
[gaim-migrate @ 15124]
Etan Reisner <pidgin@unreliablesource.net>
parents:
11290
diff
changeset
|
73 Gaim::Cipher cipher |
| 11118 | 74 void *extra |
| 75 | |
| 76 Gaim::Cipher::Context | |
| 77 gaim_cipher_context_new_by_name(name, extra) | |
| 78 gchar *name | |
| 79 void *extra | |
| 80 | |
|
12777
6911a971c97f
[gaim-migrate @ 15124]
Etan Reisner <pidgin@unreliablesource.net>
parents:
11290
diff
changeset
|
81 void |
| 11118 | 82 gaim_cipher_context_reset(context, extra) |
| 83 Gaim::Cipher::Context context | |
| 84 gpointer extra | |
| 85 | |
|
12777
6911a971c97f
[gaim-migrate @ 15124]
Etan Reisner <pidgin@unreliablesource.net>
parents:
11290
diff
changeset
|
86 void |
| 11118 | 87 gaim_cipher_context_destroy(context) |
| 88 Gaim::Cipher::Context context | |
| 89 | |
|
12777
6911a971c97f
[gaim-migrate @ 15124]
Etan Reisner <pidgin@unreliablesource.net>
parents:
11290
diff
changeset
|
90 void |
| 11118 | 91 gaim_cipher_context_set_iv(context, iv, len) |
| 92 Gaim::Cipher::Context context | |
| 11183 | 93 guchar * iv |
| 11118 | 94 size_t len |
| 95 | |
|
12777
6911a971c97f
[gaim-migrate @ 15124]
Etan Reisner <pidgin@unreliablesource.net>
parents:
11290
diff
changeset
|
96 void |
| 11118 | 97 gaim_cipher_context_append(context, data, len) |
| 98 Gaim::Cipher::Context context | |
| 11183 | 99 guchar * data |
| 11118 | 100 size_t len |
| 101 | |
|
12777
6911a971c97f
[gaim-migrate @ 15124]
Etan Reisner <pidgin@unreliablesource.net>
parents:
11290
diff
changeset
|
102 gboolean |
| 11118 | 103 gaim_cipher_context_digest(context, in_len, digest, out_len) |
| 104 Gaim::Cipher::Context context | |
| 105 size_t in_len | |
| 11183 | 106 guchar &digest |
| 11118 | 107 size_t &out_len |
| 108 | |
|
12777
6911a971c97f
[gaim-migrate @ 15124]
Etan Reisner <pidgin@unreliablesource.net>
parents:
11290
diff
changeset
|
109 gboolean |
| 11118 | 110 gaim_cipher_context_digest_to_str(context, in_len, digest_s, out_len) |
| 111 Gaim::Cipher::Context context | |
| 112 size_t in_len | |
| 11202 | 113 gchar &digest_s |
| 11118 | 114 size_t &out_len |
| 115 | |
|
12777
6911a971c97f
[gaim-migrate @ 15124]
Etan Reisner <pidgin@unreliablesource.net>
parents:
11290
diff
changeset
|
116 gint |
| 11118 | 117 gaim_cipher_context_encrypt(context, data, len, output, outlen) |
| 118 Gaim::Cipher::Context context | |
| 11183 | 119 guchar &data |
| 11118 | 120 size_t len |
| 11183 | 121 guchar &output |
| 11118 | 122 size_t &outlen |
| 123 | |
|
12777
6911a971c97f
[gaim-migrate @ 15124]
Etan Reisner <pidgin@unreliablesource.net>
parents:
11290
diff
changeset
|
124 gint |
| 11118 | 125 gaim_cipher_context_decrypt(context, data, len, output, outlen) |
| 126 Gaim::Cipher::Context context | |
| 11183 | 127 guchar &data |
| 11118 | 128 size_t len |
| 11183 | 129 guchar &output |
| 11118 | 130 size_t &outlen |
| 131 | |
|
12777
6911a971c97f
[gaim-migrate @ 15124]
Etan Reisner <pidgin@unreliablesource.net>
parents:
11290
diff
changeset
|
132 void |
| 11118 | 133 gaim_cipher_context_set_salt(context, salt) |
|
12777
6911a971c97f
[gaim-migrate @ 15124]
Etan Reisner <pidgin@unreliablesource.net>
parents:
11290
diff
changeset
|
134 Gaim::Cipher::Context context |
| 11183 | 135 guchar *salt |
| 11118 | 136 |
|
12777
6911a971c97f
[gaim-migrate @ 15124]
Etan Reisner <pidgin@unreliablesource.net>
parents:
11290
diff
changeset
|
137 size_t |
| 11118 | 138 gaim_cipher_context_get_salt_size(context) |
| 139 Gaim::Cipher::Context context | |
| 140 | |
|
12777
6911a971c97f
[gaim-migrate @ 15124]
Etan Reisner <pidgin@unreliablesource.net>
parents:
11290
diff
changeset
|
141 void |
| 11118 | 142 gaim_cipher_context_set_key(context, key) |
|
12777
6911a971c97f
[gaim-migrate @ 15124]
Etan Reisner <pidgin@unreliablesource.net>
parents:
11290
diff
changeset
|
143 Gaim::Cipher::Context context |
| 11183 | 144 guchar *key |
| 11118 | 145 |
|
12777
6911a971c97f
[gaim-migrate @ 15124]
Etan Reisner <pidgin@unreliablesource.net>
parents:
11290
diff
changeset
|
146 size_t |
| 11118 | 147 gaim_cipher_context_get_key_size(context) |
| 148 Gaim::Cipher::Context context | |
| 149 | |
|
12777
6911a971c97f
[gaim-migrate @ 15124]
Etan Reisner <pidgin@unreliablesource.net>
parents:
11290
diff
changeset
|
150 void |
| 11118 | 151 gaim_cipher_context_set_data(context, data) |
| 152 Gaim::Cipher::Context context | |
| 153 gpointer data | |
| 154 | |
|
12777
6911a971c97f
[gaim-migrate @ 15124]
Etan Reisner <pidgin@unreliablesource.net>
parents:
11290
diff
changeset
|
155 gpointer |
| 11118 | 156 gaim_cipher_context_get_data(context) |
| 157 Gaim::Cipher::Context context |
