All of lore.kernel.org
 help / color / mirror / Atom feed
* [LTP] LTP: keyctl05: unexpected error adding 'dns_resolver' key: EINVAL
@ 2018-10-08 12:35 Naresh Kamboju
  2018-10-08 13:20 ` Cyril Hrubis
  0 siblings, 1 reply; 3+ messages in thread
From: Naresh Kamboju @ 2018-10-08 12:35 UTC (permalink / raw)
  To: ltp

keyctl05 failed on all device (x86_64, i386, arm / arm64)
started failing from Linux version 4.19.0-rc6-next-20181005
Do you see this failure at your end?

tst_test.c:1015: INFO: Timeout per run is 0h 15m 00s
keyctl05.c:135: INFO: Try to update the 'asymmetric' key...
keyctl05.c:148: PASS: updating 'asymmetric' key expectedly failed with
EOPNOTSUPP
keyctl05.c:119: BROK: unexpected error adding 'dns_resolver' key: EINVAL
tst_test.c:884: BROK: Test 1 haven't reported results!

Full test log,
https://lkft.validation.linaro.org/scheduler/job/452884#L5182

Best regards
Naresh Kamboju

^ permalink raw reply	[flat|nested] 3+ messages in thread

* [LTP] LTP: keyctl05: unexpected error adding 'dns_resolver' key: EINVAL
  2018-10-08 12:35 [LTP] LTP: keyctl05: unexpected error adding 'dns_resolver' key: EINVAL Naresh Kamboju
@ 2018-10-08 13:20 ` Cyril Hrubis
  2018-10-08 13:30   ` Jan Stancek
  0 siblings, 1 reply; 3+ messages in thread
From: Cyril Hrubis @ 2018-10-08 13:20 UTC (permalink / raw)
  To: ltp

Hi!
> tst_test.c:1015: INFO: Timeout per run is 0h 15m 00s
> keyctl05.c:135: INFO: Try to update the 'asymmetric' key...
> keyctl05.c:148: PASS: updating 'asymmetric' key expectedly failed with
> EOPNOTSUPP
> keyctl05.c:119: BROK: unexpected error adding 'dns_resolver' key: EINVAL
> tst_test.c:884: BROK: Test 1 haven't reported results!

Looks like kernel does not know 'dns_resolver' key type and as this type
is registered by the dns_resolver code I suppose that you are missing
some CONFIG_DNS_RESOLVER, if that is the case the test should handle
EINVAL and return with TCONF.

-- 
Cyril Hrubis
chrubis@suse.cz

^ permalink raw reply	[flat|nested] 3+ messages in thread

* [LTP] LTP: keyctl05: unexpected error adding 'dns_resolver' key: EINVAL
  2018-10-08 13:20 ` Cyril Hrubis
@ 2018-10-08 13:30   ` Jan Stancek
  0 siblings, 0 replies; 3+ messages in thread
From: Jan Stancek @ 2018-10-08 13:30 UTC (permalink / raw)
  To: ltp



----- Original Message -----
> Hi!
> > tst_test.c:1015: INFO: Timeout per run is 0h 15m 00s
> > keyctl05.c:135: INFO: Try to update the 'asymmetric' key...
> > keyctl05.c:148: PASS: updating 'asymmetric' key expectedly failed with
> > EOPNOTSUPP
> > keyctl05.c:119: BROK: unexpected error adding 'dns_resolver' key: EINVAL
> > tst_test.c:884: BROK: Test 1 haven't reported results!
> 
> Looks like kernel does not know 'dns_resolver' key type and as this type
> is registered by the dns_resolver code I suppose that you are missing
> some CONFIG_DNS_RESOLVER, if that is the case the test should handle
> EINVAL and return with TCONF.

I'm guessing it's
  https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git/commit/net/dns_resolver?id=bbb4c4323a4d9cb5ca04db904aa3050a7586839a
which added some additional checks.

Test currently uses 2 zeroes:

+        const struct dns_payload_header *bin;
...
+		if (datalen <= sizeof(*bin))
+			return -EINVAL;

+struct dns_payload_header {
+	__u8		zero;		/* Zero byte: marks this as not being text */
+	__u8		content;	/* enum dns_payload_content_type */
+	__u8		version;	/* Encoding version */
+} __packed;

and commit above appears to need 0x00 0x00 0x01 or 0xFF 0x00 to not return EINVAL.

Regards,
Jan

> 
> --
> Cyril Hrubis
> chrubis@suse.cz
> 

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2018-10-08 13:30 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-10-08 12:35 [LTP] LTP: keyctl05: unexpected error adding 'dns_resolver' key: EINVAL Naresh Kamboju
2018-10-08 13:20 ` Cyril Hrubis
2018-10-08 13:30   ` Jan Stancek

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.