+OicSecOxm_t selectOTMcb_default(const OicSecOxm_t* otmList, const uint32_t len)
+{
+ OIC_LOG(INFO, TAG, "IN selectOTMcb_default");
+ OicSecOxm_t ret = -1;
+ VERIFY_NON_NULL(TAG, otmList, ERROR);
+ VERIFY_SUCCESS(TAG, (len > 0), ERROR);
+
+ ret = otmList[len-1];
+
+ for (size_t i = 0; i < len; i++)
+ {
+ if (OIC_RANDOM_DEVICE_PIN == otmList[i])
+ {
+ ret = OIC_RANDOM_DEVICE_PIN;
+ break;
+ }
+ }
+
+exit:
+ OIC_LOG(INFO, TAG, "OUT selectOTMcb_default");
+ return ret;
+}
+