Please test snapshots of the coming R9C

Mikael Karlsson mikael.karlsson@REDACTED
Sun Jul 13 20:34:30 CEST 2003

It seems that the ssl:peercert function crashes if there is an
"unexpected" object identifier. I am trying to read a cert from
the Swedish Postens eID (Smartcard) . It does not crash if
I use the options [pkix, subject] instead of [ssl, subject] in the
example below.


ERROR erlang  code  crashed:
 File: /home/mikael/public_html/getpeercert.yaws:8
Reason: {function_clause,[{ssl_pkix_oid,id2atom,[{1,2,752,34,2,1}]},
Req: {http_request,'GET',{abs_path,"/getpeercert.yaws"},{1,1}}

yaws code:
out(A) ->
       case Res = ssl:peercert(A#arg.clisock,[ssl, subject]) of
       {ok,Sequence} ->
            {html,io_lib:format("Accept: peer cert:~n~p~n", [Sequence])};
	_ ->
	   {ehtml,{p,[],f("Error in peer cert sequence ~p", [Res])}}

More information about the erlang-questions mailing list