src/x509.c

changeset 33
cc36229b3be1
parent 32
c47594a84f04
child 35
4994321eae31
equal deleted inserted replaced
32:c47594a84f04 33:cc36229b3be1
171 lua_rawseti(L, -2, lua_objlen(L, -2)+1); 171 lua_rawseti(L, -2, lua_objlen(L, -2)+1);
172 172
173 lua_pop(L, 1); 173 lua_pop(L, 1);
174 break; 174 break;
175 } 175 }
176 case GEN_EMAIL:
177 lua_pushstring(L, "rfc822Name");
178 luasec_push_subtable(L, -2);
179 luasec_push_asn1_string(L, general_name->d.rfc822Name);
180 lua_rawseti(L, -2, lua_objlen(L, -2)+1);
181 lua_pop(L, 1);
182 break;
176 case GEN_DNS: 183 case GEN_DNS:
177 {
178 lua_pushstring(L, "dNSName"); 184 lua_pushstring(L, "dNSName");
179 luasec_push_subtable(L, -2); 185 luasec_push_subtable(L, -2);
180 luasec_push_asn1_string(L, general_name->d.dNSName); 186 luasec_push_asn1_string(L, general_name->d.dNSName);
181 lua_rawseti(L, -2, lua_objlen(L, -2)+1); 187 lua_rawseti(L, -2, lua_objlen(L, -2)+1);
182 lua_pop(L, 1); 188 lua_pop(L, 1);
183 break; 189 break;
184 } 190 case GEN_X400:
191 /* x400Address */
192 break;
193 case GEN_DIRNAME:
194 /* directoryName */
195 break;
196 case GEN_EDIPARTY:
197 /* ediPartyName */
198 break;
199 case GEN_URI:
200 lua_pushstring(L, "uniformResourceIdentifier");
201 luasec_push_subtable(L, -2);
202 luasec_push_asn1_string(L, general_name->d.uniformResourceIdentifier);
203 lua_rawseti(L, -2, lua_objlen(L, -2)+1);
204 lua_pop(L, 1);
205 break;
206 case GEN_IPADD:
207 lua_pushstring(L, "iPAddress");
208 luasec_push_subtable(L, -2);
209 luasec_push_asn1_string(L, general_name->d.iPAddress);
210 lua_rawseti(L, -2, lua_objlen(L, -2)+1);
211 lua_pop(L, 1);
212 break;
213 case GEN_RID:
214 /* registeredID */
215 break;
185 default: 216 default:
186 break; 217 break;
187 } 218 }
188 } 219 }
189 220

mercurial