# Kconfig - CoAP implementation for Zephyr

#
# Copyright (c) 2017 Intel Corporation
#
# SPDX-License-Identifier: Apache-2.0
#

config COAP
	bool
	prompt "CoAP Support"
	default n
	help
	  This option enables the CoAP implementation.

# This setting is only used by unit test. Do not enable it in applications
config COAP_TEST_API_ENABLE
	bool "Enable test API for CoAP unit tests"
	default n
	depends on COAP
	help
	  Do not enable this for normal use.

config COAP_WELL_KNOWN_BLOCK_WISE
	bool
	prompt "CoAP ./well-known/core services block wise support"
	default n
	depends on COAP
	help
	  This option enables the block wise support of CoAP response
	  to ./well-known/core request. Without this option all resource's
	  information will be sent in a single IP packet (can be multiple
	  fragments depends on MTU size). This will be useful in mesh kind
	  of networks.

config COAP_WELL_KNOWN_BLOCK_WISE_SIZE
	int
	prompt "CoAP ./well-known/core services block wise support"
	default 32
	depends on COAP_WELL_KNOWN_BLOCK_WISE
	help
	  Maximum size of CoAP block. Valid values are 16, 32, 64, 128,
	  256, 512 and 1024.

config COAP_EXTENDED_OPTIONS_LEN
	bool "Support for CoAP extended options"
	default n
	depends on COAP
	help
	  This option enables the parsing of extended CoAP options length.
	  CoAP extended options length can be 2 byte value, which
	  requires more memory. User can save memory by disabling this.
	  That means only length of maximum 12 bytes are supported by default.
	  Enable this if length field going to bigger that 12.

config COAP_EXTENDED_OPTIONS_LEN_VALUE
	int "CoAP extended options length value"
	default 13
	depends on COAP_EXTENDED_OPTIONS_LEN
	help
	  This option specifies the maximum value of length field when
	  COAP_EXTENDED_OPTIONS_LEN is enabled. Define the value according to
	  user requirement.

config COAP_MBEDTLS_SSL_MAX_CONTENT_LEN
	int "CoAP MBEDTLS maximum content length value"
	default 1500
	range 256 16384
	depends on MBEDTLS
	help
	  This option sets the value of the MBEDTLS_SSL_MAX_CONTENT_LEN option
	  in ext/lib/crypto/mbedtls/configs/config-coap.h  For client/server
	  communication to work these values need to be the same on both sides.

config NET_DEBUG_COAP
	bool "Debug COAP"
	default n
	depends on COAP && NET_LOG
	help
	  Enables CoaP output debug messages
