+#if defined TIZEN_EXT
+#define NETCONFIG_SERVICE "net.netconfig"
+#define NETCONFIG_WIFI_PATH "/net/netconfig/wifi"
+#define NETCONFIG_WIFI_INTERFACE NETCONFIG_SERVICE ".wifi"
+
+static gchar* send_cryptographic_request(const char *passphrase, const char *method)
+{
+ DBusConnection *connection = NULL;
+ DBusMessage *msg = NULL, *reply = NULL;
+ DBusError error;
+ gchar *result;
+ const char *out_data;
+
+ if (!passphrase || !method) {
+ DBG("Invalid parameter");
+ return NULL;
+ }
+
+ dbus_error_init(&error);
+
+ connection = connman_dbus_get_connection();
+ if (!connection) {
+ DBG("dbus connection does not exist");
+ return NULL;
+ }
+
+ msg = dbus_message_new_method_call(NETCONFIG_SERVICE, NETCONFIG_WIFI_PATH,
+ NETCONFIG_WIFI_INTERFACE, method);
+ if (!msg) {
+ dbus_connection_unref(connection);
+ return NULL;
+ }
+
+ dbus_message_append_args(msg, DBUS_TYPE_STRING, &passphrase,
+ DBUS_TYPE_INVALID);
+
+ reply = dbus_connection_send_with_reply_and_block(connection, msg,
+ DBUS_TIMEOUT_USE_DEFAULT, &error);
+ if (reply == NULL) {
+ if (dbus_error_is_set(&error)) {
+ DBG("%s", error.message);
+ dbus_error_free(&error);
+ } else {
+ DBG("Failed to request cryptographic request");
+ }
+ dbus_connection_unref(connection);
+ dbus_message_unref(msg);
+ return NULL;
+ }
+
+ dbus_message_unref(msg);
+ dbus_connection_unref(connection);
+
+ if (!dbus_message_get_args(reply, NULL,
+ DBUS_TYPE_STRING, &out_data,
+ DBUS_TYPE_INVALID)) {
+ dbus_message_unref(reply);
+ return NULL;
+ }
+
+ result = g_strdup((const gchar *)out_data);
+ dbus_message_unref(reply);
+
+ return result;
+}
+#endif
+