anchor.diff:          ]).
   
   %% -- Certificate management APIs --
  --export([get_cert_key/1, decode_cert_key/1]).
  +-export([get_cert_key/1]).
    
   start_link(Params) ->
       Interface   = proplists:get_value(tcp_ip,Params),
  
positive.code:                             end];
          [{KeyType,Key,_}|_] -> [{key, {KeyType, Key}}]
      end.
  
  -spec decode_cert_key({file, list()} | {bin, binary()}) -> list().
  decode_cert_key({file, CertFile}) when is_list(CertFile) ->
      {ok, CertBin} = file:read_file(CertFile),
      decode_cert_key({bin,CertBin});
  decode_cert_key({bin,CertBin}) when is_binary(CertBin) ->
      [public_key:pem_entry_decode(Cert)
       || Cert <- public_key:pem_decode(CertBin)].
  
negative.code: %% -- Certificate management interface --
  %%
  
  -spec get_cert_key(binary()) -> [{cert | cacerts | key, any()}].
  get_cert_key(Bin) when is_binary(Bin) ->
      case public_key:pem_decode(Bin) of
          [{'Certificate',Cert,not_encrypted} | Certs] ->
              CACerts = [C || {'Certificate',C,not_encrypted} <- Certs],
  