aboutsummaryrefslogtreecommitdiffstats
path: root/lib/common_test/test
diff options
context:
space:
mode:
authorSiri Hansen <[email protected]>2012-12-06 12:02:00 +0100
committerSiri Hansen <[email protected]>2012-12-14 11:20:55 +0100
commitf044676419eea2f77f81ccd718ea67524fac03c6 (patch)
tree63ff7ef2b65b6c332b72f6470c7c58db1a5bdd72 /lib/common_test/test
parent14351577fbc3e560ca36fa888e8988e332e5ad79 (diff)
downloadotp-f044676419eea2f77f81ccd718ea67524fac03c6.tar.gz
otp-f044676419eea2f77f81ccd718ea67524fac03c6.tar.bz2
otp-f044676419eea2f77f81ccd718ea67524fac03c6.zip
[common_test] Changed call to publick_key to use documented interface
Earlier used 'OTP-PUB-KEY':encode/2 - now public_key:der_encode/2 instead.
Diffstat (limited to 'lib/common_test/test')
-rw-r--r--lib/common_test/test/ct_netconfc_SUITE_data/netconfc1_SUITE.erl7
1 files changed, 2 insertions, 5 deletions
diff --git a/lib/common_test/test/ct_netconfc_SUITE_data/netconfc1_SUITE.erl b/lib/common_test/test/ct_netconfc_SUITE_data/netconfc1_SUITE.erl
index d337158bce..54526e8e83 100644
--- a/lib/common_test/test/ct_netconfc_SUITE_data/netconfc1_SUITE.erl
+++ b/lib/common_test/test/ct_netconfc_SUITE_data/netconfc1_SUITE.erl
@@ -1044,12 +1044,9 @@ gen_dsa(LSize,NSize) when is_integer(LSize), is_integer(NSize) ->
Key = gen_dsa2(LSize, NSize),
{Key, encode_key(Key)}.
-encode_key(Key = #'RSAPrivateKey'{}) ->
- {ok, Der} = 'OTP-PUB-KEY':encode('RSAPrivateKey', Key),
- {'RSAPrivateKey', list_to_binary(Der), not_encrypted};
encode_key(Key = #'DSAPrivateKey'{}) ->
- {ok, Der} = 'OTP-PUB-KEY':encode('DSAPrivateKey', Key),
- {'DSAPrivateKey', list_to_binary(Der), not_encrypted}.
+ Der = public_key:der_encode('DSAPrivateKey', Key),
+ {'DSAPrivateKey', Der, not_encrypted}.
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%