SlideShare a Scribd company logo
2017#apricot2017
RSA and ECDSA
Geoff Huston
APNIC
2017#apricot2017
It’s all about Cryptography
2017#apricot2017
Why use Cryptography?
Public	key	cryptography	can	be	used	in	a	number	of	ways:
– protecting	a	session	from	third	party	eavesdroppers
Encryption	using	a	session	key	that	is	known	only	to	the	parties	to	the	conversation
– protecting	a	session	from	interference
Injection	(or	removal)	of	part	of	a	session	can	only	be	undertaken	by	the	parties	to	the	
session
– authentication	and	non-repudiation
What	is	received	is	exactly	what	the	other	party	sent,	and	cannot	be	repudiated
2017#apricot2017
Symmetric Crypto
A	symmetric	crypto	algorithm	uses	the	same	key	to
– Convert	a	plaintext	message	to	a	crypted message
– Convert	a	crypted message	to	its	plaintext	message
• They	are	generally	fast	and	simple
BUT	they	use	a	shared	key
– This	key	distribution	problem	can	be	a	critical	weakness	in	the	crypto	
framework
2017#apricot2017
Asymmetric Crypto
This	is	a	class	of	asymmetric	transforms	applied	to	a	message	such	that:
Messages	encrypted	using	Key	A	and	algorithm	X	can	only	be	translated	back	to	the	
original	message	using	Key	B	and	algorithm	X
This	also	holds	in	reverse
This	can	address	the	shared	key	problem:
If	I	publish	Key	A	and	keep	Key	B	a	secret	then	you	can	send	me	a	secret	by	
encrypting	it	using	my	public	key	A
2017#apricot2017
The Asymmetric Crypto Challenge
Devise	an	algorithm	(encoding)	and	
keys	such	that:
– Messages	encoded	with	one	key	can	
only	be	decoded	with	the	other	key
– Knowledge	of	the	value	of	one	key	does	
not	infer	the	value	of	the	other	key
http://bit.ly/2iQ0oi7
2017#apricot2017
RSA
Select	two	large	(>	256	bit)	prime	numbers,	p and	q,	then:
n	=	p.q
⏀(n)	=	(p-1).(q-1)	(the	number	of	numbers	that	are	relatively	prime	to	n)
Pick	an	e	that	is	relatively	prime	to	⏀(n)
The	PUBLIC	KEY	is	<e,n>
Pick	a	value	for	d such	that	d.e =	1	mod	⏀(n)
The	PRIVATE	KEY	is	<d,n>
For	any	x,			xde ≡ x	(mod	n)
2017#apricot2017
Why does RSA work?
Encryption	using	the	public	key	consists	of	taking	a	message	x and	
raising	it	to	the	power	e
Crypt	=	xe
Decryption	consists	of	taking	an	encrypted	message	and	raising	it	
to	the	power	d,	mod	n
Decrypt	=	Cryptd mod	n	=	(xe)d mod	n	=	xed mod	n	=	x
Similarly,	one	can	encrypt	a	message	with	the	private	key	(xd )	and	
decrypt	with	the	public	key	((xd )	e mod	n	=	x)
2017#apricot2017
Why does RSA work?
If	you	know	e and	n	(the	public	key)	then	how	can	you	calculate	d (the	
private	key)?
Now	d.e =	1	mod	⏀(n)
If	you	know	⏀(n)	you	can	calculate	d
But	⏀(n)	=	(p-1).(q-1),	where	p.q =	n
i.e.	you	need	to	find	the	prime	factors	of	n,	a	large	composite	number	that	
is	the	product	of	two	primes
2017#apricot2017
The ‘core’ of RSA
(xe)d ≡	x mod n
As	long	as	d and	n are	relatively	large,	and	n is	
the	product	of	two	large	prime	numbers,	then	
finding	the	value	of	d when	you	already	know	
the	values	of	e and	n is	computationally	
expensive
2017#apricot2017
The ‘core’ of RSA
(xe)d ≡	x mod n
As	long	as	d and	n are	relatively	large,	and	n is	
the	product	of	two	large	prime	numbers,	then	
finding	the	value	of	d when	you	already	know	
the	values	of	e and	n is	computationally	
expensive
2017#apricot2017
The ‘core’ of RSA
(xe)d ≡	x mod n
As	long	as	d and	n are	relatively	large,	and	n is	
the	
product	of	two	large	prime	numbers,	then	
finding	the	value	of	d when	you	already	know	
the	values	of	e and	n is	computationally	
expensive
2017#apricot2017
Why is this important?
Because much of the foundation of
Internet Security rests upon this
relationship
2017#apricot2017
How big can RSA go?
In	theory	we	can	push	this	to	very	large	sizes	of	n to	generate	RSA	
private	keys
The	algorithm	is	not	itself	arbitrarily	limited	in	terms	of	key	size
But	as	the	numbers	get	larger	there	is	higher	computation	overhead	to	
generate	and	manipulate	these	keys
So	we	want	it	large	enough	not	to	be	‘broken’	by	most	forms	of	brute	
force,	but	small	enough	to	be	computed	by	our	everyday	processors
2017#apricot2017
How big should RSA go?
You	need	to	consider	time as	well
How	long	do	you	want	or	need	your	secret	to	remain	a	secret?
Because	if	the	attacker	has	enough	time	a	brute	force	attack	may	work
Also	time	is	on	the	attacker’s	side:	keys	that	are	considered	robust	today	may	not	
be	as	robust	tomorrow,	assuming	that	feasible	compute	capabilities	rise	over	time
So	you	want	to	pick	a	key	size	that	is	resistant	to	attempts	to	brute	force	the	
key	both	today	and	tomorrow
2017#apricot2017
Bigger and bigger?
Well,	no	– the	larger	the	key	sizes	compared	to	compute	
capabilities	means:
– Longer	times	to	generate	keys
– Longer	times	to	encrypt	(and	decrypt)	messages
– More	space	to	represent	the	key	values
So	you	need	to	use	big	keys,	but	no	bigger	then	necessary!
2017#apricot2017
Be Specific!
Time	to	consult	the	experts!
http://nvlpubs.nist.gov/nistpubs/SpecialPublications/NIST.SP.800-57Pt3r1.pdf
2017#apricot2017
RSA is everywhere…
2017#apricot2017
My Bank…(I hope!)
2017#apricot2017
TLS: Protecting the session
https://rhsecurity.wordpress.com/tag/tls/
2017#apricot2017
The Key to My Bank
Yes, the fine print says my
bank is using a 2048-bit RSA
Public key to as the foundation
of the session key used to
secure access to my bank
2017#apricot2017
I trust its my bank because …
• The	server	has	demonstrated	knowledge	of	a	private	key	that	
is	associated	with	a	public	key	that	I	have	been	provided
• The	public	key	has	been	associated	with	a	particular	domain	
name	by	a	Certificate	Authority
• My	browser	trusts	that	this	Certificate	Authority	never	lies	
about	such	associations
• So	if	the	server	can	demonstrate	that	it	has	the	private	key	
then	my	browser	will	believe	that	its	my	bank!
2017#apricot2017
DNSSEC and the DNS
Another	major	application	for	crypto	in	the	Internet	is	securing	
the	DNS
You	want	to	be	assured	that	the	response	you	get	to	from	DNS	
query	is:
– Authentic
– Complete
– Current
2017#apricot2017
DNSSEC Interlocking Signatures
.	(root)
.com
.example.com
www.example.com
.	Key-Signing	Key	– signs	over
.	Zone-Signing	Key	– signs	over
DS	for	.com	(Key-Signing	Key)
.com	Key-Signing	Key	– signs	over
.com	Zone-Signing	Key	– signs	over
DS	for	example	.com	(Key-Signing	Key)
example.com Key-Signing	Key	– signs	over
example.com Zone-Signing	Key	– signs	over
www.example.com
2017#apricot2017
DNSSEC Interlocking Signatures
.	(root)
.com
.example.com
www.example.com IN	A	192.0.1
.	Key-Signing	Key	– signs	over
.	Zone-Signing	Key	– signs	over
DS	for	.com	(Key-Signing	Key)
.com	Key-Signing	Key	– signs	over
.com	Zone-Signing	Key	– signs	over
DS	for	example	.com	(Key-Signing	Key)
example.com Key-Signing	Key	– signs	over
example.com Zone-Signing	Key	– signs	over
www.example.com
2017#apricot2017
DNSSEC Interlocking Signatures
.	(root)
.com
.example.com
www.example.com IN	A	192.0.1
.	Key-Signing	Key	– signs	over
.	Zone-Signing	Key	– signs	over
DS	for	.com	(Key-Signing	Key)
.com	Key-Signing	Key	– signs	over
.com	Zone-Signing	Key	– signs	over
DS	for	example	.com	(Key-Signing	Key)
example.com Key-Signing	Key	– signs	over
example.com Zone-Signing	Key	– signs	over
www.example.com
Is the signature for this record valid?
Is the ZSK for example.com valid?
Is the KSK for example.com valid?
Is this DS equal to the hash of the KSK?
Is the signature for this record valid?
Is the ZSK for .com valid?
Is the KSK for .com valid?
Is this DS equal to the hash of the KSK?
Is the signature for this record valid?
Is the ZSK for . valid?
Is the KSK for . valid?
2017#apricot2017
DNSSEC Interlocking Signatures
.	(root)
.com
.example.com
www.example.com IN	A	192.0.1
.	Key-Signing	Key	– signs	over
.	Zone-Signing	Key	– signs	over
DS	for	.com	(Key-Signing	Key)
.com	Key-Signing	Key	– signs	over
.com	Zone-Signing	Key	– signs	over
DS	for	example	.com	(Key-Signing	Key)
example.com Key-Signing	Key	– signs	over
example.com Zone-Signing	Key	– signs	over
www.example.com
Is the signature for this record valid?
Is the ZSK for example.com valid?
Is the KSK for example.com valid?
Is this DS equal to the hash of the KSK?
Is the signature for this record valid?
Is the ZSK for .com valid?
Is the KSK for .com valid?
Is this DS equal to the hash of the KSK?
Is the signature for this record valid?
Is the ZSK for . valid?
Is the KSK for . valid?
As long as you have a valid
local trust anchor for the
root zone then you can
validate a signed DNS
response by constructing
this backward path to the
local root trust anchor
2017#apricot2017
A DNSSEC response using RSA
$ dig +dnssec u5221730329.s1425859199.i5075.vcf100.5a593.z.dotnxdomain.net
; <<>> DiG 9.9.6-P1 <<>> +dnssec u5221730329.s1425859199.i5075.vcf100.5a593.z.dotnxdomain.net
;; global options: +cmd
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 25461
;; flags: qr rd ra ad; QUERY: 1, ANSWER: 2, AUTHORITY: 4, ADDITIONAL: 1
;; OPT PSEUDOSECTION:
; EDNS: version: 0, flags: do; udp: 4096
;; QUESTION SECTION:
;u5221730329.s1425859199.i5075.vcf100.5a593.z.dotnxdomain.net. IN A
;; ANSWER SECTION:
u5221730329.s1425859199.i5075.vcf100.5a593.z.dotnxdomain.net. 1 IN A 199.102.79.186
u5221730329.s1425859199.i5075.vcf100.5a593.z.dotnxdomain.net. 1 IN RRSIG A 5 4 3600 20200724235900 20130729104013 1968 5a593.z.dotnxdomain.net. ghHPoQd71aZtsdH823eW
;; AUTHORITY SECTION:
33d23a33.3b7acf35.9bd5b553.3ad4aa35.09207c36.a095a7ae.1dc33700.103ad556.3a564678.16395067.a12ec545.6183d935.c68cebfb.41a4008e.4f291b87.479c6f9e.5ea48f86.7d1187f1.7572d59a
33d23a33.3b7acf35.9bd5b553.3ad4aa35.09207c36.a095a7ae.1dc33700.103ad556.3a564678.16395067.a12ec545.6183d935.c68cebfb.41a4008e.4f291b87.479c6f9e.5ea48f86.7d1187f1.7572d59a
5a593.z.dotnxdomain.net. 3599 IN NS nsz1.z.dotnxdomain.net.
5a593.z.dotnxdomain.net. 3600 IN RRSIG NS 5 4 3600 20200724235900 20130729104013 1968 5a593.z.dotnxdomain.net. ntxWo5UwL1vQjOHY0z5DCVNDDScnd3Tglgd0PsBRRhk3B9iJ
;; Query time: 1052 msec
;; SERVER: 127.0.0.1#53(127.0.0.1)
;; WHEN: Thu Mar 12 03:59:57 UTC 2015
;; MSG SIZE rcvd: 937
RSA	signed	response	– 937	octets
2017#apricot2017
$ dig +dnssec DNSKEY org
; <<>> DiG 9.11.0-P1 <<>> +dnssec DNSKEY org
;; global options: +cmd
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 53713
;; flags: qr rd ra; QUERY: 1, ANSWER: 7, AUTHORITY: 0, ADDITIONAL: 1
;; OPT PSEUDOSECTION:
; EDNS: version: 0, flags: do; udp: 4096
;; QUESTION SECTION:
;org. IN DNSKEY
;; ANSWER SECTION:
org. 900 IN DNSKEY 256 3 7 AwEAAXxsMmN/JgpEE9Y4uFNRJm7Q9GBwmEYUCsCxuKlgBU9WrQEFRrvA eMamUBeX4SE
org. 900 IN DNSKEY 256 3 7 AwEAAayiVbuM+ehlsKsuAL1CI3mA+5JM7ti3VeY8ysmogElVMuSLNsX7 HFyq9O6qhZV
org. 900 IN DNSKEY 257 3 7 AwEAAcMnWBKLuvG/LwnPVykcmpvnntwxfshHlHRhlY0F3oz8AMcuF8gw 9McCw+BoC2Y
org. 900 IN DNSKEY 257 3 7 AwEAAZTjbIO5kIpxWUtyXc8avsKyHIIZ+LjC2Dv8naO+Tz6X2fqzDC1b dq7HlZwtkaq
org. 900 IN RRSIG DNSKEY 7 1 900 20170207153219 20170117143219 3947 org. S6+vpFWz6hfPmvI7zxRa4
org. 900 IN RRSIG DNSKEY 7 1 900 20170207153219 20170117143219 9795 org. iEyiroy02ljtH5hf5RIdf
org. 900 IN RRSIG DNSKEY 7 1 900 20170207153219 20170117143219 17883 org. A2hLUswcas+W4h8gZYpA
;; Query time: 475 msec
;; SERVER: 203.133.248.1#53(203.133.248.1)
;; WHEN: Thu Jan 19 23:37:38 UTC 2017
;; MSG SIZE rcvd: 1625
Another DNSSEC response using RSA
RSA	signed	response	– 1,625	octets
2017#apricot2017
Not every application can tolerate
large keys…
The	DNS	and	DNSSEC	is	a	problem	here:
– including	the	digital	signature	increases	the	response	size
– Large	responses	generate	packet	fragmentation
– Fragments	are	commonly	filtered	by	firewalls
– IPv6	Fragments	required	IPv6	Extension	Headers,	and	
packets	with	Extension	Headers	are	commonly	filtered
– DNS	over	TCP	imposes	server	load
– DNS	over	TCP	is	commonly	filtered
If	you	can avoid	large	responses	in	the	DNS,	you	should!
2017#apricot2017
The search for small keys
• Large	keys	and	the	DNS	don’t	mix	very	well:
– We	try	and	make	UDP	fragmentation	work	reliably	(for	once!)
– Or	we	switch	the	DNS	to	use	TCP
– Or	we	look	for	smaller	keys
2017#apricot2017
Enter Elliptic Curves
y2 =	x3 +	ax +	b
2017#apricot2017
y2 =	x3 +	ax +	b
Enter Elliptic Curves
“It	is	not	immediately	obvious	why	
verification	even	functions	correctly.”	!!
2017#apricot2017
ECDSA P-256
Elliptic	Curve	Cryptography	allows	for	the	construction	
of	“strong”	public/private	key	pairs	with	key	lengths	
that	are	far	shorter	than	equivalent	strength	keys	using	
RSA	
A	256-bit	ECC	key	should	provide	comparable	security	
to	a	3072-bit	RSA	key
2017#apricot2017
ECDSA vs RSS
$ dig +dnssec u5221730329.s1425859199.i5075.vcf100.5a593.y.dotnxdomain.net
; <<>> DiG 9.9.6-P1 <<>> +dnssec u5221730329.s1425859199.i5075.vcf100.5a593.y.dotnxdomain.net
;; global options: +cmd
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 61126
;; flags: qr rd ra ad; QUERY: 1, ANSWER: 2, AUTHORITY: 4, ADDITIONAL: 1
;; OPT PSEUDOSECTION:
; EDNS: version: 0, flags: do; udp: 4096
;; QUESTION SECTION:
;u5221730329.s1425859199.i5075.vcf100.5a593.y.dotnxdomain.net. IN A
;; ANSWER SECTION:
u5221730329.s1425859199.i5075.vcf100.5a593.y.dotnxdomain.net. 1 IN A 144.76.167.10
u5221730329.s1425859199.i5075.vcf100.5a593.y.dotnxdomain.net. 1 IN RRSIG A 13 4 3600 20200724235900 20150301105936 35456 5a593.y.dotnxdomain.net. IMXSIJ/uKixSAt8GXsh6Lm8CvEOmK5n/5bPgs
;; AUTHORITY SECTION:
ns1.5a593.y.dotnxdomain.net. 1 IN NSEC x.5a593.y.dotnxdomain.net. A RRSIG NSEC
ns1.5a593.y.dotnxdomain.net. 1 IN RRSIG NSEC 13 5 1 20200724235900 20150301105936 35456 5a593.y.dotnxdomain.net. vM+5YEkAc8B9iYHV3ZO3r9v+RvICn3qfWRfneytLP+nHCOku66X31pzB
5a593.y.dotnxdomain.net. 3598 IN NS ns1.5a593.y.dotnxdomain.net.
5a593.y.dotnxdomain.net. 3600 IN RRSIG NS 13 4 3600 20200724235900 20150301105936 35456 5a593.y.dotnxdomain.net. dzFik3O4HhiEg8TXcn3dCFdCfXCzLj7V0y5qIkCNYXYQ5EfoiWMhUh1s Lb9I0CQk
;; Query time: 1880 msec
;; SERVER: 127.0.0.1#53(127.0.0.1)
;; WHEN: Thu Mar 12 03:59:42 UTC 2015
;; MSG SIZE rcvd: 527
$ dig +dnssec u5221730329.s1425859199.i5075.vcf100.5a593.z.dotnxdomain.net
; <<>> DiG 9.9.6-P1 <<>> +dnssec u5221730329.s1425859199.i5075.vcf100.5a593.z.dotnxdomain.net
;; global options: +cmd
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 25461
;; flags: qr rd ra ad; QUERY: 1, ANSWER: 2, AUTHORITY: 4, ADDITIONAL: 1
;; OPT PSEUDOSECTION:
; EDNS: version: 0, flags: do; udp: 4096
;; QUESTION SECTION:
;u5221730329.s1425859199.i5075.vcf100.5a593.z.dotnxdomain.net. IN A
;; ANSWER SECTION:
u5221730329.s1425859199.i5075.vcf100.5a593.z.dotnxdomain.net. 1 IN A 199.102.79.186
u5221730329.s1425859199.i5075.vcf100.5a593.z.dotnxdomain.net. 1 IN RRSIG A 5 4 3600 2020072423590
;; AUTHORITY SECTION:
33d23a33.3b7acf35.9bd5b553.3ad4aa35.09207c36.a095a7ae.1dc33700.103ad556.3a564678.16395067.a12ec545.6183
33d23a33.3b7acf35.9bd5b553.3ad4aa35.09207c36.a095a7ae.1dc33700.103ad556.3a564678.16395067.a12ec545.6183
5a593.z.dotnxdomain.net. 3599 IN NS nsz1.z.dotnxdomain.net.
5a593.z.dotnxdomain.net. 3600 IN RRSIG NS 5 4 3600 20200724235900 20130729104013 1968 5a593.
;; Query time: 1052 msec
;; SERVER: 127.0.0.1#53(127.0.0.1)
;; WHEN: Thu Mar 12 03:59:57 UTC 2015
;; MSG SIZE rcvd: 937
ECDSA	signed	response	– 527	octets RSA	signed	response	– 937	octets
2017#apricot2017
ECDSA has a history…
2017#apricot2017
ECDSA and OpenSSL
• OpenSSL	added	ECDSA	support	as	from	0.9.8	(2005)	
• Other	bundles	and	specific	builds	added	ECDSA	support	later
• But	deployed	systems	often	lag	behind	the	latest	bundles,	and	
therefore	still	do	not	include	ECC	support	in	their	running	
configuration
2017#apricot2017
Is ECDSA viable?
What	does	NIST	say?
http://nvlpubs.nist.gov/nistpubs/SpecialPublications/NIST.SP.800-57Pt3r1.pdf
2017#apricot2017
Do folk use ECDSA for public keys?
$ dig +dnssec www.cloudflare-dnssec-auth.com
; <<>> DiG 9.9.6-P1 <<>> +dnssec www.cloudflare-dnssec-auth.com
;; global options: +cmd
;; Got answer:
;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 7049
;; flags: qr rd ra ad; QUERY: 1, ANSWER: 6, AUTHORITY: 0, ADDITIONAL: 1
;; OPT PSEUDOSECTION:
; EDNS: version: 0, flags: do; udp: 4096
;; QUESTION SECTION:
;www.cloudflare-dnssec-auth.com. IN A
;; ANSWER SECTION:
www.cloudflare-dnssec-auth.com. 300 IN A 104.20.23.140
www.cloudflare-dnssec-auth.com. 300 IN A 104.20.21.140
www.cloudflare-dnssec-auth.com. 300 IN A 104.20.19.140
www.cloudflare-dnssec-auth.com. 300 IN A 104.20.22.140
www.cloudflare-dnssec-auth.com. 300 IN A 104.20.20.140
www.cloudflare-dnssec-auth.com. 300 IN RRSIG A 13 3 300 20150317021923 20150315001923 35273
cloudflare-dnssec-auth.com. pgBvfQkU4Il8ted2hGL9o8NspvKksDT8/jvQ+4o4h4tGmAX0fDBEoorb
tLiW7mcdOWYLoOnjovzYh3Q0Odu0Xw==
;; Query time: 237 msec
;; SERVER: 127.0.0.1#53(127.0.0.1)
;; WHEN: Mon Mar 16 01:19:24 UTC 2015
;; MSG SIZE rcvd: 261
Algorithm 13 is ECDSA P-256
Signed response is 261 octets long!
2017#apricot2017
So lets use ECDSA for DNSSEC
Or	maybe	we	should	look	before	we	leap...
– Is	ECDSA	a	“well	supported”	crypto	protocol?	*
– If	you	signed	using	ECDSA	would	resolvers	
validate	the	signature?
It’s	not	that	crypto	libraries	deliberately	exclude	ECDSA	support	these	days.	
The	more	likely	issue	appears	to	be	the	operational	practic es of	some	ISPs	
who	use	crufty old	software	sets	to	support	DNS	resolvers	which	are	now	
running	old	libraries	that	predate	the	incorporation	of	ECDSA	into	Open	SSL	
*
2017#apricot2017
Where are the users who can validate
ECDSA-signed DNSSEC records?
https://stats.labs.apnic.net/ecdsa
2017#apricot2017
And where ECDSA support is
missing
https://stats.labs.apnic.net/ecdsa
2017#apricot2017
Today we’re in Vietnam…
2017#apricot2017
Today we’re in Vietnam…
2017#apricot2017
The Top 5 Vietnam ISPs
And	the	extent	to	which	their	uses	perform	DNSSEC	validation	with	ECDSA	and	RSA
2017#apricot2017
And it if wasn’t for Google…
There would probably be no DNSSEC at all!
And no ECDSA!
2017#apricot2017
APNIC Labs Report on ECDSA use
https://stats.labs.apnic.net/ecdsa
2017#apricot2017
Me: gih@apnic.net

More Related Content

PPT
Diffiehellman
PPT
Secure shell ppt
PPTX
Spread spectrum
PDF
ECDSA/EdDSA
PDF
18CS2005 Cryptography and Network Security
PPTX
Digital signature(Cryptography)
PPTX
Internet Key Exchange Protocol
PDF
Introduction to Cryptography
Diffiehellman
Secure shell ppt
Spread spectrum
ECDSA/EdDSA
18CS2005 Cryptography and Network Security
Digital signature(Cryptography)
Internet Key Exchange Protocol
Introduction to Cryptography

What's hot (20)

PPTX
IP Sec - Basic Concepts
PPT
Authentication Protocols
PPTX
Cryptography - Block cipher & stream cipher
PPT
Elgamal Digital Signature
PDF
CRYPTOGRAPHY AND NETWORK SECURITY
PPT
CONVENTIONAL ENCRYPTION
PPT
Digital Signature Standard
PPT
Diffie-hellman algorithm
PDF
The CAP Theorem
DOCX
Symmetric ciphers questions and answers
PPTX
Secure Hash Algorithm
PPTX
Secure Shell(ssh)
PPTX
Hash Function
PPTX
Principles of public key cryptography and its Uses
PPTX
Elgamal digital signature
PDF
Block Ciphers and the Data Encryption Standard
PPTX
Carrier Sense Multiple Access With Collision Detection (CSMA/CD) Details : Me...
PPT
Hash Function & Analysis
PPTX
Public Key Distribution
IP Sec - Basic Concepts
Authentication Protocols
Cryptography - Block cipher & stream cipher
Elgamal Digital Signature
CRYPTOGRAPHY AND NETWORK SECURITY
CONVENTIONAL ENCRYPTION
Digital Signature Standard
Diffie-hellman algorithm
The CAP Theorem
Symmetric ciphers questions and answers
Secure Hash Algorithm
Secure Shell(ssh)
Hash Function
Principles of public key cryptography and its Uses
Elgamal digital signature
Block Ciphers and the Data Encryption Standard
Carrier Sense Multiple Access With Collision Detection (CSMA/CD) Details : Me...
Hash Function & Analysis
Public Key Distribution
Ad

Viewers also liked (20)

PDF
RSA ALGORITHM
PPT
Public Key Cryptography and RSA algorithm
PPT
RSA and RAD 8.5 Top New Value Features
PPT
2013 Good Design is Good Business mobile and RSA
PPT
Nazira Omuralieva - Susan Kaufman - Improving Application Security - Vulnerab...
PDF
Controller encryption using RSA public-key encryption scheme (Asian Control C...
PDF
RSA 2015 Blending the Automated and the Manual: Making Application Vulnerabil...
PPT
Chapter 09
PDF
Pluggable Authentication Module
PPT
Lecture 3b public key_encryption
PDF
Running a Local Copy of the DNS Root Zone
PDF
Kona Web Application Firewall Overview - Akamai at RSA Conference 2013
PDF
Introduction to Bitcoin and ECDSA
PDF
Authentication Modules For Linux - PAM Architecture
PDF
Ch12 Encryption
PDF
Using ~300 Billion DNS Queries to Analyse the TLD Name Collision Problem
PPT
Digital signature
PDF
TLD Anycast DNS servers to ISPs
PPT
PUBLIC KEY ENCRYPTION
RSA ALGORITHM
Public Key Cryptography and RSA algorithm
RSA and RAD 8.5 Top New Value Features
2013 Good Design is Good Business mobile and RSA
Nazira Omuralieva - Susan Kaufman - Improving Application Security - Vulnerab...
Controller encryption using RSA public-key encryption scheme (Asian Control C...
RSA 2015 Blending the Automated and the Manual: Making Application Vulnerabil...
Chapter 09
Pluggable Authentication Module
Lecture 3b public key_encryption
Running a Local Copy of the DNS Root Zone
Kona Web Application Firewall Overview - Akamai at RSA Conference 2013
Introduction to Bitcoin and ECDSA
Authentication Modules For Linux - PAM Architecture
Ch12 Encryption
Using ~300 Billion DNS Queries to Analyse the TLD Name Collision Problem
Digital signature
TLD Anycast DNS servers to ISPs
PUBLIC KEY ENCRYPTION
Ad

Similar to Cryptography - RSA and ECDSA (20)

PDF
Why DANE?
PDF
DNSSEC Validation Tutorial
PDF
National Public Key Infrastructure: Friend or Foe?
PDF
B.Noviansyah - National Public Key Infrastructure: Friend or Foe?
PPTX
Certificates, PKI, and SSL/TLS for infrastructure builders and operators
PPT
المحاضرة_التاسعة_المفتاح العام هيكلية_PKI.ppt
PPT
enkripsi and authentication
PPT
Jerad Bates - Public Key Infrastructure.ppt
PPT
Jerad Bates - Public Key Infrastructure.ppt
PPT
Jerad Bates - Public Key Infrastructure (1).ppt
PPT
29th_Nov-Public_Key_Infrastructure-tell_me_in_plain_English_AND_THEN_deep_tec...
PDF
Rolling the Root Zone DNSSEC Key Signing Key
PDF
Trust - Digital Signature
PDF
computer-security-and-cryptography-a-simple-presentation
PPTX
PACE-IT, Security+ 6.3: Introduction to Public Key Infrastructure (part 1)
PDF
Hardening the Core of the Internet
PDF
Lecture13certaficate.pdf
PDF
SSL/TLS for Mortals (Voxxed Days Luxembourg)
PPT
Crypto Analysis slides presentation slides
Why DANE?
DNSSEC Validation Tutorial
National Public Key Infrastructure: Friend or Foe?
B.Noviansyah - National Public Key Infrastructure: Friend or Foe?
Certificates, PKI, and SSL/TLS for infrastructure builders and operators
المحاضرة_التاسعة_المفتاح العام هيكلية_PKI.ppt
enkripsi and authentication
Jerad Bates - Public Key Infrastructure.ppt
Jerad Bates - Public Key Infrastructure.ppt
Jerad Bates - Public Key Infrastructure (1).ppt
29th_Nov-Public_Key_Infrastructure-tell_me_in_plain_English_AND_THEN_deep_tec...
Rolling the Root Zone DNSSEC Key Signing Key
Trust - Digital Signature
computer-security-and-cryptography-a-simple-presentation
PACE-IT, Security+ 6.3: Introduction to Public Key Infrastructure (part 1)
Hardening the Core of the Internet
Lecture13certaficate.pdf
SSL/TLS for Mortals (Voxxed Days Luxembourg)
Crypto Analysis slides presentation slides

More from APNIC (20)

PPTX
APNIC Report, presented at APAN 60 by Thy Boskovic
PDF
APNIC Update, presented at PHNOG 2025 by Shane Hermoso
PDF
RPKI Status Update, presented by Makito Lay at IDNOG 10
PDF
The Internet -By the Numbers, Sri Lanka Edition
PDF
Triggering QUIC, presented by Geoff Huston at IETF 123
PDF
DNSSEC Made Easy, presented at PHNOG 2025
PDF
BGP Security Best Practices that Matter, presented at PHNOG 2025
PDF
APNIC's Role in the Pacific Islands, presented at Pacific IGF 2205
PDF
IPv6 Deployment and Best Practices, presented by Makito Lay
PDF
Cleaning up your RPKI invalids, presented at PacNOG 35
PDF
The Internet - By the numbers, presented at npNOG 11
PDF
Transmission Control Protocol (TCP) and Starlink
PDF
DDoS in India, presented at INNOG 8 by Dave Phelan
PDF
Global Networking Trends, presented at the India ISP Conclave 2025
PDF
Make DDoS expensive for the threat actors
PDF
Fast Reroute in SR-MPLS, presented at bdNOG 19
PDF
DDos Mitigation Strategie, presented at bdNOG 19
PDF
ICP -2 Review – What It Is, and How to Participate and Provide Your Feedback
PDF
APNIC Update - Global Synergy among the RIRs: Connecting the Regions
PDF
Measuring Starlink Protocol Performance, presented at LACNIC 43
APNIC Report, presented at APAN 60 by Thy Boskovic
APNIC Update, presented at PHNOG 2025 by Shane Hermoso
RPKI Status Update, presented by Makito Lay at IDNOG 10
The Internet -By the Numbers, Sri Lanka Edition
Triggering QUIC, presented by Geoff Huston at IETF 123
DNSSEC Made Easy, presented at PHNOG 2025
BGP Security Best Practices that Matter, presented at PHNOG 2025
APNIC's Role in the Pacific Islands, presented at Pacific IGF 2205
IPv6 Deployment and Best Practices, presented by Makito Lay
Cleaning up your RPKI invalids, presented at PacNOG 35
The Internet - By the numbers, presented at npNOG 11
Transmission Control Protocol (TCP) and Starlink
DDoS in India, presented at INNOG 8 by Dave Phelan
Global Networking Trends, presented at the India ISP Conclave 2025
Make DDoS expensive for the threat actors
Fast Reroute in SR-MPLS, presented at bdNOG 19
DDos Mitigation Strategie, presented at bdNOG 19
ICP -2 Review – What It Is, and How to Participate and Provide Your Feedback
APNIC Update - Global Synergy among the RIRs: Connecting the Regions
Measuring Starlink Protocol Performance, presented at LACNIC 43

Recently uploaded (20)

PPTX
artificial intelligence overview of it and more
DOCX
Unit-3 cyber security network security of internet system
PPTX
international classification of diseases ICD-10 review PPT.pptx
PPTX
Digital Literacy And Online Safety on internet
PPTX
522797556-Unit-2-Temperature-measurement-1-1.pptx
PDF
SASE Traffic Flow - ZTNA Connector-1.pdf
PPT
isotopes_sddsadsaadasdasdasdasdsa1213.ppt
PPTX
Module 1 - Cyber Law and Ethics 101.pptx
PDF
WebRTC in SignalWire - troubleshooting media negotiation
PPTX
Power Point - Lesson 3_2.pptx grad school presentation
PPTX
Mathew Digital SEO Checklist Guidlines 2025
PPT
Ethics in Information System - Management Information System
PDF
Tenda Login Guide: Access Your Router in 5 Easy Steps
PDF
Decoding a Decade: 10 Years of Applied CTI Discipline
PDF
The New Creative Director: How AI Tools for Social Media Content Creation Are...
PPT
tcp ip networks nd ip layering assotred slides
PDF
Introduction to the IoT system, how the IoT system works
PDF
Best Practices for Testing and Debugging Shopify Third-Party API Integrations...
PDF
Automated vs Manual WooCommerce to Shopify Migration_ Pros & Cons.pdf
PPTX
Introduction about ICD -10 and ICD11 on 5.8.25.pptx
artificial intelligence overview of it and more
Unit-3 cyber security network security of internet system
international classification of diseases ICD-10 review PPT.pptx
Digital Literacy And Online Safety on internet
522797556-Unit-2-Temperature-measurement-1-1.pptx
SASE Traffic Flow - ZTNA Connector-1.pdf
isotopes_sddsadsaadasdasdasdasdsa1213.ppt
Module 1 - Cyber Law and Ethics 101.pptx
WebRTC in SignalWire - troubleshooting media negotiation
Power Point - Lesson 3_2.pptx grad school presentation
Mathew Digital SEO Checklist Guidlines 2025
Ethics in Information System - Management Information System
Tenda Login Guide: Access Your Router in 5 Easy Steps
Decoding a Decade: 10 Years of Applied CTI Discipline
The New Creative Director: How AI Tools for Social Media Content Creation Are...
tcp ip networks nd ip layering assotred slides
Introduction to the IoT system, how the IoT system works
Best Practices for Testing and Debugging Shopify Third-Party API Integrations...
Automated vs Manual WooCommerce to Shopify Migration_ Pros & Cons.pdf
Introduction about ICD -10 and ICD11 on 5.8.25.pptx

Cryptography - RSA and ECDSA

  • 3. 2017#apricot2017 Why use Cryptography? Public key cryptography can be used in a number of ways: – protecting a session from third party eavesdroppers Encryption using a session key that is known only to the parties to the conversation – protecting a session from interference Injection (or removal) of part of a session can only be undertaken by the parties to the session – authentication and non-repudiation What is received is exactly what the other party sent, and cannot be repudiated
  • 4. 2017#apricot2017 Symmetric Crypto A symmetric crypto algorithm uses the same key to – Convert a plaintext message to a crypted message – Convert a crypted message to its plaintext message • They are generally fast and simple BUT they use a shared key – This key distribution problem can be a critical weakness in the crypto framework
  • 6. 2017#apricot2017 The Asymmetric Crypto Challenge Devise an algorithm (encoding) and keys such that: – Messages encoded with one key can only be decoded with the other key – Knowledge of the value of one key does not infer the value of the other key http://bit.ly/2iQ0oi7
  • 8. 2017#apricot2017 Why does RSA work? Encryption using the public key consists of taking a message x and raising it to the power e Crypt = xe Decryption consists of taking an encrypted message and raising it to the power d, mod n Decrypt = Cryptd mod n = (xe)d mod n = xed mod n = x Similarly, one can encrypt a message with the private key (xd ) and decrypt with the public key ((xd ) e mod n = x)
  • 9. 2017#apricot2017 Why does RSA work? If you know e and n (the public key) then how can you calculate d (the private key)? Now d.e = 1 mod ⏀(n) If you know ⏀(n) you can calculate d But ⏀(n) = (p-1).(q-1), where p.q = n i.e. you need to find the prime factors of n, a large composite number that is the product of two primes
  • 10. 2017#apricot2017 The ‘core’ of RSA (xe)d ≡ x mod n As long as d and n are relatively large, and n is the product of two large prime numbers, then finding the value of d when you already know the values of e and n is computationally expensive
  • 11. 2017#apricot2017 The ‘core’ of RSA (xe)d ≡ x mod n As long as d and n are relatively large, and n is the product of two large prime numbers, then finding the value of d when you already know the values of e and n is computationally expensive
  • 12. 2017#apricot2017 The ‘core’ of RSA (xe)d ≡ x mod n As long as d and n are relatively large, and n is the product of two large prime numbers, then finding the value of d when you already know the values of e and n is computationally expensive
  • 13. 2017#apricot2017 Why is this important? Because much of the foundation of Internet Security rests upon this relationship
  • 14. 2017#apricot2017 How big can RSA go? In theory we can push this to very large sizes of n to generate RSA private keys The algorithm is not itself arbitrarily limited in terms of key size But as the numbers get larger there is higher computation overhead to generate and manipulate these keys So we want it large enough not to be ‘broken’ by most forms of brute force, but small enough to be computed by our everyday processors
  • 15. 2017#apricot2017 How big should RSA go? You need to consider time as well How long do you want or need your secret to remain a secret? Because if the attacker has enough time a brute force attack may work Also time is on the attacker’s side: keys that are considered robust today may not be as robust tomorrow, assuming that feasible compute capabilities rise over time So you want to pick a key size that is resistant to attempts to brute force the key both today and tomorrow
  • 16. 2017#apricot2017 Bigger and bigger? Well, no – the larger the key sizes compared to compute capabilities means: – Longer times to generate keys – Longer times to encrypt (and decrypt) messages – More space to represent the key values So you need to use big keys, but no bigger then necessary!
  • 20. 2017#apricot2017 TLS: Protecting the session https://rhsecurity.wordpress.com/tag/tls/
  • 21. 2017#apricot2017 The Key to My Bank Yes, the fine print says my bank is using a 2048-bit RSA Public key to as the foundation of the session key used to secure access to my bank
  • 22. 2017#apricot2017 I trust its my bank because … • The server has demonstrated knowledge of a private key that is associated with a public key that I have been provided • The public key has been associated with a particular domain name by a Certificate Authority • My browser trusts that this Certificate Authority never lies about such associations • So if the server can demonstrate that it has the private key then my browser will believe that its my bank!
  • 23. 2017#apricot2017 DNSSEC and the DNS Another major application for crypto in the Internet is securing the DNS You want to be assured that the response you get to from DNS query is: – Authentic – Complete – Current
  • 24. 2017#apricot2017 DNSSEC Interlocking Signatures . (root) .com .example.com www.example.com . Key-Signing Key – signs over . Zone-Signing Key – signs over DS for .com (Key-Signing Key) .com Key-Signing Key – signs over .com Zone-Signing Key – signs over DS for example .com (Key-Signing Key) example.com Key-Signing Key – signs over example.com Zone-Signing Key – signs over www.example.com
  • 25. 2017#apricot2017 DNSSEC Interlocking Signatures . (root) .com .example.com www.example.com IN A 192.0.1 . Key-Signing Key – signs over . Zone-Signing Key – signs over DS for .com (Key-Signing Key) .com Key-Signing Key – signs over .com Zone-Signing Key – signs over DS for example .com (Key-Signing Key) example.com Key-Signing Key – signs over example.com Zone-Signing Key – signs over www.example.com
  • 26. 2017#apricot2017 DNSSEC Interlocking Signatures . (root) .com .example.com www.example.com IN A 192.0.1 . Key-Signing Key – signs over . Zone-Signing Key – signs over DS for .com (Key-Signing Key) .com Key-Signing Key – signs over .com Zone-Signing Key – signs over DS for example .com (Key-Signing Key) example.com Key-Signing Key – signs over example.com Zone-Signing Key – signs over www.example.com Is the signature for this record valid? Is the ZSK for example.com valid? Is the KSK for example.com valid? Is this DS equal to the hash of the KSK? Is the signature for this record valid? Is the ZSK for .com valid? Is the KSK for .com valid? Is this DS equal to the hash of the KSK? Is the signature for this record valid? Is the ZSK for . valid? Is the KSK for . valid?
  • 27. 2017#apricot2017 DNSSEC Interlocking Signatures . (root) .com .example.com www.example.com IN A 192.0.1 . Key-Signing Key – signs over . Zone-Signing Key – signs over DS for .com (Key-Signing Key) .com Key-Signing Key – signs over .com Zone-Signing Key – signs over DS for example .com (Key-Signing Key) example.com Key-Signing Key – signs over example.com Zone-Signing Key – signs over www.example.com Is the signature for this record valid? Is the ZSK for example.com valid? Is the KSK for example.com valid? Is this DS equal to the hash of the KSK? Is the signature for this record valid? Is the ZSK for .com valid? Is the KSK for .com valid? Is this DS equal to the hash of the KSK? Is the signature for this record valid? Is the ZSK for . valid? Is the KSK for . valid? As long as you have a valid local trust anchor for the root zone then you can validate a signed DNS response by constructing this backward path to the local root trust anchor
  • 28. 2017#apricot2017 A DNSSEC response using RSA $ dig +dnssec u5221730329.s1425859199.i5075.vcf100.5a593.z.dotnxdomain.net ; <<>> DiG 9.9.6-P1 <<>> +dnssec u5221730329.s1425859199.i5075.vcf100.5a593.z.dotnxdomain.net ;; global options: +cmd ;; Got answer: ;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 25461 ;; flags: qr rd ra ad; QUERY: 1, ANSWER: 2, AUTHORITY: 4, ADDITIONAL: 1 ;; OPT PSEUDOSECTION: ; EDNS: version: 0, flags: do; udp: 4096 ;; QUESTION SECTION: ;u5221730329.s1425859199.i5075.vcf100.5a593.z.dotnxdomain.net. IN A ;; ANSWER SECTION: u5221730329.s1425859199.i5075.vcf100.5a593.z.dotnxdomain.net. 1 IN A 199.102.79.186 u5221730329.s1425859199.i5075.vcf100.5a593.z.dotnxdomain.net. 1 IN RRSIG A 5 4 3600 20200724235900 20130729104013 1968 5a593.z.dotnxdomain.net. ghHPoQd71aZtsdH823eW ;; AUTHORITY SECTION: 33d23a33.3b7acf35.9bd5b553.3ad4aa35.09207c36.a095a7ae.1dc33700.103ad556.3a564678.16395067.a12ec545.6183d935.c68cebfb.41a4008e.4f291b87.479c6f9e.5ea48f86.7d1187f1.7572d59a 33d23a33.3b7acf35.9bd5b553.3ad4aa35.09207c36.a095a7ae.1dc33700.103ad556.3a564678.16395067.a12ec545.6183d935.c68cebfb.41a4008e.4f291b87.479c6f9e.5ea48f86.7d1187f1.7572d59a 5a593.z.dotnxdomain.net. 3599 IN NS nsz1.z.dotnxdomain.net. 5a593.z.dotnxdomain.net. 3600 IN RRSIG NS 5 4 3600 20200724235900 20130729104013 1968 5a593.z.dotnxdomain.net. ntxWo5UwL1vQjOHY0z5DCVNDDScnd3Tglgd0PsBRRhk3B9iJ ;; Query time: 1052 msec ;; SERVER: 127.0.0.1#53(127.0.0.1) ;; WHEN: Thu Mar 12 03:59:57 UTC 2015 ;; MSG SIZE rcvd: 937 RSA signed response – 937 octets
  • 29. 2017#apricot2017 $ dig +dnssec DNSKEY org ; <<>> DiG 9.11.0-P1 <<>> +dnssec DNSKEY org ;; global options: +cmd ;; Got answer: ;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 53713 ;; flags: qr rd ra; QUERY: 1, ANSWER: 7, AUTHORITY: 0, ADDITIONAL: 1 ;; OPT PSEUDOSECTION: ; EDNS: version: 0, flags: do; udp: 4096 ;; QUESTION SECTION: ;org. IN DNSKEY ;; ANSWER SECTION: org. 900 IN DNSKEY 256 3 7 AwEAAXxsMmN/JgpEE9Y4uFNRJm7Q9GBwmEYUCsCxuKlgBU9WrQEFRrvA eMamUBeX4SE org. 900 IN DNSKEY 256 3 7 AwEAAayiVbuM+ehlsKsuAL1CI3mA+5JM7ti3VeY8ysmogElVMuSLNsX7 HFyq9O6qhZV org. 900 IN DNSKEY 257 3 7 AwEAAcMnWBKLuvG/LwnPVykcmpvnntwxfshHlHRhlY0F3oz8AMcuF8gw 9McCw+BoC2Y org. 900 IN DNSKEY 257 3 7 AwEAAZTjbIO5kIpxWUtyXc8avsKyHIIZ+LjC2Dv8naO+Tz6X2fqzDC1b dq7HlZwtkaq org. 900 IN RRSIG DNSKEY 7 1 900 20170207153219 20170117143219 3947 org. S6+vpFWz6hfPmvI7zxRa4 org. 900 IN RRSIG DNSKEY 7 1 900 20170207153219 20170117143219 9795 org. iEyiroy02ljtH5hf5RIdf org. 900 IN RRSIG DNSKEY 7 1 900 20170207153219 20170117143219 17883 org. A2hLUswcas+W4h8gZYpA ;; Query time: 475 msec ;; SERVER: 203.133.248.1#53(203.133.248.1) ;; WHEN: Thu Jan 19 23:37:38 UTC 2017 ;; MSG SIZE rcvd: 1625 Another DNSSEC response using RSA RSA signed response – 1,625 octets
  • 30. 2017#apricot2017 Not every application can tolerate large keys… The DNS and DNSSEC is a problem here: – including the digital signature increases the response size – Large responses generate packet fragmentation – Fragments are commonly filtered by firewalls – IPv6 Fragments required IPv6 Extension Headers, and packets with Extension Headers are commonly filtered – DNS over TCP imposes server load – DNS over TCP is commonly filtered If you can avoid large responses in the DNS, you should!
  • 31. 2017#apricot2017 The search for small keys • Large keys and the DNS don’t mix very well: – We try and make UDP fragmentation work reliably (for once!) – Or we switch the DNS to use TCP – Or we look for smaller keys
  • 33. 2017#apricot2017 y2 = x3 + ax + b Enter Elliptic Curves “It is not immediately obvious why verification even functions correctly.” !!
  • 35. 2017#apricot2017 ECDSA vs RSS $ dig +dnssec u5221730329.s1425859199.i5075.vcf100.5a593.y.dotnxdomain.net ; <<>> DiG 9.9.6-P1 <<>> +dnssec u5221730329.s1425859199.i5075.vcf100.5a593.y.dotnxdomain.net ;; global options: +cmd ;; Got answer: ;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 61126 ;; flags: qr rd ra ad; QUERY: 1, ANSWER: 2, AUTHORITY: 4, ADDITIONAL: 1 ;; OPT PSEUDOSECTION: ; EDNS: version: 0, flags: do; udp: 4096 ;; QUESTION SECTION: ;u5221730329.s1425859199.i5075.vcf100.5a593.y.dotnxdomain.net. IN A ;; ANSWER SECTION: u5221730329.s1425859199.i5075.vcf100.5a593.y.dotnxdomain.net. 1 IN A 144.76.167.10 u5221730329.s1425859199.i5075.vcf100.5a593.y.dotnxdomain.net. 1 IN RRSIG A 13 4 3600 20200724235900 20150301105936 35456 5a593.y.dotnxdomain.net. IMXSIJ/uKixSAt8GXsh6Lm8CvEOmK5n/5bPgs ;; AUTHORITY SECTION: ns1.5a593.y.dotnxdomain.net. 1 IN NSEC x.5a593.y.dotnxdomain.net. A RRSIG NSEC ns1.5a593.y.dotnxdomain.net. 1 IN RRSIG NSEC 13 5 1 20200724235900 20150301105936 35456 5a593.y.dotnxdomain.net. vM+5YEkAc8B9iYHV3ZO3r9v+RvICn3qfWRfneytLP+nHCOku66X31pzB 5a593.y.dotnxdomain.net. 3598 IN NS ns1.5a593.y.dotnxdomain.net. 5a593.y.dotnxdomain.net. 3600 IN RRSIG NS 13 4 3600 20200724235900 20150301105936 35456 5a593.y.dotnxdomain.net. dzFik3O4HhiEg8TXcn3dCFdCfXCzLj7V0y5qIkCNYXYQ5EfoiWMhUh1s Lb9I0CQk ;; Query time: 1880 msec ;; SERVER: 127.0.0.1#53(127.0.0.1) ;; WHEN: Thu Mar 12 03:59:42 UTC 2015 ;; MSG SIZE rcvd: 527 $ dig +dnssec u5221730329.s1425859199.i5075.vcf100.5a593.z.dotnxdomain.net ; <<>> DiG 9.9.6-P1 <<>> +dnssec u5221730329.s1425859199.i5075.vcf100.5a593.z.dotnxdomain.net ;; global options: +cmd ;; Got answer: ;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 25461 ;; flags: qr rd ra ad; QUERY: 1, ANSWER: 2, AUTHORITY: 4, ADDITIONAL: 1 ;; OPT PSEUDOSECTION: ; EDNS: version: 0, flags: do; udp: 4096 ;; QUESTION SECTION: ;u5221730329.s1425859199.i5075.vcf100.5a593.z.dotnxdomain.net. IN A ;; ANSWER SECTION: u5221730329.s1425859199.i5075.vcf100.5a593.z.dotnxdomain.net. 1 IN A 199.102.79.186 u5221730329.s1425859199.i5075.vcf100.5a593.z.dotnxdomain.net. 1 IN RRSIG A 5 4 3600 2020072423590 ;; AUTHORITY SECTION: 33d23a33.3b7acf35.9bd5b553.3ad4aa35.09207c36.a095a7ae.1dc33700.103ad556.3a564678.16395067.a12ec545.6183 33d23a33.3b7acf35.9bd5b553.3ad4aa35.09207c36.a095a7ae.1dc33700.103ad556.3a564678.16395067.a12ec545.6183 5a593.z.dotnxdomain.net. 3599 IN NS nsz1.z.dotnxdomain.net. 5a593.z.dotnxdomain.net. 3600 IN RRSIG NS 5 4 3600 20200724235900 20130729104013 1968 5a593. ;; Query time: 1052 msec ;; SERVER: 127.0.0.1#53(127.0.0.1) ;; WHEN: Thu Mar 12 03:59:57 UTC 2015 ;; MSG SIZE rcvd: 937 ECDSA signed response – 527 octets RSA signed response – 937 octets
  • 37. 2017#apricot2017 ECDSA and OpenSSL • OpenSSL added ECDSA support as from 0.9.8 (2005) • Other bundles and specific builds added ECDSA support later • But deployed systems often lag behind the latest bundles, and therefore still do not include ECC support in their running configuration
  • 39. 2017#apricot2017 Do folk use ECDSA for public keys? $ dig +dnssec www.cloudflare-dnssec-auth.com ; <<>> DiG 9.9.6-P1 <<>> +dnssec www.cloudflare-dnssec-auth.com ;; global options: +cmd ;; Got answer: ;; ->>HEADER<<- opcode: QUERY, status: NOERROR, id: 7049 ;; flags: qr rd ra ad; QUERY: 1, ANSWER: 6, AUTHORITY: 0, ADDITIONAL: 1 ;; OPT PSEUDOSECTION: ; EDNS: version: 0, flags: do; udp: 4096 ;; QUESTION SECTION: ;www.cloudflare-dnssec-auth.com. IN A ;; ANSWER SECTION: www.cloudflare-dnssec-auth.com. 300 IN A 104.20.23.140 www.cloudflare-dnssec-auth.com. 300 IN A 104.20.21.140 www.cloudflare-dnssec-auth.com. 300 IN A 104.20.19.140 www.cloudflare-dnssec-auth.com. 300 IN A 104.20.22.140 www.cloudflare-dnssec-auth.com. 300 IN A 104.20.20.140 www.cloudflare-dnssec-auth.com. 300 IN RRSIG A 13 3 300 20150317021923 20150315001923 35273 cloudflare-dnssec-auth.com. pgBvfQkU4Il8ted2hGL9o8NspvKksDT8/jvQ+4o4h4tGmAX0fDBEoorb tLiW7mcdOWYLoOnjovzYh3Q0Odu0Xw== ;; Query time: 237 msec ;; SERVER: 127.0.0.1#53(127.0.0.1) ;; WHEN: Mon Mar 16 01:19:24 UTC 2015 ;; MSG SIZE rcvd: 261 Algorithm 13 is ECDSA P-256 Signed response is 261 octets long!
  • 40. 2017#apricot2017 So lets use ECDSA for DNSSEC Or maybe we should look before we leap... – Is ECDSA a “well supported” crypto protocol? * – If you signed using ECDSA would resolvers validate the signature? It’s not that crypto libraries deliberately exclude ECDSA support these days. The more likely issue appears to be the operational practic es of some ISPs who use crufty old software sets to support DNS resolvers which are now running old libraries that predate the incorporation of ECDSA into Open SSL *
  • 41. 2017#apricot2017 Where are the users who can validate ECDSA-signed DNSSEC records? https://stats.labs.apnic.net/ecdsa
  • 42. 2017#apricot2017 And where ECDSA support is missing https://stats.labs.apnic.net/ecdsa
  • 45. 2017#apricot2017 The Top 5 Vietnam ISPs And the extent to which their uses perform DNSSEC validation with ECDSA and RSA
  • 46. 2017#apricot2017 And it if wasn’t for Google… There would probably be no DNSSEC at all! And no ECDSA!
  • 47. 2017#apricot2017 APNIC Labs Report on ECDSA use https://stats.labs.apnic.net/ecdsa