tizen 2.3 release tizen_2.3 submit/tizen_2.3/20150202.063407 tizen_2.3_release
authorjk7744.park <jk7744.park@samsung.com>
Sun, 1 Feb 2015 04:49:10 +0000 (13:49 +0900)
committerjk7744.park <jk7744.park@samsung.com>
Sun, 1 Feb 2015 04:49:10 +0000 (13:49 +0900)
28 files changed:
CMakeLists.txt
LICENSE [moved from LICENSE.APLv2 with 100% similarity]
NOTICE [deleted file]
TC/_export_env.sh [deleted file]
TC/_export_target_env.sh [deleted file]
TC/build.sh [deleted file]
TC/clean.sh [deleted file]
TC/config [deleted file]
TC/execute.sh [deleted file]
TC/testcase/Makefile [deleted file]
TC/testcase/tslist [deleted file]
TC/testcase/utc_account [deleted file]
TC/testcase/utc_account.c [deleted file]
TC/tet_scen [deleted file]
TC/tetbuild.cfg [deleted file]
TC/tetclean.cfg [deleted file]
TC/tetexec.cfg [deleted file]
accounts-svc.pc.in
doc/account_manager_doc.h [new file with mode: 0644]
include/account-error.h
include/account-private.h
include/account-types.h
include/account.h
include/account_PG.h
libaccounts-svc.manifest
packaging/libaccounts-svc.spec
src/account.c
src/utc-account.c

index 1b3699c..f2aa542 100755 (executable)
@@ -6,7 +6,7 @@ SET(EXEC_PREFIX "\${prefix}")
 SET(LIBDIR "\${prefix}/lib")
 SET(INCLUDEDIR "\${prefix}/include ")
 SET(VERSION_MAJOR 0)
-SET(VERSION "${VERSION_MAJOR}.2.66")
+SET(VERSION "${VERSION_MAJOR}.2.97")
 
 SET(SRCS
 src/account.c
@@ -15,22 +15,12 @@ src/account.c
 INCLUDE_DIRECTORIES(${CMAKE_SOURCE_DIR}/include)
 
 INCLUDE(FindPkgConfig)
-pkg_check_modules(pkgs REQUIRED sqlite3 dlog db-util glib-2.0 capi-base-common vconf pkgmgr-info aul)
+pkg_check_modules(pkgs REQUIRED sqlite3 dlog db-util glib-2.0 capi-base-common vconf pkgmgr-info aul libsmack)
 
 FOREACH(flag ${pkgs_CFLAGS})
        SET(EXTRA_CFLAGS "${EXTRA_CFLAGS} ${flag}")
 ENDFOREACH(flag)
 
-FIND_PROGRAM(UNAME NAMES uname)
-EXEC_PROGRAM("${UNAME}" ARGS "-m" OUTPUT_VARIABLE "ARCH")
-IF ("${ARCH}" STREQUAL "arm")
-        ADD_DEFINITIONS("-DTARGET_ARM")
-        MESSAGE("[TARGET] Compile")
-ELSE  ("${ARCH}" STREQUAL "arm")
-        ADD_DEFINITIONS("-DTARGET_I386")
-        MESSAGE("[i386] Compile")
-ENDIF ("${ARCH}" STREQUAL "arm")
-
 SET(CMAKE_C_FLAGS "${CMAKE_C_FLAGS} ${EXTRA_CFLAGS} -Wall")
 SET(CMAKE_LDFLAGS "-Wl,-zdefs")
 
similarity index 100%
rename from LICENSE.APLv2
rename to LICENSE
diff --git a/NOTICE b/NOTICE
deleted file mode 100755 (executable)
index ac46488..0000000
--- a/NOTICE
+++ /dev/null
@@ -1,3 +0,0 @@
-Copyright (c) Samsung Electronics Co., Ltd. All rights reserved.
-Except as noted, this software is licensed under Apache License, Version 2.
-Please, see the LICENSE.APLv2 file for Apache License, Version 2 terms and conditions.
diff --git a/TC/_export_env.sh b/TC/_export_env.sh
deleted file mode 100755 (executable)
index 72a11ec..0000000
+++ /dev/null
@@ -1,8 +0,0 @@
-#!/bin/sh
-
-. ./config
-export TET_INSTALL_PATH=$TET_INSTALL_HOST_PATH # tetware root path
-export TET_TARGET_PATH=$TET_INSTALL_PATH/tetware-target # tetware target path
-export PATH=$TET_TARGET_PATH/bin:$PATH
-export LD_LIBRARY_PATH=$TET_TARGET_PATH/lib/tet3:$LD_LIBRARY_PATH
-export TET_ROOT=$TET_TARGET_PATH
diff --git a/TC/_export_target_env.sh b/TC/_export_target_env.sh
deleted file mode 100755 (executable)
index 5ddaa53..0000000
+++ /dev/null
@@ -1,7 +0,0 @@
-#!/bin/sh
-. ./config
-export TET_INSTALL_PATH=$TET_INSTALL_TARGET_PATH # path to path
-export TET_TARGET_PATH=$TET_INSTALL_PATH/tetware-target
-export PATH=$TET_TARGET_PATH/bin:$PATH
-export LD_LIBRARY_PATH=$TET_TARGET_PATH/lib/tet3:$LD_LIBRARY_PATH
-export TET_ROOT=$TET_TARGET_PATH
diff --git a/TC/build.sh b/TC/build.sh
deleted file mode 100755 (executable)
index 72aad6c..0000000
+++ /dev/null
@@ -1,16 +0,0 @@
-#!/bin/sh
-
-. ./_export_env.sh                              # setting environment variables
-
-export TET_SUITE_ROOT=`pwd`
-FILE_NAME_EXTENSION=`date +%s`
-
-RESULT_DIR=results
-HTML_RESULT=$RESULT_DIR/build-tar-result-$FILE_NAME_EXTENSION.html
-JOURNAL_RESULT=$RESULT_DIR/build-tar-result-$FILE_NAME_EXTENSION.journal
-
-mkdir -p $RESULT_DIR
-
-tcc -c -p ./
-tcc -b -j $JOURNAL_RESULT -p ./
-grw -c 7 -f chtml -o $HTML_RESULT $JOURNAL_RESULT
diff --git a/TC/clean.sh b/TC/clean.sh
deleted file mode 100755 (executable)
index 29743e0..0000000
+++ /dev/null
@@ -1,11 +0,0 @@
-#!/bin/sh
-
-. ./_export_env.sh                              # setting environment variables
-
-export TET_SUITE_ROOT=`pwd`
-RESULT_DIR=results
-
-tcc -c -p ./                                # executing tcc, with clean option (-c)
-rm -r $RESULT_DIR
-rm -r tet_tmp_dir
-rm testcase/tet_captured
diff --git a/TC/config b/TC/config
deleted file mode 100755 (executable)
index 4f2d054..0000000
--- a/TC/config
+++ /dev/null
@@ -1,2 +0,0 @@
-TET_INSTALL_HOST_PATH=/home/user/git_new/DTS/TETware
-TET_INSTALL_TARGET_PATH=/mnt/nfs/DTS/TETware
diff --git a/TC/execute.sh b/TC/execute.sh
deleted file mode 100755 (executable)
index d22e75c..0000000
+++ /dev/null
@@ -1,20 +0,0 @@
-#!/bin/sh
-
-. ./_export_target_env.sh                    # setting environment variables
-
-export TET_INSTALL_PATH=/mnt/nfs/TETWare
-export TET_TARGET_PATH=$TET_INSTALL_PATH/tetware-target
-export PATH=$TEST_TARGET_PATH/bin:$PATH
-export LD_LIBRARY_PATH=$TET_TARGET_PATH/lib/tet3:$LD_LIBRARY_PATH
-export TET_ROOT=$TET_TARGET_PATH
-export TET_SUITE_ROOT=`pwd`
-FILE_NAME_EXTENSION=`date +%s`
-
-RESULT_DIR=results
-HTML_RESULT=$RESULT_DIR/exec-tar-result-$FILE_NAME_EXTENSION.html
-JOURNAL_RESULT=$RESULT_DIR/exec-tar-result-$FILE_NAME_EXTENSION.journal
-
-mkdir -p $RESULT_DIR
-
-tcc -e -j $JOURNAL_RESULT -p ./
-grw -c 3 -f chtml -o $HTML_RESULT $JOURNAL_RESULT
diff --git a/TC/testcase/Makefile b/TC/testcase/Makefile
deleted file mode 100755 (executable)
index ac48db4..0000000
+++ /dev/null
@@ -1,24 +0,0 @@
-CC ?= gcc
-
-C_FILES = $(shell ls *.c)
-       
-PKGS =  accounts-svc dlog gthread-2.0
-
-LDFLAGS = `pkg-config --libs $(PKGS)`
-LDFLAGS += $(TET_ROOT)/lib/tet3/tcm_s.o
-LDFLAGS += -L$(TET_ROOT)/lib/tet3 -ltcm_s
-LDFLAGS += -L$(TET_ROOT)/lib/tet3 -lapi_s
-
-CFLAGS = -I. `pkg-config --cflags $(PKGS)`
-CFLAGS += -I$(TET_ROOT)/inc/tet3
-CFLAGS += -Wall
-
-TCS := $(shell ls -1 *.c | cut -d. -f1)
-
-all: $(TCS)
-
-%: %.c
-       $(CC) -o $@ $< $(CFLAGS) $(LDFLAGS)
-
-clean:
-       rm -f $(TCS)
diff --git a/TC/testcase/tslist b/TC/testcase/tslist
deleted file mode 100755 (executable)
index 4bfe3b0..0000000
+++ /dev/null
@@ -1,3 +0,0 @@
-/testcase/utc_account
-
-
diff --git a/TC/testcase/utc_account b/TC/testcase/utc_account
deleted file mode 100755 (executable)
index a95003e..0000000
Binary files a/TC/testcase/utc_account and /dev/null differ
diff --git a/TC/testcase/utc_account.c b/TC/testcase/utc_account.c
deleted file mode 100755 (executable)
index beeb8a5..0000000
+++ /dev/null
@@ -1,3926 +0,0 @@
-/*
- * Copyright (c) 2011 Samsung Electronics Co., Ltd All Rights Reserved
- *
- * Licensed under the Apache License, Version 2.0 (the License);
- * you may not use this file except in compliance with the License.
- * You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing, software
- * distributed under the License is distributed on an AS IS BASIS,
- * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
- * See the License for the specific language governing permissions and
- * limitations under the License.
- */
-
-#include <tet_api.h>
-#include <account.h>
-#include <account-types.h>
-#include <account-error.h>
-
-#define TEST_PACKAGE_NAME              "com.samsung.facebook"
-
-static void startup(void);
-static void cleanup(void);
-
-void (*tet_startup)(void) = startup;
-void (*tet_cleanup)(void) = cleanup;
-
-static void utc_account_connect_positive(void);
-static void utc_account_connect_negative(void);
-static void utc_account_create_positive(void);
-static void utc_account_create_negative(void);
-static void utc_account_destroy_positive(void);
-static void utc_account_destroy_negative(void);
-static void utc_account_insert_to_db_positive(void);
-static void utc_account_insert_to_db_negative(void);
-static void utc_account_delete_from_db_by_id_positive(void);
-static void utc_account_delete_from_db_by_id_negative(void);
-static void utc_account_delete_from_db_by_user_name_positive(void);
-static void utc_account_delete_from_db_by_user_name_negative(void);
-static void utc_account_delete_from_db_by_package_name_positive(void);
-static void utc_account_delete_from_db_by_package_name_negative(void);
-static void utc_account_update_to_db_by_id_positive(void);
-static void utc_account_update_to_db_by_id_negative(void);
-static void utc_account_update_to_db_by_user_name_positive(void);
-static void utc_account_update_to_db_by_user_name_negative(void);
-static void utc_account_update_sync_status_by_id_positive(void);
-static void utc_account_update_sync_status_by_id_negative(void);
-static void utc_account_get_account_id_positive(void);
-static void utc_account_get_account_id_negative(void);
-static void utc_account_get_user_name_positive(void);
-static void utc_account_get_user_name_negative(void);
-static void utc_account_set_user_name_positive(void);
-static void utc_account_set_user_name_negative(void);
-static void utc_account_get_display_name_positive(void);
-static void utc_account_get_display_name_negative(void);
-static void utc_account_set_display_name_positive(void);
-static void utc_account_set_display_name_negative(void);
-static void utc_account_get_capability_positive(void);
-static void utc_account_get_capability_negative(void);
-static void utc_account_set_capability_positive(void);
-static void utc_account_set_capability_negative(void);
-static void utc_account_get_icon_path_positive(void);
-static void utc_account_get_icon_path_negative(void);
-static void utc_account_set_icon_path_positive(void);
-static void utc_account_set_icon_path_negative(void);
-static void utc_account_get_domain_name_positive(void);
-static void utc_account_get_domain_name_negative(void);
-static void utc_account_set_domain_name_positive(void);
-static void utc_account_set_domain_name_negative(void);
-static void utc_account_get_email_address_positive(void);
-static void utc_account_get_email_address_negative(void);
-static void utc_account_set_email_address_positive(void);
-static void utc_account_set_email_address_negative(void);
-static void utc_account_get_package_name_positive(void);
-static void utc_account_get_package_name_negative(void);
-static void utc_account_set_package_name_positive(void);
-static void utc_account_set_package_name_negative(void);
-static void utc_account_get_access_token_positive(void);
-static void utc_account_get_access_token_negative(void);
-static void utc_account_set_access_token_positive(void);
-static void utc_account_set_access_token_negative(void);
-static void utc_account_get_user_text_positive(void);
-static void utc_account_get_user_text_negative(void);
-static void utc_account_set_user_text_positive(void);
-static void utc_account_set_user_text_negative(void);
-static void utc_account_get_user_int_positive(void);
-static void utc_account_get_user_int_negative(void);
-static void utc_account_set_user_int_positive(void);
-static void utc_account_set_user_int_negative(void);
-static void utc_account_get_auth_type_positive(void);
-static void utc_account_get_auth_type_negative(void);
-static void utc_account_set_auth_type_positive(void);
-static void utc_account_set_auth_type_negative(void);
-static void utc_account_get_secret_positive(void);
-static void utc_account_get_secret_negative(void);
-static void utc_account_set_secret_positive(void);
-static void utc_account_set_secret_negative(void);
-static void utc_account_get_sync_support_positive(void);
-static void utc_account_get_sync_support_negative(void);
-static void utc_account_set_sync_support_positive(void);
-static void utc_account_set_sync_support_negative(void);
-static void utc_account_get_source_positive(void);
-static void utc_account_get_source_negative(void);
-static void utc_account_set_source_positive(void);
-static void utc_account_set_source_negative(void);
-static void utc_account_foreach_account_from_db_positive(void);
-static void utc_account_foreach_account_from_db_negative(void);
-static void utc_account_query_account_by_account_id_positive(void);
-static void utc_account_query_account_by_account_id_negative(void);
-static void utc_account_query_account_by_user_name_positive(void);
-static void utc_account_query_account_by_user_name_negative(void);
-static void utc_account_query_account_by_package_name_positive(void);
-static void utc_account_query_account_by_package_name_negative(void);
-static void utc_account_query_account_by_capability_positive(void);
-static void utc_account_query_account_by_capability_negative(void);
-static void utc_account_query_capability_by_account_id_positive(void);
-static void utc_account_query_capability_by_account_id_negative(void);
-static void utc_account_get_total_count_from_db_positive(void);
-static void utc_account_get_total_count_from_db_negative(void);
-
-
-struct tet_testlist tet_testlist[] = {
-       {utc_account_connect_positive, 1},
-       //{utc_account_connect_negative, 1},
-       {utc_account_create_positive, 1},
-       {utc_account_create_negative, 1},
-       {utc_account_destroy_positive, 1},
-       //{utc_account_destroy_negative, 1},
-       {utc_account_insert_to_db_positive, 1},
-       {utc_account_insert_to_db_negative, 1},
-       {utc_account_update_to_db_by_id_positive, 1},
-       {utc_account_update_to_db_by_id_negative, 1},
-       {utc_account_update_to_db_by_user_name_positive, 1},
-       {utc_account_update_to_db_by_user_name_negative, 1},
-       {utc_account_update_sync_status_by_id_positive, 1},
-       {utc_account_update_sync_status_by_id_negative, 1},
-       {utc_account_get_account_id_positive, 1},
-       {utc_account_get_account_id_negative, 1},
-       {utc_account_get_user_name_positive, 1},
-       {utc_account_get_user_name_negative, 1},
-       {utc_account_set_user_name_positive, 1},
-       {utc_account_set_user_name_negative, 1},
-       {utc_account_get_display_name_positive, 1},
-       {utc_account_get_display_name_negative, 1},
-       {utc_account_set_display_name_positive, 1},
-       {utc_account_set_display_name_negative, 1},
-       {utc_account_get_capability_positive, 1},
-       {utc_account_get_capability_negative, 1},
-       {utc_account_set_capability_positive, 1},
-       {utc_account_set_capability_negative, 1},
-       {utc_account_get_icon_path_positive, 1},
-       {utc_account_get_icon_path_negative, 1},
-       {utc_account_set_icon_path_positive, 1},
-       {utc_account_set_icon_path_negative, 1},
-       {utc_account_get_domain_name_positive, 1},
-       {utc_account_get_domain_name_negative, 1},
-       {utc_account_set_domain_name_positive, 1},
-       {utc_account_set_domain_name_negative, 1},
-       {utc_account_get_email_address_positive, 1},
-       {utc_account_get_email_address_negative, 1},
-       {utc_account_set_email_address_positive, 1},
-       {utc_account_set_email_address_negative, 1},
-       {utc_account_get_package_name_positive, 1},
-       {utc_account_get_package_name_negative, 1},
-       {utc_account_set_package_name_positive, 1},
-       {utc_account_set_package_name_negative, 1},
-       {utc_account_get_access_token_positive, 1},
-       {utc_account_get_access_token_negative, 1},
-       {utc_account_set_access_token_positive, 1},
-       {utc_account_set_access_token_negative, 1},
-       {utc_account_get_user_text_positive, 1},
-       {utc_account_get_user_text_negative, 1},
-       {utc_account_set_user_text_positive, 1},
-       {utc_account_set_user_text_negative, 1},
-       {utc_account_get_user_int_negative, 1},
-       {utc_account_get_user_int_negative, 1},
-       {utc_account_set_user_int_negative, 1},
-       {utc_account_set_user_int_negative, 1},
-       {utc_account_get_auth_type_positive, 1},
-       {utc_account_get_auth_type_negative, 1},
-       {utc_account_set_auth_type_positive, 1},
-       {utc_account_set_auth_type_negative, 1},
-       {utc_account_get_secret_positive, 1},
-       {utc_account_get_secret_negative, 1},
-       {utc_account_set_secret_positive, 1},
-       {utc_account_set_secret_negative, 1},
-       {utc_account_get_sync_support_positive, 1},
-       {utc_account_get_sync_support_negative, 1},
-       {utc_account_set_sync_support_positive, 1},
-       {utc_account_set_sync_support_negative, 1},
-       {utc_account_get_source_positive, 1},
-       {utc_account_get_source_negative, 1},
-       {utc_account_set_source_positive, 1},
-       {utc_account_set_source_negative, 1},
-       {utc_account_foreach_account_from_db_positive, 1},
-       {utc_account_foreach_account_from_db_negative, 1},
-       {utc_account_query_account_by_account_id_positive, 1},
-       {utc_account_query_account_by_account_id_negative, 1},
-       {utc_account_query_account_by_user_name_positive, 1},
-       {utc_account_query_account_by_user_name_negative, 1},
-       {utc_account_query_account_by_package_name_positive, 1},
-       {utc_account_query_account_by_package_name_negative, 1},
-       {utc_account_query_account_by_capability_positive, 1},
-       {utc_account_query_account_by_capability_negative, 1},
-       {utc_account_query_capability_by_account_id_positive, 1},
-       {utc_account_query_capability_by_account_id_negative, 1},
-       {utc_account_get_total_count_from_db_positive, 1},
-       {utc_account_get_total_count_from_db_negative, 1},
-       {utc_account_delete_from_db_by_id_positive, 1},
-       {utc_account_delete_from_db_by_id_negative, 1},
-       {utc_account_delete_from_db_by_user_name_positive, 1},
-       {utc_account_delete_from_db_by_user_name_negative, 1},
-       {utc_account_delete_from_db_by_package_name_positive, 1},
-       {utc_account_delete_from_db_by_package_name_negative, 1},
-       /* TODO : Add more test case */
-       {NULL, 0},
-};
-
-static void startup(void)
-{
-
-}
-
-
-static void cleanup(void)
-{
-       /* end of TC */
-}
-
-static void _account_free_text(char *text)
-{
-       if (text) {
-               free(text);
-               text = NULL;
-       }
-}
-
-// START example for libaccounts-svc API test case
-
-static void utc_account_connect_positive(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       int ret = ACCOUNT_ERROR_NONE;
-
-       ret = account_connect();
-
-       if ( ret == ACCOUNT_ERROR_NONE ) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-}
-
-static void utc_account_connect_negative(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       int ret = ACCOUNT_ERROR_NONE;
-
-       ret = rename("/opt/dbspace/.account.db", "/opt/dbspace/.account-tmp.db");
-
-       ret = rename("/opt/dbspace/.account.db-journal", "/opt/dbspace/.account-tmp.db-journal");
-
-       ret = account_connect();
-
-       if ( ret == ACCOUNT_ERROR_DB_NOT_OPENED ) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = rename("/opt/dbspace/.account-tmp.db", "/opt/dbspace/.account.db");
-       ret = rename("/opt/dbspace/.account-tmp.db-journal", "/opt/dbspace/.account.db-journal");
-
-       ret = account_disconnect();
-       if ( ret != ACCOUNT_ERROR_NONE) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-
-static void utc_account_destroy_positive(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       int ret = ACCOUNT_ERROR_NONE;
-
-       ret = account_connect();
-       if ( ret != ACCOUNT_ERROR_NONE) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret == ACCOUNT_ERROR_NONE ) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-}
-
-static void utc_account_destroy_negative(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       int ret = ACCOUNT_ERROR_NONE;
-
-       ret = rename("/opt/dbspace/.account.db", "/opt/dbspace/.account-tmp.db");
-
-       ret = rename("/opt/dbspace/.account.db-journal", "/opt/dbspace/.account-tmp.db-journal");
-
-       ret = account_disconnect();
-
-       if ( ret == ACCOUNT_ERROR_DB_NOT_OPENED ) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = rename("/opt/dbspace/.account-tmp.db", "/opt/dbspace/.account.db");
-       ret = rename("/opt/dbspace/.account-tmp.db-journal", "/opt/dbspace/.account.db-journal");
-}
-
-static void utc_account_create_positive(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       account_h account;
-       int ret = ACCOUNT_ERROR_NONE;
-
-       ret = account_connect();
-       if ( ret != ACCOUNT_ERROR_NONE) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_create(&account);
-
-       if ( ret == ACCOUNT_ERROR_NONE ) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_destroy(account);
-       if ( ret != ACCOUNT_ERROR_NONE) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-       if ( ret != ACCOUNT_ERROR_NONE) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-
-static void utc_account_create_negative(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       account_h account;
-       int ret = ACCOUNT_ERROR_NONE;
-
-       ret = account_connect();
-       if ( ret != ACCOUNT_ERROR_NONE) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_create(NULL);
-
-       if ( ret == ACCOUNT_ERROR_INVALID_PARAMETER ) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-       if ( ret != ACCOUNT_ERROR_NONE) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-
-static void utc_account_insert_to_db_positive(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       account_h account;
-       int account_id = -1;
-       int ret = ACCOUNT_ERROR_NONE;
-       ret = account_connect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_create(&account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_set_user_name(account, "tarun.kr");
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_set_package_name(account, TEST_PACKAGE_NAME);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_insert_to_db(account, &account_id);
-
-       if ( ret == ACCOUNT_ERROR_NONE ) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_destroy(account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-
-static void utc_account_insert_to_db_negative(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       account_h account;
-       int account_id = -1;
-       int ret = ACCOUNT_ERROR_NONE;
-       ret = account_connect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_create(&account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_insert_to_db(NULL, &account_id);
-
-       if ( ret == ACCOUNT_ERROR_INVALID_PARAMETER ) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_destroy(account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-
-static void utc_account_set_display_name_positive(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       account_h account;
-       int account_id = -1;
-       int ret = ACCOUNT_ERROR_NONE;
-       ret = account_connect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_create(&account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_set_display_name(account, "tarun.kr");
-
-       if ( ret == ACCOUNT_ERROR_NONE ) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_insert_to_db(account, &account_id);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_destroy(account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-
-static void utc_account_set_display_name_negative(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       account_h account;
-       int account_id = -1;
-       int ret = ACCOUNT_ERROR_NONE;
-       ret = account_connect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_create(&account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-       ret = account_set_display_name(account, NULL);
-
-       if ( ret == ACCOUNT_ERROR_INVALID_PARAMETER ) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_insert_to_db(account, &account_id);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_destroy(account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-
-static void utc_account_set_user_name_positive(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       account_h account;
-       int account_id = -1;
-       int ret = ACCOUNT_ERROR_NONE;
-       ret = account_connect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_create(&account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_set_user_name(account, "tarun.kr");
-
-       if ( ret == ACCOUNT_ERROR_NONE ) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_insert_to_db(account, &account_id);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_destroy(account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-
-static void utc_account_set_user_name_negative(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       account_h account;
-       int account_id = -1;
-       int ret = ACCOUNT_ERROR_NONE;
-       ret = account_connect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_create(&account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-       ret = account_set_user_name(account, NULL);
-
-       if ( ret == ACCOUNT_ERROR_INVALID_PARAMETER ) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_insert_to_db(account, &account_id);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_destroy(account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-
-static void utc_account_set_icon_path_positive(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       account_h account;
-       int account_id = -1;
-       int ret = ACCOUNT_ERROR_NONE;
-       ret = account_connect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_create(&account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_set_icon_path(account, "icon-path");
-
-       if ( ret == ACCOUNT_ERROR_NONE ) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_insert_to_db(account, &account_id);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_destroy(account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-
-static void utc_account_set_icon_path_negative(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       account_h account;
-       int account_id = -1;
-       int ret = ACCOUNT_ERROR_NONE;
-       ret = account_connect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_create(&account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-       ret = account_set_icon_path(account, NULL);
-
-       if ( ret == ACCOUNT_ERROR_INVALID_PARAMETER ) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_insert_to_db(account, &account_id);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_destroy(account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-
-static void utc_account_set_domain_name_positive(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       account_h account;
-       int account_id = -1;
-       int ret = ACCOUNT_ERROR_NONE;
-       ret = account_connect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_create(&account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_set_domain_name(account, "domain-name");
-
-       if ( ret == ACCOUNT_ERROR_NONE ) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_insert_to_db(account, &account_id);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_destroy(account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-
-static void utc_account_set_domain_name_negative(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       account_h account;
-       int account_id = -1;
-       int ret = ACCOUNT_ERROR_NONE;
-       ret = account_connect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_create(&account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-       ret = account_set_domain_name(account, NULL);
-
-       if ( ret == ACCOUNT_ERROR_INVALID_PARAMETER ) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_insert_to_db(account, &account_id);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_destroy(account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-
-static void utc_account_set_email_address_positive(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       account_h account;
-       int account_id = -1;
-       int ret = ACCOUNT_ERROR_NONE;
-       ret = account_connect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_create(&account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_set_email_address(account, "email-address");
-
-       if ( ret == ACCOUNT_ERROR_NONE ) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_insert_to_db(account, &account_id);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_destroy(account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-
-static void utc_account_set_email_address_negative(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       account_h account;
-       int account_id = -1;
-       int ret = ACCOUNT_ERROR_NONE;
-       ret = account_connect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_create(&account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-       ret = account_set_email_address(account, NULL);
-
-       if ( ret == ACCOUNT_ERROR_INVALID_PARAMETER ) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_insert_to_db(account, &account_id);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_destroy(account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-
-static void utc_account_set_source_positive(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       account_h account;
-       int account_id = -1;
-       int ret = ACCOUNT_ERROR_NONE;
-       ret = account_connect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_create(&account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_set_source(account, "source");
-
-       if ( ret == ACCOUNT_ERROR_NONE ) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_insert_to_db(account, &account_id);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_destroy(account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-
-static void utc_account_set_source_negative(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       account_h account;
-       int account_id = -1;
-       int ret = ACCOUNT_ERROR_NONE;
-       ret = account_connect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_create(&account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-       ret = account_set_source(account, NULL);
-
-       if ( ret == ACCOUNT_ERROR_INVALID_PARAMETER ) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_insert_to_db(account, &account_id);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_destroy(account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-
-static void utc_account_set_package_name_positive(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       account_h account;
-       int account_id = -1;
-       int ret = ACCOUNT_ERROR_NONE;
-       ret = account_connect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_create(&account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_set_package_name(account, "package_name");
-
-       if ( ret == ACCOUNT_ERROR_NONE ) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_insert_to_db(account, &account_id);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_destroy(account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-
-static void utc_account_set_package_name_negative(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       account_h account;
-       int account_id = -1;
-       int ret = ACCOUNT_ERROR_NONE;
-       ret = account_connect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_create(&account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-       ret = account_set_package_name(account, NULL);
-
-       if ( ret == ACCOUNT_ERROR_INVALID_PARAMETER ) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_insert_to_db(account, &account_id);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_destroy(account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-
-static void utc_account_set_access_token_positive(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       account_h account;
-       int account_id = -1;
-       int ret = ACCOUNT_ERROR_NONE;
-       ret = account_connect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_create(&account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_set_access_token(account, "access_token");
-
-       if ( ret == ACCOUNT_ERROR_NONE ) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_insert_to_db(account, &account_id);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_destroy(account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-
-static void utc_account_set_access_token_negative(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       account_h account;
-       int account_id = -1;
-       int ret = ACCOUNT_ERROR_NONE;
-       ret = account_connect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_create(&account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-       ret = account_set_access_token(account, NULL);
-
-       if ( ret == ACCOUNT_ERROR_INVALID_PARAMETER ) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_insert_to_db(account, &account_id);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_destroy(account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-
-static void utc_account_set_auth_type_positive(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       account_h account;
-       int account_id = -1;
-       int ret = ACCOUNT_ERROR_NONE;
-       ret = account_connect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_create(&account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_set_auth_type(account, ACCOUNT_AUTH_TYPE_XAUTH);
-
-       if ( ret == ACCOUNT_ERROR_NONE ) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_insert_to_db(account, &account_id);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_destroy(account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-
-static void utc_account_set_auth_type_negative(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       account_h account;
-       int account_id = -1;
-       int ret = ACCOUNT_ERROR_NONE;
-       ret = account_connect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_create(&account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-       ret = account_set_auth_type(account, -999);
-
-       if ( ret == ACCOUNT_ERROR_INVALID_PARAMETER ) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_insert_to_db(account, &account_id);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_destroy(account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-
-static void utc_account_set_secret_positive(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       account_h account;
-       int account_id = -1;
-       int ret = ACCOUNT_ERROR_NONE;
-       ret = account_connect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_create(&account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_set_secret(account, ACCOUNT_SECRECY_INVISIBLE);
-
-       if ( ret == ACCOUNT_ERROR_NONE ) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_insert_to_db(account, &account_id);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_destroy(account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-
-static void utc_account_set_secret_negative(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       account_h account;
-       int account_id = -1;
-       int ret = ACCOUNT_ERROR_NONE;
-       ret = account_connect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_create(&account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-       ret = account_set_secret(account, -999);
-
-       if ( ret == ACCOUNT_ERROR_INVALID_PARAMETER ) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_insert_to_db(account, &account_id);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_destroy(account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-
-static void utc_account_set_sync_support_positive(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       account_h account;
-       int account_id = -1;
-       int ret = ACCOUNT_ERROR_NONE;
-       ret = account_connect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_create(&account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_set_sync_support(account, ACCOUNT_SYNC_STATUS_IDLE);
-
-       if ( ret == ACCOUNT_ERROR_NONE ) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_insert_to_db(account, &account_id);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_destroy(account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-
-static void utc_account_set_sync_support_negative(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       account_h account;
-       int account_id = -1;
-       int ret = ACCOUNT_ERROR_NONE;
-       ret = account_connect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_create(&account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-       ret = account_set_sync_support(account, -999);
-
-       if ( ret == ACCOUNT_ERROR_INVALID_PARAMETER ) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_insert_to_db(account, &account_id);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_destroy(account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-
-static void utc_account_set_user_text_positive(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       account_h account;
-       int account_id = -1;
-       int ret = ACCOUNT_ERROR_NONE;
-       ret = account_connect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_create(&account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-       int i;
-       for ( i = 0; i < 5; i++)
-               ret = account_set_user_text(account, i, "user-text");
-
-       if ( ret == ACCOUNT_ERROR_NONE ) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_insert_to_db(account, &account_id);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_destroy(account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-
-static void utc_account_set_user_text_negative(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       account_h account;
-       int account_id = -1;
-       int ret = ACCOUNT_ERROR_NONE;
-       ret = account_connect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_create(&account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-       int i;
-
-       for (i = 0; i < 5; i++)
-               ret = account_set_user_text(account, i, NULL);
-
-       if ( ret == ACCOUNT_ERROR_INVALID_PARAMETER ) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_insert_to_db(account, &account_id);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_destroy(account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-
-static void utc_account_set_user_int_positive(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       account_h account;
-       int account_id = -1;
-       int ret = ACCOUNT_ERROR_NONE;
-       ret = account_connect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_create(&account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-       int i;
-       for (i = 0; i < 5; i++)
-               ret = account_set_user_int(account, i, 999);
-
-       if ( ret == ACCOUNT_ERROR_NONE ) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_insert_to_db(account, &account_id);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_destroy(account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-
-static void utc_account_set_user_int_negative(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       account_h account;
-       int account_id = -1;
-       int ret = ACCOUNT_ERROR_NONE;
-       ret = account_connect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_create(&account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-       int i;
-       for (i = 0; i < 5; i++)
-               ret = account_set_user_int(NULL, i, 999);
-
-       if ( ret == ACCOUNT_ERROR_INVALID_PARAMETER ) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_insert_to_db(account, &account_id);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_destroy(account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-
-static void utc_account_set_capability_positive(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       account_h account;
-       int account_id = -1;
-       int ret = ACCOUNT_ERROR_NONE;
-       ret = account_connect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_create(&account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_set_capability(account, ACCOUNT_CAPABILITY_CALENDAR, ACCOUNT_CAPABILITY_ENABLED);
-
-       if ( ret == ACCOUNT_ERROR_NONE ) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_insert_to_db(account, &account_id);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_destroy(account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-
-static void utc_account_set_capability_negative(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       account_h account;
-       int account_id = -1;
-       int ret = ACCOUNT_ERROR_NONE;
-       ret = account_connect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_create(&account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_set_capability(account, -100, -5);
-
-       if ( ret == ACCOUNT_ERROR_INVALID_PARAMETER ) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_insert_to_db(account, &account_id);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_destroy(account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-
-static void utc_account_get_display_name_positive(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       char * display_name;
-       account_h account;
-       int account_id = -1;
-       int ret = ACCOUNT_ERROR_NONE;
-       ret = account_connect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_create(&account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_query_account_by_account_id(1, &account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_get_display_name(account, &display_name);
-
-       if ( ret == ACCOUNT_ERROR_NONE ) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       _account_free_text(display_name);
-
-       ret = account_destroy(account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-
-static void utc_account_get_display_name_negative(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       account_h account;
-       int account_id = -1;
-       int ret = ACCOUNT_ERROR_NONE;
-       ret = account_connect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_create(&account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-
-       ret = account_query_account_by_account_id(1, &account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_get_display_name(account, NULL);
-
-       if ( ret == ACCOUNT_ERROR_INVALID_PARAMETER ) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_destroy(account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-
-static void utc_account_get_account_id_positive(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       account_h account;
-       int account_id = -1;
-       int ret = ACCOUNT_ERROR_NONE;
-       ret = account_connect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_create(&account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_query_account_by_account_id(1, &account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_get_account_id(account, &account_id);
-
-       if ( ret == ACCOUNT_ERROR_NONE ) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_destroy(account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-
-static void utc_account_get_account_id_negative(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       account_h account;
-       int account_id = -1;
-       int ret = ACCOUNT_ERROR_NONE;
-       ret = account_connect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_create(&account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_query_account_by_account_id(1, &account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_get_account_id(account, NULL);
-
-       if ( ret == ACCOUNT_ERROR_INVALID_PARAMETER ) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_destroy(account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-
-static void utc_account_get_user_name_positive(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       char *user_name;
-       account_h account;
-       int account_id = -1;
-       int ret = ACCOUNT_ERROR_NONE;
-       ret = account_connect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_create(&account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_query_account_by_account_id(1, &account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_get_user_name(account, &user_name);
-
-       if ( ret == ACCOUNT_ERROR_NONE ) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       _account_free_text(user_name);
-
-       ret = account_destroy(account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-
-static void utc_account_get_user_name_negative(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       account_h account;
-       int account_id = -1;
-       int ret = ACCOUNT_ERROR_NONE;
-       ret = account_connect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_create(&account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_query_account_by_account_id(1, &account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_get_user_name(account, NULL);
-
-       if ( ret == ACCOUNT_ERROR_INVALID_PARAMETER ) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_destroy(account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-
-static void utc_account_get_icon_path_positive(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       char *icon_path;
-       account_h account;
-       int account_id = -1;
-       int ret = ACCOUNT_ERROR_NONE;
-       ret = account_connect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_create(&account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_query_account_by_account_id(1, &account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_get_icon_path(account, &icon_path);
-
-       if ( ret == ACCOUNT_ERROR_NONE ) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       _account_free_text(icon_path);
-
-       ret = account_destroy(account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-
-static void utc_account_get_icon_path_negative(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       account_h account;
-       int account_id = -1;
-       int ret = ACCOUNT_ERROR_NONE;
-       ret = account_connect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_create(&account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_query_account_by_account_id(1, &account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_get_icon_path(account, NULL);
-
-       if ( ret == ACCOUNT_ERROR_INVALID_PARAMETER ) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_destroy(account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-
-static void utc_account_get_domain_name_positive(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       account_h account;
-       char *domain_name;
-       int account_id = -1;
-       int ret = ACCOUNT_ERROR_NONE;
-       ret = account_connect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_create(&account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_query_account_by_account_id(1, &account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_get_domain_name(account, &domain_name);
-
-       if ( ret == ACCOUNT_ERROR_NONE ) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       _account_free_text(domain_name);
-
-       ret = account_destroy(account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-
-static void utc_account_get_domain_name_negative(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       account_h account;
-       int account_id = -1;
-       int ret = ACCOUNT_ERROR_NONE;
-       ret = account_connect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_create(&account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_query_account_by_account_id(1, &account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_get_domain_name(account, NULL);
-
-       if ( ret == ACCOUNT_ERROR_INVALID_PARAMETER ) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_destroy(account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-
-static void utc_account_get_email_address_positive(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       account_h account;
-       char *email_address;
-       int account_id = -1;
-       int ret = ACCOUNT_ERROR_NONE;
-       ret = account_connect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_create(&account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_query_account_by_account_id(1, &account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_get_email_address(account, &email_address);
-
-       if ( ret == ACCOUNT_ERROR_NONE ) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       _account_free_text(email_address);
-
-       ret = account_destroy(account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-
-static void utc_account_get_email_address_negative(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       account_h account;
-       int account_id = -1;
-       int ret = ACCOUNT_ERROR_NONE;
-       ret = account_connect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_create(&account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_query_account_by_account_id(1, &account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_get_email_address(account, NULL);
-
-       if ( ret == ACCOUNT_ERROR_INVALID_PARAMETER ) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_destroy(account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-
-static void utc_account_get_source_positive(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       account_h account;
-       char *source;
-       int account_id = -1;
-       int ret = ACCOUNT_ERROR_NONE;
-       ret = account_connect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_create(&account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_query_account_by_account_id(1, &account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_get_source(account, &source);
-
-       if ( ret == ACCOUNT_ERROR_NONE ) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       _account_free_text(source);
-
-       ret = account_destroy(account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-
-static void utc_account_get_source_negative(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       account_h account;
-       int account_id = -1;
-       int ret = ACCOUNT_ERROR_NONE;
-       ret = account_connect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_create(&account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_query_account_by_account_id(1, &account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_get_source(account, NULL);
-
-       if ( ret == ACCOUNT_ERROR_INVALID_PARAMETER ) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_destroy(account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-
-static void utc_account_get_package_name_positive(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       account_h account;
-       char *package_name;
-       int account_id = -1;
-       int ret = ACCOUNT_ERROR_NONE;
-       ret = account_connect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_create(&account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_query_account_by_account_id(1, &account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_get_package_name(account, &package_name);
-
-       if ( ret == ACCOUNT_ERROR_NONE ) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       _account_free_text(package_name);
-
-       ret = account_destroy(account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-
-static void utc_account_get_package_name_negative(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       account_h account;
-       int account_id = -1;
-       int ret = ACCOUNT_ERROR_NONE;
-       ret = account_connect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_create(&account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_query_account_by_account_id(1, &account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_get_package_name(account, NULL);
-
-       if ( ret == ACCOUNT_ERROR_INVALID_PARAMETER ) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_destroy(account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-
-static void utc_account_get_access_token_positive(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       account_h account;
-       char *access_token;
-       int account_id = -1;
-       int ret = ACCOUNT_ERROR_NONE;
-       ret = account_connect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_create(&account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_query_account_by_account_id(1, &account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_get_access_token(account, &access_token);
-
-       if ( ret == ACCOUNT_ERROR_NONE ) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       _account_free_text(access_token);
-
-       ret = account_destroy(account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-
-static void utc_account_get_access_token_negative(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       account_h account;
-       int account_id = -1;
-       int ret = ACCOUNT_ERROR_NONE;
-       ret = account_connect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_create(&account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_query_account_by_account_id(1, &account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_get_access_token(account, NULL);
-
-       if ( ret == ACCOUNT_ERROR_INVALID_PARAMETER ) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_destroy(account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-
-static void utc_account_get_auth_type_positive(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       account_h account;
-       int auth_type;
-       int account_id = -1;
-       int ret = ACCOUNT_ERROR_NONE;
-       ret = account_connect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_create(&account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_query_account_by_account_id(1, &account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_get_auth_type(account, &auth_type);
-
-       if ( ret == ACCOUNT_ERROR_NONE ) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_destroy(account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-
-static void utc_account_get_auth_type_negative(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       account_h account;
-       int account_id = -1;
-       int ret = ACCOUNT_ERROR_NONE;
-       ret = account_connect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_create(&account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_query_account_by_account_id(1, &account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_get_auth_type(account, NULL);
-
-       if ( ret == ACCOUNT_ERROR_INVALID_PARAMETER ) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_destroy(account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-
-static void utc_account_get_secret_positive(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       account_h account;
-       account_secrecy_state_e secret;
-       int account_id = -1;
-       int ret = ACCOUNT_ERROR_NONE;
-       ret = account_connect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_create(&account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_query_account_by_account_id(1, &account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_get_secret(account, &secret);
-
-       if ( ret == ACCOUNT_ERROR_NONE ) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_destroy(account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-
-static void utc_account_get_sync_support_positive(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       account_h account;
-       account_sync_state_e sync_support;
-       int account_id = -1;
-       int ret = ACCOUNT_ERROR_NONE;
-       ret = account_connect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_create(&account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_query_account_by_account_id(1, &account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_get_sync_support(account, &sync_support);
-
-       if ( ret == ACCOUNT_ERROR_NONE ) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_destroy(account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-
-static void utc_account_get_secret_negative(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       account_h account;
-       int account_id = -1;
-       int ret = ACCOUNT_ERROR_NONE;
-       ret = account_connect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_create(&account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_query_account_by_account_id(1, &account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_get_secret(account, NULL);
-
-       if ( ret == ACCOUNT_ERROR_INVALID_PARAMETER ) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_destroy(account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-
-static void utc_account_get_sync_support_negative(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       account_h account;
-       int account_id = -1;
-       int ret = ACCOUNT_ERROR_NONE;
-       ret = account_connect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_create(&account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_query_account_by_account_id(1, &account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_get_sync_support(account, NULL);
-
-       if ( ret == ACCOUNT_ERROR_INVALID_PARAMETER ) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_destroy(account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-
-static void utc_account_get_user_text_positive(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       account_h account;
-       char *user_text;
-       int account_id = -1;
-       int ret = ACCOUNT_ERROR_NONE;
-       ret = account_connect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_create(&account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_query_account_by_account_id(1, &account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-       int i;
-       for (i = 0; i < 5; i++) {
-               ret = account_get_user_text(account, i, &user_text);
-               _account_free_text(user_text);
-       }
-
-       if ( ret == ACCOUNT_ERROR_NONE ) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_destroy(account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-
-static void utc_account_get_user_text_negative(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       account_h account;
-       int account_id = -1;
-       int ret = ACCOUNT_ERROR_NONE;
-       ret = account_connect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_create(&account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_query_account_by_account_id(1, &account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-       int i;
-       for (i = 0; i < 5; i++)
-               ret = account_get_user_text(account, i, NULL);
-
-       if ( ret == ACCOUNT_ERROR_INVALID_PARAMETER ) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_destroy(account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-
-static void utc_account_get_user_int_positive(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       account_h account;
-       int user_int;
-       int account_id = -1;
-       int ret = ACCOUNT_ERROR_NONE;
-       ret = account_connect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_create(&account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_query_account_by_account_id(1, &account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-       int i;
-       for (i = 0; i < 5; i++)
-               ret = account_get_user_int(account, i, &user_int);
-
-       if ( ret == ACCOUNT_ERROR_NONE ) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_insert_to_db(account, &account_id);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_destroy(account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-
-static void utc_account_get_user_int_negative(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       account_h account;
-       int account_id = -1;
-       int ret = ACCOUNT_ERROR_NONE;
-       ret = account_connect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_create(&account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_query_account_by_account_id(1, &account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-       int i;
-       for (i = 0; i < 5; i++)
-               ret = account_get_user_int(NULL, i, NULL);
-
-       if ( ret == ACCOUNT_ERROR_INVALID_PARAMETER ) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_destroy(account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-bool capability_call_back(account_capability_type_e capability_type, account_capability_state_e capability_state, void *user_data)
-{
-
-}
-
-static void utc_account_get_capability_positive(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       account_h account;
-       int account_id = -1;
-       int ret = ACCOUNT_ERROR_NONE;
-       ret = account_connect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_create(&account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_query_account_by_account_id(1, &account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_get_capability(account, capability_call_back, NULL);
-
-       if ( ret == ACCOUNT_ERROR_NONE ) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_destroy(account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-
-static void utc_account_get_capability_negative(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       account_h account;
-       int account_id = -1;
-       int ret = ACCOUNT_ERROR_NONE;
-       ret = account_connect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_create(&account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_query_account_by_account_id(1, &account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_get_capability(account, NULL, NULL);
-
-       if ( ret == ACCOUNT_ERROR_INVALID_PARAMETER ) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_destroy(account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-
-bool account_call_back(account_h account, void *user_data)
-{
-
-}
-
-static void utc_account_foreach_account_from_db_positive(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       account_h account;
-       int account_id = -1;
-       int ret = ACCOUNT_ERROR_NONE;
-       ret = account_connect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_foreach_account_from_db(account_call_back, NULL);
-
-       if ( ret == ACCOUNT_ERROR_NONE ) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-
-static void utc_account_foreach_account_from_db_negative(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       account_h account;
-       int account_id = -1;
-       int ret = ACCOUNT_ERROR_NONE;
-       ret = account_connect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_foreach_account_from_db(NULL, NULL);
-
-       if ( ret == ACCOUNT_ERROR_INVALID_PARAMETER ) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-
-static void utc_account_query_account_by_account_id_positive(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       account_h account;
-       int account_id = -1;
-       int ret = ACCOUNT_ERROR_NONE;
-       ret = account_connect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_create(&account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_query_account_by_account_id(1, &account);
-
-       if ( ret == ACCOUNT_ERROR_NONE ) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_destroy(account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-
-static void utc_account_query_account_by_account_id_negative(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       account_h account;
-       int account_id = -1;
-       int ret = ACCOUNT_ERROR_NONE;
-       ret = account_connect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_create(&account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_query_account_by_account_id(-999, NULL);
-
-       if ( ret == ACCOUNT_ERROR_INVALID_PARAMETER ) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_destroy(account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-
-static void utc_account_query_account_by_user_name_positive(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       account_h account;
-       int account_id = -1;
-       int ret = ACCOUNT_ERROR_NONE;
-       ret = account_connect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_query_account_by_user_name(account_call_back, "tarun.kr", NULL);
-
-       if ( ret == ACCOUNT_ERROR_NONE || ret == ACCOUNT_ERROR_RECORD_NOT_FOUND) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-
-static void utc_account_query_account_by_user_name_negative(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       account_h account;
-       int account_id = -1;
-       int ret = ACCOUNT_ERROR_NONE;
-       ret = account_connect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_query_account_by_user_name(account_call_back, NULL, NULL);
-
-       if ( ret == ACCOUNT_ERROR_INVALID_PARAMETER ) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-
-static void utc_account_query_account_by_package_name_positive(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       account_h account;
-       int account_id = -1;
-       int ret = ACCOUNT_ERROR_NONE;
-       ret = account_connect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_query_account_by_package_name(account_call_back, TEST_PACKAGE_NAME, NULL);
-
-       if ( ret == ACCOUNT_ERROR_NONE ) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-
-static void utc_account_query_account_by_package_name_negative(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       account_h account;
-       int account_id = -1;
-       int ret = ACCOUNT_ERROR_NONE;
-       ret = account_connect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_query_account_by_package_name(account_call_back, NULL, NULL);
-
-       if ( ret == ACCOUNT_ERROR_INVALID_PARAMETER ) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-
-static void utc_account_query_account_by_capability_positive(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       account_h account;
-       int account_id = -1;
-       int ret = ACCOUNT_ERROR_NONE;
-       ret = account_connect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_query_account_by_capability(account_call_back, ACCOUNT_CAPABILITY_PHOTO, ACCOUNT_CAPABILITY_ENABLED, NULL);
-
-       if ( ret == ACCOUNT_ERROR_NONE || ret == ACCOUNT_ERROR_RECORD_NOT_FOUND) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-
-static void utc_account_query_account_by_capability_negative(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       account_h account;
-       int account_id = -1;
-       int ret = ACCOUNT_ERROR_NONE;
-       ret = account_connect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_query_account_by_capability(account_call_back, -999, -999, NULL);
-
-       if ( ret == ACCOUNT_ERROR_INVALID_PARAMETER ) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-
-static void utc_account_query_capability_by_account_id_positive(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       account_h account;
-       int account_id = -1;
-       int ret = ACCOUNT_ERROR_NONE;
-       ret = account_connect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_query_capability_by_account_id(capability_call_back, 1, NULL);
-
-       if ( ret == ACCOUNT_ERROR_NONE || ret == ACCOUNT_ERROR_RECORD_NOT_FOUND) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-
-static void utc_account_query_capability_by_account_id_negative(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       account_h account;
-       int account_id = -1;
-       int ret = ACCOUNT_ERROR_NONE;
-       ret = account_connect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_query_capability_by_account_id(capability_call_back, -1, NULL);
-
-       if ( ret == ACCOUNT_ERROR_INVALID_PARAMETER ) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-
-static void utc_account_get_total_count_from_db_positive(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       account_h account;
-       int account_id = -1;
-       int *count;
-       int ret = ACCOUNT_ERROR_NONE;
-       ret = account_connect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_get_total_count_from_db(&count);
-
-       if ( ret == ACCOUNT_ERROR_NONE ) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-
-static void utc_account_get_total_count_from_db_negative(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       account_h account;
-       int account_id = -1;
-       int ret = ACCOUNT_ERROR_NONE;
-       ret = account_connect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_get_total_count_from_db(NULL);
-
-       if ( ret == ACCOUNT_ERROR_INVALID_PARAMETER ) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-
-static void utc_account_update_sync_status_by_id_positive(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       account_h account;
-       int account_id = -1;
-       int ret = ACCOUNT_ERROR_NONE;
-       ret = account_connect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_update_sync_status_by_id(1, ACCOUNT_SYNC_STATUS_IDLE);
-
-       if ( ret == ACCOUNT_ERROR_NONE || ret == ACCOUNT_ERROR_RECORD_NOT_FOUND) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-
-static void utc_account_update_sync_status_by_id_negative(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       account_h account;
-       int account_id = -1;
-       int ret = ACCOUNT_ERROR_NONE;
-       ret = account_connect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_update_sync_status_by_id(-1, ACCOUNT_SYNC_STATUS_IDLE);
-
-       if ( ret == ACCOUNT_ERROR_RECORD_NOT_FOUND || ret == ACCOUNT_ERROR_INVALID_PARAMETER ) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-}
-
-static void utc_account_delete_from_db_by_id_positive(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       account_h account;
-       int account_id = -1;
-       int ret = ACCOUNT_ERROR_NONE;
-       ret = account_connect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_delete_from_db_by_id(1);
-
-       if ( ret == ACCOUNT_ERROR_NONE || ret == ACCOUNT_ERROR_RECORD_NOT_FOUND) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-
-static void utc_account_delete_from_db_by_id_negative(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       account_h account;
-       int account_id = -1;
-       int ret = ACCOUNT_ERROR_NONE;
-       ret = account_connect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_delete_from_db_by_id(-1);
-
-       if ( ret == ACCOUNT_ERROR_RECORD_NOT_FOUND || ret == ACCOUNT_ERROR_INVALID_PARAMETER ) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-}
-
-static void utc_account_delete_from_db_by_user_name_positive(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       account_h account;
-       int account_id = -1;
-       int ret = ACCOUNT_ERROR_NONE;
-       ret = account_connect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_delete_from_db_by_user_name("tarun.kr", TEST_PACKAGE_NAME);
-
-       if ( ret == ACCOUNT_ERROR_NONE || ret == ACCOUNT_ERROR_RECORD_NOT_FOUND) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-
-static void utc_account_delete_from_db_by_user_name_negative(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       account_h account;
-       int account_id = -1;
-       int ret = ACCOUNT_ERROR_NONE;
-       ret = account_connect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_delete_from_db_by_user_name(NULL, TEST_PACKAGE_NAME);
-
-       if ( ret == ACCOUNT_ERROR_INVALID_PARAMETER ) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-
-static void utc_account_delete_from_db_by_package_name_positive(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       account_h account;
-       int account_id = -1;
-       int ret = ACCOUNT_ERROR_NONE;
-       ret = account_connect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_delete_from_db_by_package_name(TEST_PACKAGE_NAME);
-
-       if ( ret == ACCOUNT_ERROR_NONE || ret == ACCOUNT_ERROR_RECORD_NOT_FOUND) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-
-static void utc_account_delete_from_db_by_package_name_negative(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       account_h account;
-       int account_id = -1;
-       int ret = ACCOUNT_ERROR_NONE;
-       ret = account_connect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_delete_from_db_by_package_name(NULL);
-
-       if ( ret == ACCOUNT_ERROR_INVALID_PARAMETER ) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-
-static void utc_account_update_to_db_by_id_positive(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       account_h account;
-       int account_id = -1;
-       int ret = ACCOUNT_ERROR_NONE;
-       ret = account_connect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_create(&account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_set_user_name(account, "update-tarun.kr");
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_set_package_name(account, TEST_PACKAGE_NAME);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_update_to_db_by_id(account, 1);
-
-       if ( ret == ACCOUNT_ERROR_NONE ) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_destroy(account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-
-static void utc_account_update_to_db_by_id_negative(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       account_h account;
-       int account_id = -1;
-       int ret = ACCOUNT_ERROR_NONE;
-       ret = account_connect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_create(&account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_update_to_db_by_id(account, -1);
-
-       if ( ret == ACCOUNT_ERROR_INVALID_PARAMETER ) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_destroy(account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-
-static void utc_account_update_to_db_by_user_name_positive(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       account_h account;
-       int account_id = -1;
-       int ret = ACCOUNT_ERROR_NONE;
-       ret = account_connect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_create(&account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_set_user_name(account, "update-tarun.kr");
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_set_package_name(account, TEST_PACKAGE_NAME);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_update_to_db_by_user_name(account, "tarun.kr", TEST_PACKAGE_NAME);
-
-       if ( ret == ACCOUNT_ERROR_NONE ) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_destroy(account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-
-static void utc_account_update_to_db_by_user_name_negative(void)
-{
-       const char *API_NAME = __FUNCTION__;
-       account_h account;
-       int account_id = -1;
-       int ret = ACCOUNT_ERROR_NONE;
-       ret = account_connect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_create(&account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_update_to_db_by_user_name(account, NULL, TEST_PACKAGE_NAME);
-
-       if ( ret == ACCOUNT_ERROR_INVALID_PARAMETER ) {
-               dts_pass(API_NAME, "passed");
-       } else {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_destroy(account);
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-
-       ret = account_disconnect();
-
-       if ( ret != ACCOUNT_ERROR_NONE ) {
-               dts_fail(API_NAME, "failed");
-       }
-}
-
-// END of example for libaccounts-svc API unit test
-
diff --git a/TC/tet_scen b/TC/tet_scen
deleted file mode 100755 (executable)
index 03f029a..0000000
+++ /dev/null
@@ -1,7 +0,0 @@
-all
-       ^TEST
-##### Scenarios for TEST #####
-
-# Test scenario
-TEST
-       :include:/testcase/tslist
diff --git a/TC/tetbuild.cfg b/TC/tetbuild.cfg
deleted file mode 100755 (executable)
index f7eda55..0000000
+++ /dev/null
@@ -1,5 +0,0 @@
-TET_OUTPUT_CAPTURE=True # capture option for build operation checking
-TET_BUILD_TOOL=make # build with using make command
-TET_BUILD_FILE=-f Makefile # execution file (Makefile) for build
-TET_API_COMPLIANT=True # use TET API in Test Case ?
-TET_PASS_TC_NAME=True # report passed TC name in Journal file?
diff --git a/TC/tetclean.cfg b/TC/tetclean.cfg
deleted file mode 100755 (executable)
index 02d7030..0000000
+++ /dev/null
@@ -1,5 +0,0 @@
-TET_OUTPUT_CAPTURE=True # capture option
-TET_CLEAN_TOOL= make clean # clean tool
-TET_CLEAN_FILE= Makefile # file for clean
-TET_API_COMPLIANT=True # TET API useage 
-TET_PASS_TC_NAME=True # showing name , passed TC
diff --git a/TC/tetexec.cfg b/TC/tetexec.cfg
deleted file mode 100755 (executable)
index ef3e452..0000000
+++ /dev/null
@@ -1,5 +0,0 @@
-TET_OUTPUT_CAPTURE=True # capturing execution or not
-TET_EXEC_TOOL=  # ex) exec : execution tool set up/ Optional
-TET_EXEC_FILE=   # ex) exectool : execution file/ Optional
-TET_API_COMPLIANT=True # Test case or Tool usesTET API?
-TET_PASS_TC_NAME=True # showing Passed TC name ?
index 12ef0c9..969d7bb 100755 (executable)
@@ -8,6 +8,6 @@ includedir=@INCLUDEDIR@
 Name: accounts-svc
 Description: Account DB library
 Version: @VERSION@
-Requires: sqlite3 dlog db-util glib-2.0 capi-base-common vconf
+Requires: capi-base-common
 Libs: -L${libdir} -laccounts-svc
 Cflags: -I${includedir}
diff --git a/doc/account_manager_doc.h b/doc/account_manager_doc.h
new file mode 100644 (file)
index 0000000..68d9ce3
--- /dev/null
@@ -0,0 +1,44 @@
+/*
+ *
+ * Copyright (c) 2012 - 2013 Samsung Electronics Co., Ltd. All rights reserved.
+ *
+ * Contact: Wonyoung Lee <wy1115.lee@samsung.com>, Sungchan Kim <sungchan81.kim@samsung.com>
+ *
+ * Licensed under the Apache License, Version 2.0 (the "License");
+ * you may not use this file except in compliance with the License.
+ * You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ *
+ */
+
+#ifndef __ACCOUNT_H__
+#define __ACCOUNT_H__
+
+/**
+ * @defgroup  CAPI_ACCOUNT_MANAGER_MODULE Account Manager
+ * @ingroup   CAPI_SOCIAL_FRAMEWORK
+ * @brief     The account APIs provide CRUD (Create, Read, Update, Delete) account management functionality.
+ *
+ * @section   CAPI_ACCOUNT_MANAGER_HEADER Required Header
+ *  \#include <account.h>
+ *
+ * @section CAPI_ACCOUNT_MANAGER_MODULE_OVERVIEW Overview
+ * The account APIs is separated into two major sections:
+ * 1. Registering an account provider while an application is installed. This information will be used for the Add account screen.
+ * 2. Adding an account information when an application signs in successfully to share the account information to the Tizen system. This information will be shown in the Tizen settings account menu.
+
+ * The APIs of both of the sections consist of the following functionality:
+ * - Create an account or account provider
+ * - Update an account or account provider(Only available for the creator)
+ * - Delete an account or account provider(Only available for the creator)
+ * - Read an account or account provider with some filter
+*/
+
+#endif /* __ACCOUNT_H__  */
index e0b55a5..592b214 100755 (executable)
@@ -1,5 +1,4 @@
 /*
- *  account
  *
  * Copyright (c) 2012 - 2013 Samsung Electronics Co., Ltd. All rights reserved.
  *
@@ -35,37 +34,38 @@ extern "C"
  */
 
 /**
- * @file        account-error.h
- * @brief      ACCOUNT error definitions.
+ * @file   account-error.h
+ * @brief  This file contains ACCOUNT error definitions.
  */
 
-//#define TIZEN_ERROR_ACCOUNT_CLASS SLP_ERROR_SOCIAL_CLASS | 0x90
+//#define TIZEN_ERROR_ACCOUNT_CLASS SLP_ERROR_ACCOUNT | 0x90
 
 /**
- *  @brief    Enumerations of error codes for ACOUNT APIs.
+ *  @brief    Enumerations of error codes for ACCOUNT APIs.
+ *  @since_tizen  2.3
  */
 typedef enum
 {
+    ACCOUNT_ERROR_NONE                  = TIZEN_ERROR_NONE,                   /**< Successful */
+    ACCOUNT_ERROR_OUT_OF_MEMORY             = TIZEN_ERROR_OUT_OF_MEMORY,              /**< Out of memory */
+    ACCOUNT_ERROR_INVALID_PARAMETER         = TIZEN_ERROR_INVALID_PARAMETER,        /**< Invalid parameter */
 
-       ACCOUNT_ERROR_NONE                                      = TIZEN_ERROR_NONE,                   /**< Successful */
-       ACCOUNT_ERROR_OUT_OF_MEMORY                             = TIZEN_ERROR_OUT_OF_MEMORY,              /**< Out of memory */
-       ACCOUNT_ERROR_INVALID_PARAMETER                 = TIZEN_ERROR_INVALID_PARAMETER,                /**< Invalid parameter */
+    ACCOUNT_ERROR_DUPLICATED = TIZEN_ERROR_ACCOUNT | 0x01, /**< Same user name exists in your application */
+    ACCOUNT_ERROR_NO_DATA  = TIZEN_ERROR_NO_DATA, /**< Empty data */
 
-       ACCOUNT_ERROR_DUPLICATED = TIZEN_ERROR_SOCIAL_CLASS | 0x01,
-       ACCOUNT_ERROR_NO_DATA  = TIZEN_ERROR_SOCIAL_CLASS | 0x02,
-
-       ACCOUNT_ERROR_RECORD_NOT_FOUND = TIZEN_ERROR_SOCIAL_CLASS | 0x03,
-       ACCOUNT_ERROR_DB_FAILED = TIZEN_ERROR_SOCIAL_CLASS | 0x04,
-       ACCOUNT_ERROR_DB_NOT_OPENED = TIZEN_ERROR_SOCIAL_CLASS | 0x05,
-       ACCOUNT_ERROR_QUERY_SYNTAX_ERROR = TIZEN_ERROR_SOCIAL_CLASS | 0x06,
-       ACCOUNT_ERROR_ITERATOR_END = TIZEN_ERROR_SOCIAL_CLASS | 0x07,
-       ACCOUNT_ERROR_NOTI_FAILED = TIZEN_ERROR_SOCIAL_CLASS | 0x08,
-       ACCOUNT_ERROR_PERMISSION_DENIED = TIZEN_ERROR_SOCIAL_CLASS | 0x09,
-       ACCOUNT_ERROR_XML_PARSE_FAILED = TIZEN_ERROR_SOCIAL_CLASS | 0x0a,
-       ACCOUNT_ERROR_XML_FILE_NOT_FOUND = TIZEN_ERROR_SOCIAL_CLASS | 0x0b,
-       ACCOUNT_ERROR_EVENT_SUBSCRIPTION_FAIL = TIZEN_ERROR_SOCIAL_CLASS | 0x0c,
-       ACCOUNT_ERROR_NOT_REGISTERED_PROVIDER = TIZEN_ERROR_SOCIAL_CLASS | 0x0d,
-       ACCOUNT_ERROR_NOT_ALLOW_MULTIPLE = TIZEN_ERROR_SOCIAL_CLASS | 0x0e,
+    ACCOUNT_ERROR_RECORD_NOT_FOUND = TIZEN_ERROR_ACCOUNT | 0x03, /**< Related record does not exist */
+    ACCOUNT_ERROR_DB_FAILED = TIZEN_ERROR_ACCOUNT | 0x04, /**< DB operation failed */
+    ACCOUNT_ERROR_DB_NOT_OPENED = TIZEN_ERROR_ACCOUNT | 0x05, /**< DB is not connected */
+    ACCOUNT_ERROR_QUERY_SYNTAX_ERROR = TIZEN_ERROR_ACCOUNT | 0x06, /**< DB query syntax error */
+    ACCOUNT_ERROR_ITERATOR_END = TIZEN_ERROR_ACCOUNT | 0x07, /**< Iterator has reached the end */
+    ACCOUNT_ERROR_NOTI_FAILED = TIZEN_ERROR_ACCOUNT | 0x08, /**< Notification failed */
+    ACCOUNT_ERROR_PERMISSION_DENIED = TIZEN_ERROR_PERMISSION_DENIED, /**< Permission denied */
+    ACCOUNT_ERROR_XML_PARSE_FAILED = TIZEN_ERROR_ACCOUNT | 0x0a, /**< XML parse failed */
+    ACCOUNT_ERROR_XML_FILE_NOT_FOUND = TIZEN_ERROR_ACCOUNT | 0x0b, /**< XML file does not exist */
+    ACCOUNT_ERROR_EVENT_SUBSCRIPTION_FAIL = TIZEN_ERROR_ACCOUNT | 0x0c, /**< Subscription failed */
+    ACCOUNT_ERROR_NOT_REGISTERED_PROVIDER = TIZEN_ERROR_ACCOUNT | 0x0d, /**< Account provider is not registered */
+    ACCOUNT_ERROR_NOT_ALLOW_MULTIPLE = TIZEN_ERROR_ACCOUNT | 0x0e, /**< Multiple accounts are not supported */
+    ACCOUNT_ERROR_DATABASE_BUSY = TIZEN_ERROR_ACCOUNT | 0x10, /**< SQLite busy handler expired */
 } account_error_e;
 
 /**
index 2005d15..766faef 100755 (executable)
@@ -23,7 +23,6 @@
 #define __ACCOUNT_PRIVATE_TYPES_H__
 
 
-/*#include <glib.h>*/
 #ifdef __cplusplus
 extern "C"
 {
@@ -39,24 +38,24 @@ extern "C"
 #define LOG_TAG "ACCOUNT"
 
 #define ACCOUNT_VERBOSE(fmt, arg...) \
-               LOGV(": " fmt "\n", ##arg);
+               LOGD(": " fmt "\n", ##arg);
 #define ACCOUNT_DEBUG(fmt, arg...) \
                LOGD(": " fmt "\n", ##arg);
-#define ACCOUNT_INFO(fmt, arg...) \
-               LOGI(": " fmt "\n", ##arg);
-#define ACCOUNT_WARNING(fmt, arg...) \
-               LOGW(": " fmt "\n", ##arg);
 #define ACCOUNT_ERROR(fmt, arg...) \
-               LOGW(": " fmt "\n", ##arg);
+               LOGE(": " fmt "\n", ##arg);
 #define ACCOUNT_FATAL(fmt, arg...) \
                LOGF(": " fmt "\n", ##arg);
+#define ACCOUNT_SLOGD(fmt, arg...) \
+               SECURE_LOGD(": " fmt "\n", ##arg);
+#define ACCOUNT_SLOGI(fmt, arg...) \
+               SECURE_LOGI(": " fmt "\n", ##arg);
+#define ACCOUNT_SLOGE(fmt, arg...) \
+               SECURE_LOGE(": " fmt "\n", ##arg);
 
 #define ACCOUNT_RETURN_VAL(eval, expr, ret_val, X)\
        if (!(eval)) \
 {\
        expr; \
-       if (1)\
-       {ACCOUNT_ERROR X;}\
        return ret_val;\
 } else {;}
 
@@ -78,8 +77,6 @@ NULL after passing    them to free: free(NULL) is safe (it does nothing).
 {\
        expr; \
        error_code = (error_val);\
-       if (1)\
-       {ACCOUNT_ERROR X;}\
        goto CATCH;\
 } else {;}
 
@@ -96,7 +93,7 @@ NULL after passing    them to free: free(NULL) is safe (it does nothing).
                                        ptr = NULL; \
                                }       \
 
-#define ACCOUNT_DB_NAME "/opt/dbspace/.account.db"
+#define ACCOUNT_DB_NAME "/opt/usr/dbspace/.account.db"
 #define ACCOUNT_TABLE "account"
 #define CAPABILITY_TABLE "capability"
 #define ACCOUNT_CUSTOM_TABLE "account_custom"
@@ -107,6 +104,46 @@ NULL after passing         them to free: free(NULL) is safe (it does nothing).
 #define ACCOUNT_SQL_LEN_MAX    1024
 #define ACCOUNT_TABLE_TOTAL_COUNT      6
 
+#define FACEBOOK_PKG_NAME              "com.samsung.facebook"
+#define EMAIL_PKG_NAME                 "email-setting-efl"
+#define EXCHANGE_PKG_NAME              "activesync-ui"
+#define IMS_SERVICE_PKG_NAME           "ims-service"
+#define SAMSUNGACCOUNTFRONT_PKG_NAME  "com.samsung.samsung-account-front"
+//#define SAMSUNGACCOUNT_PKG_NAME  "gr47by21a5.SamsungAccount"
+#define SAMSUNGACCOUNT_PKG_NAME  "com.samsung.samsungaccount"
+#define CHATON_PKG_NAME                        "xnq5eh9vop.ChatON"
+#define DROPBOX_PKG_NAME  "com.samsung.dropbox"
+#define SYNCHRONISE_PKG_NAME "setting-synchronise-efl"
+
+#define USER_TXT_CNT 5
+#define USER_INT_CNT 5
+
+
+/* account uri list */
+#define ACCOUNT_DATA_SERVICE_PROVIDER                     "http://tizen.org/account/data/service_provider"
+#define ACCOUNT_OPERATION_SIGNIN_OLD                      "http://tizen.org/account/operation/signin"
+
+// private account operation type
+#define ACCOUNT_OPERATION_FMM                             "http://tizen.org/account/operation/fmm"
+#define ACCOUNT_OPERATION_MYACCOUNT                       "http://tizen.org/account/operation/signin_from_myaccount"
+// End of private account operation type
+
+#define ACCOUNT_SUPPORTS_CAPABILITY_POST                  "http://tizen.org/account/capability/post"
+#define ACCOUNT_SUPPORTS_CAPABILITY_VOIP                  "http://tizen.org/account/capability/voip"
+#define ACCOUNT_SUPPORTS_CAPABILITY_SAMSUNG_APPS          "http://tizen.org/account/capability/samsungapps"
+#define ACCOUNT_SUPPORTS_CAPABILITY_TASK                  "http://tizen.org/account/capability/task"
+#define ACCOUNT_SUPPORTS_CAPABILITY_MOBILE_TRACKER        "http://tizen.org/account/capability/mobiletracker"
+#define ACCOUNT_SUPPORTS_CAPABILITY_S_NOTE                "http://tizen.org/account/capability/snote"
+#define ACCOUNT_SUPPORTS_CAPABILITY_GALLERY               "http://tizen.org/account/capability/gallery"
+#define ACCOUNT_SUPPORTS_CAPABILITY_MEMO                  "http://tizen.org/account/capability/memo"
+#define ACCOUNT_SUPPORTS_CAPABILITY_CHAT                  "http://tizen.org/account/capability/chat"
+#define ACCOUNT_SUPPORTS_CAPABILITY_BOOKMARK              "http://tizen.org/account/capability/bookmark"
+#define ACCOUNT_SUPPORTS_CAPABILITY_SYNCHRONISE           "http://tizen.org/account/capability/synchronise"
+#define ACCOUNT_SUPPORTS_CAPABILITY_TIZEN_EMAIL           "http://tizen.org/account/capability/tizen_email"
+#define ACCOUNT_SUPPORTS_CAPABILITY_INTERNET              "http://tizen.org/account/capability/internet"
+#define ACCOUNT_SUPPORTS_CAPABILITY_DOCOMO_SCHEDULE_MEMO  "http://tizen.org/account/capability/docomo"
+/* end of account uri list */
+
 typedef struct _account_s
 {
        int                     id;
@@ -264,7 +301,8 @@ typedef enum {
 
 typedef sqlite3_stmt* account_stmt;
 
-#define ACCOUNT_SCHEMA "create table %s \n"\
+//ACCOUNT_TABLE
+#define ACCOUNT_SCHEMA "create table account \n"\
        "(\n"\
 "_id INTEGER PRIMARY KEY AUTOINCREMENT, "\
 "user_name TEXT, "\
@@ -290,7 +328,8 @@ typedef sqlite3_stmt* account_stmt;
 "int_custom4 INTEGER "\
 ");"
 
-#define CAPABILITY_SCHEMA  "create table %s \n"\
+//CAPABILITY_TABLE
+#define CAPABILITY_SCHEMA  "create table capability \n"\
        "(\n"\
 "_id INTEGER PRIMARY KEY AUTOINCREMENT, "\
 "key TEXT, "\
@@ -300,7 +339,8 @@ typedef sqlite3_stmt* account_stmt;
 "account_id INTEGER "\
 ");"
 
-#define ACCOUNT_CUSTOM_SCHEMA  "create table %s \n"\
+//ACCOUNT_CUSTOM_TABLE
+#define ACCOUNT_CUSTOM_SCHEMA  "create table account_custom \n"\
        "(\n"\
 "AccountId INTEGER, "\
 "AppId TEXT, "\
@@ -308,7 +348,8 @@ typedef sqlite3_stmt* account_stmt;
 "Value TEXT "\
 ");"
 
-#define ACCOUNT_TYPE_SCHEMA "create table %s \n"\
+//ACCOUNT_TYPE_TABLE
+#define ACCOUNT_TYPE_SCHEMA "create table account_type \n"\
        "(\n"\
 "_id INTEGER PRIMARY KEY AUTOINCREMENT, "\
 "AppId TEXT, "\
@@ -318,14 +359,16 @@ typedef sqlite3_stmt* account_stmt;
 "MultipleAccountSupport INTEGER "\
 ");"
 
-#define LABEL_SCHEMA "create table %s \n"\
+//LABEL_TABLE
+#define LABEL_SCHEMA "create table label \n"\
        "(\n"\
 "AppId TEXT, "\
 "Label TEXT, "\
 "Locale TEXT"\
 ");"
 
-#define PROVIDER_FEATURE_SCHEMA "create table %s \n"\
+//PROVIDER_FEATURE_TABLE
+#define PROVIDER_FEATURE_SCHEMA "create table provider_feature \n"\
        "(\n"\
 "app_id TEXT, "\
 "key TEXT "\
index 86c1a16..5eb582f 100755 (executable)
@@ -1,5 +1,4 @@
 /*
- *  account
  *
  * Copyright (c) 2012 - 2013 Samsung Electronics Co., Ltd. All rights reserved.
  *
@@ -22,8 +21,6 @@
 #ifndef __ACCOUNT_TYPES_H__
 #define __ACCOUNT_TYPES_H__
 
-#include <db-util.h>
-
 #ifdef __cplusplus
 extern "C"
 {
@@ -36,120 +33,221 @@ extern "C"
  */
 
 /**
- * @file               account-types.h
- * @ingroup    CAPI_ACCOUNT
- * @brief              This file defines common types and enums of ACCOUNT.
+ * @file     account-types.h
+ * @ingroup  CAPI_ACCOUNT
+ * @brief    This file defines common types and enums of ACCOUNT.
  */
 
 /**
- * @brief      Enumerations for the state of capability.
+ * @brief  Enumeration for the state of capability.
+ * @since_tizen  2.3
  */
 typedef enum
 {
-       ACCOUNT_CAPABILITY_STATE_INVALID = 0,
-       ACCOUNT_CAPABILITY_DISABLED,
-       ACCOUNT_CAPABILITY_ENABLED,
-       ACCOUNT_CAPABILITY_STATE_MAX
+    ACCOUNT_CAPABILITY_STATE_INVALID = 0, /**< Account capability is invalid */
+    ACCOUNT_CAPABILITY_DISABLED, /**< Account capability is disabled */
+    ACCOUNT_CAPABILITY_ENABLED, /**< Account capability is enabled */
+    ACCOUNT_CAPABILITY_STATE_MAX
 }
 account_capability_state_e;
 
 /**
- * @brief      Enumerations for the state of account secrecy.
+ * @brief  Enumeration for the state of account secrecy.
+ * @since_tizen  2.3
  */
 typedef enum
 {
-       ACCOUNT_SECRECY_INVALID = 0,
-       ACCOUNT_SECRECY_INVISIBLE,
-       ACCOUNT_SECRECY_VISIBLE,
-       ACCOUNT_SECRECY_MAX
+    ACCOUNT_SECRECY_INVALID = 0, /**< Account secrecy is invalid */
+    ACCOUNT_SECRECY_INVISIBLE, /**< Account is not visible */
+    ACCOUNT_SECRECY_VISIBLE, /**< Account is visible */
+    ACCOUNT_SECRECY_MAX
 }
 account_secrecy_state_e;
 
 /**
- * @brief      Enumerations for the account supported sync or not.
- * ACCOUNT_SYNC_NOT_SUPPORT: sync not supported
- * ACCOUNT_SYNC_STATUS_OFF: supproted sync but all synchronization functionalities are off
- * ACCOUNT_SYNC_STATUS_IDLE: sync support and sync status is idle
- * ACCOUNT_SYNC_STATUS_RUNNING: sync support and sync status is running
- * ACCOUNT_SUPPORTS_SYNC: NOT USED, WILL BE REMOVED. TO PREVENT BUILD ERROR.
- * ACCOUNT_NOT_SUPPORTS_SYNC: NOT USED, WILL BE REMOVED. TO PREVENT BUILD ERROR.
+ * @brief  Enumeration for the account sync status.
+ * @since_tizen  2.3
  */
 typedef enum
 {
-       ACCOUNT_SYNC_INVALID = 0,
-       ACCOUNT_SYNC_NOT_SUPPORT,
-       ACCOUNT_SYNC_STATUS_OFF,
-       ACCOUNT_SYNC_STATUS_IDLE,
-       ACCOUNT_SYNC_STATUS_RUNNING,
-       ACCOUNT_SUPPORTS_SYNC,
-       ACCOUNT_NOT_SUPPORTS_SYNC,
-       ACCOUNT_SYNC_MAX
+    ACCOUNT_SYNC_INVALID = 0, /**< Account sync is invalid */
+    ACCOUNT_SYNC_NOT_SUPPORT,  /**< Account sync not supported */
+    ACCOUNT_SYNC_STATUS_OFF, /**< Account sync supported but all synchronization functionalities are off */
+    ACCOUNT_SYNC_STATUS_IDLE, /**< Account sync support and sync status is idle */
+    ACCOUNT_SYNC_STATUS_RUNNING, /**< Account sync support and sync status is running */
+    ACCOUNT_SUPPORTS_SYNC, /**<  NOT USED, WILL BE REMOVED TO PREVENT BUILD ERROR */
+    ACCOUNT_NOT_SUPPORTS_SYNC, /**<  NOT USED, WILL BE REMOVED TO PREVENT BUILD ERROR */
+    ACCOUNT_SYNC_MAX
 }
 account_sync_state_e;
 
+/**
+ * @brief  Enumeration for the account auth type.
+ * @since_tizen  2.3
+ */
 typedef enum
 {
-       ACCOUNT_AUTH_TYPE_INVALID = 0,
-       ACCOUNT_AUTH_TYPE_XAUTH,
-       ACCOUNT_AUTH_TYPE_OAUTH,
-       ACCOUNT_AUTH_TYPE_CLIENT_LOGIN,
-       ACCOUNT_AUTH_TYPE_MAX
+    ACCOUNT_AUTH_TYPE_INVALID = 0, /**< Auth type is invalid */
+    ACCOUNT_AUTH_TYPE_XAUTH, /**< XAuth type */
+    ACCOUNT_AUTH_TYPE_OAUTH, /**< OAuth type */
+    ACCOUNT_AUTH_TYPE_CLIENT_LOGIN, /**< Client-Login type */
+    ACCOUNT_AUTH_TYPE_MAX
 }account_auth_type_e;
 
 /**
- * @brief Account handle.
+ * @brief  The structure type for the Account handle.
+ * @since_tizen  2.3
  */
 typedef struct account_s* account_h;
 
 /**
- * @brief Account capability handle.
- */
-typedef struct account_capability_s* account_capability_h;
-
-/**
- * @brief Account type handle.
+ * @brief  The structure type for the Account provider handle.
+ * @since_tizen  2.3
  */
 typedef struct account_type_s* account_type_h;
 
 /**
- * @brief Account handle.
+ * @brief  The structure type for the Account handle.
+ * @since_tizen  2.3
  */
 typedef struct label_s* label_h;
 
+
+/**
+ * @brief  The structure type for the Account subscribe handle.
+ * @since_tizen  2.3
+ */
 typedef struct account_subscribe_s* account_subscribe_h;
 
-#define ACCOUNT_DATA_USERNAME                                  "http://tizen.org/account/data/username"
-#define ACCOUNT_DATA_SERVICE_PROVIDER                          "http://tizen.org/account/data/service_provider"
-#define ACCOUNT_DATA_ID                                                "http://tizen.org/appcontrol/data/account/id"
-#define ACCOUNT_OPERATION_SIGNIN                               "http://tizen.org/appcontrol/operation/account/add"
-#define ACCOUNT_OPERATION_VIEW                         "http://tizen.org/appcontrol/operation/account/configure"
-
-#define ACCOUNT_SUPPORTS_CAPABILITY_CONTACT    "http://tizen.org/account/capability/contact"
-#define ACCOUNT_SUPPORTS_CAPABILITY_CALENDAR   "http://tizen.org/account/capability/calendar"
-#define ACCOUNT_SUPPORTS_CAPABILITY_PHOTO              "http://tizen.org/account/capability/photo"
-#define ACCOUNT_SUPPORTS_CAPABILITY_VIDEO              "http://tizen.org/account/capability/video"
-#define ACCOUNT_SUPPORTS_CAPABILITY_EMAIL              "http://tizen.org/account/capability/email"
-#define ACCOUNT_SUPPORTS_CAPABILITY_POST               "http://tizen.org/account/capability/post"
-#define ACCOUNT_SUPPORTS_CAPABILITY_VOIP               "http://tizen.org/account/capability/voip"
-#define ACCOUNT_SUPPORTS_CAPABILITY_SAMSUNG_APPS               "http://tizen.org/account/capability/samsungapps"
-#define ACCOUNT_SUPPORTS_CAPABILITY_TASK               "http://tizen.org/account/capability/task"
-#define ACCOUNT_SUPPORTS_CAPABILITY_MOBILE_TRACKER             "http://tizen.org/account/capability/mobiletracker"
-#define ACCOUNT_SUPPORTS_CAPABILITY_S_NOTE             "http://tizen.org/account/capability/snote"
-#define ACCOUNT_SUPPORTS_CAPABILITY_GALLERY            "http://tizen.org/account/capability/gallery"
-#define ACCOUNT_SUPPORTS_CAPABILITY_MUSIC              "http://tizen.org/account/capability/music"
-#define ACCOUNT_SUPPORTS_CAPABILITY_MEMO               "http://tizen.org/account/capability/memo"
-#define ACCOUNT_SUPPORTS_CAPABILITY_MESSAGE            "http://tizen.org/account/capability/message"
-#define ACCOUNT_SUPPORTS_CAPABILITY_CHAT               "http://tizen.org/account/capability/chat"
-#define ACCOUNT_SUPPORTS_CAPABILITY_BOOKMARK           "http://tizen.org/account/capability/bookmark"
-#define ACCOUNT_SUPPORTS_CAPABILITY_TIZEN_EMAIL        "http://tizen.org/account/capability/tizen_email"
-
-#define USER_TXT_CNT 5
-#define USER_INT_CNT 5
-
-#define ACCOUNT_NOTI_NAME_INSERT               "insert"
-#define ACCOUNT_NOTI_NAME_UPDATE               "update"
-#define ACCOUNT_NOTI_NAME_DELETE               "delete"
-#define ACCOUNT_NOTI_NAME_SYNC_UPDATE          "sync_update"
+/**
+ * @brief        The insert notification type.
+ * @since_tizen  2.3
+ * @remarks      When the account database is changed, You can distinguish one event type from the other which are set for subscribing notification.
+ *
+ * @see account_subscribe_notification()
+ */
+#define ACCOUNT_NOTI_NAME_INSERT        "insert"
+
+/**
+ * @brief        The update notification type.
+ * @since_tizen  2.3
+ * @remarks      When the account database is changed, You can distinguish one event type from the other which are set for subscribing notification.
+ *
+ * @see account_subscribe_notification()
+ */
+#define ACCOUNT_NOTI_NAME_UPDATE        "update"
+
+/**
+ * @brief        The delete notification type.
+ * @since_tizen  2.3
+ * @remarks      When the account database is changed, You can distinguish one event type from the other which are set for subscribing notification.
+ *
+ * @see account_subscribe_notification()
+ */
+#define ACCOUNT_NOTI_NAME_DELETE        "delete"
+
+/**
+ * @brief        The sync_update notification type.
+ * @since_tizen  2.3
+ * @remarks      When the account database is changed, You can distinguish one event type from the other which are set for subscribing notification.
+ *
+ * @see account_subscribe_notification()
+ */
+#define ACCOUNT_NOTI_NAME_SYNC_UPDATE   "sync_update"
+
+
+/**
+ * @brief        This is a key of app_control_h’s extra data. The value of the key is a user account name.
+ * @since_tizen  2.3
+ * @remarks      You can retrieve the value like this, app_control_get_extra_data(app_control, ACCOUNT_DATA_USERNAME, &username).\n
+                 This value will be sent with ACCOUNT_OPERATION_VIEW.
+ */
+#define ACCOUNT_DATA_USERNAME                             "http://tizen.org/account/data/username"
+
+/**
+ * @brief        This is a key of app_control_h’s extra data. The value of the key is account DB ID of the user’s account information.
+ * @since_tizen  2.3
+ * @remarks      You can retrieve the value like this, app_control_get_extra_data(app_control, ACCOUNT_DATA_ID, &id).\n
+                 This value will be sent with ACCOUNT_OPERATION_VIEW.
+ */
+#define ACCOUNT_DATA_ID                                   "http://tizen.org/appcontrol/data/account/id"
+
+/**
+ * @brief        This is an application launch operation name.
+ * @since_tizen  2.3
+ * @remarks      This operation will be sent when a user selects your account in add account view.
+ */
+#define ACCOUNT_OPERATION_SIGNIN                          "http://tizen.org/appcontrol/operation/account/add"
+
+/**
+ * @brief        This is an application launch operation name.
+ * @since_tizen  2.3
+ * @remarks      This operation will be sent when a user selects your account in account list view.
+ */
+#define ACCOUNT_OPERATION_VIEW                            "http://tizen.org/appcontrol/operation/account/configure"
+
+/**
+ * @brief        This is contact capability string.
+ * @since_tizen  2.3
+ * @remarks      If your provider service has contact information and contact information is provided another application, register this capability through manifest file.
+ */
+#define ACCOUNT_SUPPORTS_CAPABILITY_CONTACT               "http://tizen.org/account/capability/contact"
+
+/**
+ * @brief        This is calendar capability string.
+ * @since_tizen  2.3
+ * @remarks      If your provider service has calendar information and calendar information is provided another application, register this capability through manifest file.
+ */
+#define ACCOUNT_SUPPORTS_CAPABILITY_CALENDAR              "http://tizen.org/account/capability/calendar"
+
+/**
+ * @brief        This is email capability string.
+ * @since_tizen  2.3
+ * @remarks      If your provider service have email service and email is provided another application, register this capability through manifest file.
+ */
+#define ACCOUNT_SUPPORTS_CAPABILITY_EMAIL                 "http://tizen.org/account/capability/email"
+
+/**
+ * @brief        This is photo capability string.
+ * @since_tizen  2.3
+ * @remarks      If your provider service has photo and photo is provided another application, register this capability through manifest file.
+ */
+#define ACCOUNT_SUPPORTS_CAPABILITY_PHOTO                 "http://tizen.org/account/capability/photo"
+
+/**
+ * @brief        This is video capability string.
+ * @since_tizen  2.3
+ * @remarks      If your provider service has video and video is provided another application, register this capability through manifest file.
+ */
+#define ACCOUNT_SUPPORTS_CAPABILITY_VIDEO                 "http://tizen.org/account/capability/video"
+
+/**
+ * @brief        This is music capability string.
+ * @since_tizen  2.3
+ * @remarks      If your provider service has music and music is provided another application, register this capability through manifest file.
+ */
+#define ACCOUNT_SUPPORTS_CAPABILITY_MUSIC                 "http://tizen.org/account/capability/music"
+
+/**
+ * @brief        This is document capability string.
+ * @since_tizen  2.3
+ * @remarks      If your provider service has document and document is provided another application, register this capability through manifest file.
+ */
+#define ACCOUNT_SUPPORTS_CAPABILITY_DOCUMENT                 "http://tizen.org/account/capability/document"
+
+/**
+ * @brief        This is message capability string.
+ * @since_tizen  2.3
+ * @remarks      This capability will be exploited to use SMS, MMS.
+ */
+#define ACCOUNT_SUPPORTS_CAPABILITY_MESSAGE               "http://tizen.org/account/capability/message"
+
+/**
+ * @brief        This is game capability string.
+ * @since_tizen  2.3
+ * @remarks      This capability will be exploited to use game data.
+ */
+#define ACCOUNT_SUPPORTS_CAPABILITY_GAME               "http://tizen.org/account/capability/game"
 
 /**
  * @}
index a828956..fefd4fe 100755 (executable)
@@ -1,5 +1,4 @@
 /*
- *  account
  *
  * Copyright (c) 2012 - 2013 Samsung Electronics Co., Ltd. All rights reserved.
  *
@@ -22,9 +21,6 @@
 #ifndef __ACCOUNT_H__
 #define __ACCOUNT_H__
 
-#include <stdlib.h>
-#include <stdio.h>
-#include <glib.h>
 #include <account-types.h>
 #include <account-error.h>
 
@@ -39,7 +35,7 @@ extern "C"
 
 /**
  * @file        account.h
- * @brief       This file contains the Account API for account management
+ * @brief       This file contains the Account API for account management.
  */
 
 /**
@@ -48,14 +44,16 @@ extern "C"
  */
 
 /**
- * @brief      Called once for each account from database
+ * @brief   Called once for each account from the database.
  *
- * @param[in]  account The account handle
- * @param[in]  user_data The user data passed from the foreach function
+ * @since_tizen 2.3
+ * @param[in]  account    The account handle
+ * @param[in]  user_data  The user data passed from the foreach function
  *
- * @return @c true to continue with the next iteration of the loop or @c false to break out of the loop.
+ * @return     @c true to continue with the next iteration of the loop, \n
+ *             otherwise @c false to break out of the loop
  *
- * @pre account_foreach_account_from_db(), account_query_account_by_account_id(), account_query_account_by_user_name() or account_query_account_by_package_name() invoke this callback.
+ * @pre account_foreach_account_from_db(), account_query_account_by_account_id(), account_query_account_by_user_name() or account_query_account_by_package_name() must be called.
  *
  * @see account_foreach_account_from_db()
  * @see account_query_account_by_account_id()
@@ -64,48 +62,130 @@ extern "C"
  */
 typedef bool (*account_cb)(account_h account, void *user_data);
 
-
 /**
- * @brief      Called once for each capability of account from database
+ * @brief  Called once for each capability of an account in the database.
  *
- * @param[in]  capability_type The capability type
- * @param[in]  capability_state The capability state
- * @param[in]  user_data The user data passed from the foreach function
+ * @since_tizen 2.3
+ * @param[in]   capability_type  The capability type
+ * @param[in]   capability_state The capability state
+ * @param[in]   user_data        The user data passed from the foreach function
  *
- * @return @c true to continue with the next iteration of the loop or @c false to break out of the loop.
+ * @return      @c true to continue with the next iteration of the loop, \n
+ *              otherwise @c false to break out of the loop
  *
- * @pre account_query_capability_by_account_id() invokes this callback.
+ * @pre account_query_capability_by_account_id() must be called.
  *
  * @see account_query_capability_by_account_id()
  */
 typedef bool (*capability_cb)(const char* capability_type, account_capability_state_e capability_state, void *user_data);
 
 /**
- * @brief      Called once for each custom data of account from database
+ * @brief  Called once for each custom data of an account in the database.
+ *
+ * @since_tizen 2.3
+ * @param[in]  key        The user custom key
+ * @param[in]  value      The user custom value of the specific key
+ * @param[in]  user_data  The user data passed
  *
- * @param[in]  key The user custom key
- * @param[in]  value The user custom value of the specific key
- * @param[in]  user_data The user data passed
+ * @return     @c true to continue with the next iteration of the loop, \n
+ *             otherwise @c false to break out of the loop
  *
- * @return @c true to continue with the next iteration of the loop or @c false to break out of the loop.
+ * @pre account_query_capability_by_account_id() must be called.
  *
  * @see account_query_capability_by_account_id()
  */
 typedef bool (*account_custom_cb)(char* key, char* value, void *user_data);
 
 
+/**
+ * @brief  Called once for each account provider in the database.
+ *
+ * @since_tizen 2.3
+ * @param[in]  account_type  The account provider handle
+ * @param[in]  user_data     The user data passed
+ *
+ * @return     @c true to continue with the next iteration of the loop, \n
+ *             otherwise @c false to break out of the loop
+ *
+ * @pre account_type_foreach_account_type_from_db(), account_type_query_by_provider_feature() must be called.
+ *
+ * @see account_type_foreach_account_type_from_db()
+ * @see account_type_query_by_provider_feature()
+ */
 typedef bool (*account_type_cb)(account_type_h account_type, void *user_data);
+
+
+/**
+ * @brief  Called once for each account label.
+ *
+ * @since_tizen 2.3
+ * @param[in]  app_id     The application ID
+ * @param[in]  label      The name of the account depends on the specified locale
+ * @param[in]  locale     The locale is specified as an ISO 3166 alpha-2 two letter country-code followed by ISO 639-1 for the two-letter language code.\n
+ *                        For example, "ko_KR" for Korean, "en_US" for American English.
+ * @param[in]  user_data  The user data passed
+ *
+ * @return     @c true to continue with the next iteration of the loop, \n
+ *             otherwise @c false to break out of the loop
+ *
+ * @pre account_type_get_label(), account_type_query_label_by_app_id() must be called.
+ *
+ * @see account_type_get_label()
+ * @see account_type_query_label_by_app_id()
+ */
 typedef bool (*account_label_cb)(char* app_id, char* label, char* locale, void *user_data);
+
+
+/**
+ * @brief  Called once for each capability of an account provider in the database.
+ *
+ * @since_tizen 2.3
+ * @param[in]  app_id     The application ID
+ * @param[in]  key        The user custom key
+ * @param[in]  user_data  The user data passed
+ *
+ * @return     @c true to continue with the next iteration of the loop, \n
+ *             otherwise @c false to break out of the loop
+ *
+ * @pre account_type_query_provider_feature_by_app_id(), account_type_get_provider_feature_all() must be called.
+ *
+ * @see account_type_query_provider_feature_by_app_id()
+ * @see account_type_get_provider_feature_all()
+ */
 typedef bool (*provider_feature_cb)(char* app_id, char* key, void* user_data);
+
+
+/**
+ * @brief Called once when an event occurs.
+ *
+ * @since_tizen 2.3
+ * @param[in]  event_type  The account event type
+ * @param[in]  account_id  The account ID to update
+ * @param[in]  user_data   The user data passed
+ *
+ * @return     @c true to continue with the next iteration of the loop, \n
+ *             otherwise @c false to break out of the loop
+ *
+ * @pre account_subscribe_notification() must be called.
+ *
+ * @see account_subscribe_notification()
+ */
 typedef bool (*account_event_cb)(const char* event_type, int account_id, void* user_data);
 
 
 /**
- * @brief      Connects to the account database.
+ * @brief  Connects to the account database by readwrite mode.
  *
- * @return     0 on success, otherwise a negative error value.
- * @retval     #ACCOUNT_ERROR_NONE Successful
- * @retval     #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter
+ * @since_tizen 2.3
+ * @privlevel  public
+ * @privilege  %http://tizen.org/privilege/account.read \n
+ *             %http://tizen.org/privilege/account.write
+ * @remarks    this API need both privileges
+ * @return     @c 0 on success,
+ *             otherwise a negative error value
+ * @retval     #ACCOUNT_ERROR_NONE               Successful
+ * @retval     #ACCOUNT_ERROR_DB_NOT_OPENED      DB is not connected
+ * @retval     #ACCOUNT_ERROR_PERMISSION_DENIED  DB Access fail by permission
  *
  * @see account_disconnect()
  */
@@ -113,11 +193,33 @@ ACCOUNT_API int account_connect(void);
 
 
 /**
- * @brief      Disconnects from account database.
+ * @brief   Connects to the account database by readonly mode.
  *
- * @return     0 on success, otherwise a negative error value.
- * @retval     #ACCOUNT_ERROR_NONE Successful
- * @retval     #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter
+ * @since_tizen 2.3
+ * @privlevel  public
+ * @privilege  %http://tizen.org/privilege/account.read
+ * @return     @c 0 on success,
+ *             otherwise a negative error value
+ * @retval     #ACCOUNT_ERROR_NONE               Successful
+ * @retval     #ACCOUNT_ERROR_DB_NOT_OPENED      DB is not connected
+ * @retval     #ACCOUNT_ERROR_PERMISSION_DENIED  DB Access fail by permission
+ *
+ * @see account_disconnect()
+ */
+ACCOUNT_API int account_connect_readonly(void);
+
+
+/**
+ * @brief  Disconnects from the account database.
+ *
+ * @since_tizen 2.3
+ * @privlevel  public
+ * @privilege  %http://tizen.org/privilege/account.read
+ * @return     @c 0 on success,
+ *             otherwise a negative error value
+ * @retval     #ACCOUNT_ERROR_NONE               Successful
+ * @retval     #ACCOUNT_ERROR_PERMISSION_DENIED  DB Access fail by permission
+ * @retval     #ACCOUNT_ERROR_DATABASE_BUSY      SQLite busy handler expired
  *
  * @see account_connect()
  */
@@ -125,17 +227,19 @@ ACCOUNT_API int account_disconnect(void);
 
 
 /**
- * @brief      Creates a handle to the account.
+ * @brief  Creates a handle to the account.
  *
- * @remarks    @a account must be released with account_destroy() by you. \n
- *  The created handle is not added to the account database until account_insert_to_db() is called.
+ * @since_tizen 2.3
+ * @remarks    Release @a account using account_destroy().
+ * @remarks    The created handle is not added to the account database until account_insert_to_db() is called.
  *
- * @param[in]  account The account handle
+ * @param[in]  account  The account handle
  *
- * @return     0 on success, otherwise a negative error value.
- * @retval     #ACCOUNT_ERROR_NONE Successful
- * @retval     #ACCOUNT_ERROR_OUT_OF_MEMORY Out of Memory
- * @retval     #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter
+ * @return     @c 0 on success,
+ *             otherwise a negative error value
+ * @retval     #ACCOUNT_ERROR_NONE               Successful
+ * @retval     #ACCOUNT_ERROR_OUT_OF_MEMORY      Out of Memory
+ * @retval     #ACCOUNT_ERROR_INVALID_PARAMETER  Invalid parameter
  *
  * @see account_destroy()
  */
@@ -143,13 +247,15 @@ ACCOUNT_API int account_create(account_h *account);
 
 
 /**
- * @brief      Destroys the account handle and releases all its resources.
+ * @brief  Destroys the account handle and releases all its resources.
  *
- * @param[in]  account The account handle
+ * @since_tizen 2.3
+ * @param[in]  account  The account handle
  *
- * @return     0 on success, otherwise a negative error value.
- * @retval     #ACCOUNT_ERROR_NONE     Successful
- * @retval     #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter
+ * @return     @c 0 on success,
+ *             otherwise a negative error value
+ * @retval     #ACCOUNT_ERROR_NONE               Successful
+ * @retval     #ACCOUNT_ERROR_INVALID_PARAMETER  Invalid parameter
  *
  * @see account_create()
  */
@@ -157,20 +263,26 @@ ACCOUNT_API int account_destroy(account_h account);
 
 
 /**
- * @brief      Inserts the account details to the account database.
+ * @brief  Inserts the account details to the account database.
  *
- * @param[in]  account The account handle
- * @param[out] account_db_id The account ID to be assigned to a account
+ * @since_tizen 2.3
+ * @privlevel   public
+ * @privilege   %http://tizen.org/privilege/account.read \n
+ *              %http://tizen.org/privilege/account.write
+ * @remarks     this API need both privileges
+ * @param[in]   account        The account handle
+ * @param[out]  account_db_id  The account ID to be assigned to an account
  *
- * @return     0 on success, otherwise a negative error value.
- * @retval     #ACCOUNT_ERROR_NONE Successful
- * @retval     #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter
- * @retval     #ACCOUNT_ERROR_DB_FAILED  Database operation failed
- * @retval     #ACCOUNT_ERROR_DUPLICATED  Same user name exist in your application
- * @retval     #ACCOUNT_ERROR_NOT_ALLOW_MULTIPLE  when you try to add an account inspite of multiple account false
- * @retval     #ACCOUNT_ERROR_NOT_REGISTERED_PROVIDER  when you try to add an account though you didn't register account type in manifest
+ * @return  @c 0 on success,
+ *          otherwise a negative error value
+ * @retval  #ACCOUNT_ERROR_NONE Successful
+ * @retval  #ACCOUNT_ERROR_INVALID_PARAMETER        Invalid parameter
+ * @retval  #ACCOUNT_ERROR_DB_FAILED                Database operation failed
+ * @retval  #ACCOUNT_ERROR_DUPLICATED               Same user name exists in your application
+ * @retval  #ACCOUNT_ERROR_NOT_ALLOW_MULTIPLE       Tried to add an account in spite of multiple false accounts
+ * @retval  #ACCOUNT_ERROR_NOT_REGISTERED_PROVIDER  Tried to add an account though you did not register the account provider in manifest
  *
- * @pre        This function requires an open connection to account service by account_connect().
+ * @pre  This function requires an open connection to an account service by account_connect().
  *
  * @see account_connect()
  * @see account_delete_from_db_by_id()
@@ -181,111 +293,146 @@ ACCOUNT_API int account_destroy(account_h account);
  */
 ACCOUNT_API int account_insert_to_db(account_h account, int *account_db_id);
 
+
 /**
- * @brief      Updates the account details to the account database without checking provider permission.
+ * @brief  Deletes an account from the account database by account DB ID.
  *
- * @param[in]  account The account handle
- * @param[in]  account_id The account ID to update
+ * @since_tizen 2.3
+ * @privlevel  public
+ * @privilege  %http://tizen.org/privilege/account.read \n
+ *             %http://tizen.org/privilege/account.write
+ * @remarks    this API need both privileges
+ * @param[in]  account_db_id  The account ID to delete
  *
- * @return     0 on success, otherwise a negative error value.
- * @retval     #ACCOUNT_ERROR_NONE Successful
- * @retval     #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter
- * @retval     #ACCOUNT_ERROR_DB_FAILED  Database operation failed
- * @retval     #ACCOUNT_ERROR_RECORD_NOT_FOUND  The account to update not exist
+ * @return  @c 0 on success,
+ *          otherwise a negative error value
+ * @retval  #ACCOUNT_ERROR_NONE               Successful
+ * @retval  #ACCOUNT_ERROR_INVALID_PARAMETER  Invalid parameter
+ * @retval  #ACCOUNT_ERROR_DB_FAILED          Database operation failed
+ * @retval  #ACCOUNT_ERROR_PERMISSION_DENIED  The account owner is different from the caller or DB Access fail by permission
  *
- * @pre        This function requires an open connection to account service by account_connect()
+ * @pre  This function requires an open connection to an account service by account_connect().
  *
  * @see account_connect()
  * @see account_insert_to_db()
- * @see account_delete_from_db_by_id()
  * @see account_delete_from_db_by_user_name()
  * @see account_delete_from_db_by_package_name()
+ * @see account_update_to_db_by_id()
  * @see account_update_to_db_by_user_name()
  */
-ACCOUNT_API int account_update_to_db_by_id_ex(account_h account, int account_id);
+ACCOUNT_API int account_delete_from_db_by_id(int account_db_id);
 
 
 /**
- * @brief      Deletes the account from the account database by accound DB ID.
+ * @brief  Deletes an account from the account database by user name.
  *
- * @param[in]  account_db_id The account ID to delete
+ * @since_tizen 2.3
+ * @privlevel  public
+ * @privilege  %http://tizen.org/privilege/account.read \n
+ *             %http://tizen.org/privilege/account.write
+ * @remarks    this API need both privileges
+ * @param[in]  user_name     The user name of the account to delete
+ * @param[in]  package_name  The package name of the account to delete
  *
- * @return     0 on success, otherwise a negative error value.
- * @retval     #ACCOUNT_ERROR_NONE Successful
- * @retval     #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter
- * @retval     #ACCOUNT_ERROR_DB_FAILED  Database operation failed
- * @retval     #ACCOUNT_ERROR_PERMISSION_DENIED  the account owner is different from caller
+ * @return  @c 0 on success,
+ *          otherwise a negative error value
+ * @retval  #ACCOUNT_ERROR_NONE               Successful
+ * @retval  #ACCOUNT_ERROR_INVALID_PARAMETER  Invalid parameter
+ * @retval  #ACCOUNT_ERROR_DB_FAILED          Database operation failed
+ * @retval  #ACCOUNT_ERROR_PERMISSION_DENIED  DB Access fail by permission
  *
- * @pre        This function requires an open connection to account service by account_connect()
+ * @pre  This function requires an open connection to an account service by account_connect().
  *
  * @see account_connect()
  * @see account_insert_to_db()
- * @see account_delete_from_db_by_user_name()
+ * @see account_delete_from_db_by_id()
  * @see account_delete_from_db_by_package_name()
  * @see account_update_to_db_by_id()
  * @see account_update_to_db_by_user_name()
  */
-ACCOUNT_API int account_delete_from_db_by_id(int account_db_id);
+ACCOUNT_API int account_delete_from_db_by_user_name(char *user_name, char *package_name);
 
 
 /**
- * @brief      Deletes the account from the account database by user name.
+ * @brief  Deletes an account from the account database by package name.
  *
- * @param[in]  user_name The user name of account to delete
- * @param[in]  package_name The package name of account to delete
+ * @since_tizen 2.3
+ * @privlevel  public
+ * @privilege  %http://tizen.org/privilege/account.read \n
+ *             %http://tizen.org/privilege/account.write
+ * @remarks    this API need both privileges
+ * @param[in]  package_name  The package name of account(s) to delete
  *
- * @return     0 on success, otherwise a negative error value.
- * @retval     #ACCOUNT_ERROR_NONE Successful
- * @retval     #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter
- * @retval     #ACCOUNT_ERROR_DB_FAILED  Database operation failed
+ * @return  @c 0 on success,
+ *          otherwise a negative error value
+ * @retval  #ACCOUNT_ERROR_NONE               Successful
+ * @retval  #ACCOUNT_ERROR_INVALID_PARAMETER  Invalid parameter
+ * @retval  #ACCOUNT_ERROR_DB_FAILED          Database operation failed
+ * @retval  #ACCOUNT_ERROR_PERMISSION_DENIED  DB Access fail by permission
  *
- * @pre        This function requires an open connection to account service by account_connect()
+ * @pre  This function requires an open connection to an account service by account_connect().
  *
  * @see account_connect()
  * @see account_insert_to_db()
  * @see account_delete_from_db_by_id()
- * @see account_delete_from_db_by_package_name()
+ * @see account_delete_from_db_by_user_name()
  * @see account_update_to_db_by_id()
  * @see account_update_to_db_by_user_name()
  */
-ACCOUNT_API int account_delete_from_db_by_user_name(char *user_name, char *package_name);
+ACCOUNT_API int account_delete_from_db_by_package_name(const char *package_name);
 
 
 /**
- * @brief      Deletes the account from the account database by package name.
+ * @brief  Updates the account details to the account database.
  *
- * @param[in]  package_name The package name of account(s) to delete
+ * @since_tizen 2.3
+ * @privlevel  public
+ * @privilege  %http://tizen.org/privilege/account.read \n
+ *             %http://tizen.org/privilege/account.write
+ * @remarks    this API need both privileges
+ * @param[in]  account     The account handle
+ * @param[in]  account_id  The account ID to update
  *
- * @return     0 on success, otherwise a negative error value.
- * @retval     #ACCOUNT_ERROR_NONE Successful
- * @retval     #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter
- * @retval     #ACCOUNT_ERROR_DB_FAILED  Database operation failed
+ * @return  @c 0 on success,
+ *          otherwise a negative error value
+ * @retval  #ACCOUNT_ERROR_NONE               Successful
+ * @retval  #ACCOUNT_ERROR_INVALID_PARAMETER  Invalid parameter
+ * @retval  #ACCOUNT_ERROR_DB_FAILED          Database operation failed
+ * @retval  #ACCOUNT_ERROR_RECORD_NOT_FOUND   The account to update does not exist
+ * @retval  #ACCOUNT_ERROR_PERMISSION_DENIED  DB Access fail by permission
  *
- * @pre        This function requires an open connection to account service by account_connect()
+ * @pre  This function requires an open connection to an account service by account_connect().
  *
  * @see account_connect()
  * @see account_insert_to_db()
  * @see account_delete_from_db_by_id()
  * @see account_delete_from_db_by_user_name()
- * @see account_update_to_db_by_id()
+ * @see account_delete_from_db_by_package_name()
  * @see account_update_to_db_by_user_name()
  */
-ACCOUNT_API int account_delete_from_db_by_package_name(const char *package_name);
+ACCOUNT_API int account_update_to_db_by_id(account_h account, int account_id);
 
 
 /**
- * @brief      Updates the account details to the account database.
+ * @brief  Updates the account details to the account database without checking provider's permission.
  *
- * @param[in]  account The account handle
- * @param[in]  account_id The account ID to update
+ * @since_tizen 2.3
+ * @privlevel  public
+ * @privilege  %http://tizen.org/privilege/account.read \n
+ *             %http://tizen.org/privilege/account.write
+ * @remarks    this API need both privileges
+ * @param[in]  account     The account handle
+ * @param[in]  account_id  The account ID to update
  *
- * @return     0 on success, otherwise a negative error value.
- * @retval     #ACCOUNT_ERROR_NONE Successful
- * @retval     #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter
- * @retval     #ACCOUNT_ERROR_DB_FAILED  Database operation failed
- * @retval     #ACCOUNT_ERROR_RECORD_NOT_FOUND  The account to update not exist
+ * @return  @c 0 on success,
+ *          otherwise a negative error value
+ * @retval  #ACCOUNT_ERROR_NONE               Successful
+ * @retval  #ACCOUNT_ERROR_INVALID_PARAMETER  Invalid parameter
+ * @retval  #ACCOUNT_ERROR_DB_FAILED          Database operation failed
+ * @retval  #ACCOUNT_ERROR_RECORD_NOT_FOUND   The account to update does not exist
+ * @retval  #ACCOUNT_ERROR_PERMISSION_DENIED  DB Access fail by permission
  *
- * @pre        This function requires an open connection to account service by account_connect()
+ * @pre  This function requires an open connection to an account service by account_connect().
  *
  * @see account_connect()
  * @see account_insert_to_db()
@@ -294,23 +441,29 @@ ACCOUNT_API int account_delete_from_db_by_package_name(const char *package_name)
  * @see account_delete_from_db_by_package_name()
  * @see account_update_to_db_by_user_name()
  */
-ACCOUNT_API int account_update_to_db_by_id(account_h account, int account_id);
-
+ACCOUNT_API int account_update_to_db_by_id_ex(account_h account, int account_id);
 
 /**
- * @brief      Updates the account details to the account database.
+ * @brief  Updates the account details to the account database.
  *
- * @param[in]  account The account handle
- * @param[in]  user_name The user name of account to update
- * @param[in]  package_name The package name for the user name
+ * @since_tizen 2.3
+ * @privlevel  public
+ * @privilege  %http://tizen.org/privilege/account.read \n
+ *             %http://tizen.org/privilege/account.write
+ * @remarks    this API need both privileges
+ * @param[in]  account       The account handle
+ * @param[in]  user_name     The user name of the account to update
+ * @param[in]  package_name  The package name for the user name
  *
- * @return     0 on success, otherwise a negative error value.
- * @retval     #ACCOUNT_ERROR_NONE Successful
- * @retval     #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter
- * @retval     #ACCOUNT_ERROR_DB_FAILED  Database operation failed
- * @retval     #ACCOUNT_ERROR_RECORD_NOT_FOUND  The account to update not exist
+ * @return  @c 0 on success,
+ *          otherwise a negative error value
+ * @retval  #ACCOUNT_ERROR_NONE               Successful
+ * @retval  #ACCOUNT_ERROR_INVALID_PARAMETER  Invalid parameter
+ * @retval  #ACCOUNT_ERROR_DB_FAILED          Database operation failed
+ * @retval  #ACCOUNT_ERROR_RECORD_NOT_FOUND   The account to update does not exist
+ * @retval  #ACCOUNT_ERROR_PERMISSION_DENIED  DB Access fail by permission
  *
- * @pre        This function requires an open connection to account service by account_connect()
+ * @pre  This function requires an open connection to an account service by account_connect().
  *
  * @see account_connect()
  * @see account_insert_to_db()
@@ -323,32 +476,34 @@ ACCOUNT_API int account_update_to_db_by_id(account_h account, int account_id);
 ACCOUNT_API int account_update_to_db_by_user_name(account_h account, const char *user_name, const char *package_name);
 
 /**
- * @brief      Gets the account id of account.
- *
+ * @brief  Gets the ID of an account.
  *
- * @param[in]  account The account handle
- * @param[out] account_id The account id of account
+ * @since_tizen 2.3
+ * @param[in]   account     The account handle
+ * @param[out]  account_id  The account ID
  *
- * @return     0 on success, otherwise a negative error value.
- * @retval     #ACCOUNT_ERROR_NONE Successful
- * @retval     #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter
+ * @return  @c 0 on success,
+ *          otherwise a negative error value
+ * @retval  #ACCOUNT_ERROR_NONE               Successful
+ * @retval  #ACCOUNT_ERROR_INVALID_PARAMETER  Invalid parameter
  *
  */
 ACCOUNT_API int account_get_account_id(account_h account, int *account_id);
 
-
 /**
- * @brief      Gets the user name of account.
+ * @brief  Gets the user name of an account.
  *
- * @remarks    @a user_name must be released with free() by you.
+ * @since_tizen 2.3
+ * @remarks    You must release @a user_name using free().
  *
- * @param[in]  account The account handle
- * @param[out] user_name The user name of account
+ * @param[in]   account    The account handle
+ * @param[out]  user_name  The user name of the account
  *
- * @return     0 on success, otherwise a negative error value.
- * @retval     #ACCOUNT_ERROR_NONE Successful
- * @retval     #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter
- * @retval     #ACCOUNT_ERROR_OUT_OF_MEMORY Out of memory
+ * @return  @c 0 on success,
+ *          otherwise a negative error value
+ * @retval  #ACCOUNT_ERROR_NONE               Successful
+ * @retval  #ACCOUNT_ERROR_INVALID_PARAMETER  Invalid parameter
+ * @retval  #ACCOUNT_ERROR_OUT_OF_MEMORY      Out of memory
  *
  * @see account_set_user_name()
  */
@@ -356,14 +511,16 @@ ACCOUNT_API int account_get_user_name(account_h account, char **user_name);
 
 
 /**
- * @brief      Sets the user name of account.
+ * @brief  Sets the user name of an account.
  *
- * @param[in]  account The account handle
- * @param[in]  user_name The string to set as user name
+ * @since_tizen 2.3
+ * @param[in]  account    The account handle
+ * @param[in]  user_name  The string to set as user name
  *
- * @return     0 on success, otherwise a negative error value.
- * @retval     #ACCOUNT_ERROR_NONE Successful
- * @retval     #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter
+ * @return  @c 0 on success,
+ *          otherwise a negative error value
+ * @retval  #ACCOUNT_ERROR_NONE               Successful
+ * @retval  #ACCOUNT_ERROR_INVALID_PARAMETER  Invalid parameter
  *
  * @see account_get_user_name()
  */
@@ -371,17 +528,19 @@ ACCOUNT_API int account_set_user_name(account_h account, const char *user_name);
 
 
 /**
- * @brief      Gets the display name of account.
+ * @brief  Gets the display name of an account.
  *
- * @remarks    @a display_name must be released with free() by you.
+ * @since_tizen 2.3
+ * @remarks    You must release @a display_name using free().
  *
- * @param[in]  account The account handle
- * @param[out] display_name The display name of account
+ * @param[in]   account       The account handle
+ * @param[out]  display_name  The display name of the account
  *
- * @return     0 on success, otherwise a negative error value.
- * @retval     #ACCOUNT_ERROR_NONE Successful
- * @retval     #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter
- * @retval     #ACCOUNT_ERROR_OUT_OF_MEMORY Out of memory
+ * @return  @c 0 on success,
+ *          otherwise a negative error value
+ * @retval  #ACCOUNT_ERROR_NONE               Successful
+ * @retval  #ACCOUNT_ERROR_INVALID_PARAMETER  Invalid parameter
+ * @retval  #ACCOUNT_ERROR_OUT_OF_MEMORY      Out of memory
  *
  * @see account_get_display_name()
  */
@@ -389,60 +548,68 @@ ACCOUNT_API int account_get_display_name(account_h account, char **display_name)
 
 
 /**
- * @brief      Sets the display name of account.
+ * @brief  Sets the display name of an account.
  *
- * @param[in]  account The account handle
- * @param[in]  display_name The text string to set as the display name
+ * @since_tizen 2.3
+ * @param[in]  account      The account handle
+ * @param[in]  display_name The text string to set as the display name
  *
- * @return     0 on success, otherwise a negative error value.
- * @retval     #ACCOUNT_ERROR_NONE Successful
- * @retval     #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter
+ * @return  @c 0 on success,
+ *          otherwise a negative error value
+ * @retval  #ACCOUNT_ERROR_NONE               Successful
+ * @retval  #ACCOUNT_ERROR_INVALID_PARAMETER  Invalid parameter
  *
  * @see account_get_display_name()
  */
 ACCOUNT_API int account_set_display_name(account_h account, const char *display_name);
 
 /**
- * @brief      Gets the capability detail of account.
+ * @brief  Gets the capability detail of an account.
  *
- * @param[in]  account The account handle
- * @param[in]  capability_type Capability type to get the capability value
- * @param[out] capability_value Corresponding capability value(on/off) of the specified capability_type
+ * @since_tizen 2.3
+ * @param[in]   account           The account handle
+ * @param[in]   capability_type   The capability type to get the capability value
+ * @param[out]  capability_value  The capability value (on/off) of the specified capability_type
  *
- * @return     0 on success, otherwise a negative error value.
- * @retval     #ACCOUNT_ERROR_NONE Successful
- * @retval     #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter
- * @retval     #ACCOUNT_ERROR_RECORD_NOT_FOUND There is no given capability_type in the account
+ * @return  @c 0 on success,
+ *          otherwise a negative error value
+ * @retval  #ACCOUNT_ERROR_NONE               Successful
+ * @retval  #ACCOUNT_ERROR_INVALID_PARAMETER  Invalid parameter
+ * @retval  #ACCOUNT_ERROR_RECORD_NOT_FOUND   There is no given capability_type in the account
  *
  * @see account_set_capability()
  */
 ACCOUNT_API int account_get_capability(account_h account, const char* capability_type, account_capability_state_e* capability_value);
 
 /**
- * @brief      Gets all the capabilities of account.
+ * @brief  Gets all the capabilities of an account.
  *
- * @param[in]  account The account handle
- * @param[in]  callback The callback function
- * @param[in]  user_data The user data to be passed to the callback function
+ * @since_tizen 2.3
+ * @param[in]  account    The account handle
+ * @param[in]  callback   The callback function
+ * @param[in]  user_data  The user data to be passed to the callback function
  *
- * @return     0 on success, otherwise a negative error value.
- * @retval     #ACCOUNT_ERROR_NONE Successful
- * @retval     #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter
+ * @return  @c 0 on success,
+ *          otherwise a negative error value
+ * @retval  #ACCOUNT_ERROR_NONE               Successful
+ * @retval  #ACCOUNT_ERROR_INVALID_PARAMETER  Invalid parameter
  *
  * @see account_set_capability()
  */
-ACCOUNT_API int account_get_capability_all(account_h account, capability_cb cb_func, void *user_data);
+ACCOUNT_API int account_get_capability_all(account_h account, capability_cb callback, void *user_data);
 
 /**
- * @brief      Sets the capability.
+ * @brief  Sets the capability.
  *
- * @param[in]  account The account handle
- * @param[in]  capability_type The capability type
- * @param[in]  capability_state The capability state
+ * @since_tizen 2.3
+ * @param[in]  account           The account handle
+ * @param[in]  capability_type   The capability type
+ * @param[in]  capability_state  The capability state
  *
- * @return     0 on success, otherwise a negative error value.
- * @retval     #ACCOUNT_ERROR_NONE Successful
- * @retval     #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter
+ * @return  @c 0 on success,
+ *          otherwise a negative error value
+ * @retval  #ACCOUNT_ERROR_NONE               Successful
+ * @retval  #ACCOUNT_ERROR_INVALID_PARAMETER  Invalid parameter
  *
  * @see account_get_capability()
  */
@@ -450,17 +617,19 @@ ACCOUNT_API int account_set_capability(account_h account, const char* capability
 
 
 /**
- * @brief      Gets the icon path.
+ * @brief  Gets the icon path.
  *
- * @remarks    @a icon_path must be released with free() by you.
+ * @since_tizen 2.3
+ * @remarks    You must release @a icon_path using free().
  *
- * @param[in]  account The account handle
- * @param[out] icon_path The icon path
+ * @param[in]   account    The account handle
+ * @param[out]  icon_path  The icon path
  *
- * @return     0 on success, otherwise a negative error value.
- * @retval     #ACCOUNT_ERROR_NONE Successful
- * @retval     #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter
- * @retval     #ACCOUNT_ERROR_OUT_OF_MEMORY Out of memory
+ * @return  @c 0 on success,
+ *          otherwise a negative error value
+ * @retval  #ACCOUNT_ERROR_NONE               Successful
+ * @retval  #ACCOUNT_ERROR_INVALID_PARAMETER  Invalid parameter
+ * @retval  #ACCOUNT_ERROR_OUT_OF_MEMORY      Out of memory
  *
  * @see account_set_icon_path()
  */
@@ -468,14 +637,16 @@ ACCOUNT_API int account_get_icon_path(account_h account, char **icon_path);
 
 
 /**
- * @brief      Sets the icon path.
+ * @brief  Sets the icon path.
  *
- * @param[in]  account The account handle
- * @param[in]  icon_path The text string to set as a icon path
+ * @since_tizen 2.3
+ * @param[in]  account    The account handle
+ * @param[in]  icon_path  The text string to set as the icon path
  *
- * @return     0 on success, otherwise a negative error value.
- * @retval     #ACCOUNT_ERROR_NONE Successful
- * @retval     #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter
+ * @return  @c 0 on success,
+ *          otherwise a negative error value
+ * @retval  #ACCOUNT_ERROR_NONE               Successful
+ * @retval  #ACCOUNT_ERROR_INVALID_PARAMETER  Invalid parameter
  *
  * @see account_get_icon_path()
  */
@@ -483,17 +654,19 @@ ACCOUNT_API int account_set_icon_path(account_h account, const char *icon_path);
 
 
 /**
- * @brief      Gets the domain name.
+ * @brief  Gets the domain name.
  *
- * @remarks    @a domain_name must be released with free() by you.
+ * @since_tizen 2.3
+ * @remarks    You must release @a domain_name using free().
  *
- * @param[in]  account The account handle
- * @param[out] domain_name The domain name
+ * @param[in]   account      The account handle
+ * @param[out]  domain_name  The domain name
  *
- * @return     0 on success, otherwise a negative error value.
- * @retval     #ACCOUNT_ERROR_NONE Successful
- * @retval     #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter
- * @retval     #ACCOUNT_ERROR_OUT_OF_MEMORY Out of memory
+ * @return  @c 0 on success,
+ *          otherwise a negative error value
+ * @retval  #ACCOUNT_ERROR_NONE               Successful
+ * @retval  #ACCOUNT_ERROR_INVALID_PARAMETER  Invalid parameter
+ * @retval  #ACCOUNT_ERROR_OUT_OF_MEMORY      Out of memory
  *
  * @see account_set_domain_name()
  */
@@ -501,14 +674,16 @@ ACCOUNT_API int account_get_domain_name(account_h account, char **domain_name);
 
 
 /**
- * @brief      Sets the domain name.
+ * @brief  Sets the domain name.
  *
- * @param[in]  account The account handle
- * @param[in]  domain_name The text string to set as a domain name
+ * @since_tizen 2.3
+ * @param[in]  account      The account handle
+ * @param[in]  domain_name  The text string to set as the domain name
  *
- * @return     0 on success, otherwise a negative error value.
- * @retval     #ACCOUNT_ERROR_NONE Successful
- * @retval     #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter
+ * @return  @c 0 on success,
+ *          otherwise a negative error value
+ * @retval  #ACCOUNT_ERROR_NONE               Successful
+ * @retval  #ACCOUNT_ERROR_INVALID_PARAMETER  Invalid parameter
  *
  * @see account_get_domain_name()
  */
@@ -516,17 +691,19 @@ ACCOUNT_API int account_set_domain_name(account_h account, const char *domain_na
 
 
 /**
- * @brief      Gets the email address.
+ * @brief  Gets the email address.
  *
- * @remarks    @a email_address must be released with free() by you.
+ * @since_tizen 2.3
+ * @remarks    You must release @a email_address using free().
  *
- * @param[in]  account The account handle
- * @param[out] email_address The email address
+ * @param[in]   account        The account handle
+ * @param[out]  email_address  The email address
  *
- * @return     0 on success, otherwise a negative error value.
- * @retval     #ACCOUNT_ERROR_NONE Successful
- * @retval     #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter
- * @retval     #ACCOUNT_ERROR_OUT_OF_MEMORY Out of memory
+ * @return  @c 0 on success,
+ *          otherwise a negative error value
+ * @retval  #ACCOUNT_ERROR_NONE               Successful
+ * @retval  #ACCOUNT_ERROR_INVALID_PARAMETER  Invalid parameter
+ * @retval  #ACCOUNT_ERROR_OUT_OF_MEMORY      Out of memory
  *
  * @see account_set_email_address()
  */
@@ -534,32 +711,36 @@ ACCOUNT_API int account_get_email_address(account_h account, char **email_addres
 
 
 /**
- * @brief      Sets the email address.
+ * @brief  Sets the email address.
  *
- * @param[in]  account The account handle
- * @param[in]  email_address The text string to set as a email address
+ * @since_tizen 2.3
+ * @param[in]  account        The account handle
+ * @param[in]  email_address  The text string to set as the email address
  *
- * @return     0 on success, otherwise a negative error value.
- * @retval     #ACCOUNT_ERROR_NONE Successful
- * @retval     #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter
+ * @return  @c 0 on success,
+ *          otherwise a negative error value
+ * @retval  #ACCOUNT_ERROR_NONE               Successful
+ * @retval  #ACCOUNT_ERROR_INVALID_PARAMETER  Invalid parameter
  *
- * @see account_get_email_addres()
+ * @see account_get_email_address()
  */
 ACCOUNT_API int account_set_email_address(account_h account, const char *email_address);
 
 
 /**
- * @brief      Gets the package name.
+ * @brief  Gets the package name.
  *
- * @remarks    @a package_name must be released with free() by you.
+ * @since_tizen 2.3
+ * @remarks    You must release @a package_name using free().
  *
- * @param[in]  account The account handle
- * @param[out] package_name The package name
+ * @param[in]   account       The account handle
+ * @param[out]  package_name  The package name
  *
- * @return     0 on success, otherwise a negative error value.
- * @retval     #ACCOUNT_ERROR_NONE Successful
- * @retval     #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter
- * @retval     #ACCOUNT_ERROR_OUT_OF_MEMORY Out of memory
+ * @return  @c 0 on success,
+ *          otherwise a negative error value
+ * @retval  #ACCOUNT_ERROR_NONE               Successful
+ * @retval  #ACCOUNT_ERROR_INVALID_PARAMETER  Invalid parameter
+ * @retval  #ACCOUNT_ERROR_OUT_OF_MEMORY      Out of memory
  *
  * @see account_set_package_name()
  */
@@ -567,32 +748,36 @@ ACCOUNT_API int account_get_package_name(account_h account, char **package_name)
 
 
 /**
- * @brief      Sets the package name.
+ * @brief  Sets the package name.
  *
- * @param[in]  account The account handle
- * @param[in]  package_name The text string to set as a package name
+ * @since_tizen 2.3
+ * @param[in]  account       The account handle
+ * @param[in]  package_name  The text string to set as the package name
  *
- * @return     0 on success, otherwise a negative error value.
- * @retval     #ACCOUNT_ERROR_NONE Successful
- * @retval     #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter
+ * @return  @c 0 on success,
+ *          otherwise a negative error value
+ * @retval  #ACCOUNT_ERROR_NONE               Successful
+ * @retval  #ACCOUNT_ERROR_INVALID_PARAMETER  Invalid parameter
  *
- * @see account_get_email_addres()
+ * @see account_get_email_address()
  */
 ACCOUNT_API int account_set_package_name(account_h account, const char *package_name);
 
 
 /**
- * @brief      Gets the access token.
+ * @brief  Gets the access token.
  *
- * @remarks    @a access_token must be released with free() by you.
+ * @since_tizen 2.3
+ * @remarks    You must release @a access_token using free().
  *
- * @param[in]  account The account handle
- * @param[out] access_token The access token
+ * @param[in]   account       The account handle
+ * @param[out]  access_token  The access token
  *
- * @return     0 on success, otherwise a negative error value.
- * @retval     #ACCOUNT_ERROR_NONE Successful
- * @retval     #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter
- * @retval     #ACCOUNT_ERROR_OUT_OF_MEMORY Out of memory
+ * @return  @c 0 on success,
+ *          otherwise a negative error value
+ * @retval  #ACCOUNT_ERROR_NONE               Successful
+ * @retval  #ACCOUNT_ERROR_INVALID_PARAMETER  Invalid parameter
+ * @retval  #ACCOUNT_ERROR_OUT_OF_MEMORY      Out of memory
  *
  * @see account_set_access_token()
  */
@@ -600,14 +785,16 @@ ACCOUNT_API int account_get_access_token(account_h account, char **access_token)
 
 
 /**
- * @brief      Set the access token.
+ * @brief  Sets the access token.
  *
- * @param[in]  account The account handle
- * @param[in]  access_token The text string to set as a access token
+ * @since_tizen 2.3
+ * @param[in]  account       The account handle
+ * @param[in]  access_token  The text string to set as the access token
  *
- * @return     0 on success, otherwise a negative error value.
- * @retval     #ACCOUNT_ERROR_NONE Successful
- * @retval     #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter
+ * @return  @c 0 on success,
+ *          otherwise a negative error value
+ * @retval  #ACCOUNT_ERROR_NONE               Successful
+ * @retval  #ACCOUNT_ERROR_INVALID_PARAMETER  Invalid parameter
  *
  * @see account_get_access_token()
  */
@@ -615,18 +802,20 @@ ACCOUNT_API int account_set_access_token(account_h account, const char *access_t
 
 
 /**
- * @brief      Gets the user text.
+ * @brief  Gets the user text.
  *
- * @remarks    @a user_text must be released with free() by you.
+ * @since_tizen 2.3
+ * @remarks    You must release @a user_text using free().
  *
- * @param[in]  account The account handle
- * @param[in]  user_text_index The index of the user text (range: 0 ~ 4)
- * @param[out] user_text The user text
+ * @param[in]   account          The account handle
+ * @param[in]   user_text_index  The index of the user text (range: 0 ~ 4)
+ * @param[out]  user_text        The user text
  *
- * @return     0 on success, otherwise a negative error value.
- * @retval     #ACCOUNT_ERROR_NONE Successful
- * @retval     #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter
- * @retval     #ACCOUNT_ERROR_OUT_OF_MEMORY Out of memory
+ * @return  @c 0 on success,
+ *          otherwise a negative error value
+ * @retval  #ACCOUNT_ERROR_NONE               Successful
+ * @retval  #ACCOUNT_ERROR_INVALID_PARAMETER  Invalid parameter
+ * @retval  #ACCOUNT_ERROR_OUT_OF_MEMORY      Out of memory
  *
  * @see account_set_user_text()
  */
@@ -634,15 +823,17 @@ ACCOUNT_API int account_get_user_text(account_h account, int user_text_index, ch
 
 
 /**
- * @brief      Sets the user text.
+ * @brief  Sets the user text.
  *
- * @param[in]  account The account handle
- * @param[in]  user_text_index The index of the user text (must be in range from 0 to 4)
- * @param[in]  user_text The text string to set as a user txt
+ * @since_tizen 2.3
+ * @param[in]  account          The account handle
+ * @param[in]  user_text_index  The index of the user text (must be in range from @c 0 to @c 4)
+ * @param[in]  user_text        The text string to set as the user text
  *
- * @return     0 on success, otherwise a negative error value.
- * @retval     #ACCOUNT_ERROR_NONE Successful
- * @retval     #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter
+ * @return  @c 0 on success,
+ *          otherwise a negative error value
+ * @retval  #ACCOUNT_ERROR_NONE               Successful
+ * @retval  #ACCOUNT_ERROR_INVALID_PARAMETER  Invalid parameter
  *
  * @see account_get_user_text()
  */
@@ -650,15 +841,17 @@ ACCOUNT_API int account_set_user_text(account_h account, int user_text_index, co
 
 
 /**
- * @brief      Gets the user integer.
+ * @brief  Gets the user integer.
  *
- * @param[in]  account The account handle
- * @param[in]  user_int_index The index of the user integer (must be in range from 0 to 4)
- * @param[out] user_integer The user interger
+ * @since_tizen 2.3
+ * @param[in]   account         The account handle
+ * @param[in]   user_int_index  The index of the user integer (must be in range from @c 0 to @c 4)
+ * @param[out]  user_integer    The user integer
  *
- * @return     0 on success, otherwise a negative error value.
- * @retval     #ACCOUNT_ERROR_NONE Successful
- * @retval     #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter
+ * @return  @c 0 on success,
+ *          otherwise a negative error value
+ * @retval  #ACCOUNT_ERROR_NONE               Successful
+ * @retval  #ACCOUNT_ERROR_INVALID_PARAMETER  Invalid parameter
  *
  * @see account_set_user_int()
  */
@@ -666,15 +859,17 @@ ACCOUNT_API int account_get_user_int(account_h account, int user_int_index, int
 
 
 /**
- * @brief      Set the user integer.
+ * @brief  Sets the user integer.
  *
- * @param[in]  account The account handle
- * @param[in]  user_int_index The index of the user integer (must be in range from 0 to 4)
- * @param[in]  user_integer The integer to set as user integer
+ * @since_tizen 2.3
+ * @param[in]  account         The account handle
+ * @param[in]  user_int_index  The index of the user integer (must be in range from @c 0 to @c 4)
+ * @param[in]  user_integer    The integer to set as the user integer
  *
- * @return     0 on success, otherwise a negative error value.
- * @retval     #ACCOUNT_ERROR_NONE Successful
- * @retval     #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter
+ * @return  @c 0 on success,
+ *          otherwise a negative error value
+ * @retval  #ACCOUNT_ERROR_NONE               Successful
+ * @retval  #ACCOUNT_ERROR_INVALID_PARAMETER  Invalid parameter
  *
  * @see account_get_user_int()
  */
@@ -682,14 +877,16 @@ ACCOUNT_API int account_set_user_int(account_h account, int user_int_index, int
 
 
 /**
- * @brief      Gets the auth type.
+ * @brief  Gets the auth type.
  *
- * @param[in]  account The account handle
- * @param[out] auth_type The auth type
+ * @since_tizen 2.3
+ * @param[in]   account    The account handle
+ * @param[out]  auth_type  The auth type
  *
- * @return     0 on success, otherwise a negative error value.
- * @retval     #ACCOUNT_ERROR_NONE Successful
- * @retval     #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter
+ * @return  @c 0 on success,
+ *          otherwise a negative error value
+ * @retval  #ACCOUNT_ERROR_NONE               Successful
+ * @retval  #ACCOUNT_ERROR_INVALID_PARAMETER  Invalid parameter
  *
  * @see account_set_auth_type()
  */
@@ -697,14 +894,16 @@ ACCOUNT_API int account_get_auth_type(account_h account, account_auth_type_e *au
 
 
 /**
- * @brief      Sets the auth type.
+ * @brief  Sets the auth type.
  *
- * @param[in]  account The account handle
- * @param[in]  auth_type Integer to be set as auth type
+ * @since_tizen 2.3
+ * @param[in]  account    The account handle
+ * @param[in]  auth_type  The integer to be set as the auth type
  *
- * @return     0 on success, otherwise a negative error value.
- * @retval     #ACCOUNT_ERROR_NONE Successful
- * @retval     #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter
+ * @return  @c 0 on success,
+ *          otherwise a negative error value
+ * @retval  #ACCOUNT_ERROR_NONE               Successful
+ * @retval  #ACCOUNT_ERROR_INVALID_PARAMETER  Invalid parameter
  *
  * @see account_get_auth_type()
  */
@@ -712,14 +911,16 @@ ACCOUNT_API int account_set_auth_type(account_h account, const account_auth_type
 
 
 /**
- * @brief      Gets the secret.
+ * @brief  Gets the secret.
  *
- * @param[in]  account The account handle
- * @param[out] secret The secret
+ * @since_tizen 2.3
+ * @param[in]   account  The account handle
+ * @param[out]  secret   The secret
  *
- * @return     0 on success, otherwise a negative error value.
- * @retval     #ACCOUNT_ERROR_NONE Successful
- * @retval     #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter
+ * @return  @c 0 on success,
+ *          otherwise a negative error value
+ * @retval  #ACCOUNT_ERROR_NONE               Successful
+ * @retval  #ACCOUNT_ERROR_INVALID_PARAMETER  Invalid parameter
  *
  * @see account_set_secret()
  */
@@ -727,28 +928,32 @@ ACCOUNT_API int account_get_secret(account_h account, account_secrecy_state_e *s
 
 
 /**
- * @brief      Sets the secret.
+ * @brief  Sets the secret.
  *
- * @param[in]  account The account handle
- * @param[in]  secret Secrecy to be set
+ * @since_tizen 2.3
+ * @param[in]  account  The account handle
+ * @param[in]  secret   The secrecy to be set
  *
- * @return     0 on success, otherwise a negative error value.
- * @retval     #ACCOUNT_ERROR_NONE Successful
- * @retval     #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter
+ * @return  @c 0 on success,
+ *          otherwise a negative error value
+ * @retval  #ACCOUNT_ERROR_NONE               Successful
+ * @retval  #ACCOUNT_ERROR_INVALID_PARAMETER  Invalid parameter
  *
  * @see account_get_secret()
  */
 ACCOUNT_API int account_set_secret(account_h account, const account_secrecy_state_e secret);
 
 /**
- * @brief      Gets the sync support.
+ * @brief  Gets the sync support.
  *
- * @param[in]  account The account handle
- * @param[out] sync_support The sync support
+ * @since_tizen 2.3
+ * @param[in]   account       The account handle
+ * @param[out]  sync_support  The sync support
  *
- * @return     0 on success, otherwise a negative error value.
- * @retval     #ACCOUNT_ERROR_NONE Successful
- * @retval     #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter
+ * @return  @c 0 on success,
+ *          otherwise a negative error value
+ * @retval  #ACCOUNT_ERROR_NONE               Successful
+ * @retval  #ACCOUNT_ERROR_INVALID_PARAMETER  Invalid parameter
  *
  * @see account_set_sync_support()
  */
@@ -756,14 +961,16 @@ ACCOUNT_API int account_get_sync_support(account_h account, account_sync_state_e
 
 
 /**
- * @brief      Sets the sync support.
+ * @brief  Sets the sync support.
  *
- * @param[in]  account The account handle
- * @param[in]  sync_support sync state to be set
+ * @since_tizen 2.3
+ * @param[in]  account       The account handle
+ * @param[in]  sync_support  The sync state to be set
  *
- * @return     0 on success, otherwise a negative error value.
- * @retval     #ACCOUNT_ERROR_NONE Successful
- * @retval     #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter
+ * @return  @c 0 on success,
+ *          otherwise a negative error value
+ * @retval  #ACCOUNT_ERROR_NONE               Successful
+ * @retval  #ACCOUNT_ERROR_INVALID_PARAMETER  Invalid parameter
  *
  * @see account_get_sync_support()
  */
@@ -771,17 +978,19 @@ ACCOUNT_API int account_set_sync_support(account_h account, const account_sync_s
 
 
 /**
- * @brief      Gets the source.
+ * @brief  Gets the source.
  *
- * @remarks    @a user_text must be released with free() by you.
+ * @since_tizen 2.3
+ * @remarks    You must release @a user_text using free().
  *
- * @param[in]  account The account handle
- * @param[out] source The source
+ * @param[in]   account  The account handle
+ * @param[out]  source   The source
  *
- * @return     0 on success, otherwise a negative error value.
- * @retval     #ACCOUNT_ERROR_NONE Successful
- * @retval     #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter
- * @retval     #ACCOUNT_ERROR_OUT_OF_MEMORY Out of memory
+ * @return  @c 0 on success,
+ *          otherwise a negative error value
+ * @retval  #ACCOUNT_ERROR_NONE               Successful
+ * @retval  #ACCOUNT_ERROR_INVALID_PARAMETER  Invalid parameter
+ * @retval  #ACCOUNT_ERROR_OUT_OF_MEMORY      Out of memory
  *
  * @see account_set_source()
  */
@@ -789,45 +998,51 @@ ACCOUNT_API int account_get_source(account_h account, char **source);
 
 
 /**
- * @brief      Sets the source.
+ * @brief  Sets the source.
  *
- * @param[in]  account The account handle
- * @param[in]  source The text string to set as a source
+ * @since_tizen 2.3
+ * @param[in]  account  The account handle
+ * @param[in]  source   The text string to set as the source
  *
- * @return     0 on success, otherwise a negative error value.
- * @retval     #ACCOUNT_ERROR_NONE Successful
- * @retval     #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter
+ * @return  @c 0 on success,
+ *          otherwise a negative error value
+ * @retval  #ACCOUNT_ERROR_NONE               Successful
+ * @retval  #ACCOUNT_ERROR_INVALID_PARAMETER  Invalid parameter
  *
  * @see account_get_source()
  */
 ACCOUNT_API int account_set_source(account_h account, const char *source);
 
 /**
- * @brief      Sets the capability.
+ * @brief  Sets the custom.
  *
- * @param[in]  account The account handle
- * @param[in]  key The user custom key for specific value
- * @param[in]  value The user custom value about the given key
+ * @since_tizen 2.3
+ * @param[in]  account  The account handle
+ * @param[in]  key      The user custom key for the specific value
+ * @param[in]  value    The user custom value about the given key
  *
- * @return     0 on success, otherwise a negative error value.
- * @retval     #ACCOUNT_ERROR_NONE Successful
- * @retval     #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter
+ * @return  @c 0 on success,
+ *          otherwise a negative error value
+ * @retval  #ACCOUNT_ERROR_NONE               Successful
+ * @retval  #ACCOUNT_ERROR_INVALID_PARAMETER  Invalid parameter
  *
  * @see account_get_custom()
  */
 ACCOUNT_API int account_set_custom(account_h account, const char* key, const char* value);
 
 /**
- * @brief      Gets the user specific custom text of account key.
+ * @brief  Gets the user specific custom text of an account key.
  *
- * @param[in]  account The account handle
- * @param[in]  callback The callback function to retreive custom text. The callback function gives key and value
- * @param[out] value text of the given key
+ * @since_tizen 2.3
+ * @param[in]   account   The account handle
+ * @param[in]   key       The key to retrieve custom text
+ * @param[out]  value     The text of the given key
  *
- * @return     0 on success, otherwise a negative error value.
- * @retval     #ACCOUNT_ERROR_NONE Successful
- * @retval     #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter
- * @retval     #ACCOUNT_ERROR_RECORD_NOT_FOUND There is no given capability_type in the account
+ * @return  @c 0 on success, 
+ *          otherwise a negative error value
+ * @retval  #ACCOUNT_ERROR_NONE               Successful
+ * @retval  #ACCOUNT_ERROR_INVALID_PARAMETER  Invalid parameter
+ * @retval  #ACCOUNT_ERROR_RECORD_NOT_FOUND   There is no given capability type in the account
  *
  * @see account_set_custom()
  */
@@ -835,33 +1050,42 @@ ACCOUNT_API int account_get_custom(account_h account, const char* key, char** va
 
 
 /**
- * @brief      Gets all the user custom texts of account.
+ * @brief  Gets all the user custom texts of an account.
  *
- * @param[in]  account The account handle
- * @param[in]  callback The callback function to retreive all custom text. The callback function gives key and value
- * @param[in]  user_data The user data to be passed to the callback function
+ * @since_tizen 2.3
+ * @param[in]  account    The account handle
+ * @param[in]  callback   The callback function to retrieve all custom text \n
+ *                        The callback function gives the key and value.
+ * @param[in]  user_data  The user data to be passed to the callback function
  *
- * @return     0 on success, otherwise a negative error value.
- * @retval     #ACCOUNT_ERROR_NONE Successful
- * @retval     #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter
+ * @return  @c 0 on success,
+ *          otherwise a negative error value
+ * @retval  #ACCOUNT_ERROR_NONE               Successful
+ * @retval  #ACCOUNT_ERROR_INVALID_PARAMETER  Invalid parameter
  *
  * @see account_set_custom()
  */
-ACCOUNT_API int account_get_custom_all(account_h account, account_custom_cb cb_func, void* user_data);
+ACCOUNT_API int account_get_custom_all(account_h account, account_custom_cb callback, void* user_data);
 
 /**
- * @brief      Retrieves all accounts details by invoking the given callback function iteratively.
+ * @brief  Retrieves all accounts details by invoking the given callback function iteratively.
  *
- * @param[in]  callback The callback function to invoke
- * @param[in]  user_data The user data to be passed to the callback function
+ * @since_tizen 2.3
+ * @privlevel   public
+ * @privilege   %http://tizen.org/privilege/account.read
+ * @param[in]   callback   The callback function to invoke
+ * @param[in]   user_data  The user data to be passed to the callback function
  *
- * @return     0 on success, otherwise a negative error value.
- * @retval     #ACCOUNT_ERROR_NONE Successful
- * @retval     #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter
- * @retval     #ACCOUNT_ERROR_DB_FAILED Database operation failed
+ * @return  @c 0 on success,
+ *          otherwise a negative error value
+ * @retval  #ACCOUNT_ERROR_NONE               Successful
+ * @retval  #ACCOUNT_ERROR_INVALID_PARAMETER  Invalid parameter
+ * @retval  #ACCOUNT_ERROR_DB_FAILED          Database operation failed
+ * @retval  #ACCOUNT_ERROR_PERMISSION_DENIED  DB Access fail by permission
+ * @retval  #ACCOUNT_ERROR_RECORD_NOT_FOUND   Related record does not exist
  *
- * @pre        This function requires an open connection to account service by account_connect().
- * @post       This function invokes account_cb().
+ * @pre   This function requires an open connection to an account service by account_connect().
+ * @post  This function invokes account_cb().
  *
  * @see account_connect()
  * @see account_query_account_by_account_id()
@@ -873,20 +1097,25 @@ ACCOUNT_API int account_foreach_account_from_db(account_cb callback, void *user_
 
 
 /**
- * @brief      Retrieves all accounts with the account database ID.
+ * @brief  Retrieve an account with the account ID.
  *
- * @param[in]  account_db_id The account database ID to search
- * @param[out] account account handle. Must be allocated by account_create and free after using by account_destroy.
+ * @since_tizen 2.3
+ * @privlevel   public
+ * @privilege   %http://tizen.org/privilege/account.read
+ * @param[in]   account_db_id  The account database ID to search
+ * @param[out]  account        The account handle \n
+ *                             Must be allocated by account_create() and freed after using by account_destroy().
  *
- * @return     0 on success, otherwise a negative error value.
- * @retval     #ACCOUNT_ERROR_NONE Successful
- * @retval     #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter
- * @retval     #ACCOUNT_ERROR_DB_FAILED Database operation failed
+ * @return  @c 0 on success,
+ *          otherwise a negative error value
+ * @retval  #ACCOUNT_ERROR_NONE               Successful
+ * @retval  #ACCOUNT_ERROR_INVALID_PARAMETER  Invalid parameter
+ * @retval  #ACCOUNT_ERROR_DB_FAILED          Database operation failed
+ * @retval  #ACCOUNT_ERROR_PERMISSION_DENIED  DB Access fail by permission
  *
- * @pre        This function requires an open connection to account service by account_connect().
+ * @pre  This function requires an open connection to an account service by account_connect().
  *
  * @see account_connect()
- * @see account_query_account_by_account_id()
  * @see account_query_account_by_user_name()
  * @see account_query_account_by_package_name()
  * @see account_query_account_by_capability()
@@ -894,19 +1123,24 @@ ACCOUNT_API int account_foreach_account_from_db(account_cb callback, void *user_
 ACCOUNT_API int account_query_account_by_account_id(int account_db_id, account_h *account);
 
 /**
- * @brief      Retrieves all accounts with the user name.
+ * @brief  Retrieves all accounts with the user name.
  *
- * @param[in]  callback The callback function to invoke
- * @param[in]  user_name The user name to search
- * @param[in]  user_data The user data to be passed to the callback function
+ * @since_tizen 2.3
+ * @privlevel   public
+ * @privilege   %http://tizen.org/privilege/account.read
+ * @param[in]   callback   The callback function to invoke
+ * @param[in]   user_name  The user name to search
+ * @param[in]   user_data  The user data to be passed to the callback function
  *
- * @return     0 on success, otherwise a negative error value.
- * @retval     #ACCOUNT_ERROR_NONE Successful
- * @retval     #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter
- * @retval     #ACCOUNT_ERROR_DB_FAILED Database operation failed
+ * @return  @c 0 on success,
+ *          otherwise a negative error value
+ * @retval  #ACCOUNT_ERROR_NONE               Successful
+ * @retval  #ACCOUNT_ERROR_INVALID_PARAMETER  Invalid parameter
+ * @retval  #ACCOUNT_ERROR_DB_FAILED          Database operation failed
+ * @retval  #ACCOUNT_ERROR_PERMISSION_DENIED  DB Access fail by permission
  *
- * @pre        This function requires an open connection to account service by account_connect().
- * @post       This function invokes account_cb().
+ * @pre   This function requires an open connection to an account service by account_connect().
+ * @post  This function invokes account_cb().
  *
  * @see account_connect()
  * @see account_foreach_account_from_db()
@@ -918,19 +1152,24 @@ ACCOUNT_API int account_query_account_by_account_id(int account_db_id, account_h
 ACCOUNT_API int account_query_account_by_user_name(account_cb callback, const char* user_name, void* user_data);
 
 /**
- * @brief      Retrieves all accounts with the package name.
+ * @brief  Retrieves all accounts with the package name.
  *
- * @param[in]  callback The callback function to invoke
- * @param[in]  package_name The package name to search
- * @param[in]  user_data The user data to be passed to the callback function
+ * @since_tizen 2.3
+ * @privlevel  public
+ * @privilege  %http://tizen.org/privilege/account.read
+ * @param[in]  callback      The callback function to invoke
+ * @param[in]  package_name  The package name to search
+ * @param[in]  user_data     The user data to be passed to the callback function
  *
- * @return     0 on success, otherwise a negative error value.
- * @retval     #ACCOUNT_ERROR_NONE Successful
- * @retval     #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter
- * @retval     #ACCOUNT_ERROR_DB_FAILED Database operation failed
+ * @return  @c 0 on success,
+ *          otherwise a negative error value
+ * @retval  #ACCOUNT_ERROR_NONE               Successful
+ * @retval  #ACCOUNT_ERROR_INVALID_PARAMETER  Invalid parameter
+ * @retval  #ACCOUNT_ERROR_DB_FAILED          Database operation failed
+ * @retval  #ACCOUNT_ERROR_PERMISSION_DENIED  DB Access fail by permission
  *
- * @pre        This function requires an open connection to account service by account_connect().
- * @post       This function invokes account_cb().
+ * @pre   This function requires an open connection to an account service by account_connect().
+ * @post  This function invokes account_cb().
  *
  * @see account_connect()
  * @see account_foreach_account_from_db()
@@ -941,20 +1180,25 @@ ACCOUNT_API int account_query_account_by_user_name(account_cb callback, const ch
 ACCOUNT_API int account_query_account_by_package_name(account_cb callback, const char *package_name, void *user_data);
 
 /**
- * @brief      Retrieves all accounts with the capability type and capability value.
+ * @brief  Retrieves all accounts with the capability type and capability value.
  *
- * @param[in]  callback The callback function to invoke
- * @param[in]  capability_type The capablity type to search
- * @param[in]  capability_value The capablity value to search
- * @param[in]  user_data The user data to be passed to the callback function
+ * @since_tizen 2.3
+ * @privlevel   public
+ * @privilege   %http://tizen.org/privilege/account.read
+ * @param[in]   callback          The callback function to invoke
+ * @param[in]   capability_type   The capability type to search
+ * @param[in]   capability_value  The capability value to search
+ * @param[in]   user_data         The user data to be passed to the callback function
  *
- * @return     0 on success, otherwise a negative error value.
- * @retval     #ACCOUNT_ERROR_NONE Successful
- * @retval     #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter
- * @retval     #ACCOUNT_ERROR_DB_FAILED Database operation failed
+ * @return  @c 0 on success,
+ *          otherwise a negative error value
+ * @retval  #ACCOUNT_ERROR_NONE               Successful
+ * @retval  #ACCOUNT_ERROR_INVALID_PARAMETER  Invalid parameter
+ * @retval  #ACCOUNT_ERROR_DB_FAILED          Database operation failed
+ * @retval  #ACCOUNT_ERROR_PERMISSION_DENIED  DB Access fail by permission
  *
- * @pre This function requires an open connection to account service by account_connect().
- * @post       This function invokes account_cb().
+ * @pre   This function requires an open connection to an account service by account_connect().
+ * @post  This function invokes account_cb().
  *
  * @see account_connect()
  * @see account_foreach_account_from_db()
@@ -965,19 +1209,24 @@ ACCOUNT_API int account_query_account_by_package_name(account_cb callback, const
 ACCOUNT_API int account_query_account_by_capability(account_cb callback, const char* capability_type, account_capability_state_e capability_value, void *user_data);
 
 /**
- * @brief      Retrieves all accounts with the capability type.
+ * @brief  Retrieves all accounts with the capability type.
  *
- * @param[in]  callback The callback function to invoke
- * @param[in]  capability_type The capablity type to search
- * @param[in]  user_data The user data to be passed to the callback function
+ * @since_tizen 2.3
+ * @privlevel   public
+ * @privilege   %http://tizen.org/privilege/account.read
+ * @param[in]   callback         The callback function to invoke
+ * @param[in]   capability_type  The capability type to search
+ * @param[in]   user_data        The user data to be passed to the callback function
  *
- * @return     0 on success, otherwise a negative error value.
- * @retval     #ACCOUNT_ERROR_NONE Successful
- * @retval     #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter
- * @retval     #ACCOUNT_ERROR_DB_FAILED Database operation failed
+ * @return  @c 0 on success,
+ *          otherwise a negative error value
+ * @retval  #ACCOUNT_ERROR_NONE               Successful
+ * @retval  #ACCOUNT_ERROR_INVALID_PARAMETER  Invalid parameter
+ * @retval  #ACCOUNT_ERROR_DB_FAILED          Database operation failed
+ * @retval  #ACCOUNT_ERROR_PERMISSION_DENIED  DB Access fail by permission
  *
- * @pre This function requires an open connection to account service by account_connect().
- * @post       This function invokes account_cb().
+ * @pre   This function requires an open connection to an account service by account_connect().
+ * @post  This function invokes account_cb().
  *
  * @see account_connect()
  * @see account_foreach_account_from_db()
@@ -985,22 +1234,27 @@ ACCOUNT_API int account_query_account_by_capability(account_cb callback, const c
  * @see account_query_account_by_user_name()
  * @see account_query_account_by_package_name()
  */
-ACCOUNT_API int account_query_account_by_capability_type(account_cb cb_func, const char* capability_type, void* user_data);
+ACCOUNT_API int account_query_account_by_capability_type(account_cb callback, const char* capability_type, void* user_data);
 
 /**
- * @brief      Retrieves all capabilities with the account database ID.
+ * @brief  Retrieves all capabilities with the account database ID.
  *
- * @param[in]  callback The callback function to invoke
- * @param[in]  account_db_id The account database ID to search
- * @param[in]  user_data The user data to be passed to the callback function
+ * @since_tizen 2.3
+ * @privlevel   public
+ * @privilege   %http://tizen.org/privilege/account.read
+ * @param[in]   callback       The callback function to invoke
+ * @param[in]   account_db_id  The account database ID to search
+ * @param[in]   user_data      The user data to be passed to the callback function
  *
- * @return     0 on success, otherwise a negative error value.
- * @retval     #ACCOUNT_ERROR_NONE Successful
- * @retval     #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter
- * @retval     #ACCOUNT_ERROR_DB_FAILED Database operation failed
+ * @return  @c 0 on success,
+ *          otherwise a negative error value
+ * @retval  #ACCOUNT_ERROR_NONE               Successful
+ * @retval  #ACCOUNT_ERROR_INVALID_PARAMETER  Invalid parameter
+ * @retval  #ACCOUNT_ERROR_DB_FAILED          Database operation failed
+ * @retval  #ACCOUNT_ERROR_PERMISSION_DENIED  DB Access fail by permission
  *
- * @pre        This function requires an open connection to account service by account_connect().
- * @post       This function invokes capability_cb().
+ * @pre   This function requires an open connection to an account service by account_connect().
+ * @post  This function invokes capability_cb().
  *
  * @see account_connect()
  * @see account_get_capability()
@@ -1010,32 +1264,44 @@ ACCOUNT_API int account_query_capability_by_account_id(capability_cb callback, i
 
 
 /**
- * @brief      Retrieves number of account in the account database.
+ * @brief  Gets the count of accounts in the account database.
  *
- * @param[out] out parameter for number of all accounts
+ * @since_tizen 2.3
+ * @privlevel   public
+ * @privilege   %http://tizen.org/privilege/account.read
+ * @param[out]  count  The out parameter for count of all accounts
  *
- * @return     0 on success, otherwise a negative error value.
- * @retval     #ACCOUNT_ERROR_NONE Successful
- * @retval     #ACCOUNT_ERROR_DB_FAILED Database operation failed
+ * @return  @c 0 on success,
+ *          otherwise a negative error value
+ * @retval  #ACCOUNT_ERROR_NONE               Successful
+ * @retval  #ACCOUNT_ERROR_DB_FAILED          Database operation failed
+ * @retval  #ACCOUNT_ERROR_PERMISSION_DENIED  DB Access fail by permission
  *
- * @pre        This function requires an open connection to account service by account_connect().
+ * @pre  This function requires an open connection to an account service by account_connect().
  *
  * @see account_connect()
  */
 ACCOUNT_API int account_get_total_count_from_db(int *count);
 
 /**
- * @brief      changes sync status of account by account id
+ * @brief  Updates the sync status of an account with the given account ID.
  *
- * @param[in]  account_db_id The account id which sync status needs to be change
- * @param[in]  sync_status New sync status
+ * @since_tizen 2.3
+ * @privlevel   public
+ * @privilege   %http://tizen.org/privilege/account.read \n
+ *              %http://tizen.org/privilege/account.write
+ * @remarks     this API need both privileges
+ * @param[in]   account_db_id  The account ID for which sync status needs to be changed
+ * @param[in]   sync_status    The new sync status
  *
- * @return     0 on success, otherwise a negative error value.
- * @retval     #ACCOUNT_ERROR_NONE Successful
- * @retval     #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter
- * @retval     #ACCOUNT_ERROR_DB_FAILED Database operation failed
+ * @return  @c 0 on success,
+ *          otherwise a negative error value
+ * @retval  #ACCOUNT_ERROR_NONE               Successful
+ * @retval  #ACCOUNT_ERROR_INVALID_PARAMETER  Invalid parameter
+ * @retval  #ACCOUNT_ERROR_DB_FAILED          Database operation failed
+ * @retval  #ACCOUNT_ERROR_PERMISSION_DENIED  DB Access fail by permission
  *
- * @pre        This function requires an open connection to account service by account_connect().
+ * @pre This function requires an open connection to an account service by account_connect().
  *
  * @see account_connect()
  */
@@ -1046,445 +1312,536 @@ ACCOUNT_API int account_update_sync_status_by_id(int account_db_id, const accoun
 
 
 /**
- * @brief      Creates a handle to the account.
+ * @brief  Creates a handle to the account provider.
  *
- * @remarks    @a account type handle must be released with account_type_destroy() by you. \n
- *  The created handle is not added to the account database until account_type_insert_to_db() is called.
+ * @since_tizen 2.3
+ * @remarks     You must release @a account_type handle using account_type_destroy().\n
  *
- * @param[in]  account_type    The account type handle
+ * @param[in]  account_type  The account provider handle
  *
- * @return     0 on success, otherwise a negative error value.
- * @retval     #ACCOUNT_ERROR_NONE Successful
- * @retval     #ACCOUNT_ERROR_OUT_OF_MEMORY Out of Memory
- * @retval     #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter
+ * @return  @c 0 on success,
+ *          otherwise a negative error value
+ * @retval  #ACCOUNT_ERROR_NONE               Successful
+ * @retval  #ACCOUNT_ERROR_OUT_OF_MEMORY      Out of Memory
+ * @retval  #ACCOUNT_ERROR_INVALID_PARAMETER  Invalid parameter
  *
  * @see account_type_destroy()
  */
 ACCOUNT_API int account_type_create(account_type_h *account_type);
 
 /**
- * @brief      Destroys the account type handle and releases all its resources.
- * When you get account_type_h through account_type_create, the handle should be released by account_destroy to avoid memory leak
+ * @brief  Destroys the account provider handle and releases all its resources.
  *
- * @param[in]  account_type    The account type handle
+ * @since_tizen 2.3
  *
- * @return     0 on success, otherwise a negative error value.
- * @retval     #ACCOUNT_ERROR_NONE     Successful
- * @retval     #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter
+ * @remarks    When you get @a account_type_h using account_type_create(), you must release the handle using account_destroy() to avoid the memory leak.
+ *
+ * @param[in]  account_type  The account provider handle
+ *
+ * @return  @c 0 on success,
+ *          otherwise a negative error value
+ * @retval  #ACCOUNT_ERROR_NONE               Successful
+ * @retval  #ACCOUNT_ERROR_INVALID_PARAMETER  Invalid parameter
  *
  * @see account_type_create()
  */
 ACCOUNT_API int account_type_destroy(account_type_h account_type);
 
 /**
- * @brief      Sets the app id. It should be filled with your application id. e.g) com.tizen.testapp
+ * @internal
+ * @brief  Sets the app ID.
+ *         It should be filled with your application ID. For example, com.tizen.testapp.
  *
- * @remarks    @ app id is mandatory field and is not allowed duplicated app id in account type database
+ * @since_tizen 2.3
+ * @remarks     @a app_id is a mandatory field and does not allow duplicate app ID in the account provider database.
  *
- * @param[in]  account_type The account type handle. It should be assigned by account_type_create()
- * @param[in]  app_id Application id of yours.
+ * @param[in]   account_type  The account provider handle \n
+ *                            It should be assigned by account_type_create().
+ * @param[in]   app_id        The application ID
  *
- * @return     0 on success, otherwise a negative error value.
- * @retval     #ACCOUNT_ERROR_NONE Successful
- * @retval     #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter
- * @retval     #ACCOUNT_ERROR_OUT_OF_MEMORY Out of memory
+ * @return  @c 0 on success,
+ *          otherwise a negative error value
+ * @retval  #ACCOUNT_ERROR_NONE               Successful
+ * @retval  #ACCOUNT_ERROR_INVALID_PARAMETER  Invalid parameter
+ * @retval  #ACCOUNT_ERROR_OUT_OF_MEMORY      Out of memory
  *
  * @see account_type_get_app_id()
  */
 ACCOUNT_API int account_type_set_app_id(account_type_h account_type, const char *app_id);
 
 /**
- * @brief      Sets the service provider id. It should be filled with your service provider id.
+ * @internal
+ * @brief  Sets the service provider ID.
+ *         It should be filled with your service provider ID.
  *
- * @remarks    @ service provider id is mandatory field.
+ * @since_tizen 2.3
+ * @remarks    @a service_provider_id is a mandatory field.
  *
- * @param[in]  account_type The account type handle. It should be assigned by account_type_create()
- * @param[in]  service_provider_id Service provider id of yours.
+ * @param[in]  account_type         The account provider handle \n
+ *                                  It should be assigned by account_type_create().
+ * @param[in]  service_provider_id  The service provider ID
  *
- * @return     0 on success, otherwise a negative error value.
- * @retval     #ACCOUNT_ERROR_NONE Successful
- * @retval     #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter
- * @retval     #ACCOUNT_ERROR_OUT_OF_MEMORY Out of memory
+ * @return  @c 0 on success,
+ *          otherwise a negative error value
+ * @retval  #ACCOUNT_ERROR_NONE               Successful
+ * @retval  #ACCOUNT_ERROR_INVALID_PARAMETER  Invalid parameter
+ * @retval  #ACCOUNT_ERROR_OUT_OF_MEMORY      Out of memory
  *
  * @see account_type_get_service_provider_id()
  */
 ACCOUNT_API int account_type_set_service_provider_id(account_type_h account_type, const char *service_provider_id);
 
 /**
- * @brief      Sets icon path. It represents your service provider or application.
+ * @internal
+ * @brief  Sets icon path. 
+ *         It represents your service provider or an application.
  *
- * @remarks    @ icon_path is not mandatory field. But when it is set, you can display this icon in add account screen.
+ * @since_tizen 2.3
+ * @remarks     @a icon_path is not a mandatory field. But when it is set, you can display this icon in the Add Account screen.
  *
- * @param[in]  account_type The account type handle. It should be assigned by account_type_create()
- * @param[in]  icon_path of your application.
+ * @param[in]  account_type  The account provider handle\n
+ *                           It should be assigned by account_type_create().
+ * @param[in]  icon_path     The icon path of the application
  *
- * @return     0 on success, otherwise a negative error value.
- * @retval     #ACCOUNT_ERROR_NONE Successful
- * @retval     #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter
- * @retval     #ACCOUNT_ERROR_OUT_OF_MEMORY Out of memory
+ * @return  @c 0 on success,
+ *          otherwise a negative error value
+ * @retval  #ACCOUNT_ERROR_NONE               Successful
+ * @retval  #ACCOUNT_ERROR_INVALID_PARAMETER  Invalid parameter
+ * @retval  #ACCOUNT_ERROR_OUT_OF_MEMORY      Out of memory
  *
  * @see account_type_get_icon_path()
  */
 ACCOUNT_API int account_type_set_icon_path(account_type_h account_type, const char *icon_path);
 
 /**
- * @brief      Sets small icon path. It also represents your service provider or application.
+ * @internal
+ * @brief  Sets small icon path. 
+ *         It also represents your service provider or an application.
  *
- * @remarks    @ small icon_path is not mandatory field.
+ * @since_tizen 2.3
+ * @remarks     @a small_icon_path is not a mandatory field.
  *
- * @param[in]  account_type The account type handle. It should be assigned by account_type_create()
- * @param[in]  small_icon_path the scaled icon of your application.
+ * @param[in]   account_type     The account provider handle \n
+ *                               It should be assigned by account_type_create().
+ * @param[in]   small_icon_path  The scaled icon of your application
  *
- * @return     0 on success, otherwise a negative error value.
- * @retval     #ACCOUNT_ERROR_NONE Successful
- * @retval     #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter
- * @retval     #ACCOUNT_ERROR_OUT_OF_MEMORY Out of memory
+ * @return  @c 0 on success,
+ *          otherwise a negative error value
+ * @retval  #ACCOUNT_ERROR_NONE               Successful
+ * @retval  #ACCOUNT_ERROR_INVALID_PARAMETER  Invalid parameter
+ * @retval  #ACCOUNT_ERROR_OUT_OF_MEMORY      Out of memory
  *
  * @see account_type_get_small_icon_path()
  */
 ACCOUNT_API int account_type_set_small_icon_path(account_type_h account_type, const char *small_icon_path);
 
 /**
- * @brief      Sets multiple account. It represents whether your application support multiple accounts or not.
+ * @internal
+ * @brief  Sets support for multiple accounts.
+ *         It represents whether your application supports multiple accounts.
  *
- * @remarks    @ The default value of multiple account support is FALSE.
+ * @since_tizen 2.3
+ * @remarks     The default value of multiple account support is @c FALSE.
  *
- * @param[in]  account_type The account type handle. It should be assigned by account_type_create()
- * @param[in]  multiple_account_support TRUE means that your application can make two or more accounts. FALSE means that your application can make only one account.
+ * @param[in]   account_type              The account provider handle \n
+ *                                        It should be assigned by account_type_create().
+ * @param[in]   multiple_account_support  Set @c TRUE if your application can support two or more accounts, \n
+ *                                        otherwise @c FALSE if your application can support only one account
  *
- * @return     0 on success, otherwise a negative error value.
- * @retval     #ACCOUNT_ERROR_NONE Successful
- * @retval     #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter
- * @retval     #ACCOUNT_ERROR_OUT_OF_MEMORY Out of memory
+ * @return  @c 0 on success,
+ *          otherwise a negative error value
+ * @retval  #ACCOUNT_ERROR_NONE               Successful
+ * @retval  #ACCOUNT_ERROR_INVALID_PARAMETER  Invalid parameter
+ * @retval  #ACCOUNT_ERROR_OUT_OF_MEMORY      Out of memory
  *
  * @see account_type_get_multiple_account_support()
  */
 ACCOUNT_API int account_type_set_multiple_account_support(account_type_h account_type, const bool multiple_account_support);
 
 /**
- * @brief      Sets label and locale. Label represents the name of account type.
+ * @internal
+ * @brief  Sets label and locale. 
+ *         Label represents the name of an account provider.
  *
- * @param[in]  account_type The account type handle. It should be assigned by account_type_create()
- * @param[in]  label The name of account depend on the specified locale
- * @param[in]  locale Locale of the corresponding label
+ * @since_tizen 2.3
+ * @param[in]   account_type  The account provider handle \n
+ *                            It should be assigned by account_type_create().
+ * @param[in]   label         The name of account depends on the specified locale
+ * @param[in]   locale        The locale is specified as an ISO 3166 alpha-2 two letter country-code followed by ISO 639-1 for the two-letter language code.\n
+ *                            For example, "ko_KR" for Korean, "en_US" for American English.
  *
- * @return     0 on success, otherwise a negative error value.
- * @retval     #ACCOUNT_ERROR_NONE Successful
- * @retval     #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter
- * @retval     #ACCOUNT_ERROR_OUT_OF_MEMORY Out of memory
+ * @return  @c 0 on success,
+ *          otherwise a negative error value
+ * @retval  #ACCOUNT_ERROR_NONE               Successful
+ * @retval  #ACCOUNT_ERROR_INVALID_PARAMETER  Invalid parameter
+ * @retval  #ACCOUNT_ERROR_OUT_OF_MEMORY      Out of memory
  *
  * @see account_type_get_label()
  */
 ACCOUNT_API int account_type_set_label(account_type_h account_type, const char* label, const char* locale);
 
 /**
- * @brief      Sets the provider feature.
+ * @internal
+ * @brief  Sets the capability.
  *
- * @param[in]  account_type The account type handle
- * @param[in]  provider_feature This will be capability key of account
+ * @since_tizen 2.3
+ * @param[in]   account_type      The account provider handle
+ * @param[in]   provider_feature  Th capability key of the account
  *
- * @return     0 on success, otherwise a negative error value.
- * @retval     #ACCOUNT_ERROR_NONE Successful
- * @retval     #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter
+ * @return  @c 0 on success,
+ *          otherwise a negative error value
+ * @retval  #ACCOUNT_ERROR_NONE               Successful
+ * @retval  #ACCOUNT_ERROR_INVALID_PARAMETER  Invalid parameter
  *
  * @see account_set_capability()
  */
 ACCOUNT_API int account_type_set_provider_feature(account_type_h account_type, const char* provider_feature);
 
 /**
- * @brief      Retrieves provider feature information with your applicaiton id.
+ * @brief  Retrieves capability information with your application ID.
  *
- * @param[in]  cb_func Callback function will carry provider feature name of app id.
- * @param[in]  app_id Your application ID to search
- * @param[in] user_data User data if you have your private data to carry into callback function, you can use.
+ * @since_tizen 2.3
+ * @privlevel   public
+ * @privilege   %http://tizen.org/privilege/account.read
+ * @param[in]   callback   The callback function carries the capability name of an app ID
+ * @param[in]   app_id     The application ID to search
+ * @param[in]   user_data  The user data \n
+ *                         If you have your private data to carry into callback function, then you can use it.
  *
- * @return     0 on success, otherwise a negative error value.
- * @retval     #ACCOUNT_ERROR_NONE Successful
- * @retval     #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter
- * @retval     #ACCOUNT_ERROR_DB_FAILED Database operation failed
+ * @return  @c 0 on success,
+ *          otherwise a negative error value
+ * @retval  #ACCOUNT_ERROR_NONE               Successful
+ * @retval  #ACCOUNT_ERROR_INVALID_PARAMETER  Invalid parameter
+ * @retval  #ACCOUNT_ERROR_DB_FAILED          Database operation failed
+ * @retval  #ACCOUNT_ERROR_PERMISSION_DENIED  DB Access fail by permission
  *
- * @pre        This function requires an open connection to account service by account_connect().
+ * @pre  This function requires an open connection to an account service by account_connect().
  *
  * @see account_connect()
- * @see account_type_set_provider_feature()
  * @see account_disconnect()
  */
-ACCOUNT_API int account_type_query_provider_feature_by_app_id(provider_feature_cb cb_func, const char* app_id, void *user_data );
+ACCOUNT_API int account_type_query_provider_feature_by_app_id(provider_feature_cb callback, const char* app_id, void *user_data );
 
 /**
- * @brief      Retrieves label information with your applicaiton id.
+ * @brief   Checks whether the given application ID supports the capability.
  *
- * @param[in]  cb_func Callback function will carry provider feature name of app id.
- * @param[in]  app_id Your application ID to search
+ * @since_tizen 2.3
+ * @privlevel   public
+ * @privilege   %http://tizen.org/privilege/account.read
+ * @remarks     The specific error code can be obtained using the get_last_result() method. Error codes are described in Exception section.
+ * @param[in]   app_id      The application ID
+ * @param[in]   capability  The capability \n
+ *                          For example, ACCOUNT_SUPPORTS_CAPABILITY_CONTACT or "http://tizen.org/account/capability/contact"
  *
- * @return     0 on success, otherwise a negative error value.
- * @retval     TRUE means the application supports the given capability
- * @retval     FALSE means the application does not support the given capability
+ * @return  @c TRUE if the application supports the given capability, \n
+ *          otherwise @c FALSE if the application does not support the given capability
+ * @retval  @c TRUE means the application supports the given capability
+ * @retval  @c FALSE means the application does not support the given capability
+ * @exception #ACCOUNT_ERROR_NONE               Successful
+ * @exception #ACCOUNT_ERROR_INVALID_PARAMETER  Invalid parameter
+ * @exception #ACCOUNT_ERROR_RECORD_NOT_FOUND   Related record does not exist
+ * @exception #ACCOUNT_ERROR_PERMISSION_DENIED  DB access fail by permission
  *
- * @pre        This function requires an open connection to account service by account_connect().
+ * @pre This function requires an open connection to an account service by account_connect().
  *
  * @see account_connect()
- * @see account_type_set_provider_feature()
  * @see account_disconnect()
  */
 ACCOUNT_API bool account_type_query_supported_feature(const char* app_id, const char* capability);
 
 /**
- * @brief      Gets the application id of account type.
+ * @brief  Gets the application ID of an account provider.
  *
- * @remarks    @a app_id must be released with free() by you.
+ * @since_tizen 2.3
+ * @remarks     You must release @a app_id using free().
  *
- * @param[in]  account_type The account type handle. It should be given by account_type_query_* functions or account_type_foreach_account_type_from_db
- * @param[out] app_id application id of account type item
+ * @param[in]   account_type  The account provider handle \n
+ *                            It should be given by account_type_query_* functions or account_type_foreach_account_type_from_db().
+ * @param[out]  app_id        The application ID of an account provider item
  *
- * @return     0 on success, otherwise a negative error value.
- * @retval     #ACCOUNT_ERROR_NONE Successful
- * @retval     #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter
- * @retval     #ACCOUNT_ERROR_OUT_OF_MEMORY Out of memory
+ * @return  @c 0 on success,
+ *          otherwise a negative error value
+ * @retval  #ACCOUNT_ERROR_NONE               Successful
+ * @retval  #ACCOUNT_ERROR_INVALID_PARAMETER  Invalid parameter
+ * @retval  #ACCOUNT_ERROR_OUT_OF_MEMORY      Out of memory
  *
  * @see account_type_foreach_account_type_from_db()
  * @see account_type_query_by_app_id()
- * @see account_type_set_app_id()
  */
 ACCOUNT_API int account_type_get_app_id(account_type_h account_type, char **app_id);
 
 /**
- * @brief      Gets the service provider id of account type.
+ * @brief  Gets the service provider ID of an account provider.
  *
- * @remarks    @a service_provider_id must be released with free() by you.
+ * @since_tizen 2.3
+ * @remarks     You must release @a service_provider_id using free().
  *
- * @param[in]  account_type The account type handle. It should be given by account_type_query_* functions or account_type_foreach_account_type_from_db
- * @param[out] service_provider_id service provider text id of account type item
+ * @param[in]   account_type         The account provider handle \n
+ *                                   It should be given by account_type_query_* functions or account_type_foreach_account_type_from_db().
+ * @param[out]  service_provider_id  The service provider text ID of an account provider item
  *
- * @return     0 on success, otherwise a negative error value.
- * @retval     #ACCOUNT_ERROR_NONE Successful
- * @retval     #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter
- * @retval     #ACCOUNT_ERROR_OUT_OF_MEMORY Out of memory
+ * @return  @c 0 on success,
+ *          otherwise a negative error value
+ * @retval  #ACCOUNT_ERROR_NONE               Successful
+ * @retval  #ACCOUNT_ERROR_INVALID_PARAMETER  Invalid parameter
+ * @retval  #ACCOUNT_ERROR_OUT_OF_MEMORY      Out of memory
  *
  * @see account_type_foreach_account_type_from_db()
  * @see account_type_query_by_app_id()
- * @see account_type_set_service_provider_id()
  */
 ACCOUNT_API int account_type_get_service_provider_id(account_type_h account_type, char **service_provider_id);
 
 /**
- * @brief      Gets icon path of account type.
+ * @brief  Gets the icon path of an account provider.
  *
- * @remarks    @a icon_path must be released with free() by you.
+ * @since_tizen 2.3
+ * @remarks     You must release @a icon_path using free().
  *
- * @param[in]  account_type The account type handle. It should be given by account_type_query_* functions or account_type_foreach_account_type_from_db
- * @param[out] icon_path It represents the icon of account type item
+ * @param[in]   account_type  The account provider handle \n
+ *                            It should be given by account_type_query_* functions or account_type_foreach_account_type_from_db().
+ * @param[out]  icon_path     The icon path of the account provider item
  *
- * @return     0 on success, otherwise a negative error value.
- * @retval     #ACCOUNT_ERROR_NONE Successful
- * @retval     #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter
- * @retval     #ACCOUNT_ERROR_OUT_OF_MEMORY Out of memory
+ * @return  @c 0 on success,
+ *          otherwise a negative error value
+ * @retval  #ACCOUNT_ERROR_NONE               Successful
+ * @retval  #ACCOUNT_ERROR_INVALID_PARAMETER  Invalid parameter
+ * @retval  #ACCOUNT_ERROR_OUT_OF_MEMORY      Out of memory
  *
  * @see account_type_foreach_account_type_from_db()
  * @see account_type_query_by_app_id()
- * @see account_type_set_icon_path()
  */
 ACCOUNT_API int account_type_get_icon_path(account_type_h account_type, char **icon_path);
 
 /**
- * @brief      Gets small icon path of account type.
+ * @brief  Gets the small icon path of an account provider.
  *
- * @remarks    @a small_icon_path must be released with free() by you.
+ * @since_tizen 2.3
+ * @remarks    You must release @a small_icon_path using free().
  *
- * @param[in]  account_type The account type handle. It should be given by account_type_query_* functions or account_type_foreach_account_type_from_db
- * @param[out] small_icon_path It represents the small icon of account type item
+ * @param[in]   account_type     The account provider handle\n
+ *                               It should be given by account_type_query_* functions or account_type_foreach_account_type_from_db().
+ * @param[out]  small_icon_path  The small icon path of the account provider item
  *
- * @return     0 on success, otherwise a negative error value.
- * @retval     #ACCOUNT_ERROR_NONE Successful
- * @retval     #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter
- * @retval     #ACCOUNT_ERROR_OUT_OF_MEMORY Out of memory
+ * @return  @c 0 on success,
+ *          otherwise a negative error value
+ * @retval  #ACCOUNT_ERROR_NONE               Successful
+ * @retval  #ACCOUNT_ERROR_INVALID_PARAMETER  Invalid parameter
+ * @retval  #ACCOUNT_ERROR_OUT_OF_MEMORY      Out of memory
  *
  * @see account_type_foreach_account_type_from_db()
  * @see account_type_query_by_app_id()
- * @see account_type_set_small_icon_path()
  */
 ACCOUNT_API int account_type_get_small_icon_path(account_type_h account_type, char **small_icon_path);
 
 /**
- * @brief      Gets small icon path of account type.
+ * @brief  Checks whether the given account provider supports multiple accounts.
  *
- * @param[in]  account_type The account type handle. It should be given by account_type_query_* functions or account_type_foreach_account_type_from_db
- * @param[out] multiple_account_support It represents whether the retreived account type supports over two accounts or not. TRUE or FALSE
+ * @since_tizen 2.3
+ * @param[in]   account_type              The account provider handle \n
+ *                                        It should be given by account_type_query_* functions or account_type_foreach_account_type_from_db.
+ * @param[out]  multiple_account_support  The flag indicating support for multiple accounts accounts\n
+ *                                        TRUE or FALSE.
  *
- * @return     0 on success, otherwise a negative error value.
- * @retval     #ACCOUNT_ERROR_NONE Successful
- * @retval     #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter
- * @retval     #ACCOUNT_ERROR_OUT_OF_MEMORY Out of memory
+ * @return  @c 0 on success,
+ *          otherwise a negative error value
+ * @retval  #ACCOUNT_ERROR_NONE               Successful
+ * @retval  #ACCOUNT_ERROR_INVALID_PARAMETER  Invalid parameter
+ * @retval  #ACCOUNT_ERROR_OUT_OF_MEMORY      Out of memory
  *
  * @see account_type_foreach_account_type_from_db()
  * @see account_type_query_by_app_id()
- * @see account_type_set_small_icon_path()
  */
 ACCOUNT_API int account_type_get_multiple_account_support(account_type_h account_type, int *multiple_account_support);
 
 /**
- * @brief      Retrieves provider feature information with the given account_type_h.
+ * @brief  Gets capability information with the given account provider handle.
  *
- * @param[in]  account_type The account type handle. It should be given by account_type_query_* functions or account_type_foreach_account_type_from_db
- * @param[in]  cb_func Callback function will carry provider feature name of app id.
- * @param[in] user_data User data if you have your private data to carry into callback function, you can use.
+ * @since_tizen 2.3
+ * @param[in]   account_type  The account provider handle\n
+ *                            It should be given by account_type_query_* functions or account_type_foreach_account_type_from_db().
+ * @param[in]   callback      The callback function that carries the capability name of the app ID
+ * @param[in]   user_data     The user data \n
+ *                            If you have your private data to carry into callback function, then you can use it.
  *
- * @return     0 on success, otherwise a negative error value.
- * @retval     #ACCOUNT_ERROR_NONE Successful
- * @retval     #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter
- * @retval     #ACCOUNT_ERROR_DB_FAILED Database operation failed
+ * @return  @c 0 on success,
+ *          otherwise a negative error value
+ * @retval  #ACCOUNT_ERROR_NONE               Successful
+ * @retval  #ACCOUNT_ERROR_INVALID_PARAMETER  Invalid parameter
+ * @retval  #ACCOUNT_ERROR_DB_FAILED          Database operation failed
  *
- * @pre        This function requires an open connection to account service by account_connect().
+ * @pre  This function requires an open connection to an account service by account_connect().
  *
  * @see account_connect()
- * @see account_type_set_provider_feature()
  * @see account_disconnect()
  */
-ACCOUNT_API int account_type_get_provider_feature_all(account_type_h account_type, provider_feature_cb cb_func, void* user_data);
+ACCOUNT_API int account_type_get_provider_feature_all(account_type_h account_type, provider_feature_cb callback, void* user_data);
 
 /**
- * @brief      Gets the specific label information detail of account type.
+ * @brief  Gets the specific label information detail of an account provider.
  *
- * @param[in]  account_type The account type handle. It should be given by account_type_query_* functions or account_type_foreach_account_type_from_db
- * @param[in]  locale Locale query. E.g) "en-gb"
- * @param[out] label Label text will be given for the locale.
+ * @since_tizen 2.3
+ * @param[in]   account_type The account provider handle\n
+ *                           It should be given by account_type_query_* functions or account_type_foreach_account_type_from_db().
+ * @param[in]   locale       The locale is specified as an ISO 3166 alpha-2 two letter country-code followed by ISO 639-1 for the two-letter language code.\n
+ *                           For example, "ko_KR" or "ko-kr" for Korean, "en_US" or "en-us" for American English.
+ * @param[out]  label        The label text given for the locale
  *
- * @return     0 on success, otherwise a negative error value.
- * @retval     #ACCOUNT_ERROR_NONE Successful
- * @retval     #ACCOUNT_ERROR_RECORD_NOT_FOUND No label for the given locale
- * @retval     #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter
+ * @return  @c 0 on success,
+ *          otherwise a negative error value
+ * @retval  #ACCOUNT_ERROR_NONE               Successful
+ * @retval  #ACCOUNT_ERROR_RECORD_NOT_FOUND   No label for the given locale
+ * @retval  #ACCOUNT_ERROR_INVALID_PARAMETER  Invalid parameter
  *
  * @see account_type_foreach_account_type_from_db()
  * @see account_type_query_by_app_id()
- * @see account_type_set_label()
  */
 
 ACCOUNT_API int account_type_get_label_by_locale(account_type_h account_type, const char* locale, char** label);
 
 /**
- * @brief      Gets the label information detail of account type.
+ * @brief  Gets the label information detail of an account provider.
  *
- * @param[in]  account_type The account type handle. It should be given by account_type_query_* functions or account_type_foreach_account_type_from_db
- * @param[in]  callback The callback function carrying label information
- * @param[in]  user_data The user data to be passed to the callback function
+ * @since_tizen 2.3
+ * @param[in]   account_type  The account provider handle\n
+ *                            It should be given by account_type_query_* functions or account_type_foreach_account_type_from_db().
+ * @param[in]   callback      The callback function carrying the label information
+ * @param[in]   user_data     The user data to be passed to the callback function
  *
- * @return     0 on success, otherwise a negative error value.
- * @retval     #ACCOUNT_ERROR_NONE Successful
- * @retval     #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter
+ * @return  @c 0 on success,
+ *          otherwise a negative error value
+ * @retval  #ACCOUNT_ERROR_NONE               Successful
+ * @retval  #ACCOUNT_ERROR_INVALID_PARAMETER  Invalid parameter
  *
  * @see account_type_foreach_account_type_from_db()
  * @see account_type_query_by_app_id()
- * @see account_type_set_label()
  */
-ACCOUNT_API int account_type_get_label(account_type_h account_type, account_label_cb cb_func, void *user_data);
+ACCOUNT_API int account_type_get_label(account_type_h account_type, account_label_cb callback, void *user_data);
 
 /**
- * @brief      Inserts the account type details to the database.
+ * @internal
+ * @brief  Inserts the account provider details to the database.
  *
- * @param[in]  account_type    The account handle which is created by account_type_create(). And the madatory fields must be filled with account_type_set_* functions
- * @param[out] account_type_id The account type ID to be assigned after inserting account type handle.
+ * @since_tizen 2.3
+ * @privlevel   public
+ * @privilege   %http://tizen.org/privilege/account.read \n
+ *              %http://tizen.org/privilege/account.write
+ * @remarks     this API need both privileges
+ * @param[in]   account_type     The account handle which is created by account_type_create() \n
+ * @param[out]  account_type_id  The account provider ID to be assigned after inserting the account provider handle
  *
- * @return     0 on success, otherwise a negative error value.
- * @retval     #ACCOUNT_ERROR_NONE Successful
- * @retval     #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter
- * @retval     #ACCOUNT_ERROR_DB_FAILED  Database operation failed
+ * @return  @c 0 on success,
+ *          otherwise a negative error value
+ * @retval  #ACCOUNT_ERROR_NONE               Successful
+ * @retval  #ACCOUNT_ERROR_INVALID_PARAMETER  Invalid parameter
+ * @retval  #ACCOUNT_ERROR_DB_FAILED          Database operation failed
+ * @retval  #ACCOUNT_ERROR_PERMISSION_DENIED  DB Access fail by permission
  *
- * @pre        This function requires an open connection to account service by account_connect().
- * @post       account_disconnect() is recommended after insertion
+ * @pre   This function requires an open connection to an account service by account_connect().
+ * @post  account_disconnect() is recommended after insertion.
  *
  * @see account_connect()
- * @see account_type_set_app_id()
- * @see account_type_set_service_provider_id()
- * @see account_type_set_icon_path()
- * @see account_type_set_small_icon_path()
- * @see account_type_set_multiple_account_support()
- * @see account_type_set_label()
- * @see account_type_delete_by_app_id()
- * @see account_type_update_to_db_by_app_id()
  * @see account_disconnect()
  */
 ACCOUNT_API int account_type_insert_to_db(account_type_h account_type, int* account_type_id);
 
 /**
- * @brief      Updates the account details to the account database.
+ * @internal
+ * @brief  Updates the account details to the account database.
  *
- * @param[in]  account_type The account handle which is created by account_type_create(). And the madatory fields must be filled with account_type_set_* functions
- * @param[in]  app_id Application id of account type
+ * @since_tizen 2.3
+ * @privlevel   public
+ * @privilege   %http://tizen.org/privilege/account.read \n
+ *              %http://tizen.org/privilege/account.write
+ * @remarks     this API need both privileges
+ * @param[in]   account_type  The account handle which is created by account_type_create() \n
+ * @param[in]   app_id        The application ID of the account provider
  *
- * @return     0 on success, otherwise a negative error value.
- * @retval     #ACCOUNT_ERROR_NONE Successful
- * @retval     #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter
- * @retval     #ACCOUNT_ERROR_DB_FAILED  Database operation failed
+ * @return  @c 0 on success,
+ *          otherwise a negative error value
+ * @retval  #ACCOUNT_ERROR_NONE               Successful
+ * @retval  #ACCOUNT_ERROR_INVALID_PARAMETER  Invalid parameter
+ * @retval  #ACCOUNT_ERROR_DB_FAILED          Database operation failed
+ * @retval  #ACCOUNT_ERROR_PERMISSION_DENIED  DB Access fail by permission
  *
- * @pre        This function requires an open connection to account service by account_connect()
- * @post       account_disconnect() is recommended after update
+ * @pre   This function requires an open connection to an account service by account_connect().
+ * @post  account_disconnect() is recommended after update.
  *
  * @see account_connect()
- * @see account_type_insert_to_db()
- * @see account_type_set_app_id()
- * @see account_type_set_service_provider_id()
- * @see account_type_set_icon_path()
- * @see account_type_set_small_icon_path()
- * @see account_type_set_multiple_account_support()
- * @see account_type_set_label()
- * @see account_type_delete_by_app_id()
  * @see account_disconnect()
  */
 ACCOUNT_API int account_type_update_to_db_by_app_id(const account_type_h account_type, const char* app_id);
 
 /**
- * @brief      Deletes the account type from the account database by application id.
+ * @internal
+ * @brief  Deletes the account provider from the account database by application ID.
  *
- * @param[in]  app_id Application id of account type to be deleted
+ * @since_tizen 2.3
+ * @privlevel   public
+ * @privilege   %http://tizen.org/privilege/account.read \n
+ *              %http://tizen.org/privilege/account.write
+ * @remarks     this API need both privileges
+ * @param[in]   app_id  The application ID of account provider to be deleted
  *
- * @return     0 on success, otherwise a negative error value.
- * @retval     #ACCOUNT_ERROR_NONE Successful
- * @retval     #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter
- * @retval     #ACCOUNT_ERROR_DB_FAILED  Database operation failed
+ * @return  @c 0 on success,
+ *          otherwise a negative error value
+ * @retval  #ACCOUNT_ERROR_NONE               Successful
+ * @retval  #ACCOUNT_ERROR_INVALID_PARAMETER  Invalid parameter
+ * @retval  #ACCOUNT_ERROR_DB_FAILED          Database operation failed
+ * @retval  #ACCOUNT_ERROR_PERMISSION_DENIED  DB Access fail by permission
  *
- * @pre        This function requires an open connection to account service by account_connect()
+ * @pre  This function requires an open connection to an account service by account_connect().
  *
  * @see account_connect()
- * @see account_type_insert_to_db()
- * @see account_type_update_to_db_by_app_id()
  * @see account_disconnect()
  */
 ACCOUNT_API int account_type_delete_by_app_id(const char* app_id);
 
 /**
- * @brief      Retrieves label information with your applicaiton id.
+ * @brief  Retrieves the label information with your application ID.
  *
- * @param[in]  cb_func Callback function will carry label_h for label information. label_h contains label info as parameter.
- * @param[in]  app_id Your application ID to search
- * @param[in] user_data User data if you have your private data to carry into callback function, you can use.
+ * @since_tizen 2.3
+ * @privlevel   public
+ * @privilege   %http://tizen.org/privilege/account.read
+ * @param[in]   callback    The callback function that carries label_h for label information \n
+ *                         label_h contains label info as parameter.
+ * @param[in]   app_id     The application ID to search
+ * @param[in]   user_data  The user data \n
+ *                         If you have your private data to carry into callback function, then you can use it.
  *
- * @return     0 on success, otherwise a negative error value.
- * @retval     #ACCOUNT_ERROR_NONE Successful
- * @retval     #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter
- * @retval     #ACCOUNT_ERROR_DB_FAILED Database operation failed
+ * @return  @c 0 on success,
+ *          otherwise a negative error value
+ * @retval  #ACCOUNT_ERROR_NONE               Successful
+ * @retval  #ACCOUNT_ERROR_INVALID_PARAMETER  Invalid parameter
+ * @retval  #ACCOUNT_ERROR_DB_FAILED          Database operation failed
+ * @retval  #ACCOUNT_ERROR_PERMISSION_DENIED  DB Access fail by permission
  *
- * @pre        This function requires an open connection to account service by account_connect().
+ * @pre  This function requires an open connection to an account service by account_connect().
  *
  * @see account_connect()
  * @see account_type_query_by_app_id()
  * @see account_type_foreach_account_type_from_db()
  * @see account_disconnect()
  */
-ACCOUNT_API int account_type_query_label_by_app_id(account_label_cb cb_func, const char* app_id, void *user_data );
+ACCOUNT_API int account_type_query_label_by_app_id(account_label_cb callback, const char* app_id, void *user_data );
 
 /**
- * @brief      Retrieves account type information with your applicaiton id.
+ * @brief  Retrieves the account provider information with your application ID.
  *
- * @param[in]  app_id Your application ID to search
- * @param[out] account_type    The account handle which is created by account_type_create().
+ * @since_tizen 2.3
+ * @privlevel   public
+ * @privilege   %http://tizen.org/privilege/account.read
+ * @param[in]   app_id        The application ID to search
+ * @param[out]  account_type  The account handle which is created by account_type_create()
  *
- * @return     0 on success, otherwise a negative error value.
- * @retval     #ACCOUNT_ERROR_NONE Successful
- * @retval     #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter
- * @retval     #ACCOUNT_ERROR_DB_FAILED Database operation failed
- * @retval     #ACCOUNT_ERROR_RECORD_NOT_FOUND query data is not exist
+ * @return  @c 0 on success,
+ *          otherwise a negative error value
+ * @retval  #ACCOUNT_ERROR_NONE               Successful
+ * @retval  #ACCOUNT_ERROR_INVALID_PARAMETER  Invalid parameter
+ * @retval  #ACCOUNT_ERROR_DB_FAILED          Database operation failed
+ * @retval  #ACCOUNT_ERROR_RECORD_NOT_FOUND   Queried data does not exist
+ * @retval  #ACCOUNT_ERROR_PERMISSION_DENIED  DB Access fail by permission
  *
- * @pre        This function requires an open connection to account service by account_connect().
+ * @pre  This function requires an open connection to an account service by account_connect().
  *
  * @see account_connect()
  * @see account_type_create()
@@ -1499,17 +1856,24 @@ ACCOUNT_API int account_type_query_label_by_app_id(account_label_cb cb_func, con
 ACCOUNT_API int account_type_query_by_app_id(const char* app_id, account_type_h *account_type);
 
 /**
- * @brief      Retrieves all account type information with your applicaiton id.
+ * @brief  Retrieves all account priovider information.
  *
- * @param[in]  callback Retrieving account type information. You can get account information through account_type_get_* with the carried account_type_handle
- * @param[in] user_data User data. It will be carried through your callback function.
+ * @since_tizen 2.3
+ * @privlevel   public
+ * @privilege   %http://tizen.org/privilege/account.read
+ * @param[in]   callback   The account provider information \n
+ *                         You can get the account information through account_type_get_* with the carried account_type_handle.
+ * @param[in]   user_data  The user data \n
+ *                         It will be carried through your callback function.
  *
- * @return     0 on success, otherwise a negative error value.
- * @retval     #ACCOUNT_ERROR_NONE Successful
- * @retval     #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter
- * @retval     #ACCOUNT_ERROR_DB_FAILED Database operation failed
+ * @return  @c 0 on success,
+ *          otherwise a negative error value
+ * @retval  #ACCOUNT_ERROR_NONE               Successful
+ * @retval  #ACCOUNT_ERROR_INVALID_PARAMETER  Invalid parameter
+ * @retval  #ACCOUNT_ERROR_DB_FAILED          Database operation failed
+ * @retval  #ACCOUNT_ERROR_PERMISSION_DENIED  DB Access fail by permission
  *
- * @pre        This function requires an open connection to account service by account_connect().
+ * @pre  This function requires an open connection to an account service by account_connect().
  *
  * @see account_connect()
  * @see account_type_create()
@@ -1524,52 +1888,71 @@ ACCOUNT_API int account_type_query_by_app_id(const char* app_id, account_type_h
 ACCOUNT_API int account_type_foreach_account_type_from_db(account_type_cb callback, void *user_data);
 
 /**
- * @brief      Retrieves all account type information with your applicaiton id.
+ * @brief  Retrieves the label information with the given application ID and locale.
  *
- * @param[in]  app_id Your application id
- * @param[in] locale Locale value to search label. e.g) en_US
- * @param[out] label label text corresponding app_id and locale. It must be free.
+ * @since_tizen 2.3
+ * @privlevel   public
+ * @privilege   %http://tizen.org/privilege/account.read
+ * @param[in]   app_id  The application ID
+ * @param[in]   locale  The locale is specified as an ISO 3166 alpha-2 two letter country-code followed by ISO 639-1 for the two-letter language code.\n
+ *                      For example, "ko_KR" or "ko-kr" for Korean, "en_US" or "en-us" for American English.
+ * @param[out]  label   The label text corresponding app_id and locale \n
+ *                      It must be free text.
  *
- * @return     0 on success, otherwise a negative error value.
- * @retval     #ACCOUNT_ERROR_NONE Successful
- * @retval     #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter
- * @retval     #ACCOUNT_ERROR_DB_FAILED Database operation failed
+ * @return  @c 0 on success,
+ *          otherwise a negative error value
+ * @retval  #ACCOUNT_ERROR_NONE               Successful
+ * @retval  #ACCOUNT_ERROR_INVALID_PARAMETER  Invalid parameter
+ * @retval  #ACCOUNT_ERROR_DB_FAILED          Database operation failed
+ * @retval  #ACCOUNT_ERROR_PERMISSION_DENIED  DB Access fail by permission
  *
- * @pre        This function requires an open connection to account service by account_connect().
+ * @pre  This function requires an open connection to an account service by account_connect().
  *
  * @see account_connect()
  */
 ACCOUNT_API int account_type_query_label_by_locale(const char* app_id, const char* locale, char** label);
 
 /**
- * @brief      Retrieves account type information with provider feature name.
+ * @brief  Retrieves account provider information with the capability name.
  *
- * @param[in] cb_func callback function to retrieve account type information
- * @param[in] key provider feature value to search account type . e.g) ACCOUNT_SUPPORTS_CAPABILITY_CONTACT or  "http://tizen.org/account/capability/contact"
- * @param[out] account_type_h handle corresponding provider feature name.
+ * @since_tizen 2.3
+ * @privlevel   public
+ * @privilege   %http://tizen.org/privilege/account.read
+ * @param[in]   callback        The callback function to retrieve account provider information
+ * @param[in]   key             The capability value to search account provider \n
+ *                              For example, ACCOUNT_SUPPORTS_CAPABILITY_CONTACT or "http://tizen.org/account/capability/contact"
+ * @param[in]  user_data        If you have your private data to carry into callback function, then you can use it
  *
- * @return     0 on success, otherwise a negative error value.
- * @retval     #ACCOUNT_ERROR_NONE Successful
- * @retval     #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter
- * @retval     #ACCOUNT_ERROR_DB_FAILED Database operation failed
+ * @return  @c 0 on success,
+ *          otherwise a negative error value
+ * @retval  #ACCOUNT_ERROR_NONE               Successful
+ * @retval  #ACCOUNT_ERROR_RECORD_NOT_FOUND   Record not found
+ * @retval  #ACCOUNT_ERROR_INVALID_PARAMETER  Invalid parameter
+ * @retval  #ACCOUNT_ERROR_DB_FAILED          Database operation failed
+ * @retval  #ACCOUNT_ERROR_PERMISSION_DENIED  DB Access fail by permission
  *
- * @pre        This function requires an open connection to account service by account_connect().
+ * @pre  This function requires an open connection to an account service by account_connect().
  *
  * @see account_connect()
  */
-ACCOUNT_API int account_type_query_by_provider_feature(account_type_cb cb_func, const char* key, void* user_data);
+ACCOUNT_API int account_type_query_by_provider_feature(account_type_cb callback, const char* key, void* user_data);
 
 /**
- * @brief      Check account type db whether the given app_id exists.
+ * @brief  Checks whether the given app_id exists in the account provider DB.
  *
- * @param[in] app_id application id to check
+ * @since_tizen 2.3
+ * @privlevel   public
+ * @privilege   %http://tizen.org/privilege/account.read
+ * @param[in]   app_id  The application ID to check
  *
- * @return     0 on success, otherwise a negative error value.
- * @retval     #ACCOUNT_ERROR_NONE Successful
- * @retval     #ACCOUNT_ERROR_RECORD_NOT_FOUND record not found
- * @retval     #ACCOUNT_ERROR_INVALID_PARAMETER invalid app id
+ * @return  @c 0 on success,
+ *          otherwise a negative error value
+ * @retval  #ACCOUNT_ERROR_NONE               Successful
+ * @retval  #ACCOUNT_ERROR_RECORD_NOT_FOUND   Record not found
+ * @retval  #ACCOUNT_ERROR_INVALID_PARAMETER  Invalid app ID
+ * @retval  #ACCOUNT_ERROR_PERMISSION_DENIED  DB Access fail by permission
  *
- * @pre        This function requires an open connection to account service by account_connect().
+ * @pre  This function requires an open connection to an account service by account_connect().
  *
  * @see account_type_query_by_app_id()
  */
@@ -1577,19 +1960,21 @@ ACCOUNT_API int account_type_query_app_id_exist(const char* app_id);
 
 
 
-/* End of account type api  */
+/* End of account provider API  */
 
 /**
- * @brief      Creates a handle for account event subscription.
+ * @brief  Creates a handle for the account event subscription.
  *
- * @remarks    @a account_subscribe handle must be released with account_unsubscribe_notification() by you. \n
+ * @since_tizen 2.3
+ * @remarks     You must release @a account_subscribe handle using account_unsubscribe_notification().
  *
- * @param[in]  account_subscribe       The account subscription handle
+ * @param[in]   account_subscribe  The account subscription handle
  *
- * @return     0 on success, otherwise a negative error value.
- * @retval     #ACCOUNT_ERROR_NONE Successful
- * @retval     #ACCOUNT_ERROR_OUT_OF_MEMORY Out of Memory
- * @retval     #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter
+ * @return  @c 0 on success,
+ *          otherwise a negative error value
+ * @retval  #ACCOUNT_ERROR_NONE               Successful
+ * @retval  #ACCOUNT_ERROR_OUT_OF_MEMORY      Out of Memory
+ * @retval  #ACCOUNT_ERROR_INVALID_PARAMETER  Invalid parameter
  *
  * @see account_unsubscribe_notification()
  * @see account_subscribe_notification()
@@ -1597,38 +1982,48 @@ ACCOUNT_API int account_type_query_app_id_exist(const char* app_id);
 ACCOUNT_API int account_subscribe_create(account_subscribe_h* account_subscribe);
 
 /**
- * @brief      Start to subscribe account event through the given callback function
+ * @brief  Starts to subscribe account event through the given callback function.
  *
- * @param[in]  account_subscribe       The account subscription handle
- * @param[in]  cb_func When an account is removed from account database. It will be called with event message and account id.
- * @param[in]  user_data user_data will be delivered to cb_func
+ * @since_tizen 2.3
+ * @privlevel   public
+ * @privilege   %http://tizen.org/privilege/account.read
+ * @param[in]   account_subscribe  The account subscription handle
+ * @param[in]   callback           The callback function that is called when an account is removed and a data of account is updated from the account database \n
+ *                                 It will be called with event message and account ID.
+ * @param[in]   user_data          The user_data that is delivered to callback
  *
- * @return     0 on success, otherwise a negative error value.
- * @retval     #ACCOUNT_ERROR_NONE Successful
- * @retval     #ACCOUNT_ERROR_EVENT_SUBSCRIPTION_FAIL Subscription fail
- * @retval     #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter
+ * @return  @c 0 on success,
+ *          otherwise a negative error value
+ * @retval  #ACCOUNT_ERROR_NONE                     Successful
+ * @retval  #ACCOUNT_ERROR_EVENT_SUBSCRIPTION_FAIL  Subscription fail
+ * @retval  #ACCOUNT_ERROR_INVALID_PARAMETER        Invalid parameter
+ *
+ * @pre account_subscribe_create()
  *
  * @see account_unsubscribe_notification()
  * @see account_subscribe_notification()
  */
-ACCOUNT_API int account_subscribe_notification(account_subscribe_h account_subscribe, account_event_cb cb_func, void* user_data);
+ACCOUNT_API int account_subscribe_notification(account_subscribe_h account_subscribe, account_event_cb callback, void* user_data);
 
 /**
- * @brief      Destroys the account subscribe handle and releases all its resources.
+ * @brief  Destroys the account subscribe handle and releases all its resources.
  *
- * @remarks    @account_unsubscribe_notification must be called when you don't need to subscribe account event \n
+ * @since_tizen 2.3
+ * @privlevel   public
+ * @privilege   %http://tizen.org/privilege/account.read
+ * @remarks     You must call @a account_unsubscribe_notification when you do not need to subscribe account event.
  *
- * @param[in]  account_subscribe       The account subscription handle
+ * @param[in]   account_subscribe  The account subscription handle
  *
- * @return     0 on success, otherwise a negative error value.
- * @retval     #ACCOUNT_ERROR_NONE     Successful
- * @retval     #ACCOUNT_ERROR_INVALID_PARAMETER Invalid parameter
- * @retval     #ACCOUNT_ERROR_EVENT_SUBSCRIPTION_FAIL Unsubscription fail
+ * @return  @c 0 on success,
+ *          otherwise a negative error value
+ * @retval  #ACCOUNT_ERROR_NONE                     Successful
+ * @retval  #ACCOUNT_ERROR_INVALID_PARAMETER        Invalid parameter
+ * @retval  #ACCOUNT_ERROR_EVENT_SUBSCRIPTION_FAIL  Unsubscription failed
  *
  * @see account_create()
  */
 ACCOUNT_API int account_unsubscribe_notification(account_subscribe_h account_subscribe);
-
 /**
 * @}
 */
index fd460af..c24c8c5 100755 (executable)
@@ -79,69 +79,69 @@ void insert_test(void)
    ret = account_connect();
    if(ret != ACCOUNT_ERROR_NONE)
    {
-      printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+      SECURE_LOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
    }
 
    ret = account_create(&account);
    if(ret != ACCOUNT_ERROR_NONE)
    {
-       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+       SECURE_LOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
    }
 
    ret = account_set_user_name(account, "tarun.kr");
 
    if(ret != ACCOUNT_ERROR_NONE)
    {
-      printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+      SECURE_LOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
    }
 
    ret = account_set_display_name(account, "Tarun Kumar");
 
    if(ret != ACCOUNT_ERROR_NONE)
    {
-      printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+      SECURE_LOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
    }
 
    ret = account_set_domain_name(account, "Samsung electronics");
    if(ret != ACCOUNT_ERROR_NONE)
    {
-       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+       SECURE_LOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
    }
 
    ret = account_set_email_address(account, "tarun@gmail.com");
    if(ret != ACCOUNT_ERROR_NONE)
    {
-       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+       SECURE_LOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
    }
 
    ret = account_set_package_name(account, "com.samsung.twiter");
    if(ret != ACCOUNT_ERROR_NONE)
    {
-       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+       SECURE_LOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
    }
 
    ret = account_set_icon_path(account, "icon-path");
    if(ret != ACCOUNT_ERROR_NONE)
    {
-       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+       SECURE_LOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
    }
 
    ret = account_set_access_token(account, "ACCESSTOKEN");
    if(ret != ACCOUNT_ERROR_NONE)
    {
-       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+       SECURE_LOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
    }
 
    ret = account_set_auth_type( account, ACCOUNT_AUTH_TYPE_OAUTH );
    if(ret != ACCOUNT_ERROR_NONE)
    {
-       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+       SECURE_LOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
    }
 
    ret = account_set_secret( account, ACCOUNT_SECRECY_INVISIBLE );
    if(ret != ACCOUNT_ERROR_NONE)
    {
-       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+       SECURE_LOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
    }
    ret = account_set_source(account, "URUSA inc.");
 
@@ -152,7 +152,7 @@ void insert_test(void)
        ret = account_set_user_text(account, i, "user txt");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-           printf("(%d)-[Account] ret = %d, account=%p, i=%d\n", __LINE__, ret, account, i);
+           SECURE_LOGD("(%d)-[Account] ret = %d, account=%p, i=%d\n", __LINE__, ret, account, i);
        }
 
    }
@@ -162,7 +162,7 @@ void insert_test(void)
        ret = account_set_user_int(account, i, 888);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-           printf("(%d)-[Account] ret = %d, account=%p, i=%d\n", __LINE__, ret, account, i);
+           SECURE_LOGD("(%d)-[Account] ret = %d, account=%p, i=%d\n", __LINE__, ret, account, i);
        }
    }
 
@@ -180,20 +180,20 @@ void insert_test(void)
    ret = account_insert_to_db(account, &account_id);
    if(ret != ACCOUNT_ERROR_NONE)
    {
-       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+       SECURE_LOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        return;
    }
 
    ret = account_destroy(account);
    if(ret != ACCOUNT_ERROR_NONE)
    {
-       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+       SECURE_LOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
    }
 
    ret = account_disconnect();
    if(ret != ACCOUNT_ERROR_NONE)
    {
-       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+       SECURE_LOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
    }
 
    return;
@@ -208,8 +208,8 @@ bool _capability_get_callback(const char* capability_type, account_capability_st
    char* test_type = capability_type;
    int test_value = capability_value;
 
-   printf("_capability_get_callback test_type = : %s\n", test_type);
-   printf("_capability_get_callback test_value = : %d\n", test_value);
+   SECURE_LOGD("_capability_get_callback test_type = : %s\n", test_type);
+   SECURE_LOGD("_capability_get_callback test_value = : %d\n", test_value);
    return TRUE;
 }
 
@@ -229,60 +229,60 @@ void get_account_by_id(int account_id)
    ret = account_connect();
    if(ret != ACCOUNT_ERROR_NONE)
    {
-          printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+          SECURE_LOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
    }
 
    ret = account_create(&account);
    if(ret != ACCOUNT_ERROR_NONE)
    {
-          printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+          SECURE_LOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
    }
 
    ret = account_query_account_by_account_id(account_id, &account);
    if(ret != ACCOUNT_ERROR_NONE)
    {
-          printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+          SECURE_LOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
    }
 
    char *test_text = NULL;
 
    account_get_user_name(handle, &test_text);
-   printf("_account_get_callback : %s\n", test_text);
+   SECURE_LOGD("_account_get_callback : %s\n", test_text);
 
    _account_free_text(test_text);
 
    account_get_display_name(handle, &test_text);
-   printf("_account_get_callback : %s\n", test_text);
+   SECURE_LOGD("_account_get_callback : %s\n", test_text);
 
    _account_free_text(test_text);
 
    account_get_email_address(handle, &test_text);
-   printf("_account_get_callback : %s\n", test_text);
+   SECURE_LOGD("_account_get_callback : %s\n", test_text);
 
    _account_free_text(test_text);
 
    account_get_icon_path(handle, &test_text);
-   printf("_account_get_callback : %s\n", test_text);
+   SECURE_LOGD("_account_get_callback : %s\n", test_text);
 
    _account_free_text(test_text);
 
    account_get_source(handle, &test_text);
-   printf("_account_get_callback : %s\n", test_text);
+   SECURE_LOGD("_account_get_callback : %s\n", test_text);
 
    _account_free_text(test_text);
 
    account_get_package_name(handle, &test_text);
-   printf("_account_get_callback : %s\n", test_text);
+   SECURE_LOGD("_account_get_callback : %s\n", test_text);
 
    _account_free_text(test_text);
 
    account_get_domain_name(handle, &test_text);
-   printf("_account_get_callback : %s\n", test_text);
+   SECURE_LOGD("_account_get_callback : %s\n", test_text);
 
    _account_free_text(test_text);
 
    account_get_access_token(handle, &test_text);
-   printf("_account_get_callback : %s\n", test_text);
+   SECURE_LOGD("_account_get_callback : %s\n", test_text);
 
    int i;
 
@@ -291,28 +291,28 @@ void get_account_by_id(int account_id)
           _account_free_text(test_text);
 
           account_get_user_text(handle, i, &test_text);
-          printf("_account_get_callback : %s\n", test_text);
+          SECURE_LOGD("_account_get_callback : %s\n", test_text);
    }
 
    int test_int  = -1;
 
    account_auth_type_e auth_type;
    account_get_auth_type(handle, &auth_type);
-   printf("account_get_auth_type : %d\n", auth_type);
+   SECURE_LOGD("account_get_auth_type : %d\n", auth_type);
 
    account_secrecy_state_e secret;
    account_get_secret(handle, &secret);
-   printf("account_get_secret : %d\n", secret);
+   SECURE_LOGD("account_get_secret : %d\n", secret);
 
    account_sync_state_e sync_support;
    account_get_sync_support(handle, &sync_support);
-   printf("account_get_sync_support : %d\n", sync_support);
+   SECURE_LOGD("account_get_sync_support : %d\n", sync_support);
 
    for(i=0;i<USER_INT_CNT;i++)
    {
           test_int  = -1;
           account_get_user_int(handle, i, &test_int);
-          printf("_account_get_callback : %d\n", test_int);
+          SECURE_LOGD("_account_get_callback : %d\n", test_int);
    }
 
    account_get_capability(handle, _capability_get_callback, NULL);
@@ -320,13 +320,13 @@ void get_account_by_id(int account_id)
    ret = account_destroy(account);
    if(ret != ACCOUNT_ERROR_NONE)
    {
-          printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+          SECURE_LOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
    }
 
    ret = account_disconnect();
    if(ret != ACCOUNT_ERROR_NONE)
    {
-          printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+          SECURE_LOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
    }
 }
 @endcode
@@ -345,47 +345,47 @@ static void _account_free_text(char *text)
 
 bool _account_get_callback(account_h handle, void* user_data)
 {
-   printf("_account_get_callback\n");
+   SECURE_LOGD("_account_get_callback\n");
 
    char *test_text = NULL;
 
    account_get_user_name(handle, &test_text);
-   printf("_account_get_callback : %s\n", test_text);
+   SECURE_LOGD("_account_get_callback : %s\n", test_text);
 
    _account_free_text(test_text);
 
    account_get_display_name(handle, &test_text);
-   printf("_account_get_callback : %s\n", test_text);
+   SECURE_LOGD("_account_get_callback : %s\n", test_text);
 
    _account_free_text(test_text);
 
    account_get_email_address(handle, &test_text);
-   printf("_account_get_callback : %s\n", test_text);
+   SECURE_LOGD("_account_get_callback : %s\n", test_text);
 
    _account_free_text(test_text);
 
    account_get_icon_path(handle, &test_text);
-   printf("_account_get_callback : %s\n", test_text);
+   SECURE_LOGD("_account_get_callback : %s\n", test_text);
 
    _account_free_text(test_text);
 
    account_get_source(handle, &test_text);
-   printf("_account_get_callback : %s\n", test_text);
+   SECURE_LOGD("_account_get_callback : %s\n", test_text);
 
    _account_free_text(test_text);
 
    account_get_package_name(handle, &test_text);
-   printf("_account_get_callback : %s\n", test_text);
+   SECURE_LOGD("_account_get_callback : %s\n", test_text);
 
    _account_free_text(test_text);
 
    account_get_domain_name(handle, &test_text);
-   printf("_account_get_callback : %s\n", test_text);
+   SECURE_LOGD("_account_get_callback : %s\n", test_text);
 
    _account_free_text(test_text);
 
    account_get_access_token(handle, &test_text);
-   printf("_account_get_callback : %s\n", test_text);
+   SECURE_LOGD("_account_get_callback : %s\n", test_text);
 
    int i;
 
@@ -394,28 +394,28 @@ bool _account_get_callback(account_h handle, void* user_data)
        _account_free_text(test_text);
 
        account_get_user_text(handle, i, &test_text);
-       printf("_account_get_callback : %s\n", test_text);
+       SECURE_LOGD("_account_get_callback : %s\n", test_text);
    }
 
    int test_int  = -1;
 
    account_auth_type_e auth_type;
    account_get_auth_type(handle, &auth_type);
-   printf("account_get_auth_type : %d\n", auth_type);
+   SECURE_LOGD("account_get_auth_type : %d\n", auth_type);
 
    account_secrecy_state_e secret;
    account_get_secret(handle, &secret);
-   printf("account_get_secret : %d\n", secret);
+   SECURE_LOGD("account_get_secret : %d\n", secret);
 
    account_sync_state_e sync_support;
    account_get_sync_support(handle, &sync_support);
-   printf("account_get_sync_support : %d\n", sync_support);
+   SECURE_LOGD("account_get_sync_support : %d\n", sync_support);
 
    for(i=0;i<USER_INT_CNT;i++)
    {
        test_int  = -1;
        account_get_user_int(handle, i, &test_int);
-       printf("_account_get_callback : %d\n", test_int);
+       SECURE_LOGD("_account_get_callback : %d\n", test_int);
    }
 
    account_get_capability(handle, _capability_get_callback, NULL);
@@ -432,19 +432,19 @@ void get_account_list_by_user_name(char * user_name)
    ret = account_connect();
    if(ret != ACCOUNT_ERROR_NONE)
    {
-          printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+          SECURE_LOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
    }
 
    ret = account_query_account_by_user_name(_account_get_callback, user_name, NULL);
    if(ret != ACCOUNT_ERROR_NONE)
    {
-          printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+          SECURE_LOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
    }
 
    ret = account_disconnect();
    if(ret != ACCOUNT_ERROR_NONE)
    {
-          printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+          SECURE_LOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
    }
 }
 @endcode
@@ -462,47 +462,47 @@ static void _account_free_text(char *text)
 
 bool _account_get_callback(account_h handle, void* user_data)
 {
-   printf("_account_get_callback\n");
+   SECURE_LOGD("_account_get_callback\n");
 
    char *test_text = NULL;
 
    account_get_user_name(handle, &test_text);
-   printf("_account_get_callback : %s\n", test_text);
+   SECURE_LOGD("_account_get_callback : %s\n", test_text);
 
    _account_free_text(test_text);
 
    account_get_display_name(handle, &test_text);
-   printf("_account_get_callback : %s\n", test_text);
+   SECURE_LOGD("_account_get_callback : %s\n", test_text);
 
    _account_free_text(test_text);
 
    account_get_email_address(handle, &test_text);
-   printf("_account_get_callback : %s\n", test_text);
+   SECURE_LOGD("_account_get_callback : %s\n", test_text);
 
    _account_free_text(test_text);
 
    account_get_icon_path(handle, &test_text);
-   printf("_account_get_callback : %s\n", test_text);
+   SECURE_LOGD("_account_get_callback : %s\n", test_text);
 
    _account_free_text(test_text);
 
    account_get_source(handle, &test_text);
-   printf("_account_get_callback : %s\n", test_text);
+   SECURE_LOGD("_account_get_callback : %s\n", test_text);
 
    _account_free_text(test_text);
 
    account_get_package_name(handle, &test_text);
-   printf("_account_get_callback : %s\n", test_text);
+   SECURE_LOGD("_account_get_callback : %s\n", test_text);
 
    _account_free_text(test_text);
 
    account_get_domain_name(handle, &test_text);
-   printf("_account_get_callback : %s\n", test_text);
+   SECURE_LOGD("_account_get_callback : %s\n", test_text);
 
    _account_free_text(test_text);
 
    account_get_access_token(handle, &test_text);
-   printf("_account_get_callback : %s\n", test_text);
+   SECURE_LOGD("_account_get_callback : %s\n", test_text);
 
    int i;
 
@@ -511,28 +511,28 @@ bool _account_get_callback(account_h handle, void* user_data)
           _account_free_text(test_text);
 
        account_get_user_text(handle, i, &test_text);
-       printf("_account_get_callback : %s\n", test_text);
+       SECURE_LOGD("_account_get_callback : %s\n", test_text);
    }
 
    int test_int  = -1;
 
    account_auth_type_e auth_type;
    account_get_auth_type(handle, &auth_type);
-   printf("account_get_auth_type : %d\n", auth_type);
+   SECURE_LOGD("account_get_auth_type : %d\n", auth_type);
 
    account_secrecy_state_e secret;
    account_get_secret(handle, &secret);
-   printf("account_get_secret : %d\n", secret);
+   SECURE_LOGD("account_get_secret : %d\n", secret);
 
    account_sync_state_e sync_support;
    account_get_sync_support(handle, &sync_support);
-   printf("account_get_sync_support : %d\n", sync_support);
+   SECURE_LOGD("account_get_sync_support : %d\n", sync_support);
 
    for(i=0;i<USER_INT_CNT;i++)
    {
        test_int  = -1;
        account_get_user_int(handle, i, &test_int);
-       printf("_account_get_callback : %d\n", test_int);
+       SECURE_LOGD("_account_get_callback : %d\n", test_int);
    }
 
    account_get_capability(handle, _capability_get_callback, NULL);
@@ -548,19 +548,19 @@ void get_account_list_by_package_name(char * package_name)
    ret = account_connect();
    if(ret != ACCOUNT_ERROR_NONE)
    {
-          printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+          SECURE_LOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
    }
 
    ret = account_query_account_by_package_name(_account_get_callback, package_name, NULL);
    if(ret != ACCOUNT_ERROR_NONE)
    {
-          printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+          SECURE_LOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
    }
 
    ret = account_disconnect();
    if(ret != ACCOUNT_ERROR_NONE)
    {
-          printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+          SECURE_LOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
    }
 }
 @endcode
@@ -578,47 +578,47 @@ static void _account_free_text(char *text)
 
 bool _account_get_callback(account_h handle, void* user_data)
 {
-   printf("_account_get_callback\n");
+   SECURE_LOGD("_account_get_callback\n");
 
    char *test_text = NULL;
 
    account_get_user_name(handle, &test_text);
-   printf("_account_get_callback : %s\n", test_text);
+   SECURE_LOGD("_account_get_callback : %s\n", test_text);
 
    _account_free_text(test_text);
 
    account_get_display_name(handle, &test_text);
-   printf("_account_get_callback : %s\n", test_text);
+   SECURE_LOGD("_account_get_callback : %s\n", test_text);
 
    _account_free_text(test_text);
 
    account_get_email_address(handle, &test_text);
-   printf("_account_get_callback : %s\n", test_text);
+   SECURE_LOGD("_account_get_callback : %s\n", test_text);
 
    _account_free_text(test_text);
 
    account_get_icon_path(handle, &test_text);
-   printf("_account_get_callback : %s\n", test_text);
+   SECURE_LOGD("_account_get_callback : %s\n", test_text);
 
    _account_free_text(test_text);
 
    account_get_source(handle, &test_text);
-   printf("_account_get_callback : %s\n", test_text);
+   SECURE_LOGD("_account_get_callback : %s\n", test_text);
 
    _account_free_text(test_text);
 
    account_get_package_name(handle, &test_text);
-   printf("_account_get_callback : %s\n", test_text);
+   SECURE_LOGD("_account_get_callback : %s\n", test_text);
 
    _account_free_text(test_text);
 
    account_get_domain_name(handle, &test_text);
-   printf("_account_get_callback : %s\n", test_text);
+   SECURE_LOGD("_account_get_callback : %s\n", test_text);
 
    _account_free_text(test_text);
 
    account_get_access_token(handle, &test_text);
-   printf("_account_get_callback : %s\n", test_text);
+   SECURE_LOGD("_account_get_callback : %s\n", test_text);
 
    int i;
 
@@ -627,28 +627,28 @@ bool _account_get_callback(account_h handle, void* user_data)
        _account_free_text(test_text);
 
        account_get_user_text(handle, i, &test_text);
-       printf("_account_get_callback : %s\n", test_text);
+       SECURE_LOGD("_account_get_callback : %s\n", test_text);
    }
 
    int test_int  = -1;
 
    account_auth_type_e auth_type;
    account_get_auth_type(handle, &auth_type);
-   printf("account_get_auth_type : %d\n", auth_type);
+   SECURE_LOGD("account_get_auth_type : %d\n", auth_type);
 
    account_secrecy_state_e secret;
    account_get_secret(handle, &secret);
-   printf("account_get_secret : %d\n", secret);
+   SECURE_LOGD("account_get_secret : %d\n", secret);
 
    account_sync_state_e sync_support;
    account_get_sync_support(handle, &sync_support);
-   printf("account_get_sync_support : %d\n", sync_support);
+   SECURE_LOGD("account_get_sync_support : %d\n", sync_support);
 
    for(i=0;i<USER_INT_CNT;i++)
    {
        test_int  = -1;
        account_get_user_int(handle, i, &test_int);
-       printf("_account_get_callback : %d\n", test_int);
+       SECURE_LOGD("_account_get_callback : %d\n", test_int);
    }
 
    account_get_capability(handle, _capability_get_callback, NULL);
@@ -664,19 +664,19 @@ void get_all_account()
    ret = account_connect();
    if(ret != ACCOUNT_ERROR_NONE)
    {
-          printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+          SECURE_LOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
    }
 
    ret = account_foreach_account_from_db(_account_get_callback, NULL);
    if(ret != ACCOUNT_ERROR_NONE)
    {
-          printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+          SECURE_LOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
    }
 
    ret = account_disconnect();
    if(ret != ACCOUNT_ERROR_NONE)
    {
-          printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+          SECURE_LOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
    }
 }
 @endcode
@@ -692,67 +692,67 @@ void update_accont_by_id(int account_id)
    ret = account_connect();
    if(ret != ACCOUNT_ERROR_NONE)
    {
-      printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+      SECURE_LOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
    }
 
    ret = account_create(&account);
    if(ret != ACCOUNT_ERROR_NONE)
    {
-      printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+      SECURE_LOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
    }
 
    ret = account_set_user_name(account, "update-tarun.kr");
 
    if(ret != ACCOUNT_ERROR_NONE)
    {
-       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+       SECURE_LOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
    }
 
    ret = account_set_display_name(account, "update-Tarun Kumar");
    if(ret != ACCOUNT_ERROR_NONE)
    {
-       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+       SECURE_LOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
    }
 
    ret = account_set_domain_name(account, "update-Samsung electronics");
    if(ret != ACCOUNT_ERROR_NONE)
    {
-       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+       SECURE_LOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
    }
 
    ret = account_set_email_address(account, "update-tarun@gmail.com");
    if(ret != ACCOUNT_ERROR_NONE)
    {
-       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+       SECURE_LOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
    }
 
    ret = account_set_package_name(account, "update-com.samsung.twiter");
    if(ret != ACCOUNT_ERROR_NONE)
    {
-       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+       SECURE_LOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
    }
 
    ret = account_set_icon_path(account, "update-icon-path");
    if(ret != ACCOUNT_ERROR_NONE)
    {
-       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+       SECURE_LOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
    }
 
    ret = account_set_access_token(account, "update-ACCESSTOKEN");
    if(ret != ACCOUNT_ERROR_NONE)
    {
-       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+       SECURE_LOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
    }
 
    ret = account_set_auth_type( account, ACCOUNT_AUTH_TYPE_OAUTH );
    if(ret != ACCOUNT_ERROR_NONE)
    {
-       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+       SECURE_LOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
    }
    ret = account_set_secret( account, ACCOUNT_SECRECY_INVISIBLE );
    if(ret != ACCOUNT_ERROR_NONE)
    {
-       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+       SECURE_LOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
    }
    ret = account_set_source(account, "update-URUSA inc.");
 
@@ -763,7 +763,7 @@ void update_accont_by_id(int account_id)
        ret = account_set_user_text(account, i, "update-user txt");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-           printf("(%d)-[Account] ret = %d, account=%p, i=%d\n", __LINE__, ret, account, i);
+           SECURE_LOGD("(%d)-[Account] ret = %d, account=%p, i=%d\n", __LINE__, ret, account, i);
        }
 
    }
@@ -773,7 +773,7 @@ void update_accont_by_id(int account_id)
        ret = account_set_user_int(account, i, 999);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-           printf("(%d)-[Account] ret = %d, account=%p, i=%d\n", __LINE__, ret, account, i);
+           SECURE_LOGD("(%d)-[Account] ret = %d, account=%p, i=%d\n", __LINE__, ret, account, i);
        }
    }
 
@@ -790,20 +790,20 @@ void update_accont_by_id(int account_id)
    ret = account_update_to_db_by_id(account, account_id);
    if(ret != ACCOUNT_ERROR_NONE)
    {
-       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+       SECURE_LOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        return;
    }
 
    ret = account_destroy(account);
    if(ret != ACCOUNT_ERROR_NONE)
    {
-       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+       SECURE_LOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
    }
 
    ret = account_disconnect();
    if(ret != ACCOUNT_ERROR_NONE)
    {
-       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+       SECURE_LOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
    }
 }
 @endcode
@@ -819,72 +819,72 @@ void update_accont_by_user_name(char *user_name, char *package_name)
    ret = account_connect();
    if(ret != ACCOUNT_ERROR_NONE)
    {
-      printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+      SECURE_LOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
    }
 
    ret = account_create(&account);
    if(ret != ACCOUNT_ERROR_NONE)
    {
-      printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+      SECURE_LOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
    }
 
    ret = account_set_user_name(account, "update-tarun.kr");
    if(ret != ACCOUNT_ERROR_NONE)
    {
-      printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+      SECURE_LOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
    }
 
    ret = account_set_display_name(account, "update-Tarun Kumar");
    if(ret != ACCOUNT_ERROR_NONE)
    {
-      printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+      SECURE_LOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
    }
 
    ret = account_set_domain_name(account, "update-Samsung electronics");
    if(ret != ACCOUNT_ERROR_NONE)
    {
-       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+       SECURE_LOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
    }
 
    ret = account_set_email_address(account, "update-tarun@gmail.com");
    if(ret != ACCOUNT_ERROR_NONE)
    {
-       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+       SECURE_LOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
    }
 
    ret = account_set_package_name(account, "update-com.samsung.twiter");
    if(ret != ACCOUNT_ERROR_NONE)
    {
-       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+       SECURE_LOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
    }
 
    ret = account_set_icon_path(account, "update-icon-path");
    if(ret != ACCOUNT_ERROR_NONE)
    {
-       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+       SECURE_LOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
    }
 
    ret = account_set_access_token(account, "update-ACCESSTOKEN");
    if(ret != ACCOUNT_ERROR_NONE)
    {
-       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+       SECURE_LOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
    }
 
    ret = account_set_auth_type( account, ACCOUNT_AUTH_TYPE_OAUTH );
    if(ret != ACCOUNT_ERROR_NONE)
    {
-       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+       SECURE_LOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
    }
    ret = account_set_secret( account, ACCOUNT_SECRECY_INVISIBLE );
    if(ret != ACCOUNT_ERROR_NONE)
    {
-          printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+          SECURE_LOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
    }
 
    ret = account_set_source(account, "update-URUSA inc.");
    if(ret != ACCOUNT_ERROR_NONE)
    {
-          printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+          SECURE_LOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
    }
 
    int i;
@@ -894,7 +894,7 @@ void update_accont_by_user_name(char *user_name, char *package_name)
        ret = account_set_user_text(account, i, "update-user txt");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-           printf("(%d)-[Account] ret = %d, account=%p, i=%d\n", __LINE__, ret, account, i);
+           SECURE_LOGD("(%d)-[Account] ret = %d, account=%p, i=%d\n", __LINE__, ret, account, i);
        }
 
    }
@@ -904,7 +904,7 @@ void update_accont_by_user_name(char *user_name, char *package_name)
        ret = account_set_user_int(account, i, 999);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-           printf("(%d)-[Account] ret = %d, account=%p, i=%d\n", __LINE__, ret, account, i);
+           SECURE_LOGD("(%d)-[Account] ret = %d, account=%p, i=%d\n", __LINE__, ret, account, i);
        }
    }
 
@@ -921,20 +921,20 @@ void update_accont_by_user_name(char *user_name, char *package_name)
    ret = account_update_to_db_by_user_name(account, user_name, package_name);
    if(ret != ACCOUNT_ERROR_NONE)
    {
-       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+       SECURE_LOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        return;
    }
 
    ret = account_destroy(account);
    if(ret != ACCOUNT_ERROR_NONE)
    {
-      printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+      SECURE_LOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
    }
 
    ret = account_disconnect();
    if(ret != ACCOUNT_ERROR_NONE)
    {
-      printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+      SECURE_LOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
    }
 }
 @endcode
@@ -949,19 +949,19 @@ void delete_account_by_id(int account_id)
    ret = account_connect();
    if(ret != ACCOUNT_ERROR_NONE)
    {
-          printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+          SECURE_LOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
    }
 
    ret = account_delete(account_id);
    if(ret != ACCOUNT_ERROR_NONE)
    {
-          printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+          SECURE_LOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
    }
 
    ret = account_disconnect();
    if(ret != ACCOUNT_ERROR_NONE)
    {
-          printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+          SECURE_LOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
    }
    return;
 }
@@ -977,19 +977,19 @@ void update_sync_status_by_id(int account_id, const account_sync_state_e sync_st
    ret = account_connect();
    if(ret != ACCOUNT_ERROR_NONE)
    {
-          printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+          SECURE_LOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
    }
 
    ret = account_update_sync_status_by_id(account_id, sync_status);
    if(ret != ACCOUNT_ERROR_NONE)
    {
-          printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+          SECURE_LOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
    }
 
    ret = account_disconnect();
    if(ret != ACCOUNT_ERROR_NONE)
    {
-          printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+          SECURE_LOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
    }
    return;
 }
@@ -1004,19 +1004,19 @@ void delete_account_by_user_name(char *user_name, char *package_name)
    ret = account_connect();
    if(ret != ACCOUNT_ERROR_NONE)
    {
-          printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+          SECURE_LOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
    }
 
    ret = account_delete_from_db_by_user_name(user_name, package_name);
    if(ret != ACCOUNT_ERROR_NONE)
    {
-          printf("(%d)-[Account] ret = %d \n", __LINE__, ret);
+          SECURE_LOGD("(%d)-[Account] ret = %d \n", __LINE__, ret);
    }
 
    ret = account_disconnect();
    if(ret != ACCOUNT_ERROR_NONE)
    {
-          printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+          SECURE_LOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
    }
    return;
 }
@@ -1031,19 +1031,19 @@ void delete_account_by_package_name(char *package_name)
    ret = account_connect();
    if(ret != ACCOUNT_ERROR_NONE)
    {
-          printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+          SECURE_LOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
    }
 
    ret = account_delete_from_db_by_package_name(package_name);
    if(ret != ACCOUNT_ERROR_NONE)
    {
-          printf("(%d)-[Account] ret = %d \n", __LINE__, ret);
+          SECURE_LOGD("(%d)-[Account] ret = %d \n", __LINE__, ret);
    }
 
    ret = account_disconnect();
    if(ret != ACCOUNT_ERROR_NONE)
    {
-          printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+          SECURE_LOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
    }
    return;
 }
@@ -1058,13 +1058,12 @@ void notify_account_insert()
     DBusConnection* conn;
     DBusError err;
 
-    printf("Listening for signals\n");
+    SECURE_LOGD("Listening for signals\n");
 
     dbus_error_init(&err);
 
     conn = dbus_bus_get(DBUS_BUS_SYSTEM, &err);
     if  (dbus_error_is_set(&err)) {
-            fprintf(stderr, "Connection Error (%s)\n", err.message);
             dbus_error_free(&err);
     }
     if (NULL == conn) {
@@ -1074,10 +1073,9 @@ void notify_account_insert()
     dbus_bus_add_match(conn, "type='signal',interface='account.signal.Type'", &err);
     dbus_connection_flush(conn);
     if  (dbus_error_is_set(&err)) {
-            fprintf(stderr, "Match Error (%s)\n", err.message);
             exit(1);
     }
-    printf("Match rule sent\n");
+    SECURE_LOGD("Match rule sent\n");
 
     while (true) {
 
@@ -1090,7 +1088,7 @@ void notify_account_insert()
             }
 
             if (dbus_message_is_signal(msg, ACCOUNT_DBUS_SIGNAL_INTERFACE, ACCOUNT_DBUS_NOTI_NAME_INSERT)) {
-                 printf("Got Signal with name insert\n");
+                 SECURE_LOGD("Got Signal with name insert\n");
             }
 
             dbus_message_unref(msg);
@@ -1108,14 +1106,13 @@ void notify_account_update()
     DBusConnection* conn;
     DBusError err;
 
-    printf("Listening for signals\n");
+    SECURE_LOGD("Listening for signals\n");
 
 
     dbus_error_init(&err);
 
     conn = dbus_bus_get(DBUS_BUS_SYSTEM, &err);
     if  (dbus_error_is_set(&err)) {
-            fprintf(stderr, "Connection Error (%s)\n", err.message);
             dbus_error_free(&err);
     }
     if (NULL == conn) {
@@ -1125,10 +1122,9 @@ void notify_account_update()
     dbus_bus_add_match(conn, "type='signal',interface='account.signal.Type'", &err);
     dbus_connection_flush(conn);
     if  (dbus_error_is_set(&err)) {
-            fprintf(stderr, "Match Error (%s)\n", err.message);
             exit(1);
     }
-    printf("Match rule sent\n");
+    SECURE_LOGD("Match rule sent\n");
 
     while (true) {
 
@@ -1141,7 +1137,7 @@ void notify_account_update()
             }
 
             if (dbus_message_is_signal(msg, ACCOUNT_DBUS_SIGNAL_INTERFACE, ACCOUNT_DBUS_NOTI_NAME_UPDATE)) {
-                printf("Got Signal with name update\n");
+                SECURE_LOGD("Got Signal with name update\n");
             }
 
             dbus_message_unref(msg);
@@ -1159,14 +1155,13 @@ void notify_account_delete()
     DBusConnection* conn;
     DBusError err;
 
-    printf("Listening for signals\n");
+    SECURE_LOGD("Listening for signals\n");
 
 
     dbus_error_init(&err);
 
     conn = dbus_bus_get(DBUS_BUS_SYSTEM, &err);
     if  (dbus_error_is_set(&err)) {
-            fprintf(stderr, "Connection Error (%s)\n", err.message);
             dbus_error_free(&err);
     }
     if (NULL == conn) {
@@ -1176,10 +1171,9 @@ void notify_account_delete()
     dbus_bus_add_match(conn, "type='signal',interface='account.signal.Type'", &err);
     dbus_connection_flush(conn);
     if  (dbus_error_is_set(&err)) {
-            fprintf(stderr, "Match Error (%s)\n", err.message);
             exit(1);
     }
-    printf("Match rule sent\n");
+    SECURE_LOGD("Match rule sent\n");
 
     while (true) {
 
@@ -1192,7 +1186,7 @@ void notify_account_delete()
             }
 
             if (dbus_message_is_signal(msg, ACCOUNT_DBUS_SIGNAL_INTERFACE, ACCOUNT_DBUS_NOTI_NAME_DELETE)) {
-                printf("Got Signal with name delete\n");
+                SECURE_LOGD("Got Signal with name delete\n");
             }
 
             dbus_message_unref(msg);
@@ -1209,8 +1203,8 @@ bool _capability_get_callback(const char* capability_type, account_capability_st
    char* test_type = capability_type;
    int test_value = capability_value;
 
-   printf("_capability_get_callback test_type = : %s\n", test_type);
-   printf("_capability_get_callback test_value = : %d\n", test_value);
+   SECURE_LOGD("_capability_get_callback test_type = : %s\n", test_type);
+   SECURE_LOGD("_capability_get_callback test_value = : %d\n", test_value);
    return TRUE;
 }
 
@@ -1220,19 +1214,19 @@ void capability_by_account_id(int account_id)
    ret = account_connect();
    if(ret != ACCOUNT_ERROR_NONE)
    {
-          printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+          SECURE_LOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
    }
 
    ret = account_query_capability_by_account_id(_capability_get_callback, account_id, NULL);
    if(ret != ACCOUNT_ERROR_NONE)
    {
-          printf("(%d)-[Account] ret = %d \n", __LINE__, ret);
+          SECURE_LOGD("(%d)-[Account] ret = %d \n", __LINE__, ret);
    }
 
    ret = account_disconnect();
    if(ret != ACCOUNT_ERROR_NONE)
    {
-          printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+          SECURE_LOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
    }
    return;
 }
index c26610e..d3b333c 100755 (executable)
@@ -3,6 +3,7 @@
                <domain name="libaccounts-svc"/>
                <provide>
                        <label name="libaccounts-svc::db"/>
+                       <label name="libaccounts-svc::check_read"/>
                </provide>
                <request>
                        <smack request="libaccounts-svc::db" type="rw" />
@@ -13,6 +14,6 @@
        </request>
        <assign>
                <filesystem path="/usr/lib/libaccounts-svc.so.0" label="_" />
-               <filesystem path="/usr/lib/libaccounts-svc.so.0.2.66" label="_" />
+               <filesystem path="/usr/lib/libaccounts-svc.so.0.2.97" label="_" />
        </assign>
 </manifest>
index 342ef5e..7ce73ac 100755 (executable)
@@ -1,13 +1,14 @@
 
 Name:       libaccounts-svc
 Summary:    Account DB library
-Version:    0.2.66
+Version:    0.2.113
 Release:    1
 Group:      TO_BE/FILLED_IN
-License:    Apache-2.0
+License:    TO BE FILLED IN
 Source0:    libaccounts-svc-%{version}.tar.gz
 
 BuildRequires:  cmake
+BuildRequires:  pkgconfig(sqlite3)
 BuildRequires:  pkgconfig(glib-2.0)
 BuildRequires:  pkgconfig(dlog)
 BuildRequires:  pkgconfig(db-util)
@@ -15,6 +16,8 @@ BuildRequires:  pkgconfig(capi-base-common)
 BuildRequires:  pkgconfig(vconf)
 BuildRequires:  pkgconfig(pkgmgr-info)
 BuildRequires:  pkgconfig(aul)
+BuildRequires:  pkgconfig(libsmack)
+
 Requires(post): /sbin/ldconfig
 Requires(post): /usr/bin/sqlite3
 Requires(postun): /sbin/ldconfig
@@ -33,6 +36,15 @@ Development files for %{name}
 %setup -q
 
 %build
+export   CFLAGS+=" -Wextra -Wcast-align -Wcast-qual -Wshadow -Wwrite-strings -Wswitch-default"
+export CXXFLAGS+=" -Wextra -Wcast-align -Wcast-qual -Wshadow -Wwrite-strings -Wswitch-default -Wnon-virtual-dtor -Wno-c++0x-compat"
+#export  CFLAGS+=" -Wno-array-bounds -Wno-ignored-qualifiers"
+export   CFLAGS+=" -Wno-unused-parameter -Wno-empty-body"
+export CXXFLAGS+=" -Wno-unused-parameter -Wno-empty-body"
+
+export   CFLAGS+=" -fno-omit-frame-pointer -fno-optimize-sibling-calls -fno-strict-aliasing -fno-unroll-loops -fsigned-char -fstrict-overflow -fno-common"
+export CXXFLAGS+=" -fno-omit-frame-pointer -fno-optimize-sibling-calls -fno-strict-aliasing -fno-unroll-loops -fsigned-char -fstrict-overflow"
+
 export CFLAGS="${CFLAGS} -fPIC -fvisibility=hidden"
 cmake . -DCMAKE_INSTALL_PREFIX=/usr
 
@@ -43,19 +55,17 @@ rm -rf %{buildroot}
 %make_install
 
 rm -rf %{buildroot}/usr/lib/accounts-svc
-mkdir -p %{buildroot}/usr/share/license
-cp %{_builddir}/%{name}-%{version}/LICENSE.APLv2 %{buildroot}/usr/share/license/%{name}
 
 %post
 /sbin/ldconfig
-if [ ! -d /opt/dbspace ]
+if [ ! -d /opt/usr/dbspace ]
 then
-        mkdir -p /opt/dbspace
+        mkdir -p /opt/usr/dbspace
 fi
-if [ ! -f /opt/dbspace/.account.db ]
-#rm -rf /opt/dbspace/.account.db*
+if [ ! -f /opt/usr/dbspace/.account.db ]
+#rm -rf /opt/usr/dbspace/.account.db*
 then
-       sqlite3 /opt/dbspace/.account.db 'PRAGMA journal_mode = PERSIST;
+        sqlite3 /opt/usr/dbspace/.account.db 'PRAGMA journal_mode = PERSIST;
         CREATE TABLE if not exists label (AppId TEXT, Label TEXT, Locale TEXT);
         CREATE TABLE if not exists account_type (_id INTEGER PRIMARY KEY AUTOINCREMENT, AppId TEXT,
         ServiceProviderId TEXT, IconPath TEXT, SmallIconPath TEXT, MultipleAccountSupport INT);
@@ -66,35 +76,37 @@ then
         int_custom0 INTEGER, int_custom1 INTEGER, int_custom2 INTEGER, int_custom3 INTEGER, int_custom4 INTEGER);
         CREATE TABLE if not exists capability (_id INTEGER PRIMARY KEY AUTOINCREMENT, key TEXT, value INTEGER,
         package_name TEXT, user_name TEXT,  account_id INTEGER, FOREIGN KEY (account_id) REFERENCES account(_id));
-       CREATE TABLE if not exists provider_feature (app_id TEXT, key TEXT);'
+       CREATE TABLE if not exists provider_feature (app_id TEXT, key TEXT);
+'
 fi
 
 mkdir -p /opt/usr/share/account
-chown 5000:5000 /opt/dbspace/.account.db
-chown 5000:5000 /opt/dbspace/.account.db-journal
-chown 5000:5000 /opt/usr/share/account
+chown 0:5000 /opt/usr/dbspace/.account.db
+chown 0:5000 /opt/usr/dbspace/.account.db-journal
 
-chmod 660 /opt/dbspace/.account.db
-chmod 660 /opt/dbspace/.account.db-journal
-chmod 755 /opt/usr/share/account
+chmod 664 /opt/usr/dbspace/.account.db
+chmod 664 /opt/usr/dbspace/.account.db-journal
 
 #set message key value to NULL
-vconftool set -t string db/account/msg '' -g 6514
+#vconftool set -t string db/account/msg '' -g 6514
+vconftool set -t string db/account/msg '' -s libaccounts-svc -g 6514
 
 #smack labeling
 if [ -f /usr/lib/rpm-plugins/msm.so ]
 then
-       chsmack -a 'libaccounts-svc::db' /opt/dbspace/.account.db-journal
-       chsmack -a 'libaccounts-svc::db' /opt/dbspace/.account.db
+       chsmack -a 'libaccounts-svc::db' /opt/usr/dbspace/.account.db-journal
+       chsmack -a 'libaccounts-svc::db' /opt/usr/dbspace/.account.db
 fi
 
+
 %postun -p /sbin/ldconfig
 
+
+
 %files
 %manifest libaccounts-svc.manifest
 %defattr(-,root,root,-)
 %{_libdir}/*.so.*
-/usr/share/license/%{name}
 
 %files devel
 %defattr(-,root,root,-)
index 30f1968..c6e4b8c 100755 (executable)
 #include <glib.h>
 #include <db-util.h>
 #include <pthread.h>
-#include <assert.h>
 #include <account-private.h>
 #include <vconf.h>
 
+#define SAMSUNG_ACCOUNT_MANAGER
+
 #include <pkgmgr-info.h>
 #include <aul.h>
 #include <unistd.h>
+#include <sys/types.h>
+#include <sys/smack.h>
 
 #define EAS_CMDLINE "/usr/bin/eas-engine"
 #define EMAIL_SERVICE_CMDLINE "/usr/bin/email-service"
+#define IMS_ENGINE_CMDLINE "/usr/bin/ims-srv"
+#define IMS_AGENT_CMDLINE "/usr/bin/ims-agent"
+#define MDM_SERVER_CMDLINE "/usr/bin/mdm-server"
+
+#define RCS_APPID "com.samsung.rcs-im"
+#define IMS_SERVICE_APPID "ims-service"
 #define ACTIVESYNC_APPID "activesync-ui"
+#define EMAIL_APPID "email-setting-efl"
+#define SYNCHRONISE_APPID "setting-synchronise-efl"
+#define DS_AGENT_CMDLINE "/usr/bin/oma-ds-agent"
+
+#define FACEBOOK_SDK_APPID "com.samsung.facebook-service"
+#define FACEBOOK_APPID "com.samsung.facebook"
+
+#define ACCOUNT_DB_OPEN_READONLY 0
+#define ACCOUNT_DB_OPEN_READWRITE 1
 
 static sqlite3* g_hAccountDB = NULL;
 static int             g_refCntDB = 0;
@@ -46,20 +64,25 @@ pthread_mutex_t account_mutex = PTHREAD_MUTEX_INITIALIZER;
 static char *_account_get_text(const char *text_data);
 static int _account_gslist_free(GSList* list);
 static int _account_glist_free(GList* list);
-static char *_account_query_table_column_text(account_stmt pStmt, int pos);
+static const char *_account_query_table_column_text(account_stmt pStmt, int pos);
 static int _account_insert_custom(account_s *account, int account_id);
 static int _account_update_custom(account_s *account, int account_id);
-static int _account_query_custom_by_account_id(account_custom_cb cb_func, int account_id, void *user_data );
+static int _account_query_custom_by_account_id(account_custom_cb callback, int account_id, void *user_data );
 static int _account_type_update_provider_feature(account_type_s *account_type, const char* app_id);
 
 int _account_get_current_appid_cb(const pkgmgrinfo_appinfo_h handle, void *user_data)
 {
-       int ret = -1;
        char* appid = NULL;
        char* item = NULL;
        GSList** appid_list = (GSList**)user_data;
+       int pkgmgr_ret = -1;
+
+       pkgmgr_ret = pkgmgrinfo_appinfo_get_appid(handle, &appid);
+
+       if( pkgmgr_ret != PMINFO_R_OK ){
+               ACCOUNT_DEBUG("pkgmgrinfo_appinfo_get_appid(%d)", pkgmgr_ret);
+       }
 
-       ret = pkgmgrinfo_appinfo_get_appid(handle, &appid);
        item = _account_get_text(appid);
        *appid_list = g_slist_append(*appid_list, item);
 
@@ -102,7 +125,7 @@ char *_account_get_proc_cmdline_bypid(int pid)
        ACCOUNT_SNPRINTF(buf, sizeof(buf), "/proc/%d/cmdline", pid);
        ret = __read_proc(buf, buf, sizeof(buf));
        if (ret <= 0) {
-               ACCOUNT_INFO("No proc directory (%d)\n", pid);
+               ACCOUNT_DEBUG("No proc directory (%d)\n", pid);
                return NULL;
        }
 
@@ -112,53 +135,79 @@ char *_account_get_proc_cmdline_bypid(int pid)
 
 static char* _account_get_current_appid()
 {
-       int pid=0, ret=-1;
+       int ret=0, pid=0;
        char appid[128]={0,};
-       pkgmgrinfo_appinfo_h ahandle=NULL;
        char* appid_ret = NULL;
 
        pid = getpid();
-       ACCOUNT_INFO("pid (%d)\n", pid, ret);
        ret = aul_app_get_appid_bypid(pid, appid, sizeof(appid));
-       ACCOUNT_INFO("appid (%s) ret(%d)!!!!!!\n", appid, ret);
+
+       if(ret < 0){
+               ACCOUNT_ERROR("fail to get current appid\n");
+       }
 
        /* SLP platform core exception */
        if(strlen(appid) == 0){
                char* cmdline = NULL;
                cmdline = _account_get_proc_cmdline_bypid(pid);
-               ACCOUNT_INFO("cmdline (%s)!!!!!!\n", cmdline);
-               if(!strcmp(cmdline, EAS_CMDLINE)) {
+               ACCOUNT_SLOGD("cmdline (%s)!!!!!!\n", cmdline);
+               if(!g_strcmp0(cmdline, EAS_CMDLINE)) {
                        appid_ret = _account_get_text(ACTIVESYNC_APPID);
+                       _ACCOUNT_FREE(cmdline);
+                       return appid_ret;
+               } else if (!g_strcmp0(cmdline, EMAIL_SERVICE_CMDLINE) || !g_strcmp0(cmdline, MDM_SERVER_CMDLINE)) {
+                       appid_ret = _account_get_text(EMAIL_APPID);
+                       _ACCOUNT_FREE(cmdline);
+                       return appid_ret;
+               } else if (!g_strcmp0(cmdline, IMS_ENGINE_CMDLINE) || !g_strcmp0(cmdline, IMS_AGENT_CMDLINE)) {
+                       if(account_type_query_app_id_exist(RCS_APPID)==ACCOUNT_ERROR_NONE){
+                               appid_ret = _account_get_text(RCS_APPID);
+                       } else if(account_type_query_app_id_exist(IMS_SERVICE_APPID)==ACCOUNT_ERROR_NONE){
+                               appid_ret = _account_get_text(IMS_SERVICE_APPID);
+                       } else {
+                               appid_ret = _account_get_text(RCS_APPID);
+                       }
+                       _ACCOUNT_FREE(cmdline);
+                       return appid_ret;
+               } else if (!g_strcmp0(cmdline, DS_AGENT_CMDLINE)) {
+                       appid_ret = _account_get_text(SYNCHRONISE_APPID);
+                       _ACCOUNT_FREE(cmdline);
                        return appid_ret;
                } else {
-                       ACCOUNT_ERROR("No app id\n");
+                       ACCOUNT_DEBUG("No app id\n");
+                       _ACCOUNT_FREE(cmdline);
                        return NULL;
                }
        }
 
-       appid_ret = _account_get_text(appid);
+       /* temporary exception */
+       if(!g_strcmp0(appid, "com.samsung.gallery")){
+               appid_ret = _account_get_text("com.samsung.facebook");
+       } else if(!g_strcmp0(appid, FACEBOOK_SDK_APPID)){
+               appid_ret = _account_get_text(FACEBOOK_APPID);
+       } else {
+               appid_ret = _account_get_text(appid);
+       }
 
-       pkgmgrinfo_appinfo_destroy_appinfo(ahandle);
        return appid_ret;
 }
 
 static int _account_check_account_type_with_appid_group(const char* appid, char** verified_appid)
 {
        int error_code = ACCOUNT_ERROR_NOT_REGISTERED_PROVIDER;
-       int ret=-1;
        pkgmgrinfo_appinfo_h ahandle=NULL;
        pkgmgrinfo_pkginfo_h phandle=NULL;
-       char* package_id;
+       char* package_id = NULL;
        GSList* appid_list = NULL;
        GSList* iter = NULL;
 
        if(!appid){
-               ACCOUNT_INFO("input param is null\n");
+               ACCOUNT_ERROR("input param is null\n");
                return ACCOUNT_ERROR_NOT_REGISTERED_PROVIDER;
        }
 
        if(!verified_appid){
-               ACCOUNT_INFO("output param is null\n");
+               ACCOUNT_ERROR("output param is null\n");
                return ACCOUNT_ERROR_NOT_REGISTERED_PROVIDER;
        }
 
@@ -168,47 +217,157 @@ static int _account_check_account_type_with_appid_group(const char* appid, char*
                return ACCOUNT_ERROR_NONE;
        }
 
-       /* Get app id family which is stored in account database */
-       ret = pkgmgrinfo_appinfo_get_appinfo(appid, &ahandle);
-       ACCOUNT_INFO("ahandle (%p), ret(%x)\n", ahandle, ret);
-       ret = pkgmgrinfo_appinfo_get_pkgid(ahandle, &package_id);
-       ACCOUNT_INFO("package_id (%s), ret(%x)\n", package_id, ret);
-       ret = pkgmgrinfo_pkginfo_get_pkginfo(package_id, &phandle);
-       ACCOUNT_INFO("phandle (%p), ret(%x)\n", package_id, ret);
+       if(!strcmp(appid, "com.samsung.samsung-account-front")){
+               ACCOUNT_DEBUG("Setting exception\n");
+               *verified_appid = _account_get_text("com.samsung.samsung-account-front");
+               return ACCOUNT_ERROR_NONE;
+       }
+
+       if(!strcmp(appid, IMS_SERVICE_APPID) || !strcmp(appid, RCS_APPID)){
+               ACCOUNT_DEBUG("ims service exception\n");
+               *verified_appid = _account_get_text(appid);
+               return ACCOUNT_ERROR_NONE;
+       }
 
-       ret = pkgmgrinfo_appinfo_get_list(phandle, PMINFO_ALL_APP, _account_get_current_appid_cb, (void *)&appid_list); //==> pkgÇڵ鿡 Â¼Ã“ÇÑ ui-appid Â¸Ã°ÂµÃŽ ÃƒÂ£Ã€Â½
-       ACCOUNT_INFO("ret(%x)\n", ret);
+       /* Get app id family which is stored in account database */
+       int pkgmgr_ret = -1;
+       pkgmgr_ret = pkgmgrinfo_appinfo_get_appinfo(appid, &ahandle);
+       if( pkgmgr_ret != PMINFO_R_OK ){
+               ACCOUNT_DEBUG("pkgmgrinfo_appinfo_get_appinfo(%d)", pkgmgr_ret);
+       }
+       pkgmgr_ret = pkgmgrinfo_appinfo_get_pkgid(ahandle, &package_id);
+       if( pkgmgr_ret != PMINFO_R_OK ){
+               ACCOUNT_DEBUG("pkgmgrinfo_appinfo_get_pkgid(%d)", pkgmgr_ret);
+       }
+       pkgmgr_ret = pkgmgrinfo_pkginfo_get_pkginfo(package_id, &phandle);
+       if( pkgmgr_ret != PMINFO_R_OK ){
+               ACCOUNT_DEBUG("pkgmgrinfo_pkginfo_get_pkginfo(%d)", pkgmgr_ret);
+       }
+       pkgmgr_ret = pkgmgrinfo_appinfo_get_list(phandle, PMINFO_ALL_APP, _account_get_current_appid_cb, (void *)&appid_list);
+       if( pkgmgr_ret != PMINFO_R_OK ){
+               ACCOUNT_DEBUG("pkgmgrinfo_appinfo_get_list(%d)", pkgmgr_ret);
+       }
 
        /* Compare current app id with the stored app id family */
        for(iter=appid_list;iter!=NULL;iter=g_slist_next(iter)){
                char* tmp = (char*)iter->data;
                if(tmp) {
                        if(account_type_query_app_id_exist(tmp) == ACCOUNT_ERROR_NONE) {
-                               ACCOUNT_INFO("permission verified appid(%s), current appid(%s)\n", tmp, appid);
                                *verified_appid = _account_get_text(tmp);
                                error_code = ACCOUNT_ERROR_NONE;
                                _ACCOUNT_FREE(tmp);
                                break;
                        } else {
-                               ACCOUNT_DEBUG("not matched owner group app id(%s), current appid(%s)\n", tmp, appid);
+                               ACCOUNT_SLOGD("not matched owner group app id(%s), current appid(%s)\n", tmp, appid);
+                       }
+               }
+               _ACCOUNT_FREE(tmp);
+       }
+
+       g_slist_free(appid_list);
+       pkgmgr_ret = pkgmgrinfo_pkginfo_destroy_pkginfo(phandle);
+       if( pkgmgr_ret != PMINFO_R_OK ){
+               ACCOUNT_DEBUG("pkgmgrinfo_pkginfo_destroy_pkginfo(%d)", pkgmgr_ret);
+       }
+
+       pkgmgr_ret = pkgmgrinfo_appinfo_destroy_appinfo(ahandle);
+       if( pkgmgr_ret != PMINFO_R_OK ){
+               ACCOUNT_DEBUG("pkgmgrinfo_appinfo_destroy_appinfo(%d)", pkgmgr_ret);
+       }
+
+       return error_code;
+}
+
+static int _account_check_appid_group_with_package_name(const char* appid, char* package_name)
+{
+       int error_code = ACCOUNT_ERROR_PERMISSION_DENIED;
+       pkgmgrinfo_appinfo_h ahandle=NULL;
+       pkgmgrinfo_pkginfo_h phandle=NULL;
+       char* package_id = NULL;
+       GSList* appid_list = NULL;
+       GSList* iter = NULL;
+
+       if(!appid){
+               ACCOUNT_ERROR("input param -appid is null\n");
+               return ACCOUNT_ERROR_INVALID_PARAMETER;
+       }
+
+       if(!package_name){
+               ACCOUNT_ERROR("input param - package name is null\n");
+               return ACCOUNT_ERROR_INVALID_PARAMETER;
+       }
+
+       /* ims-service Exception */
+       if ( strcmp(appid, "ims-service") == 0 &&       strcmp(package_name, "ims-service") == 0 ) {
+               ACCOUNT_DEBUG("ims exception.");                                // TODO: NEED TO REMOVE, debug log.
+               return ACCOUNT_ERROR_NONE;
+       }
+
+       /* Get app id family which is stored in account database */
+       int pkgmgr_ret = -1;
+       pkgmgr_ret = pkgmgrinfo_appinfo_get_appinfo(appid, &ahandle);
+       if( pkgmgr_ret != PMINFO_R_OK ){
+               ACCOUNT_DEBUG("pkgmgrinfo_appinfo_get_appinfo(%d)", pkgmgr_ret);
+       }
+       pkgmgr_ret = pkgmgrinfo_appinfo_get_pkgid(ahandle, &package_id);
+       if( pkgmgr_ret != PMINFO_R_OK ){
+               ACCOUNT_DEBUG("pkgmgrinfo_appinfo_get_pkgid(%d)", pkgmgr_ret);
+       }
+       pkgmgr_ret = pkgmgrinfo_pkginfo_get_pkginfo(package_id, &phandle);
+       if( pkgmgr_ret != PMINFO_R_OK ){
+               ACCOUNT_DEBUG("pkgmgrinfo_pkginfo_get_pkginfo(%d)", pkgmgr_ret);
+       }
+       pkgmgr_ret = pkgmgrinfo_appinfo_get_list(phandle, PMINFO_ALL_APP, _account_get_current_appid_cb, (void *)&appid_list);
+       if( pkgmgr_ret != PMINFO_R_OK ){
+               ACCOUNT_DEBUG("pkgmgrinfo_appinfo_get_list(%d)", pkgmgr_ret);
+       }
+
+       /* Compare current app id with the stored app id family */
+       for(iter=appid_list;iter!=NULL;iter=g_slist_next(iter)){
+               char* tmp = (char*)iter->data;
+               if(tmp) {
+                       //ACCOUNT_ERROR("tmp(%s)package_name(%s)\n\n", tmp, package_name);      // TODO: NEED TO REMOVE, debug log.
+                       if( strcmp(tmp, package_name) == 0) {
+                               error_code = ACCOUNT_ERROR_NONE;
+                               _ACCOUNT_FREE(tmp);
+                               break;
+                       } else if ( strcmp(tmp, SAMSUNGACCOUNTFRONT_PKG_NAME) == 0 &&
+                                               strcmp(package_name, SAMSUNGACCOUNT_PKG_NAME) == 0 ) {
+                               /* Samung Account Exception */
+                               error_code = ACCOUNT_ERROR_NONE;
+                               _ACCOUNT_FREE(tmp);
+                               break;
+                       } else {
+                               ACCOUNT_SLOGD("not matched owner group app id(%s), current appid(%s)\n", tmp, appid);
                        }
                }
                _ACCOUNT_FREE(tmp);
        }
 
        g_slist_free(appid_list);
-       pkgmgrinfo_pkginfo_destroy_pkginfo(phandle);
-       pkgmgrinfo_appinfo_destroy_appinfo(ahandle);
+       pkgmgr_ret = pkgmgrinfo_pkginfo_destroy_pkginfo(phandle);
+       if( pkgmgr_ret != PMINFO_R_OK ){
+               ACCOUNT_DEBUG("pkgmgrinfo_pkginfo_destroy_pkginfo(%d)", pkgmgr_ret);
+       }
+
+       pkgmgr_ret = pkgmgrinfo_appinfo_destroy_appinfo(ahandle);
+       if( pkgmgr_ret != PMINFO_R_OK ){
+               ACCOUNT_DEBUG("pkgmgrinfo_appinfo_destroy_appinfo(%d)", pkgmgr_ret);
+       }
 
        return error_code;
 }
 
 static const char *_account_db_err_msg()
 {
-       assert(NULL != g_hAccountDB);
        return sqlite3_errmsg(g_hAccountDB);
 }
 
+static int _account_db_err_code()
+{
+       return sqlite3_errcode(g_hAccountDB);
+}
+
 static void _account_insert_delete_update_notification_send(char *noti_name)
 {
        if (!noti_name) {
@@ -216,11 +375,9 @@ static void _account_insert_delete_update_notification_send(char *noti_name)
                return;
        }
 
-       ACCOUNT_DEBUG("Sending notification with value %s\n", noti_name);
+       ACCOUNT_DEBUG("noti_type = %s", noti_name);
 
-       if (vconf_set_str(VCONFKEY_ACCOUNT_MSG_STR, noti_name) == 0) {
-               ACCOUNT_VERBOSE("Vconf MSG Str set SUCCESS !!!!!!\n");;
-       } else {
+       if (vconf_set_str(VCONFKEY_ACCOUNT_MSG_STR, noti_name) != 0) {
                ACCOUNT_ERROR("Vconf MSG Str set FAILED !!!!!!\n");;
        }
 }
@@ -231,12 +388,34 @@ static int _account_get_record_count(char* query)
        int ncount = 0;
        account_stmt pStmt = NULL;
 
-       assert(NULL != query);
-       assert(NULL != g_hAccountDB);
+       if(!query){
+               ACCOUNT_ERROR("NULL query\n");
+               return ACCOUNT_ERROR_QUERY_SYNTAX_ERROR;
+       }
+
+       if(!g_hAccountDB){
+               ACCOUNT_ERROR("DB is not opened\n");
+               return ACCOUNT_ERROR_DB_NOT_OPENED;
+       }
+
        rc = sqlite3_prepare_v2(g_hAccountDB, query, strlen(query), &pStmt, NULL);
 
+       if (SQLITE_BUSY == rc){
+               ACCOUNT_ERROR("sqlite3_prepare_v2() failed(%d, %s).", rc, _account_db_err_msg());
+               sqlite3_finalize(pStmt);
+               return ACCOUNT_ERROR_DATABASE_BUSY;
+       } else if (SQLITE_OK != rc) {
+               ACCOUNT_ERROR("sqlite3_prepare_v2() failed(%d, %s).", rc, _account_db_err_msg());
+               sqlite3_finalize(pStmt);
+               return ACCOUNT_ERROR_DB_FAILED;
+       }
+
        rc = sqlite3_step(pStmt);
-       if (SQLITE_ROW != rc) {
+       if (SQLITE_BUSY == rc) {
+               ACCOUNT_ERROR("sqlite3_step() failed(%d, %s).", rc, _account_db_err_msg());
+               sqlite3_finalize(pStmt);
+               return ACCOUNT_ERROR_DATABASE_BUSY;
+       } else if (SQLITE_ROW != rc) {
                ACCOUNT_ERROR("sqlite3_step() failed(%d, %s).", rc, _account_db_err_msg());
                sqlite3_finalize(pStmt);
                return ACCOUNT_ERROR_DB_FAILED;
@@ -244,25 +423,29 @@ static int _account_get_record_count(char* query)
 
        ncount = sqlite3_column_int(pStmt, 0);
 
-       ACCOUNT_VERBOSE("count : %d, End", ncount);
        sqlite3_finalize(pStmt);
 
        return ncount;
 }
 
-static int _account_execute_query(char *query)
+static int _account_execute_query(const char *query)
 {
        int rc = -1;
        char* pszErrorMsg = NULL;
 
-       assert(NULL != query);
-       assert(NULL != g_hAccountDB);
+       if(!query){
+               ACCOUNT_ERROR("NULL query\n");
+               return ACCOUNT_ERROR_QUERY_SYNTAX_ERROR;
+       }
 
-       ACCOUNT_INFO("query : %s", query);
+       if(!g_hAccountDB){
+               ACCOUNT_ERROR("DB is not opened\n");
+               return ACCOUNT_ERROR_DB_NOT_OPENED;
+       }
 
        rc = sqlite3_exec(g_hAccountDB, query, NULL, NULL, &pszErrorMsg);
        if (SQLITE_OK != rc) {
-               ACCOUNT_FATAL("sqlite3_exec(%s) failed(%s).", query, pszErrorMsg);
+               ACCOUNT_ERROR("sqlite3_exec rc(%d) query(%s) failed(%s).", rc, query, pszErrorMsg);
                sqlite3_free(pszErrorMsg);
        }
 
@@ -275,8 +458,11 @@ static int _account_begin_transaction(void)
 
        ret = _account_execute_query("BEGIN IMMEDIATE TRANSACTION");
 
-       if (ret != SQLITE_OK) {
-               ACCOUNT_FATAL("_account_svc_begin_transaction fail :: %d", ret);
+       if (ret == SQLITE_BUSY){
+               ACCOUNT_ERROR(" sqlite3 busy = %d", ret);
+               return ACCOUNT_ERROR_DATABASE_BUSY;
+       } else if(ret != SQLITE_OK) {
+               ACCOUNT_ERROR("_account_svc_begin_transaction fail :: %d", ret);
                return ACCOUNT_ERROR_DB_FAILED;
        }
 
@@ -293,8 +479,18 @@ static int _account_end_transaction(bool is_success)
                ret = _account_execute_query("ROLLBACK TRANSACTION");
        }
 
+       if(ret == SQLITE_PERM){
+               ACCOUNT_ERROR("Account permission denied :: %d", ret);
+               return ACCOUNT_ERROR_PERMISSION_DENIED;
+       }
+
+       if (ret == SQLITE_BUSY){
+               ACCOUNT_DEBUG(" sqlite3 busy = %d", ret);
+               return ACCOUNT_ERROR_DATABASE_BUSY;
+       }
+
        if (ret != SQLITE_OK) {
-               ACCOUNT_FATAL("_account_svc_end_transaction fail :: %d", ret);
+               ACCOUNT_ERROR("_account_svc_end_transaction fail :: %d", ret);
                return ACCOUNT_ERROR_DB_FAILED;
        }
 
@@ -311,16 +507,12 @@ static bool _account_check_add_more_account(const char* app_id)
 
        ACCOUNT_MEMSET(query, 0x00, ACCOUNT_SQL_LEN_MAX);
 
-       ACCOUNT_DEBUG("app id (%s)\n", app_id);
-
        ACCOUNT_SNPRINTF(query, sizeof(query), "SELECT COUNT(*) FROM %s WHERE AppId = '%s' and MultipleAccountSupport = 1", ACCOUNT_TYPE_TABLE, app_id);
        rc = _account_get_record_count(query);
 
-       ACCOUNT_DEBUG("app id (%s) supports multiple account. rc(%d)\n", app_id, rc);
-
        /* multiple account support case */
        if(rc > 0) {
-               ACCOUNT_DEBUG("app id (%s) supports multiple account. rc(%d)\n", app_id, rc);
+               ACCOUNT_SLOGD("app id (%s) supports multiple account. rc(%d)\n", app_id, rc);
                return TRUE;
        }
 
@@ -330,7 +522,7 @@ static bool _account_check_add_more_account(const char* app_id)
        rc = _account_get_record_count(query);
 
        if(rc <= 0) {
-               ACCOUNT_DEBUG("app id (%s) supports single account. and there is no account of the app id\n", app_id);
+               ACCOUNT_SLOGD("app id (%s) supports single account. and there is no account of the app id\n", app_id);
                return TRUE;
        }
 
@@ -343,20 +535,16 @@ static int _account_create_all_tables(void)
        int error_code = ACCOUNT_ERROR_NONE;
        char    query[ACCOUNT_SQL_LEN_MAX] = {0, };
 
-
+       ACCOUNT_DEBUG("create all table - BEGIN");
        ACCOUNT_MEMSET(query, 0, sizeof(query));
 
-       ACCOUNT_VERBOSE("_account_create_all_tables begin");
-
        /*Create the account table*/
        ACCOUNT_SNPRINTF(query, sizeof(query), "select count(*) from sqlite_master where name in ('%s')", ACCOUNT_TABLE);
        rc = _account_get_record_count(query);
        if (rc <= 0) {
-               ACCOUNT_MEMSET(query, 0, sizeof(query));
-               ACCOUNT_SNPRINTF(query, sizeof(query),  ACCOUNT_SCHEMA, ACCOUNT_TABLE);
-               ACCOUNT_INFO("Create %s table", ACCOUNT_TABLE);
-               rc = _account_execute_query(query);
-               ACCOUNT_RETURN_VAL((SQLITE_OK == rc), {}, ACCOUNT_ERROR_DB_FAILED, ("_account_execute_query(%s) failed(%d, %s).\n", query, rc, _account_db_err_msg()));
+               rc = _account_execute_query(ACCOUNT_SCHEMA);
+               if(rc == SQLITE_BUSY) return ACCOUNT_ERROR_DATABASE_BUSY;
+               ACCOUNT_RETURN_VAL((SQLITE_OK == rc), {}, ACCOUNT_ERROR_DB_FAILED, ("_account_execute_query(%s) failed(%d, %s).\n", ACCOUNT_SCHEMA, rc, _account_db_err_msg()));
        }
 
        /*Create capability table*/
@@ -364,11 +552,9 @@ static int _account_create_all_tables(void)
        ACCOUNT_SNPRINTF(query, sizeof(query), "select count(*) from sqlite_master where name in ('%s')", CAPABILITY_TABLE);
        rc = _account_get_record_count(query);
        if (rc <= 0) {
-               ACCOUNT_MEMSET(query, 0, sizeof(query));
-               ACCOUNT_SNPRINTF(query, sizeof(query),  CAPABILITY_SCHEMA, CAPABILITY_TABLE);
-               ACCOUNT_INFO("Create %s table", CAPABILITY_TABLE);
-               rc = _account_execute_query(query);
-               ACCOUNT_RETURN_VAL((SQLITE_OK == rc), {}, ACCOUNT_ERROR_DB_FAILED, ("_account_execute_query(%s) failed(%d, %s).\n", query, rc, _account_db_err_msg()));
+               rc = _account_execute_query(CAPABILITY_SCHEMA);
+               if(rc == SQLITE_BUSY) return ACCOUNT_ERROR_DATABASE_BUSY;
+               ACCOUNT_RETURN_VAL((SQLITE_OK == rc), {}, ACCOUNT_ERROR_DB_FAILED, ("_account_execute_query(%s) failed(%d, %s).\n", CAPABILITY_SCHEMA, rc, _account_db_err_msg()));
        }
 
        /* Create account custom table */
@@ -376,10 +562,8 @@ static int _account_create_all_tables(void)
        ACCOUNT_SNPRINTF(query, sizeof(query), "select count(*) from sqlite_master where name in ('%s')", ACCOUNT_CUSTOM_TABLE);
        rc = _account_get_record_count(query);
        if (rc <= 0) {
-               ACCOUNT_MEMSET(query, 0, sizeof(query));
-               ACCOUNT_SNPRINTF(query, sizeof(query),  ACCOUNT_CUSTOM_SCHEMA, ACCOUNT_CUSTOM_TABLE);
-               ACCOUNT_INFO("Create %s table", ACCOUNT_CUSTOM_TABLE);
-               rc = _account_execute_query(query);
+               rc = _account_execute_query(ACCOUNT_CUSTOM_SCHEMA);
+               if(rc == SQLITE_BUSY) return ACCOUNT_ERROR_DATABASE_BUSY;
                ACCOUNT_RETURN_VAL((SQLITE_OK == rc), {}, ACCOUNT_ERROR_DB_FAILED, ("_account_execute_query(%s) failed(%d, %s).\n", query, rc, _account_db_err_msg()));
        }
 
@@ -388,11 +572,9 @@ static int _account_create_all_tables(void)
        ACCOUNT_SNPRINTF(query, sizeof(query), "select count(*) from sqlite_master where name in ('%s')", ACCOUNT_TYPE_TABLE);
        rc = _account_get_record_count(query);
        if (rc <= 0) {
-               ACCOUNT_MEMSET(query, 0, sizeof(query));
-               ACCOUNT_SNPRINTF(query, sizeof(query),  ACCOUNT_TYPE_SCHEMA, ACCOUNT_TYPE_TABLE);
-               ACCOUNT_INFO("Create %s table", ACCOUNT_TYPE_TABLE);
-               rc = _account_execute_query(query);
-               ACCOUNT_RETURN_VAL((SQLITE_OK == rc), {}, ACCOUNT_ERROR_DB_FAILED, ("_account_execute_query(%s) failed(%d, %s).\n", query, rc, _account_db_err_msg()));
+               rc = _account_execute_query(ACCOUNT_TYPE_SCHEMA);
+               if(rc == SQLITE_BUSY) return ACCOUNT_ERROR_DATABASE_BUSY;
+               ACCOUNT_RETURN_VAL((SQLITE_OK == rc), {}, ACCOUNT_ERROR_DB_FAILED, ("_account_execute_query(%s) failed(%d, %s).\n", ACCOUNT_TYPE_SCHEMA, rc, _account_db_err_msg()));
        }
 
        /* Create label table */
@@ -400,11 +582,9 @@ static int _account_create_all_tables(void)
        ACCOUNT_SNPRINTF(query, sizeof(query), "select count(*) from sqlite_master where name in ('%s')", LABEL_TABLE);
        rc = _account_get_record_count(query);
        if (rc <= 0) {
-               ACCOUNT_MEMSET(query, 0, sizeof(query));
-               ACCOUNT_SNPRINTF(query, sizeof(query),  LABEL_SCHEMA, LABEL_TABLE);
-               ACCOUNT_INFO("Create %s table", LABEL_TABLE);
-               rc = _account_execute_query(query);
-               ACCOUNT_RETURN_VAL((SQLITE_OK == rc), {}, ACCOUNT_ERROR_DB_FAILED, ("_account_execute_query(%s) failed(%d, %s).\n", query, rc, _account_db_err_msg()));
+               rc = _account_execute_query(LABEL_SCHEMA);
+               if(rc == SQLITE_BUSY) return ACCOUNT_ERROR_DATABASE_BUSY;
+               ACCOUNT_RETURN_VAL((SQLITE_OK == rc), {}, ACCOUNT_ERROR_DB_FAILED, ("_account_execute_query(%s) failed(%d, %s).\n", LABEL_SCHEMA, rc, _account_db_err_msg()));
        }
 
        /* Create account feature table */
@@ -412,76 +592,84 @@ static int _account_create_all_tables(void)
        ACCOUNT_SNPRINTF(query, sizeof(query), "select count(*) from sqlite_master where name in ('%s')", PROVIDER_FEATURE_TABLE);
        rc = _account_get_record_count(query);
        if (rc <= 0) {
-               ACCOUNT_MEMSET(query, 0, sizeof(query));
-               ACCOUNT_SNPRINTF(query, sizeof(query),  PROVIDER_FEATURE_SCHEMA, PROVIDER_FEATURE_TABLE);
-               ACCOUNT_INFO("Create %s table", PROVIDER_FEATURE_TABLE);
-               rc = _account_execute_query(query);
-               ACCOUNT_RETURN_VAL((SQLITE_OK == rc), {}, ACCOUNT_ERROR_DB_FAILED, ("_account_execute_query(%s) failed(%d, %s).\n", query, rc, _account_db_err_msg()));
+               rc = _account_execute_query(PROVIDER_FEATURE_SCHEMA);
+               if(rc == SQLITE_BUSY) return ACCOUNT_ERROR_DATABASE_BUSY;
+               ACCOUNT_RETURN_VAL((SQLITE_OK == rc), {}, ACCOUNT_ERROR_DB_FAILED, ("_account_execute_query(%s) failed(%d, %s).\n", PROVIDER_FEATURE_SCHEMA, rc, _account_db_err_msg()));
        }
 
+       ACCOUNT_DEBUG("create all table - END");
        return error_code;
 }
 
-static bool _account_check_is_all_table_exists()
+static int _account_check_is_all_table_exists()
 {
        int     rc = 0;
        char    query[ACCOUNT_SQL_LEN_MAX] = {0,};
        ACCOUNT_MEMSET(query, 0, sizeof(query));
 
-       ACCOUNT_VERBOSE("_account_check_is_all_table_exists");
-
        ACCOUNT_SNPRINTF(query, sizeof(query), "select count(*) from sqlite_master where name in ('%s', '%s', '%s', '%s', '%s', '%s')",
                        ACCOUNT_TABLE, CAPABILITY_TABLE, ACCOUNT_CUSTOM_TABLE, ACCOUNT_TYPE_TABLE, LABEL_TABLE, PROVIDER_FEATURE_TABLE);
        rc = _account_get_record_count(query);
 
-       ACCOUNT_DEBUG("Table count = %d\n", rc);
-
        if (rc != ACCOUNT_TABLE_TOTAL_COUNT) {
                ACCOUNT_ERROR("Table count is not matched rc=%d\n", rc);
-               return FALSE;
        }
 
-       ACCOUNT_VERBOSE("END of _account_check_is_all_table_exists\n");
-
-       return TRUE;
+       return rc;
 }
 
-static int _account_db_open(void)
+static int _account_db_open(int mode)
 {
-       int     rc = 0;
+       int  rc = 0;
        char query[ACCOUNT_SQL_LEN_MAX] = {0, };
 
        ACCOUNT_MEMSET(query, 0x00, sizeof(query));
 
        if (!g_hAccountDB) {
-               rc = db_util_open(ACCOUNT_DB_NAME, &g_hAccountDB, DB_UTIL_REGISTER_HOOK_METHOD);
-               ACCOUNT_RETURN_VAL((rc == SQLITE_OK), {}, ACCOUNT_ERROR_DB_NOT_OPENED, ("The database isn't connected. rc : %d", rc));
+               if(mode == ACCOUNT_DB_OPEN_READWRITE)
+                       rc = db_util_open(ACCOUNT_DB_NAME, &g_hAccountDB, DB_UTIL_REGISTER_HOOK_METHOD);
+               else if(mode == ACCOUNT_DB_OPEN_READONLY)
+                       rc = db_util_open_with_options(ACCOUNT_DB_NAME, &g_hAccountDB, SQLITE_OPEN_READONLY, NULL);
+               else
+                       return ACCOUNT_ERROR_DB_NOT_OPENED;
+
+               if( _account_db_err_code() == SQLITE_PERM ){
+                       ACCOUNT_ERROR( "Access failed(%s)", _account_db_err_msg());
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
 
+               ACCOUNT_RETURN_VAL((rc != SQLITE_PERM), {}, ACCOUNT_ERROR_PERMISSION_DENIED, ("Account permission denied rc : %d", rc));
+               ACCOUNT_RETURN_VAL((rc == SQLITE_OK), {}, ACCOUNT_ERROR_DB_NOT_OPENED, ("The database isn't connected. rc : %d", rc));
                g_refCntDB++;
-               ACCOUNT_INFO("_account_db_open: The database connected. refcnt=%d ", g_refCntDB);
        } else {
                g_refCntDB++;
-               ACCOUNT_INFO("The database already connected. refcnt=%d ", g_refCntDB);
        }
 
+       ACCOUNT_RETURN_VAL((rc == SQLITE_OK), {}, ACCOUNT_ERROR_DB_NOT_OPENED, ("busy handler fail. rc : %d", rc));
+
        return ACCOUNT_ERROR_NONE;
 }
 
 static int _account_db_close(void)
 {
-       int     rc = 0;
+       int rc = 0;
        int ret = -1;
 
        if (g_hAccountDB) {
                if (g_refCntDB > 0) {
                        g_refCntDB--;
-                       ACCOUNT_INFO("_account_svc_db_close: The database disconnected. refcnt=%d ", g_refCntDB);
                }
                if (g_refCntDB == 0) {
                        rc = db_util_close(g_hAccountDB);
+                       if(  rc == SQLITE_PERM ){
+                               ACCOUNT_ERROR( "Access failed(SQLITE_PERM)");
+                               return ACCOUNT_ERROR_PERMISSION_DENIED;
+                       } else if ( rc == SQLITE_BUSY ){
+                               ACCOUNT_ERROR( "database busy");
+                               return ACCOUNT_ERROR_DATABASE_BUSY;
+                       }
                        ACCOUNT_RETURN_VAL((rc == SQLITE_OK), {}, ACCOUNT_ERROR_DB_FAILED, ("The database isn't connected. rc : %d", rc));
                        g_hAccountDB = NULL;
-                       ACCOUNT_INFO( "_account_svc_db_close: The database disconnected really. ");
                }
                ret = ACCOUNT_ERROR_NONE;
        } else {
@@ -492,23 +680,64 @@ static int _account_db_close(void)
        return ret;
 }
 
-static int _account_connect(void)
+static int _account_connect(int mode)
 {
        int error_code = ACCOUNT_ERROR_NONE;
 
-       pthread_mutex_lock(&account_mutex);
+       int res;
+       int process_uid = getuid();
+       char subject_label[SMACK_LABEL_LEN + 1] = {0,};
 
-       ACCOUNT_VERBOSE("db path = %s\n", ACCOUNT_DB_NAME);
+       if(process_uid != 0) {
+               int fd = open("/proc/self/attr/current", O_RDONLY);
+               if(fd < 0)
+               {
+                       ACCOUNT_ERROR("file open fail :: /proc/self/attr/current");
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+
+               res = read(fd, subject_label, SMACK_LABEL_LEN);
+               if(res < 0)
+               {
+                       ACCOUNT_ERROR("file read fail :: /proc/self/attr/current");
+                       close(fd);
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+
+               res = smack_have_access(subject_label, "libaccounts-svc::check_read", "r");
+               if(res != 1) {
+                       ACCOUNT_ERROR("Account permission denied :: This API can not be used without account.read privilege");
+                       close(fd);
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+               close(fd);
+       }
+
+       pthread_mutex_lock(&account_mutex);
 
-       error_code = _account_db_open();
+       error_code = _account_db_open(mode);
        if (ACCOUNT_ERROR_NONE != error_code) {
                ACCOUNT_ERROR("The database isn't connected.\n");
                pthread_mutex_unlock(&account_mutex);
-               return ACCOUNT_ERROR_DB_NOT_OPENED;
+
+               if(error_code == ACCOUNT_ERROR_PERMISSION_DENIED)
+                       return error_code;
+               else
+                       return ACCOUNT_ERROR_DB_NOT_OPENED;
        }
 
-       if (FALSE == _account_check_is_all_table_exists())
+       int rc = _account_check_is_all_table_exists();
+
+       if ( rc < 0 ){
+               pthread_mutex_unlock(&account_mutex);
+               ACCOUNT_ERROR("rc(%d)", rc);
+               return rc;
+       } else if (rc == ACCOUNT_TABLE_TOTAL_COUNT){
+               // do nothing
+               ACCOUNT_DEBUG("Tables OK");
+       } else {
                error_code = _account_create_all_tables();
+       }
 
        pthread_mutex_unlock(&account_mutex);
        return ACCOUNT_ERROR_NONE;
@@ -516,15 +745,48 @@ static int _account_connect(void)
 
 ACCOUNT_API int account_connect (void)
 {
-       return _account_connect();
+       return _account_connect(ACCOUNT_DB_OPEN_READWRITE);
+}
+
+ACCOUNT_API int account_connect_readonly (void)
+{
+       return _account_connect(ACCOUNT_DB_OPEN_READONLY);
 }
 
 static int _account_disconnect(void)
 {
        int error_code = ACCOUNT_ERROR_NONE;
 
+       int res;
+       int process_uid = getuid();
+       char subject_label[SMACK_LABEL_LEN + 1] = {0,};
+
+       if(process_uid != 0) {
+               int fd = open("/proc/self/attr/current", O_RDONLY);
+               if(fd < 0)
+               {
+                       ACCOUNT_ERROR("file open fail :: /proc/self/attr/current");
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+
+               res = read(fd, subject_label, SMACK_LABEL_LEN);
+               if(res < 0)
+               {
+                       ACCOUNT_ERROR("file read fail :: /proc/self/attr/current");
+                       close(fd);
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+
+               res = smack_have_access(subject_label, "libaccounts-svc::check_read", "r");
+               if(res != 1) {
+                       ACCOUNT_ERROR("Account permission denied :: This API can not be used without account.read privilege");
+                       close(fd);
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+               close(fd);
+       }
+
        pthread_mutex_lock(&account_mutex);
-       ACCOUNT_INFO("db path = %s have been closed!!!\n", ACCOUNT_DB_NAME);
 
        error_code = _account_db_close();
        pthread_mutex_unlock(&account_mutex);
@@ -557,7 +819,9 @@ static int _account_custom_item_free(account_custom_s *data)
 
 static int _account_custom_gslist_free(GSList* list)
 {
-       ACCOUNT_RETURN_VAL((list != NULL), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("GSlist is NULL"));
+       if(!list){
+               return ACCOUNT_ERROR_INVALID_PARAMETER;
+       }
 
        GSList* iter;
 
@@ -597,7 +861,9 @@ static int _account_free_account_items(account_s *data)
 
 static int _account_gslist_free(GSList* list)
 {
-       ACCOUNT_RETURN_VAL((list != NULL), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("GSlist is NULL"));
+       if(!list){
+               return ACCOUNT_ERROR_INVALID_PARAMETER;
+       }
 
        GSList* iter;
 
@@ -615,7 +881,9 @@ static int _account_gslist_free(GSList* list)
 
 static int _account_glist_free(GList* list)
 {
-       ACCOUNT_RETURN_VAL((list != NULL), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("Glist is NULL"));
+       if(!list){
+               return ACCOUNT_ERROR_INVALID_PARAMETER;
+       }
 
        GList* iter;
 
@@ -644,34 +912,35 @@ static gboolean _account_check_duplicated(account_s *data)
 
        count = _account_get_record_count(query);
        if (count > 0) {
-               ACCOUNT_INFO("_account_check_duplicated : duplicated %d account(s) exist!, user_name=%s, domain_name=%s\n",
+               ACCOUNT_SLOGI("_account_check_duplicated : duplicated %d account(s) exist!, user_name=%s, domain_name=%s\n",
                        count, data->user_name, data->domain_name );
                return TRUE;
        }
 #endif
-
        return FALSE;
+
 }
 
-static int _account_get_next_sequence(char *pszName)
+static int _account_get_next_sequence(const char *pszName)
 {
        int                     rc = 0;
        account_stmt    pStmt = NULL;
        int                     max_seq = 0;
        char                    szQuery[ACCOUNT_SQL_LEN_MAX] = {0,};
 
-       ACCOUNT_VERBOSE( "[Enter] pszName:%s\n", pszName);
-
        ACCOUNT_MEMSET(szQuery, 0x00, sizeof(szQuery));
        ACCOUNT_SNPRINTF(szQuery, sizeof(szQuery),  "SELECT max(seq) FROM %s where name = '%s' ", ACCOUNT_SQLITE_SEQ, pszName);
        rc = sqlite3_prepare_v2(g_hAccountDB, szQuery, strlen(szQuery), &pStmt, NULL);
+       if (SQLITE_OK != rc) {
+               ACCOUNT_SLOGE("sqlite3_prepare_v2() failed(%d, %s).", rc, _account_db_err_msg());
+               sqlite3_finalize(pStmt);
+               return ACCOUNT_ERROR_DB_FAILED;
+       }
 
        rc = sqlite3_step(pStmt);
        max_seq = sqlite3_column_int(pStmt, 0);
        max_seq++;
 
-       ACCOUNT_VERBOSE( "sqlite3_column_int, rc=%d, max_seq=%d\n", rc, max_seq);
-
        /*Finalize Statement*/
        rc = sqlite3_finalize(pStmt);
        pStmt = NULL;
@@ -686,9 +955,8 @@ static account_stmt _account_prepare_query(char *query)
 
        ACCOUNT_RETURN_VAL((query != NULL), {}, NULL, ("query is NULL"));
 
-       ACCOUNT_INFO( "prepare query : %s", query);
-
        rc = sqlite3_prepare_v2(g_hAccountDB, query, strlen(query), &pStmt, NULL);
+
        ACCOUNT_RETURN_VAL((SQLITE_OK == rc), {}, NULL, ("sqlite3_prepare_v2(%s) failed(%s).", query, _account_db_err_msg()));
 
        return pStmt;
@@ -696,14 +964,25 @@ static account_stmt _account_prepare_query(char *query)
 
 static int _account_query_bind_int(account_stmt pStmt, int pos, int num)
 {
-       assert(NULL != pStmt);
-       assert(pos > -1);
+       if(!pStmt){
+               ACCOUNT_ERROR("statement is null");
+               return -1;
+       }
+
+       if(pos < 0){
+               ACCOUNT_ERROR("invalid pos");
+               return -1;
+       }
+
        return sqlite3_bind_int(pStmt, pos, num);
 }
 
 static int _account_query_bind_text(account_stmt pStmt, int pos, const char *str)
 {
-       assert(NULL != pStmt);
+       if(!pStmt){
+               ACCOUNT_ERROR("statement is null");
+               return -1;
+       }
 
        if(str)
                return sqlite3_bind_text(pStmt, pos, (const char*)str, strlen(str), SQLITE_STATIC);
@@ -713,7 +992,6 @@ static int _account_query_bind_text(account_stmt pStmt, int pos, const char *str
 
 static int _account_convert_account_to_sql(account_s *account, account_stmt hstmt, char *sql_value)
 {
-       ACCOUNT_VERBOSE( "_account_convert_account_to_sql");
        int count = 1;
 
        /*Caution : Keep insert query orders.*/
@@ -764,26 +1042,34 @@ static int _account_convert_account_to_sql(account_s *account, account_stmt hstm
        return count;
 }
 
-static void _account_query_finalize(account_stmt pStmt)
+static int _account_query_finalize(account_stmt pStmt)
 {
        int rc = -1;
 
        if (!pStmt) {
-               ACCOUNT_FATAL( "pStmt is NULL");
-               return;
+               ACCOUNT_ERROR( "pStmt is NULL");
+               return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
 
        rc = sqlite3_finalize(pStmt);
-       if (rc != SQLITE_OK) {
-               ACCOUNT_FATAL( "sqlite3_finalize fail, rc : %d, db_error : %s\n", rc, _account_db_err_msg());
+       if (rc == SQLITE_BUSY){
+               ACCOUNT_ERROR(" sqlite3 busy = %d", rc);
+               return ACCOUNT_ERROR_DATABASE_BUSY;
+       } else if (rc != SQLITE_OK) {
+               ACCOUNT_ERROR( "sqlite3_finalize fail, rc : %d, db_error : %s\n", rc, _account_db_err_msg());
+               return ACCOUNT_ERROR_DB_FAILED;
        }
 
-       ACCOUNT_VERBOSE( "sqlite3_finalize finish");
+       return ACCOUNT_ERROR_NONE;
 }
 
 static int _account_query_step(account_stmt pStmt)
 {
-       assert(NULL != pStmt);
+       if(!pStmt){
+               ACCOUNT_ERROR( "pStmt is NULL");
+               return -1;
+       }
+
        return sqlite3_step(pStmt);
 }
 
@@ -801,31 +1087,10 @@ static int _account_execute_insert_query(account_s *account)
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
 
-       /* Check account own icon existence */
-       if(!account->icon_path) {
-               char* temptxt = NULL;
-               account_type_h account_type = NULL;
-               error_code = account_type_create(&account_type);
-               error_code = account_type_query_by_app_id((const char*)account->package_name, &account_type);
-               error_code = account_type_get_icon_path(account_type, &temptxt);
-               if (error_code != ACCOUNT_ERROR_NONE) {
-                               ACCOUNT_ERROR("account_type_get_icon_path: Failed \n");
-               } else if (temptxt && strlen(temptxt)) {
-                       ACCOUNT_DEBUG("icon path (%s) app_id(%s) \n", temptxt, account->package_name);
-                       account->icon_path = _account_get_text(temptxt);
-               } else {
-                       ACCOUNT_DEBUG("account_get_icon_path: returned NULL \n");
-               }
-               _ACCOUNT_FREE(temptxt);
-               error_code = account_type_destroy(account_type);
-       }
-
-       /* End of Check account own icon existence */
-
        ACCOUNT_MEMSET(query, 0x00, sizeof(query));
        ACCOUNT_SNPRINTF(query, sizeof(query), "INSERT INTO %s( user_name, email_address , display_name , icon_path , source , package_name , "
                        "access_token , domain_name , auth_type , secret , sync_support , txt_custom0, txt_custom1, txt_custom2, txt_custom3, txt_custom4, "
-                       "int_custom0, int_custom1, int_custom2, int_custom3, int_custom4, txt_custom0 ) values "
+                       "int_custom0, int_custom1, int_custom2, int_custom3, int_custom4, txt_custom0 ) values " // to do urusa
                        "(?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ?, ? , ?, ?)",  ACCOUNT_TABLE);
 
        hstmt = _account_prepare_query(query);
@@ -835,11 +1100,16 @@ static int _account_execute_insert_query(account_s *account)
 
        rc = _account_query_step(hstmt);
        if (rc != SQLITE_DONE) {
-               ACCOUNT_FATAL( "account_db_query_step() failed(%d, %s)", rc, _account_db_err_msg());
-               error_code = ACCOUNT_ERROR_DB_FAILED;
+               ACCOUNT_ERROR( "account_db_query_step() failed(%d, %s)", rc, _account_db_err_msg());
+
+               if( _account_db_err_code() == SQLITE_PERM )
+                       error_code = ACCOUNT_ERROR_PERMISSION_DENIED;
+               else
+                       error_code = ACCOUNT_ERROR_DB_FAILED;
        }
 
-       _account_query_finalize(hstmt);
+       rc = _account_query_finalize(hstmt);
+       ACCOUNT_RETURN_VAL((rc == ACCOUNT_ERROR_NONE), {}, rc, ("finalize error"));
        hstmt = NULL;
 
        return error_code;
@@ -854,7 +1124,7 @@ static int _account_insert_capability(account_s *account, int account_id)
        ACCOUNT_RETURN_VAL((account != NULL), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("ACCOUNT HANDLE IS NULL"));
 
        if (g_slist_length( account->capablity_list)==0) {
-               ACCOUNT_ERROR( "_account_insert_capability, no capability\n");
+               ACCOUNT_DEBUG( "_account_insert_capability, no capability\n");
                return ACCOUNT_ERROR_NONE;
        }
 
@@ -862,8 +1132,11 @@ static int _account_insert_capability(account_s *account, int account_id)
 
        rc = _account_get_record_count(query);
 
+       if( _account_db_err_code() == SQLITE_PERM ){
+               ACCOUNT_ERROR( "Access failed(%s)", _account_db_err_msg());
+               return ACCOUNT_ERROR_PERMISSION_DENIED;
+       }
        if (rc <= 0) {
-               ACCOUNT_WARNING( "_account_insert_capability : related account item is not existed rc=%d , %s", rc, _account_db_err_msg());
                return ACCOUNT_ERROR_RECORD_NOT_FOUND;
        }
 
@@ -872,13 +1145,13 @@ static int _account_insert_capability(account_s *account, int account_id)
        GSList *iter;
 
        for (iter = account->capablity_list; iter != NULL; iter = g_slist_next(iter)) {
-               int rc, ret;
+               int ret;
                count = 1;
 
                account_capability_s* cap_data = NULL;
                cap_data = (account_capability_s*)iter->data;
 
-               ACCOUNT_VERBOSE("cap_data->type = %s, cap_data->value = %d \n", cap_data->type, cap_data->value);
+               ACCOUNT_SLOGD("cap_data->type = %s, cap_data->value = %d \n", cap_data->type, cap_data->value);
 
                ACCOUNT_MEMSET(query, 0x00, sizeof(query));
                ACCOUNT_SNPRINTF(query, sizeof(query), "INSERT INTO %s(key, value, package_name, user_name, account_id) VALUES "
@@ -901,17 +1174,16 @@ static int _account_insert_capability(account_s *account, int account_id)
                rc = _account_query_step(hstmt);
 
                if (rc != SQLITE_DONE) {
-                       ACCOUNT_FATAL( "_account_query_step() failed(%d, %s)", rc, _account_db_err_msg());
+                       ACCOUNT_ERROR( "_account_query_step() failed(%d, %s)", rc, _account_db_err_msg());
                        break;
                }
 
-               _account_query_finalize(hstmt);
+               rc = _account_query_finalize(hstmt);
+               ACCOUNT_RETURN_VAL((rc == ACCOUNT_ERROR_NONE), {}, rc, ("finalize error"));
                hstmt = NULL;
 
        }
 
-       ACCOUNT_VERBOSE( "_account_insert_capability() DONE\n");
-
        return ACCOUNT_ERROR_NONE;
 }
 
@@ -924,7 +1196,7 @@ static int _account_update_capability(account_s *account, int account_id)
        ACCOUNT_RETURN_VAL((account != NULL), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("ACCOUNT HANDLE IS NULL"));
 
        if (g_slist_length( account->capablity_list)==0) {
-               ACCOUNT_ERROR( "_account_insert_capability, no capability\n");
+               ACCOUNT_ERROR( "_account_update_capability, no capability\n");
                return ACCOUNT_ERROR_NONE;
        }
 
@@ -933,7 +1205,7 @@ static int _account_update_capability(account_s *account, int account_id)
        rc = _account_get_record_count(query);
 
        if (rc <= 0) {
-               ACCOUNT_WARNING( "_account_insert_capability : related account item is not existed rc=%d , %s", rc, _account_db_err_msg());
+               ACCOUNT_SLOGI( "_account_update_capability : related account item is not existed rc=%d , %s", rc, _account_db_err_msg());
                return ACCOUNT_ERROR_RECORD_NOT_FOUND;
        }
 
@@ -946,16 +1218,17 @@ static int _account_update_capability(account_s *account, int account_id)
        rc = _account_query_step(hstmt);
 
        if (rc != SQLITE_DONE) {
-               ACCOUNT_FATAL( "_account_query_step() failed(%d, %s)", rc, _account_db_err_msg());
+               ACCOUNT_ERROR( "_account_query_step() failed(%d, %s)", rc, _account_db_err_msg());
                return ACCOUNT_ERROR_DB_FAILED;
        }
-       _account_query_finalize(hstmt);
+       rc = _account_query_finalize(hstmt);
+       ACCOUNT_RETURN_VAL((rc == ACCOUNT_ERROR_NONE), {}, rc, ("finalize error"));
        hstmt = NULL;
 
        GSList *iter;
 
        for (iter = account->capablity_list; iter != NULL; iter = g_slist_next(iter)) {
-               int rc, ret;
+               int ret;
                count = 1;
                ACCOUNT_MEMSET(query, 0x00, sizeof(query));
                ACCOUNT_SNPRINTF(query, sizeof(query), "INSERT INTO %s(key, value, package_name, user_name, account_id) VALUES "
@@ -982,21 +1255,20 @@ static int _account_update_capability(account_s *account, int account_id)
                rc = _account_query_step(hstmt);
 
                if (rc != SQLITE_DONE) {
-                       ACCOUNT_FATAL( "_account_query_step() failed(%d, %s)", rc, _account_db_err_msg());
+                       ACCOUNT_ERROR( "_account_query_step() failed(%d, %s)", rc, _account_db_err_msg());
                        break;
                }
 
-               _account_query_finalize(hstmt);
+               rc = _account_query_finalize(hstmt);
+               ACCOUNT_RETURN_VAL((rc == ACCOUNT_ERROR_NONE), {}, rc, ("finalize error"));
                hstmt = NULL;
 
        }
 
-       ACCOUNT_DEBUG( "_account_insert_capability() DONE\n");
-
        return ACCOUNT_ERROR_NONE;
 }
 
-static int _account_update_capability_by_user_name(account_s *account, char *user_name, char *package_name )
+static int _account_update_capability_by_user_name(account_s *account, const char *user_name, const char *package_name )
 {
        int                     rc, count = 1;
        char                    query[ACCOUNT_SQL_LEN_MAX] = {0, };
@@ -1005,16 +1277,16 @@ static int _account_update_capability_by_user_name(account_s *account, char *use
        ACCOUNT_RETURN_VAL((account != NULL), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("ACCOUNT HANDLE IS NULL"));
 
        if (g_slist_length( account->capablity_list)==0) {
-               ACCOUNT_ERROR( "_account_insert_capability, no capability\n");
+               ACCOUNT_ERROR( "_account_update_capability_by_user_name, no capability\n");
                return ACCOUNT_ERROR_NONE;
        }
 
-       ACCOUNT_SNPRINTF(query, sizeof(query), "SELECT COUNT(*) from %s where package_name=%s and user_name=%s", ACCOUNT_TABLE, package_name, user_name);
+       ACCOUNT_SNPRINTF(query, sizeof(query), "SELECT COUNT(*) from %s where package_name= '%s' and user_name='%s'", ACCOUNT_TABLE, package_name, user_name);
 
        rc = _account_get_record_count(query);
 
        if (rc <= 0) {
-               ACCOUNT_WARNING( "_account_insert_capability : related account item is not existed rc=%d , %s ", rc, _account_db_err_msg());
+               ACCOUNT_SLOGI( "_account_update_capability_by_user_name : related account item is not existed rc=%d , %s ", rc, _account_db_err_msg());
                return ACCOUNT_ERROR_RECORD_NOT_FOUND;
        }
 
@@ -1027,17 +1299,18 @@ static int _account_update_capability_by_user_name(account_s *account, char *use
        _account_query_bind_text(hstmt, count++, (char*)account->user_name);
        rc = _account_query_step(hstmt);
        if (rc != SQLITE_DONE) {
-               ACCOUNT_FATAL( "_account_query_step() failed(%d, %s)", rc, _account_db_err_msg());
+               ACCOUNT_ERROR( "_account_query_step() failed(%d, %s)", rc, _account_db_err_msg());
                return ACCOUNT_ERROR_DB_FAILED;
        }
 
-       _account_query_finalize(hstmt);
+       rc = _account_query_finalize(hstmt);
+       ACCOUNT_RETURN_VAL((rc == ACCOUNT_ERROR_NONE), {}, rc, ("finalize error"));
        hstmt = NULL;
 
        GSList* iter;
 
        for (iter = account->capablity_list; iter != NULL; iter = g_slist_next(iter)) {
-               int rc, ret;
+               int ret;
                count = 1;
                ACCOUNT_MEMSET(query, 0x00, sizeof(query));
                ACCOUNT_SNPRINTF(query, sizeof(query), "INSERT INTO %s(key, value, package_name, user_name, account_id) VALUES "
@@ -1064,32 +1337,47 @@ static int _account_update_capability_by_user_name(account_s *account, char *use
                rc = _account_query_step(hstmt);
 
                if (rc != SQLITE_DONE) {
-                       ACCOUNT_FATAL( "_account_query_step() failed(%d, %s)", rc, _account_db_err_msg());
+                       ACCOUNT_ERROR( "_account_query_step() failed(%d, %s)", rc, _account_db_err_msg());
                        break;
                }
 
-               _account_query_finalize(hstmt);
+               rc = _account_query_finalize(hstmt);
+               ACCOUNT_RETURN_VAL((rc == ACCOUNT_ERROR_NONE), {}, rc, ("finalize error"));
                hstmt = NULL;
 
        }
 
-       ACCOUNT_VERBOSE( "_account_insert_capability() DONE\n");
-
        return ACCOUNT_ERROR_NONE;
 }
 
 static int _account_query_table_column_int(account_stmt pStmt, int pos)
 {
-       assert(NULL != pStmt);
-       assert(pos > -1);
+       if(!pStmt){
+               ACCOUNT_ERROR("statement is null");
+               return -1;
+       }
+
+       if(pos < 0){
+               ACCOUNT_ERROR("invalid pos");
+               return -1;
+       }
+
        return sqlite3_column_int(pStmt, pos);
 }
 
-static char *_account_query_table_column_text(account_stmt pStmt, int pos)
+static const char *_account_query_table_column_text(account_stmt pStmt, int pos)
 {
-       assert(NULL != pStmt);
-       assert(pos > -1);
-       return (char *)sqlite3_column_text(pStmt, pos);
+       if(!pStmt){
+               ACCOUNT_ERROR("statement is null");
+               return NULL;
+       }
+
+       if(pos < 0){
+               ACCOUNT_ERROR("invalid pos");
+               return NULL;
+       }
+
+       return (const char *)sqlite3_column_text(pStmt, pos);
 }
 
 static void _account_db_data_to_text(const char *textbuf, char **output)
@@ -1105,7 +1393,7 @@ static void _account_db_data_to_text(const char *textbuf, char **output)
 
 static void _account_convert_column_to_account(account_stmt hstmt, account_s *account_record)
 {
-       char    *textbuf = NULL;
+       const char *textbuf = NULL;
 
        account_record->id = _account_query_table_column_int(hstmt, ACCOUNT_FIELD_ID);
 
@@ -1159,13 +1447,11 @@ static void _account_convert_column_to_account(account_stmt hstmt, account_s *ac
        account_record->user_data_int[2] = _account_query_table_column_int(hstmt, ACCOUNT_FIELD_USER_INT_2);
        account_record->user_data_int[3] = _account_query_table_column_int(hstmt, ACCOUNT_FIELD_USER_INT_3);
        account_record->user_data_int[4] = _account_query_table_column_int(hstmt, ACCOUNT_FIELD_USER_INT_4);
-
-       ACCOUNT_VERBOSE("END _account_convert_column_to_account");
 }
 
 static void _account_convert_column_to_capability(account_stmt hstmt, account_capability_s *capability_record)
 {
-       char *textbuf = NULL;
+       const char *textbuf = NULL;
 
        capability_record->id = _account_query_table_column_int(hstmt, CAPABILITY_FIELD_ID);
 
@@ -1181,13 +1467,11 @@ static void _account_convert_column_to_capability(account_stmt hstmt, account_ca
        _account_db_data_to_text(textbuf, &(capability_record->user_name));
 
        capability_record->account_id = _account_query_table_column_int(hstmt, CAPABILITY_FIELD_ACCOUNT_ID);
-
-       ACCOUNT_VERBOSE("END _account_convert_column_to_capability");
 }
 
 static void _account_convert_column_to_custom(account_stmt hstmt, account_custom_s *custom_record)
 {
-       char *textbuf = NULL;
+       const char *textbuf = NULL;
 
        custom_record->account_id = _account_query_table_column_int(hstmt, ACCOUNT_CUSTOM_FIELD_ACCOUNT_ID);
 
@@ -1199,8 +1483,6 @@ static void _account_convert_column_to_custom(account_stmt hstmt, account_custom
 
        textbuf = _account_query_table_column_text(hstmt, ACCOUNT_CUSTOM_FIELD_VALUE);
        _account_db_data_to_text(textbuf, &(custom_record->value));
-
-       ACCOUNT_VERBOSE("END _account_convert_column_to_custom");
 }
 
 bool _account_get_capability_text_cb(const char* capability_type, account_capability_state_e capability_value, void *user_data)
@@ -1218,8 +1500,6 @@ bool _account_get_capability_text_cb(const char* capability_type, account_capabi
 
        data->capablity_list = g_slist_append(data->capablity_list, (gpointer)cap_data);
 
-       ACCOUNT_VERBOSE("_account_get_capability_text_cb :: %s\n", capability_type);
-
        return TRUE;
 }
 
@@ -1253,7 +1533,6 @@ static char *_account_get_text(const char *text_data)
 
        if (text_data != NULL) {
                text_value = strdup(text_data);
-               ACCOUNT_VERBOSE("text_value = %s", text_value);
        }
        return text_value;
 }
@@ -1287,11 +1566,11 @@ static int _account_compare_old_record_by_user_name(account_s *new_account, cons
 
        while (rc == SQLITE_ROW) {
                _account_convert_column_to_account(hstmt, old_account);
-               ACCOUNT_VERBOSE("get account info by id %p\n", old_account);
                rc = _account_query_step(hstmt);
        }
 
-       _account_query_finalize(hstmt);
+       rc = _account_query_finalize(hstmt);
+       ACCOUNT_CATCH_ERROR((rc == ACCOUNT_ERROR_NONE), {}, rc, ("finalize error"));
        hstmt = NULL;
 
        // get capability
@@ -1388,22 +1667,23 @@ static int _account_compare_old_record_by_user_name(account_s *new_account, cons
 
 
        CATCH:
-               if (hstmt != NULL) {
-                       _account_query_finalize(hstmt);
-                       hstmt = NULL;
-               }
+       if (old_account) {
+               _account_free_account_items(old_account);
+               _ACCOUNT_FREE(old_account);
+       }
 
-               if (old_account) {
-                       _account_free_account_items(old_account);
-                       _ACCOUNT_FREE(old_account);
-               }
+       if (hstmt != NULL) {
+               rc = _account_query_finalize(hstmt);
+               ACCOUNT_RETURN_VAL((rc == ACCOUNT_ERROR_NONE), {}, rc, ("finalize error"));
+               hstmt = NULL;
+       }
 
        return ACCOUNT_ERROR_NONE;
 }
 
 
 
-static int _account_update_account_by_user_name(account_s *account, char *user_name, char *package_name)
+static int _account_update_account_by_user_name(account_s *account, const char *user_name, const char *package_name)
 {
        int                             rc = 0, binding_count = 0, count = 0;
        char                    query[ACCOUNT_SQL_LEN_MAX] = {0, };
@@ -1429,6 +1709,11 @@ static int _account_update_account_by_user_name(account_s *account, char *user_n
 
        _account_compare_old_record_by_user_name(account, user_name, package_name);
 
+       if( _account_db_err_code() == SQLITE_PERM ){
+               ACCOUNT_ERROR( "Access failed(%s)", _account_db_err_msg());
+               return ACCOUNT_ERROR_PERMISSION_DENIED;
+       }
+
        if (!account->package_name) {
                ACCOUNT_ERROR("Package name is mandetory field, it can not be NULL!!!!\n");
                return ACCOUNT_ERROR_INVALID_PARAMETER;
@@ -1443,8 +1728,14 @@ static int _account_update_account_by_user_name(account_s *account, char *user_n
                        , ACCOUNT_TABLE, user_name, package_name);
 
        count = _account_get_record_count(query);
+
+       if( _account_db_err_code() == SQLITE_PERM ){
+               ACCOUNT_ERROR( "Access failed(%s)", _account_db_err_msg());
+               return ACCOUNT_ERROR_PERMISSION_DENIED;
+       }
+
        if (count <= 0) {
-               ACCOUNT_INFO("_account_update_account_by_user_name : The account not exist!, count = %d, user_name=%s, package_name=%s\n",
+               ACCOUNT_SLOGI("_account_update_account_by_user_name : The account not exist!, count = %d, user_name=%s, package_name=%s\n",
                        count, user_name, package_name);
                return ACCOUNT_ERROR_RECORD_NOT_FOUND;
        }
@@ -1456,6 +1747,11 @@ static int _account_update_account_by_user_name(account_s *account, char *user_n
                        "int_custom0=?, int_custom1=?, int_custom2=?, int_custom3=?, int_custom4=? WHERE user_name=? and package_name=? ", ACCOUNT_TABLE);
 
        hstmt = _account_prepare_query(query);
+       if( _account_db_err_code() == SQLITE_PERM ){
+               _account_end_transaction(FALSE);
+               ACCOUNT_ERROR( "Access failed(%s)", _account_db_err_msg());
+               return ACCOUNT_ERROR_PERMISSION_DENIED;
+       }
        ACCOUNT_RETURN_VAL((hstmt != NULL), {}, ACCOUNT_ERROR_DB_FAILED, ("_account_svc_query_prepare() failed(%s).\n", _account_db_err_msg()));
 
        binding_count = _account_convert_account_to_sql(account, hstmt, query);
@@ -1464,9 +1760,10 @@ static int _account_update_account_by_user_name(account_s *account, char *user_n
        _account_query_bind_text(hstmt, binding_count++, package_name);
        rc = _account_query_step(hstmt);
        if (rc != SQLITE_DONE) {
-               ACCOUNT_FATAL( "account_db_query_step() failed(%d, %s)", rc, _account_db_err_msg());
+               ACCOUNT_ERROR( "account_db_query_step() failed(%d, %s)", rc, _account_db_err_msg());
        }
-       _account_query_finalize(hstmt);
+       rc = _account_query_finalize(hstmt);
+       ACCOUNT_RETURN_VAL((rc == ACCOUNT_ERROR_NONE), {}, rc, ("finalize error"));
        hstmt = NULL;
 
        /*update capability*/
@@ -1483,38 +1780,77 @@ ACCOUNT_API int account_insert_to_db(account_h account, int *account_id)
        int             error_code = ACCOUNT_ERROR_NONE;
        int     ret_transaction = 0;
 
+       int res;
+       int process_uid = getuid();
+       char subject_label[SMACK_LABEL_LEN + 1] = {0,};
+
+       if(process_uid != 0) {
+               int fd = open("/proc/self/attr/current", O_RDONLY);
+               if(fd < 0)
+               {
+                       ACCOUNT_ERROR("file open fail :: /proc/self/attr/current");
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+
+               res = read(fd, subject_label, SMACK_LABEL_LEN);
+               if(res < 0)
+               {
+                       ACCOUNT_ERROR("file read fail :: /proc/self/attr/current");
+                       close(fd);
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+
+               res = smack_have_access(subject_label, "libaccounts-svc::check_read", "r");
+               if(res != 1) {
+                       ACCOUNT_ERROR("Account permission denied :: This API can not be used without account.read privilege");
+                       close(fd);
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+               close(fd);
+       }
+
        ACCOUNT_RETURN_VAL((g_hAccountDB != NULL), {}, ACCOUNT_ERROR_DB_NOT_OPENED, ("The database isn't connected."));
        ACCOUNT_RETURN_VAL((account != NULL), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("ACCOUNT HANDLE IS NULL"));
        ACCOUNT_RETURN_VAL((account_id != NULL), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("ACCOUNT ID POINTER IS NULL"));
 
        account_s *data = (account_s*)account;
+       ACCOUNT_SLOGD("(%s)-(%d) account_insert_to_db: begin_transaction.\n", __FUNCTION__, __LINE__);
 
        pthread_mutex_lock(&account_mutex);
 
        /* transaction control required*/
        ret_transaction = _account_begin_transaction();
 
-       if (ret_transaction != ACCOUNT_ERROR_NONE) {
-               ACCOUNT_ERROR("account_delete:_account_begin_transaction fail %d\n", ret_transaction);
+       if(_account_db_err_code() == SQLITE_PERM){
+               pthread_mutex_unlock(&account_mutex);
+               ACCOUNT_ERROR( "Access failed(%s)", _account_db_err_msg());
+               return ACCOUNT_ERROR_PERMISSION_DENIED;
+       }
+
+       if (ret_transaction == ACCOUNT_ERROR_DATABASE_BUSY) {
+               ACCOUNT_ERROR("account insert:_account_begin_transaction fail %d\n", ret_transaction);
+               pthread_mutex_unlock(&account_mutex);
+               return ACCOUNT_ERROR_DATABASE_BUSY;
+       }else if (ret_transaction != ACCOUNT_ERROR_NONE) {
+               ACCOUNT_ERROR("account insert:_account_begin_transaction fail %d\n", ret_transaction);
                pthread_mutex_unlock(&account_mutex);
                return ret_transaction;
        }
 
        if (_account_check_duplicated(data)) {
                ret_transaction = _account_end_transaction(FALSE);
-               ACCOUNT_ERROR("Duplicated, rollback insert query(%x)!!!!\n", ret_transaction);
+               ACCOUNT_DEBUG("Duplicated, rollback insert query(%x)!!!!\n", ret_transaction);
                *account_id = -1;
                pthread_mutex_unlock(&account_mutex);
                return ACCOUNT_ERROR_DUPLICATED;
        } else {
                *account_id = _account_get_next_sequence(ACCOUNT_TABLE);
 
-               char* appid = NULL;
+               char*                   appid = NULL;
                appid = _account_get_current_appid();
 
                if(!appid){
                        // API caller cannot be recognized
-                       ACCOUNT_ERROR("APP ID not detectable!\n");
                        ret_transaction = _account_end_transaction(FALSE);
                        ACCOUNT_ERROR("App id is not registered in account type DB, transaction ret (%x)!!!!\n", ret_transaction);
                        pthread_mutex_unlock(&account_mutex);
@@ -1548,6 +1884,24 @@ ACCOUNT_API int account_insert_to_db(account_h account, int *account_id)
                        _ACCOUNT_FREE(verified_appid);
                }
 
+#ifdef SAMSUNG_ACCOUNT_MANAGER
+               if(!strcmp(data->package_name,SAMSUNGACCOUNT_PKG_NAME)){
+                       //temporary feature for samsung account domain
+                       int ret = -1;
+                       ret = account_set_domain_name(account, "Samsung");
+                       if(ret != ACCOUNT_ERROR_NONE) {
+                               ACCOUNT_DEBUG("set_domain error(%x)!!!!\n", ret);
+                       }
+               }
+#endif
+
+               if(!_account_check_add_more_account(data->package_name)) {
+                       ret_transaction = _account_end_transaction(FALSE);
+                       ACCOUNT_ERROR("No more account cannot be added, transaction ret (%x)!!!!\n", ret_transaction);
+                       pthread_mutex_unlock(&account_mutex);
+                       return ACCOUNT_ERROR_NOT_ALLOW_MULTIPLE;
+               }
+
                error_code = _account_execute_insert_query(data);
 
                if (error_code != ACCOUNT_ERROR_NONE) {
@@ -1559,8 +1913,6 @@ ACCOUNT_API int account_insert_to_db(account_h account, int *account_id)
                }
        }
 
-       ACCOUNT_VERBOSE( "_account_execute_insert_query, insert error_code : %d", error_code);
-
        error_code = _account_insert_capability(data, *account_id);
        if (error_code != ACCOUNT_ERROR_NONE) {
                ret_transaction = _account_end_transaction(FALSE);
@@ -1581,10 +1933,12 @@ ACCOUNT_API int account_insert_to_db(account_h account, int *account_id)
 
        pthread_mutex_unlock(&account_mutex);
        _account_end_transaction(TRUE);
+       ACCOUNT_SLOGD("(%s)-(%d) account _end_transaction.\n", __FUNCTION__, __LINE__);
 
        char buf[64]={0,};
        ACCOUNT_SNPRINTF(buf, sizeof(buf), "%s:%d", ACCOUNT_NOTI_NAME_INSERT, *account_id);
        _account_insert_delete_update_notification_send(buf);
+       ACCOUNT_SLOGD("(%s)-(%d) account _notification_send.\n", __FUNCTION__, __LINE__);
 
        return ACCOUNT_ERROR_NONE;
 
@@ -1593,7 +1947,7 @@ ACCOUNT_API int account_insert_to_db(account_h account, int *account_id)
 ACCOUNT_API int account_create(account_h *account)
 {
        if (!account) {
-               ACCOUNT_ERROR("(%s)-(%d) account is NULL.\n", __FUNCTION__, __LINE__);
+               ACCOUNT_SLOGE("(%s)-(%d) account is NULL.\n", __FUNCTION__, __LINE__);
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
 
@@ -1605,8 +1959,6 @@ ACCOUNT_API int account_create(account_h *account)
        }
        ACCOUNT_MEMSET(data, 0, sizeof(account_s));
 
-       ACCOUNT_VERBOSE("create handle=%p\n", *account);
-
        /*Setting account as visible by default*/
        data->secret = ACCOUNT_SECRECY_VISIBLE;
 
@@ -1621,12 +1973,12 @@ ACCOUNT_API int account_create(account_h *account)
 ACCOUNT_API int account_set_user_name(account_h account, const char *user_name)
 {
        if (!account) {
-               ACCOUNT_ERROR("(%s)-(%d) account handle is NULL.\n", __FUNCTION__, __LINE__);
+               ACCOUNT_SLOGE("(%s)-(%d) account handle is NULL.\n", __FUNCTION__, __LINE__);
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
 
        if (!user_name) {
-               ACCOUNT_ERROR("(%s)-(%d) user_name is NULL.\n", __FUNCTION__, __LINE__);
+               ACCOUNT_SLOGE("(%s)-(%d) user_name is NULL.\n", __FUNCTION__, __LINE__);
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
 
@@ -1635,20 +1987,18 @@ ACCOUNT_API int account_set_user_name(account_h account, const char *user_name)
        _ACCOUNT_FREE(data->user_name);
        data->user_name = _account_get_text(user_name);
 
-       ACCOUNT_VERBOSE("(%s)-(%d) %s, %s\n", __FUNCTION__, __LINE__ , data->user_name, user_name);
-
        return ACCOUNT_ERROR_NONE;
 }
 
 ACCOUNT_API int account_set_display_name(account_h account, const char *display_name)
 {
        if (!account) {
-               ACCOUNT_ERROR("(%s)-(%d) account handle is NULL.\n", __FUNCTION__, __LINE__);
+               ACCOUNT_SLOGE("(%s)-(%d) account handle is NULL.\n", __FUNCTION__, __LINE__);
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
 
        if (!display_name) {
-               ACCOUNT_ERROR("(%s)-(%d) display_name is NULL.\n", __FUNCTION__, __LINE__);
+               ACCOUNT_SLOGE("(%s)-(%d) display_name is NULL.\n", __FUNCTION__, __LINE__);
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
 
@@ -1657,20 +2007,18 @@ ACCOUNT_API int account_set_display_name(account_h account, const char *display_
        _ACCOUNT_FREE(data->display_name);
        data->display_name = _account_get_text(display_name);
 
-       ACCOUNT_VERBOSE("(%s)-(%d) %s, %s\n", __FUNCTION__, __LINE__ , data->display_name, display_name);
-
        return ACCOUNT_ERROR_NONE;
 }
 
 ACCOUNT_API int account_set_email_address(account_h account, const char *email_address)
 {
        if (!account) {
-               ACCOUNT_ERROR("(%s)-(%d) account handle is NULL.\n", __FUNCTION__, __LINE__);
+               ACCOUNT_SLOGE("(%s)-(%d) account handle is NULL.\n", __FUNCTION__, __LINE__);
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
 
        if (!email_address) {
-               ACCOUNT_ERROR("(%s)-(%d) email_address is NULL.\n", __FUNCTION__, __LINE__);
+               ACCOUNT_SLOGE("(%s)-(%d) email_address is NULL.\n", __FUNCTION__, __LINE__);
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
 
@@ -1679,20 +2027,18 @@ ACCOUNT_API int account_set_email_address(account_h account, const char *email_a
        _ACCOUNT_FREE(data->email_address);
        data->email_address = _account_get_text(email_address);
 
-       ACCOUNT_VERBOSE("(%s)-(%d) %s, %s\n", __FUNCTION__, __LINE__ , data->email_address, email_address);
-
        return ACCOUNT_ERROR_NONE;
 }
 
 ACCOUNT_API int account_set_icon_path(account_h account, const char *icon_path)
 {
        if (!account) {
-               ACCOUNT_ERROR("(%s)-(%d) account handle is NULL.\n", __FUNCTION__, __LINE__);
+               ACCOUNT_SLOGE("(%s)-(%d) account handle is NULL.\n", __FUNCTION__, __LINE__);
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
 
        if (!icon_path) {
-               ACCOUNT_ERROR("(%s)-(%d) icon_path is NULL.\n", __FUNCTION__, __LINE__);
+               ACCOUNT_SLOGE("(%s)-(%d) icon_path is NULL.\n", __FUNCTION__, __LINE__);
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
 
@@ -1701,20 +2047,18 @@ ACCOUNT_API int account_set_icon_path(account_h account, const char *icon_path)
        _ACCOUNT_FREE(data->icon_path);
        data->icon_path = _account_get_text(icon_path);
 
-       ACCOUNT_VERBOSE("(%s)-(%d) %s, %s\n", __FUNCTION__, __LINE__ , data->icon_path, icon_path);
-
        return ACCOUNT_ERROR_NONE;
 }
 
 ACCOUNT_API int account_set_source(account_h account, const char *source)
 {
        if (!account) {
-               ACCOUNT_ERROR("(%s)-(%d) account handle is NULL.\n", __FUNCTION__, __LINE__);
+               ACCOUNT_SLOGE("(%s)-(%d) account handle is NULL.\n", __FUNCTION__, __LINE__);
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
 
        if (!source) {
-               ACCOUNT_ERROR("(%s)-(%d) source is NULL.\n", __FUNCTION__, __LINE__);
+               ACCOUNT_SLOGE("(%s)-(%d) source is NULL.\n", __FUNCTION__, __LINE__);
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
        account_s *data = (account_s*)account;
@@ -1722,20 +2066,18 @@ ACCOUNT_API int account_set_source(account_h account, const char *source)
        _ACCOUNT_FREE(data->source);
        data->source = _account_get_text(source);
 
-       ACCOUNT_VERBOSE("(%s)-(%d) %s, %s\n", __FUNCTION__, __LINE__ , data->source, source);
-
        return ACCOUNT_ERROR_NONE;
 }
 
 ACCOUNT_API int account_set_package_name(account_h account, const char *package_name)
 {
        if (!account) {
-               ACCOUNT_ERROR("(%s)-(%d) account handle is NULL.\n", __FUNCTION__, __LINE__);
+               ACCOUNT_SLOGE("(%s)-(%d) account handle is NULL.\n", __FUNCTION__, __LINE__);
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
 
        if (!package_name) {
-               ACCOUNT_ERROR("(%s)-(%d) package_name is NULL.\n", __FUNCTION__, __LINE__);
+               ACCOUNT_SLOGE("(%s)-(%d) package_name is NULL.\n", __FUNCTION__, __LINE__);
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
 
@@ -1744,20 +2086,18 @@ ACCOUNT_API int account_set_package_name(account_h account, const char *package_
        _ACCOUNT_FREE(data->package_name);
        data->package_name = _account_get_text(package_name);
 
-       ACCOUNT_VERBOSE("(%s)-(%d) %s, %s\n", __FUNCTION__, __LINE__ , data->package_name, package_name);
-
        return ACCOUNT_ERROR_NONE;
 }
 
 ACCOUNT_API int account_set_domain_name(account_h account, const char *domain_name)
 {
        if (!account) {
-               ACCOUNT_ERROR("(%s)-(%d) account handle is NULL.\n", __FUNCTION__, __LINE__);
+               ACCOUNT_SLOGE("(%s)-(%d) account handle is NULL.\n", __FUNCTION__, __LINE__);
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
 
        if (!domain_name) {
-               ACCOUNT_ERROR("(%s)-(%d) domain_name is NULL.\n", __FUNCTION__, __LINE__);
+               ACCOUNT_SLOGE("(%s)-(%d) domain_name is NULL.\n", __FUNCTION__, __LINE__);
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
        account_s *data = (account_s*)account;
@@ -1765,20 +2105,18 @@ ACCOUNT_API int account_set_domain_name(account_h account, const char *domain_na
        _ACCOUNT_FREE(data->domain_name);
        data->domain_name = _account_get_text(domain_name);
 
-       ACCOUNT_VERBOSE("(%s)-(%d) %s, %s\n", __FUNCTION__, __LINE__ , data->domain_name, domain_name);
-
        return ACCOUNT_ERROR_NONE;
 }
 
 ACCOUNT_API int account_set_access_token(account_h account, const char *access_token)
 {
        if (!account) {
-               ACCOUNT_ERROR("(%s)-(%d) account handle is NULL.\n", __FUNCTION__, __LINE__);
+               ACCOUNT_SLOGE("(%s)-(%d) account handle is NULL.\n", __FUNCTION__, __LINE__);
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
 
        if (!access_token) {
-               ACCOUNT_ERROR("(%s)-(%d) access_token is NULL.\n", __FUNCTION__, __LINE__);
+               ACCOUNT_SLOGE("(%s)-(%d) access_token is NULL.\n", __FUNCTION__, __LINE__);
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
 
@@ -1787,33 +2125,29 @@ ACCOUNT_API int account_set_access_token(account_h account, const char *access_t
        _ACCOUNT_FREE(data->access_token);
        data->access_token = _account_get_text(access_token);
 
-       ACCOUNT_VERBOSE("(%s)-(%d) %s, %s\n", __FUNCTION__, __LINE__ , data->access_token, access_token);
-
        return ACCOUNT_ERROR_NONE;
 }
 
-ACCOUNT_API int account_set_user_text(account_h account, int index, const char *user_txt)
+ACCOUNT_API int account_set_user_text(account_h account, int idx, const char *user_txt)
 {
        if (!account) {
-               ACCOUNT_ERROR("(%s)-(%d) account handle is NULL.\n", __FUNCTION__, __LINE__);
+               ACCOUNT_SLOGE("(%s)-(%d) account handle is NULL.\n", __FUNCTION__, __LINE__);
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
 
        if (!user_txt) {
-               ACCOUNT_ERROR("(%s)-(%d) user_txt is NULL.\n", __FUNCTION__, __LINE__);
+               ACCOUNT_SLOGE("(%s)-(%d) user_txt is NULL.\n", __FUNCTION__, __LINE__);
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
-       if (index >= USER_TXT_CNT || index < 0) {
-               ACCOUNT_ERROR("(%s)-(%d) index rage should be between 0-4.\n", __FUNCTION__, __LINE__);
+       if (idx >= USER_TXT_CNT || idx < 0) {
+               ACCOUNT_SLOGE("(%s)-(%d) index rage should be between 0-4.\n", __FUNCTION__, __LINE__);
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
 
        account_s *data = (account_s*)account;
 
-       _ACCOUNT_FREE(data->user_data_txt[index]);
-       data->user_data_txt[index] = _account_get_text(user_txt);
-
-       ACCOUNT_VERBOSE("(%s)-(%d) %s, %s\n", __FUNCTION__, __LINE__ , data->user_data_txt[index], user_txt);
+       _ACCOUNT_FREE(data->user_data_txt[idx]);
+       data->user_data_txt[idx] = _account_get_text(user_txt);
 
        return ACCOUNT_ERROR_NONE;
 }
@@ -1821,17 +2155,17 @@ ACCOUNT_API int account_set_user_text(account_h account, int index, const char *
 ACCOUNT_API int account_set_custom(account_h account, const char* key, const char* value)
 {
        if (!account) {
-               ACCOUNT_ERROR("(%s)-(%d) account handle is NULL.\n", __FUNCTION__, __LINE__);
+               ACCOUNT_SLOGE("(%s)-(%d) account handle is NULL.\n", __FUNCTION__, __LINE__);
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
 
        if (!key) {
-               ACCOUNT_ERROR("(%s)-(%d) key is NULL.\n", __FUNCTION__, __LINE__);
+               ACCOUNT_SLOGE("(%s)-(%d) key is NULL.\n", __FUNCTION__, __LINE__);
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
 
        if (!value) {
-               ACCOUNT_ERROR("(%s)-(%d) value is NULL.\n", __FUNCTION__, __LINE__);
+               ACCOUNT_SLOGE("(%s)-(%d) value is NULL.\n", __FUNCTION__, __LINE__);
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
 
@@ -1844,7 +2178,7 @@ ACCOUNT_API int account_set_custom(account_h account, const char* key, const cha
 
                account_custom_s* custom_data = NULL;
                custom_data = (account_custom_s*)iter->data;
-               ACCOUNT_VERBOSE( "account_custom_s->key = %s, account_custom_s->value = %s \n", custom_data->key, custom_data->value);
+               ACCOUNT_SLOGD( "account_custom_s->key = %s, account_custom_s->value = %s \n", custom_data->key, custom_data->value);
 
                if(!strcmp(custom_data->key, key)) {
                        _ACCOUNT_FREE(custom_data->value);
@@ -1857,7 +2191,6 @@ ACCOUNT_API int account_set_custom(account_h account, const char* key, const cha
                account_custom_s* custom_data = (account_custom_s*)malloc(sizeof(account_custom_s));
 
                if (custom_data == NULL) {
-                       ACCOUNT_FATAL("(%s)-(%d) MALLOC FAIL\n", __FUNCTION__, __LINE__);
                        return ACCOUNT_ERROR_OUT_OF_MEMORY;
                }
                ACCOUNT_MEMSET(custom_data, 0, sizeof(account_custom_s));
@@ -1875,8 +2208,7 @@ ACCOUNT_API int account_set_auth_type(account_h account, const account_auth_type
 {
        ACCOUNT_RETURN_VAL((account != NULL), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("(%s)-(%d) account handle is NULL.\n",  __FUNCTION__, __LINE__));
 
-       if ( (auth_type < 0) || (auth_type > ACCOUNT_AUTH_TYPE_CLIENT_LOGIN)) {
-               ACCOUNT_ERROR("(%s)-(%d) auth_type is less than 1 or more than enum max.\n", __FUNCTION__, __LINE__);
+       if ( ((int)auth_type < 0) || (auth_type > ACCOUNT_AUTH_TYPE_MAX) ) {
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
 
@@ -1891,8 +2223,7 @@ ACCOUNT_API int account_set_secret(account_h account, const account_secrecy_stat
 {
        ACCOUNT_RETURN_VAL((account != NULL), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("(%s)-(%d) account handle is NULL.\n",      __FUNCTION__, __LINE__));
 
-       if ( (secret < 0) || (secret > ACCOUNT_SECRECY_VISIBLE)) {
-               ACCOUNT_ERROR("(%s)-(%d) auth_type is less than 1 or more than enum max.\n", __FUNCTION__, __LINE__);
+       if ( ((int)secret < 0) || (secret > ACCOUNT_SECRECY_MAX)) {
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
 
@@ -1907,8 +2238,7 @@ ACCOUNT_API int account_set_sync_support(account_h account, const account_sync_s
 {
        ACCOUNT_RETURN_VAL((account != NULL), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("(%s)-(%d) account handle is NULL.\n",      __FUNCTION__, __LINE__));
 
-       if ( (sync_support < 0) || (sync_support > ACCOUNT_SUPPORTS_SYNC)) {
-               ACCOUNT_ERROR("(%s)-(%d) sync_support is less than 1 or more than enum max.\n", __FUNCTION__, __LINE__);
+       if ( ((int)sync_support < 0) || (sync_support > ACCOUNT_SYNC_MAX)) {
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
 
@@ -1919,21 +2249,19 @@ ACCOUNT_API int account_set_sync_support(account_h account, const account_sync_s
        return ACCOUNT_ERROR_NONE;
 }
 
-ACCOUNT_API int account_set_user_int(account_h account, int index, const int user_int)
+ACCOUNT_API int account_set_user_int(account_h account, int idx, const int user_int)
 {
        if (!account) {
-               ACCOUNT_ERROR("(%s)-(%d) account handle is NULL.\n", __FUNCTION__, __LINE__);
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
 
-       if (index >= USER_INT_CNT ||index < 0) {
-               ACCOUNT_ERROR("(%s)-(%d) index rage should be between 0-4.\n", __FUNCTION__, __LINE__);
+       if (idx >= USER_INT_CNT ||idx < 0) {
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
 
        account_s *data = (account_s*)account;
 
-       data->user_data_int[index] = user_int;
+       data->user_data_int[idx] = user_int;
 
        return ACCOUNT_ERROR_NONE;
 }
@@ -1944,7 +2272,6 @@ ACCOUNT_API int account_set_capability(account_h account, const char* capability
        ACCOUNT_RETURN_VAL((capability_type != NULL), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("capability_type is null"));
 
        if ((capability_value != ACCOUNT_CAPABILITY_DISABLED) && (capability_value != ACCOUNT_CAPABILITY_ENABLED)) {
-               ACCOUNT_ERROR("(%s)-(%d) capability_value is not equal to 0 or 1.\n", __FUNCTION__, __LINE__);
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
 
@@ -1982,12 +2309,10 @@ ACCOUNT_API int account_set_capability(account_h account, const char* capability
 ACCOUNT_API int account_get_user_name(account_h account, char **user_name)
 {
        if (!account) {
-               ACCOUNT_ERROR("(%s)-(%d) account handle is NULL.\n", __FUNCTION__, __LINE__);
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
 
        if (!user_name) {
-               ACCOUNT_ERROR("(%s)-(%d) user name is NULL.\n", __FUNCTION__, __LINE__);
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
 
@@ -2002,12 +2327,10 @@ ACCOUNT_API int account_get_user_name(account_h account, char **user_name)
 ACCOUNT_API int account_get_display_name(account_h account, char **display_name)
 {
        if (!account) {
-               ACCOUNT_ERROR("(%s)-(%d) account handle is NULL.\n", __FUNCTION__, __LINE__);
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
 
        if (!display_name) {
-               ACCOUNT_ERROR("(%s)-(%d) display name is NULL.\n", __FUNCTION__, __LINE__);
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
 
@@ -2023,12 +2346,10 @@ ACCOUNT_API int account_get_display_name(account_h account, char **display_name)
 ACCOUNT_API int account_get_email_address(account_h account,char **email_address)
 {
        if (!account) {
-               ACCOUNT_ERROR("(%s)-(%d) account handle is NULL.\n", __FUNCTION__, __LINE__);
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
 
        if (!email_address) {
-               ACCOUNT_ERROR("(%s)-(%d) email address is NULL.\n", __FUNCTION__, __LINE__);
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
 
@@ -2044,12 +2365,10 @@ ACCOUNT_API int account_get_email_address(account_h account,char **email_address
 ACCOUNT_API int  account_get_icon_path(account_h account, char **icon_path)
 {
        if (!account) {
-               ACCOUNT_ERROR("(%s)-(%d) account handle is NULL.\n", __FUNCTION__, __LINE__);
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
 
        if (!icon_path) {
-               ACCOUNT_ERROR("(%s)-(%d) icon path is NULL.\n", __FUNCTION__, __LINE__);
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
 
@@ -2065,12 +2384,10 @@ ACCOUNT_API int  account_get_icon_path(account_h account, char **icon_path)
 ACCOUNT_API int account_get_source(account_h account, char **source)
 {
        if (!account) {
-               ACCOUNT_ERROR("(%s)-(%d) account handle is NULL.\n", __FUNCTION__, __LINE__);
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
 
        if (!source) {
-               ACCOUNT_ERROR("(%s)-(%d) source is NULL.\n", __FUNCTION__, __LINE__);
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
 
@@ -2086,12 +2403,10 @@ ACCOUNT_API int account_get_source(account_h account, char **source)
 ACCOUNT_API int account_get_package_name(account_h account, char **package_name)
 {
        if (!account) {
-               ACCOUNT_ERROR("(%s)-(%d) account handle is NULL.\n", __FUNCTION__, __LINE__);
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
 
        if (!package_name) {
-               ACCOUNT_ERROR("(%s)-(%d) package name is NULL.\n", __FUNCTION__, __LINE__);
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
 
@@ -2107,12 +2422,10 @@ ACCOUNT_API int account_get_package_name(account_h account, char **package_name)
 ACCOUNT_API int account_get_domain_name(account_h account, char **domain_name)
 {
        if (!account) {
-               ACCOUNT_ERROR("(%s)-(%d) account handle is NULL.\n", __FUNCTION__, __LINE__);
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
 
        if (!domain_name) {
-               ACCOUNT_ERROR("(%s)-(%d) domain name is NULL.\n", __FUNCTION__, __LINE__);
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
 
@@ -2128,12 +2441,10 @@ ACCOUNT_API int account_get_domain_name(account_h account, char **domain_name)
 ACCOUNT_API int account_get_access_token(account_h account, char **access_token)
 {
        if (!account) {
-               ACCOUNT_ERROR("(%s)-(%d) account handle is NULL.\n", __FUNCTION__, __LINE__);
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
 
        if (!access_token) {
-               ACCOUNT_ERROR("(%s)-(%d) access token is NULL.\n", __FUNCTION__, __LINE__);
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
 
@@ -2149,12 +2460,10 @@ ACCOUNT_API int account_get_access_token(account_h account, char **access_token)
 ACCOUNT_API int account_get_user_text(account_h account, int user_text_index, char **text)
 {
        if (!account) {
-               ACCOUNT_ERROR("(%s)-(%d) account handle is NULL.\n", __FUNCTION__, __LINE__);
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
 
        if (!text) {
-               ACCOUNT_ERROR("(%s)-(%d) text is NULL.\n", __FUNCTION__, __LINE__);
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
        ACCOUNT_RETURN_VAL((user_text_index >=0 && user_text_index < USER_TXT_CNT ), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("INVALID USER TEXT INDEX"));
@@ -2171,11 +2480,9 @@ ACCOUNT_API int account_get_user_text(account_h account, int user_text_index, ch
 ACCOUNT_API int account_get_auth_type(account_h account, account_auth_type_e *auth_type)
 {
        if (!account) {
-               ACCOUNT_ERROR("(%s)-(%d) account handle is NULL.\n", __FUNCTION__, __LINE__);
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
        if (!auth_type) {
-               ACCOUNT_ERROR("(%s)-(%d) auth_type is NULL.\n", __FUNCTION__, __LINE__);
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
 
@@ -2189,11 +2496,9 @@ ACCOUNT_API int account_get_auth_type(account_h account, account_auth_type_e *au
 ACCOUNT_API int account_get_secret(account_h account, account_secrecy_state_e *secret)
 {
        if (!account) {
-               ACCOUNT_ERROR("(%s)-(%d) account handle is NULL.\n", __FUNCTION__, __LINE__);
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
        if (!secret) {
-               ACCOUNT_ERROR("(%s)-(%d) secret is NULL.\n", __FUNCTION__, __LINE__);
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
 
@@ -2207,11 +2512,9 @@ ACCOUNT_API int account_get_secret(account_h account, account_secrecy_state_e *s
 ACCOUNT_API int account_get_sync_support(account_h account, account_sync_state_e *sync_support)
 {
        if (!account) {
-               ACCOUNT_ERROR("(%s)-(%d) account handle is NULL.\n", __FUNCTION__, __LINE__);
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
        if (!sync_support) {
-               ACCOUNT_ERROR("(%s)-(%d) sync_support is NULL.\n", __FUNCTION__, __LINE__);
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
 
@@ -2225,11 +2528,9 @@ ACCOUNT_API int account_get_sync_support(account_h account, account_sync_state_e
 ACCOUNT_API int account_get_account_id(account_h account, int *account_id)
 {
        if (!account) {
-               ACCOUNT_ERROR("(%s)-(%d) account handle is NULL.\n", __FUNCTION__, __LINE__);
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
        if (!account_id) {
-               ACCOUNT_ERROR("(%s)-(%d) account_id is NULL.\n", __FUNCTION__, __LINE__);
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
 
@@ -2243,14 +2544,12 @@ ACCOUNT_API int account_get_account_id(account_h account, int *account_id)
 ACCOUNT_API int account_get_user_int(account_h account, int user_int_index, int *integer)
 {
        if (!account) {
-               ACCOUNT_ERROR("(%s)-(%d) account handle is NULL.\n", __FUNCTION__, __LINE__);
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
 
        ACCOUNT_RETURN_VAL((user_int_index >=0 && user_int_index < USER_TXT_CNT ), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("INVALID USER TEXT INDEX"));
 
        if (!integer) {
-               ACCOUNT_ERROR("(%s)-(%d) integer is NULL.\n", __FUNCTION__, __LINE__);
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
 
@@ -2275,8 +2574,6 @@ ACCOUNT_API int account_get_capability(account_h account, const char* capability
 
                cap_data = (account_capability_s*)iter->data;
 
-               ACCOUNT_VERBOSE("account_get_capability :: type = %d, value = %d", cap_data->type, cap_data->value);
-
                if(!strcmp(capability_type, cap_data->type)) {
                        *capability_value = cap_data->value;
                        return ACCOUNT_ERROR_NONE;
@@ -2286,10 +2583,10 @@ ACCOUNT_API int account_get_capability(account_h account, const char* capability
        return ACCOUNT_ERROR_RECORD_NOT_FOUND;
 }
 
-ACCOUNT_API int account_get_capability_all(account_h account, capability_cb cb_func, void *user_data)
+ACCOUNT_API int account_get_capability_all(account_h account, capability_cb callback, void *user_data)
 {
        ACCOUNT_RETURN_VAL((account != NULL), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("ACCOUNT HANDLE IS NULL"));
-       ACCOUNT_RETURN_VAL((cb_func != NULL), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("NO CALLBACK FUNCTION"));
+       ACCOUNT_RETURN_VAL((callback != NULL), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("NO CALLBACK FUNCTION"));
 
        GSList *iter;
        account_s *data = (account_s*)account;
@@ -2299,11 +2596,7 @@ ACCOUNT_API int account_get_capability_all(account_h account, capability_cb cb_f
 
                cap_data = (account_capability_s*)iter->data;
 
-               ACCOUNT_VERBOSE("account_get_capability :: type = %d, value = %d", cap_data->type, cap_data->value);
-
-               //cb_func(cap_data->type, cap_data->value, user_data);
-               if(cb_func(cap_data->type, cap_data->value, user_data)!=TRUE){
-                       ACCOUNT_VERBOSE("account_get_capability ::  cb_func returns false, it is stopped\n");
+               if(callback(cap_data->type, cap_data->value, user_data)!=TRUE){
                        return ACCOUNT_ERROR_NONE;
                }
        }
@@ -2325,8 +2618,6 @@ ACCOUNT_API int account_get_custom(account_h account, const char* key, char** va
 
                custom_data = (account_custom_s*)iter->data;
 
-               ACCOUNT_VERBOSE("account_get_custom ::  key = %s, value = %s", custom_data->key, custom_data->value);
-
                if(!strcmp(key, custom_data->key)) {
                        (*value) = NULL;
                        *value = _account_get_text(custom_data->value);
@@ -2334,15 +2625,13 @@ ACCOUNT_API int account_get_custom(account_h account, const char* key, char** va
                }
        }
 
-       ACCOUNT_INFO("key is not found %s", key);
-
        return ACCOUNT_ERROR_RECORD_NOT_FOUND;
 }
 
-ACCOUNT_API int account_get_custom_all(account_h account, account_custom_cb cb_func, void* user_data)
+ACCOUNT_API int account_get_custom_all(account_h account, account_custom_cb callback, void* user_data)
 {
        ACCOUNT_RETURN_VAL((account != NULL), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("ACCOUNT HANDLE IS NULL"));
-       ACCOUNT_RETURN_VAL((cb_func != NULL), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("NO CALLBACK FUNCTION"));
+       ACCOUNT_RETURN_VAL((callback != NULL), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("NO CALLBACK FUNCTION"));
 
        GSList *iter;
        account_s *data = (account_s*)account;
@@ -2353,27 +2642,53 @@ ACCOUNT_API int account_get_custom_all(account_h account, account_custom_cb cb_f
 
                custom_data = (account_custom_s*)iter->data;
 
-               ACCOUNT_VERBOSE("account_get_custom ::  key = %s, value = %s", custom_data->key, custom_data->value);
-
-               cb_ret = cb_func(custom_data->key, custom_data->value, user_data);
+               cb_ret = callback(custom_data->key, custom_data->value, user_data);
                if(!cb_ret) {
-                       ACCOUNT_INFO("account_get_custom_all callback func ret = %d", cb_ret);
                        break;
-       }
+               }
        }
 
        return ACCOUNT_ERROR_NONE;
 }
 
-ACCOUNT_API int account_query_capability_by_account_id(capability_cb cb_func, int account_id, void *user_data )
+ACCOUNT_API int account_query_capability_by_account_id(capability_cb callback, int account_id, void *user_data )
 {
        int                     error_code = ACCOUNT_ERROR_NONE;
        account_stmt    hstmt = NULL;
        char                    query[ACCOUNT_SQL_LEN_MAX] = {0, };
        int                     rc = 0;
 
+       int res;
+       int process_uid = getuid();
+       char subject_label[SMACK_LABEL_LEN + 1] = {0,};
+
+       if(process_uid != 0) {
+               int fd = open("/proc/self/attr/current", O_RDONLY);
+               if(fd < 0)
+               {
+                       ACCOUNT_ERROR("file open fail :: /proc/self/attr/current");
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+
+               res = read(fd, subject_label, SMACK_LABEL_LEN);
+               if(res < 0)
+               {
+                       ACCOUNT_ERROR("file read fail :: /proc/self/attr/current");
+                       close(fd);
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+
+               res = smack_have_access(subject_label, "libaccounts-svc::check_read", "r");
+               if(res != 1) {
+                       ACCOUNT_ERROR("Account permission denied :: This API can not be used without account.read privilege");
+                       close(fd);
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+               close(fd);
+       }
+
        ACCOUNT_RETURN_VAL((account_id > 0), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("ACCOUNT INDEX IS LESS THAN 0"));
-       ACCOUNT_RETURN_VAL((cb_func != NULL), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("NO CALLBACK FUNCTION"));
+       ACCOUNT_RETURN_VAL((callback != NULL), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("NO CALLBACK FUNCTION"));
        ACCOUNT_RETURN_VAL((g_hAccountDB != NULL), {}, ACCOUNT_ERROR_DB_NOT_OPENED, ("The database isn't connected."));
 
        ACCOUNT_MEMSET(query, 0x00, ACCOUNT_SQL_LEN_MAX);
@@ -2381,6 +2696,11 @@ ACCOUNT_API int account_query_capability_by_account_id(capability_cb cb_func, in
        ACCOUNT_SNPRINTF(query, sizeof(query), "SELECT * FROM %s WHERE account_id = %d", CAPABILITY_TABLE, account_id);
        hstmt = _account_prepare_query(query);
 
+       if( _account_db_err_code() == SQLITE_PERM ){
+               ACCOUNT_ERROR( "Access failed(%s)", _account_db_err_msg());
+               return ACCOUNT_ERROR_PERMISSION_DENIED;
+       }
+
        rc = _account_query_step(hstmt);
        ACCOUNT_CATCH_ERROR(rc == SQLITE_ROW, {}, ACCOUNT_ERROR_RECORD_NOT_FOUND, ("The record isn't found.\n"));
 
@@ -2399,7 +2719,7 @@ ACCOUNT_API int account_query_capability_by_account_id(capability_cb cb_func, in
 
                _account_convert_column_to_capability(hstmt, capability_record);
 
-               cb_ret = cb_func(capability_record->type, capability_record->value, user_data);
+               cb_ret = callback(capability_record->type, capability_record->value, user_data);
 
                _account_free_capability_items(capability_record);
                _ACCOUNT_FREE(capability_record);
@@ -2409,14 +2729,16 @@ ACCOUNT_API int account_query_capability_by_account_id(capability_cb cb_func, in
                rc = _account_query_step(hstmt);
        }
 
-       _account_query_finalize(hstmt);
+       rc = _account_query_finalize(hstmt);
+       ACCOUNT_RETURN_VAL((rc == ACCOUNT_ERROR_NONE), {}, rc, ("finalize error"));
        hstmt = NULL;
 
        error_code = ACCOUNT_ERROR_NONE;
 
 CATCH:
        if (hstmt != NULL) {
-               _account_query_finalize(hstmt);
+               rc = _account_query_finalize(hstmt);
+               ACCOUNT_RETURN_VAL((rc == ACCOUNT_ERROR_NONE), {}, rc, ("finalize error"));
                hstmt = NULL;
        }
 
@@ -2448,11 +2770,11 @@ static int _account_compare_old_record(account_s *new_account, int account_id)
 
        while (rc == SQLITE_ROW) {
                _account_convert_column_to_account(hstmt, old_account);
-               ACCOUNT_VERBOSE("get account info by id %p\n", old_account);
                rc = _account_query_step(hstmt);
        }
 
-       _account_query_finalize(hstmt);
+       rc = _account_query_finalize(hstmt);
+       ACCOUNT_CATCH_ERROR((rc == ACCOUNT_ERROR_NONE), {}, rc, ("finalize error"));
        hstmt = NULL;
 
        // get capability
@@ -2550,17 +2872,68 @@ static int _account_compare_old_record(account_s *new_account, int account_id)
 
 
        CATCH:
+               if (old_account) {
+                       _account_free_account_items(old_account);
+                       _ACCOUNT_FREE(old_account);
+               }
+
                if (hstmt != NULL) {
-                       _account_query_finalize(hstmt);
+                       rc = _account_query_finalize(hstmt);
+                       ACCOUNT_RETURN_VAL((rc == ACCOUNT_ERROR_NONE), {}, rc, ("finalize error"));
                        hstmt = NULL;
                }
 
+       return ACCOUNT_ERROR_NONE;
+}
+
+static int _account_get_package_name_from_account_id(int account_id, char **package_name)
+{
+       int                             error_code = ACCOUNT_ERROR_NONE;
+       account_stmt    hstmt = NULL;
+       char                    query[ACCOUNT_SQL_LEN_MAX] = {0, };
+       int                             rc = 0;
+       account_s *old_account = NULL;
+
+       ACCOUNT_RETURN_VAL((account_id > 0), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("ACCOUNT INDEX IS LESS THAN 0"));
+       ACCOUNT_RETURN_VAL((g_hAccountDB != NULL), {}, ACCOUNT_ERROR_DB_NOT_OPENED, ("The database isn't connected."));
+
+       old_account = (account_s*)calloc(1, sizeof(account_s));
+
+       ACCOUNT_MEMSET(query, 0x00, ACCOUNT_SQL_LEN_MAX);
+
+       ACCOUNT_SNPRINTF(query, sizeof(query), "SELECT * FROM %s WHERE _id = %d", ACCOUNT_TABLE, account_id);
+       hstmt = _account_prepare_query(query);
+
+       rc = _account_query_step(hstmt);
+       ACCOUNT_CATCH_ERROR(rc == SQLITE_ROW, {}, ACCOUNT_ERROR_RECORD_NOT_FOUND, ("The record isn't found.\n"));
+
+       while (rc == SQLITE_ROW) {
+               _account_convert_column_to_account(hstmt, old_account);
+               rc = _account_query_step(hstmt);
+       }
+
+       rc = _account_query_finalize(hstmt);
+       ACCOUNT_CATCH_ERROR((rc == ACCOUNT_ERROR_NONE), {}, rc, ("finalize error"));
+       hstmt = NULL;
+
+       // get package name.
+       *package_name = _account_get_text(old_account->package_name);
+
+
+       CATCH:
                if (old_account) {
                        _account_free_account_items(old_account);
                        _ACCOUNT_FREE(old_account);
                }
 
-       return ACCOUNT_ERROR_NONE;
+               if (hstmt != NULL) {
+                       rc = _account_query_finalize(hstmt);
+                       ACCOUNT_RETURN_VAL((rc == ACCOUNT_ERROR_NONE), {}, rc, ("finalize error"));
+                       hstmt = NULL;
+               }
+
+       return error_code;
+
 }
 
 static int _account_update_account(account_s *account, int account_id)
@@ -2575,14 +2948,25 @@ static int _account_update_account(account_s *account, int account_id)
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
 
+       /* Check permission of requested appid */
        char* current_appid = NULL;
-       char* verified_appid = NULL;
+       char *package_name = NULL;
 
        current_appid = _account_get_current_appid();
-       error_code = _account_check_account_type_with_appid_group(current_appid, &verified_appid);
+       error_code = _account_get_package_name_from_account_id(account_id, &package_name);
+
+       if(error_code != ACCOUNT_ERROR_NONE || package_name == NULL){
+               ACCOUNT_ERROR("No package name with account_id\n");
+               _ACCOUNT_FREE(current_appid);
+               _ACCOUNT_FREE(package_name);
+               return ACCOUNT_ERROR_RECORD_NOT_FOUND;
+       }
+
+       error_code = _account_check_appid_group_with_package_name(current_appid, package_name);
+       ACCOUNT_DEBUG( "UPDATE:account_id[%d],current_appid[%s]package_name[%s]", account_id, current_appid, package_name);     // TODO: remove the log later.
 
        _ACCOUNT_FREE(current_appid);
-       _ACCOUNT_FREE(verified_appid);
+       _ACCOUNT_FREE(package_name);
 
        if(error_code != ACCOUNT_ERROR_NONE){
                ACCOUNT_ERROR("No permission to update\n");
@@ -2591,6 +2975,14 @@ static int _account_update_account(account_s *account, int account_id)
 
        _account_compare_old_record(account, account_id);
 
+       if( _account_db_err_code() == SQLITE_PERM ){
+               ACCOUNT_ERROR( "Access failed(%s)", _account_db_err_msg());
+               return ACCOUNT_ERROR_PERMISSION_DENIED;
+       } else if( _account_db_err_code() == SQLITE_BUSY ){
+               ACCOUNT_ERROR( "database busy(%s)", _account_db_err_msg());
+               return ACCOUNT_ERROR_DATABASE_BUSY;
+       }
+
        if (!account->user_name && !account->display_name && !account->email_address) {
                ACCOUNT_ERROR("One field should be set among user name, display name, email address\n");
                return ACCOUNT_ERROR_INVALID_PARAMETER;
@@ -2602,12 +2994,17 @@ static int _account_update_account(account_s *account, int account_id)
 
        count = _account_get_record_count(query);
        if (count <= 0) {
-               ACCOUNT_WARNING(" Account record not found, count = %d\n", count);
+               ACCOUNT_DEBUG(" Account record not found, count = %d\n", count);
                return ACCOUNT_ERROR_RECORD_NOT_FOUND;
        }
 
        /* transaction control required*/
        ret_transaction = _account_begin_transaction();
+       if( ret_transaction == ACCOUNT_ERROR_DATABASE_BUSY ){
+               ACCOUNT_ERROR( "database busy(%s)", _account_db_err_msg());
+               pthread_mutex_unlock(&account_mutex);
+               return ACCOUNT_ERROR_DATABASE_BUSY;
+       }
 
        ACCOUNT_MEMSET(query, 0x00, sizeof(query));
        ACCOUNT_SNPRINTF(query, sizeof(query), "UPDATE %s SET user_name=?, email_address =?, display_name =?, "
@@ -2616,6 +3013,13 @@ static int _account_update_account(account_s *account, int account_id)
                        "int_custom0=?, int_custom1=?, int_custom2=?, int_custom3=?, int_custom4=? WHERE _id=? ", ACCOUNT_TABLE);
 
        hstmt = _account_prepare_query(query);
+
+       if( _account_db_err_code() == SQLITE_PERM ){
+               ret_transaction = _account_end_transaction(FALSE);
+               ACCOUNT_ERROR( "Access failed(%s)", _account_db_err_msg());
+               return ACCOUNT_ERROR_PERMISSION_DENIED;
+       }
+
        ACCOUNT_RETURN_VAL((hstmt != NULL), {}, ACCOUNT_ERROR_DB_FAILED, ("_account_svc_query_prepare() failed(%s)(%x).\n", _account_db_err_msg(), _account_end_transaction(FALSE)));
 
        binding_count = _account_convert_account_to_sql(account, hstmt, query);
@@ -2623,10 +3027,11 @@ static int _account_update_account(account_s *account, int account_id)
 
        rc = _account_query_step(hstmt);
        if (rc != SQLITE_DONE) {
-               ACCOUNT_DEBUG( "account_db_query_step() failed(%d, %s)", rc, _account_db_err_msg());
+               ACCOUNT_SLOGE( "account_db_query_step() failed(%d, %s)", rc, _account_db_err_msg());
        }
 
-       _account_query_finalize(hstmt);
+       rc = _account_query_finalize(hstmt);
+       ACCOUNT_RETURN_VAL((rc == ACCOUNT_ERROR_NONE), {}, rc, ("finalize error"));
        hstmt = NULL;
 
        /*update capability*/
@@ -2646,11 +3051,11 @@ static int _account_update_account(account_s *account, int account_id)
        }
 
        ret_transaction = _account_end_transaction(TRUE);
-       ACCOUNT_DEBUG("update capability success, trying to commit(%x) !!!\n", ret_transaction);
 
        return error_code;
 }
 
+
 static int _account_update_account_ex(account_s *account, int account_id)
 {
        int                             rc = 0, binding_count =0;
@@ -2665,6 +3070,11 @@ static int _account_update_account_ex(account_s *account, int account_id)
 
        _account_compare_old_record(account, account_id);
 
+       if( _account_db_err_code() == SQLITE_PERM ){
+               ACCOUNT_ERROR( "Access failed(%s)", _account_db_err_msg());
+               return ACCOUNT_ERROR_PERMISSION_DENIED;
+       }
+
        if (!account->user_name && !account->display_name && !account->email_address) {
                ACCOUNT_ERROR("One field should be set among user name, display name, email address\n");
                return ACCOUNT_ERROR_INVALID_PARAMETER;
@@ -2676,12 +3086,17 @@ static int _account_update_account_ex(account_s *account, int account_id)
 
        count = _account_get_record_count(query);
        if (count <= 0) {
-               ACCOUNT_WARNING(" Account record not found, count = %d\n", count);
+               ACCOUNT_DEBUG(" Account record not found, count = %d\n", count);
                return ACCOUNT_ERROR_RECORD_NOT_FOUND;
        }
 
        /* transaction control required*/
        ret_transaction = _account_begin_transaction();
+       if( ret_transaction == ACCOUNT_ERROR_DATABASE_BUSY ){
+               ACCOUNT_ERROR( "database busy(%s)", _account_db_err_msg());
+               pthread_mutex_unlock(&account_mutex);
+               return ACCOUNT_ERROR_DATABASE_BUSY;
+       }
 
        ACCOUNT_MEMSET(query, 0x00, sizeof(query));
        ACCOUNT_SNPRINTF(query, sizeof(query), "UPDATE %s SET user_name=?, email_address =?, display_name =?, "
@@ -2690,6 +3105,13 @@ static int _account_update_account_ex(account_s *account, int account_id)
                        "int_custom0=?, int_custom1=?, int_custom2=?, int_custom3=?, int_custom4=? WHERE _id=? ", ACCOUNT_TABLE);
 
        hstmt = _account_prepare_query(query);
+
+       if( _account_db_err_code() == SQLITE_PERM ){
+               ret_transaction = _account_end_transaction(FALSE);
+               ACCOUNT_ERROR( "Access failed(%s)", _account_db_err_msg());
+               return ACCOUNT_ERROR_PERMISSION_DENIED;
+       }
+
        ACCOUNT_RETURN_VAL((hstmt != NULL), {}, ACCOUNT_ERROR_DB_FAILED, ("_account_svc_query_prepare() failed(%s)(%x).\n", _account_db_err_msg(), _account_end_transaction(FALSE)));
 
        binding_count = _account_convert_account_to_sql(account, hstmt, query);
@@ -2697,10 +3119,11 @@ static int _account_update_account_ex(account_s *account, int account_id)
 
        rc = _account_query_step(hstmt);
        if (rc != SQLITE_DONE) {
-               ACCOUNT_DEBUG( "account_db_query_step() failed(%d, %s)", rc, _account_db_err_msg());
+               ACCOUNT_SLOGE( "account_db_query_step() failed(%d, %s)", rc, _account_db_err_msg());
        }
 
-       _account_query_finalize(hstmt);
+       rc = _account_query_finalize(hstmt);
+       ACCOUNT_RETURN_VAL((rc == ACCOUNT_ERROR_NONE), {}, rc, ("finalize error"));
        hstmt = NULL;
 
        /*update capability*/
@@ -2720,13 +3143,42 @@ static int _account_update_account_ex(account_s *account, int account_id)
        }
 
        ret_transaction = _account_end_transaction(TRUE);
-       ACCOUNT_DEBUG("update capability success, trying to commit(%x) !!!\n", ret_transaction);
 
        return error_code;
 }
 
+
 ACCOUNT_API int account_update_to_db_by_id(const account_h account, int account_id)
 {
+       int res;
+       int process_uid = getuid();
+       char subject_label[SMACK_LABEL_LEN + 1] = {0,};
+
+       if(process_uid != 0) {
+               int fd = open("/proc/self/attr/current", O_RDONLY);
+               if(fd < 0)
+               {
+                       ACCOUNT_ERROR("file open fail :: /proc/self/attr/current");
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+
+               res = read(fd, subject_label, SMACK_LABEL_LEN);
+               if(res < 0)
+               {
+                       ACCOUNT_ERROR("file read fail :: /proc/self/attr/current");
+                       close(fd);
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+
+               res = smack_have_access(subject_label, "libaccounts-svc::check_read", "r");
+               if(res != 1) {
+                       ACCOUNT_ERROR("Account permission denied :: This API can not be used without account.read privilege");
+                       close(fd);
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+               close(fd);
+       }
+
        ACCOUNT_RETURN_VAL((account != NULL), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("DATA IS NULL"));
        ACCOUNT_RETURN_VAL((account_id > 0), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("Account id is not valid"));
        ACCOUNT_RETURN_VAL((g_hAccountDB != NULL), {}, ACCOUNT_ERROR_DB_NOT_OPENED, ("The database isn't connected."));
@@ -2753,6 +3205,35 @@ ACCOUNT_API int account_update_to_db_by_id(const account_h account, int account_
 
 ACCOUNT_API int account_update_to_db_by_id_ex(const account_h account, int account_id)
 {
+       int res;
+       int process_uid = getuid();
+       char subject_label[SMACK_LABEL_LEN + 1] = {0,};
+
+       if(process_uid != 0) {
+               int fd = open("/proc/self/attr/current", O_RDONLY);
+               if(fd < 0)
+               {
+                       ACCOUNT_ERROR("file open fail :: /proc/self/attr/current");
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+
+               res = read(fd, subject_label, SMACK_LABEL_LEN);
+               if(res < 0)
+               {
+                       ACCOUNT_ERROR("file read fail :: /proc/self/attr/current");
+                       close(fd);
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+
+               res = smack_have_access(subject_label, "libaccounts-svc::check_read", "r");
+               if(res != 1) {
+                       ACCOUNT_ERROR("Account permission denied :: This API can not be used without account.read privilege");
+                       close(fd);
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+               close(fd);
+       }
+
        ACCOUNT_RETURN_VAL((account != NULL), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("DATA IS NULL"));
        ACCOUNT_RETURN_VAL((account_id > 0), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("Account id is not valid"));
        ACCOUNT_RETURN_VAL((g_hAccountDB != NULL), {}, ACCOUNT_ERROR_DB_NOT_OPENED, ("The database isn't connected."));
@@ -2777,8 +3258,38 @@ ACCOUNT_API int account_update_to_db_by_id_ex(const account_h account, int accou
        return ACCOUNT_ERROR_NONE;
 }
 
+
 ACCOUNT_API int account_update_to_db_by_user_name(account_h account, const char *user_name, const char *package_name)
 {
+       int res;
+       int process_uid = getuid();
+       char subject_label[SMACK_LABEL_LEN + 1] = {0,};
+
+       if(process_uid != 0) {
+               int fd = open("/proc/self/attr/current", O_RDONLY);
+               if(fd < 0)
+               {
+                       ACCOUNT_ERROR("file open fail :: /proc/self/attr/current");
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+
+               res = read(fd, subject_label, SMACK_LABEL_LEN);
+               if(res < 0)
+               {
+                       ACCOUNT_ERROR("file read fail :: /proc/self/attr/current");
+                       close(fd);
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+
+               res = smack_have_access(subject_label, "libaccounts-svc::check_read", "r");
+               if(res != 1) {
+                       ACCOUNT_ERROR("Account permission denied :: This API can not be used without account.read privilege");
+                       close(fd);
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+               close(fd);
+       }
+
        ACCOUNT_RETURN_VAL((account != NULL), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("DATA IS NULL"));
        ACCOUNT_RETURN_VAL((user_name != NULL), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("USER NAME IS NULL"));
        ACCOUNT_RETURN_VAL((package_name != NULL), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("PACKAGE NAME IS NULL"));
@@ -2789,7 +3300,7 @@ ACCOUNT_API int account_update_to_db_by_user_name(account_h account, const char
 
        pthread_mutex_lock(&account_mutex);
 
-       error_code = _account_update_account_by_user_name(data, (char*)user_name, (char*)package_name);
+       error_code = _account_update_account_by_user_name(data, user_name, package_name);
 
        pthread_mutex_unlock(&account_mutex);
 
@@ -2808,6 +3319,35 @@ ACCOUNT_API int account_foreach_account_from_db(account_cb callback, void *user_
        int                     rc = 0;
        GList                   *account_list = NULL;
 
+       int res;
+       int process_uid = getuid();
+       char subject_label[SMACK_LABEL_LEN + 1] = {0,};
+
+       if(process_uid != 0) {
+               int fd = open("/proc/self/attr/current", O_RDONLY);
+               if(fd < 0)
+               {
+                       ACCOUNT_ERROR("file open fail :: /proc/self/attr/current");
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+
+               res = read(fd, subject_label, SMACK_LABEL_LEN);
+               if(res < 0)
+               {
+                       ACCOUNT_ERROR("file read fail :: /proc/self/attr/current");
+                       close(fd);
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+
+               res = smack_have_access(subject_label, "libaccounts-svc::check_read", "r");
+               if(res != 1) {
+                       ACCOUNT_ERROR("Account permission denied :: This API can not be used without account.read privilege");
+                       close(fd);
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+               close(fd);
+       }
+
        ACCOUNT_RETURN_VAL((callback != NULL), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("ACCOUNT INFO IS NULL"));
        ACCOUNT_RETURN_VAL((g_hAccountDB != NULL), {}, ACCOUNT_ERROR_DB_NOT_OPENED, ("The database isn't connected."));
 
@@ -2816,6 +3356,11 @@ ACCOUNT_API int account_foreach_account_from_db(account_cb callback, void *user_
        ACCOUNT_SNPRINTF(query, sizeof(query), "SELECT * FROM %s ", ACCOUNT_TABLE);
        hstmt = _account_prepare_query(query);
 
+       if( _account_db_err_code() == SQLITE_PERM ){
+               ACCOUNT_ERROR( "Access failed(%s)", _account_db_err_msg());
+               return ACCOUNT_ERROR_PERMISSION_DENIED;
+       }
+
        rc = _account_query_step(hstmt);
 
        account_s *account_record = NULL;
@@ -2838,7 +3383,8 @@ ACCOUNT_API int account_foreach_account_from_db(account_cb callback, void *user_
                k++;
        }
 
-       _account_query_finalize(hstmt);
+       rc = _account_query_finalize(hstmt);
+       ACCOUNT_RETURN_VAL((rc == ACCOUNT_ERROR_NONE), {_account_glist_free(account_list);}, rc, ("finalize error"));
        hstmt = NULL;
 
        GList* iter;
@@ -2856,7 +3402,8 @@ ACCOUNT_API int account_foreach_account_from_db(account_cb callback, void *user_
 
 CATCH:
        if (hstmt != NULL) {
-               _account_query_finalize(hstmt);
+               rc = _account_query_finalize(hstmt);
+               ACCOUNT_RETURN_VAL((rc == ACCOUNT_ERROR_NONE), {}, rc, ("finalize error"));
                hstmt = NULL;
        }
        if (account_list) {
@@ -2875,10 +3422,39 @@ ACCOUNT_API int account_update_sync_status_by_id(int account_db_id, const accoun
        int                             rc = 0;
        int count =1;
 
+       int res;
+       int process_uid = getuid();
+       char subject_label[SMACK_LABEL_LEN + 1] = {0,};
+
+       if(process_uid != 0) {
+               int fd = open("/proc/self/attr/current", O_RDONLY);
+               if(fd < 0)
+               {
+                       ACCOUNT_ERROR("file open fail :: /proc/self/attr/current");
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+
+               res = read(fd, subject_label, SMACK_LABEL_LEN);
+               if(res < 0)
+               {
+                       ACCOUNT_ERROR("file read fail :: /proc/self/attr/current");
+                       close(fd);
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+
+               res = smack_have_access(subject_label, "libaccounts-svc::check_read", "r");
+               if(res != 1) {
+                       ACCOUNT_ERROR("Account permission denied :: This API can not be used without account.read privilege");
+                       close(fd);
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+               close(fd);
+       }
+
        ACCOUNT_RETURN_VAL((account_db_id > 0), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("ACCOUNT INDEX IS LESS THAN 0"));
        ACCOUNT_RETURN_VAL((g_hAccountDB != NULL), {}, ACCOUNT_ERROR_DB_NOT_OPENED, ("The database isn't connected."));
-       if ( (sync_status < 0) || (sync_status > ACCOUNT_SYNC_STATUS_RUNNING)) {
-               ACCOUNT_ERROR("(%s)-(%d) sync_status is less than 0 or more than enum max.\n", __FUNCTION__, __LINE__);
+       if ( ((int)sync_status < 0) || (sync_status > ACCOUNT_SYNC_MAX) ) {
+               ACCOUNT_SLOGE("(%s)-(%d) sync_status is less than 0 or more than enum max.\n", __FUNCTION__, __LINE__);
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
 
@@ -2890,8 +3466,14 @@ ACCOUNT_API int account_update_sync_status_by_id(int account_db_id, const accoun
 
        rc = _account_get_record_count(query);
 
+       if( _account_db_err_code() == SQLITE_PERM ){
+               pthread_mutex_unlock(&account_mutex);
+               ACCOUNT_ERROR( "Access failed(%s)", _account_db_err_msg());
+               return ACCOUNT_ERROR_PERMISSION_DENIED;
+       }
+
        if (rc <= 0) {
-               ACCOUNT_ERROR( "account_update_sync_status_by_id : related account item is not existed rc=%d , %s", rc, _account_db_err_msg());
+               ACCOUNT_SLOGE( "account_update_sync_status_by_id : related account item is not existed rc=%d , %s", rc, _account_db_err_msg());
                pthread_mutex_unlock(&account_mutex);
                return ACCOUNT_ERROR_RECORD_NOT_FOUND;
        }
@@ -2905,11 +3487,21 @@ ACCOUNT_API int account_update_sync_status_by_id(int account_db_id, const accoun
 
        rc = _account_query_step(hstmt);
 
+       if( _account_db_err_code() == SQLITE_PERM ){
+               pthread_mutex_unlock(&account_mutex);
+               ACCOUNT_ERROR( "Access failed(%s)", _account_db_err_msg());
+               return ACCOUNT_ERROR_PERMISSION_DENIED;
+       }
+
        ACCOUNT_CATCH_ERROR(rc == SQLITE_DONE, {}, ACCOUNT_ERROR_DB_FAILED,
                                ("account_db_query_step() failed(%d, %s)", rc, _account_db_err_msg()));
 
-       _account_query_finalize(hstmt);
-
+       rc = _account_query_finalize(hstmt);
+       if (rc != ACCOUNT_ERROR_NONE) {
+               ACCOUNT_ERROR("_account_query_finalize error");
+               pthread_mutex_unlock(&account_mutex);
+               return rc;
+       }
        char buf[64]={0,};
        ACCOUNT_SNPRINTF(buf, sizeof(buf), "%s:%d", ACCOUNT_NOTI_NAME_SYNC_UPDATE, account_db_id);
        _account_insert_delete_update_notification_send(buf);
@@ -2919,7 +3511,9 @@ ACCOUNT_API int account_update_sync_status_by_id(int account_db_id, const accoun
 
 CATCH:
        if (hstmt != NULL) {
-               _account_query_finalize(hstmt);
+               rc = _account_query_finalize(hstmt);
+               pthread_mutex_unlock(&account_mutex);
+               ACCOUNT_RETURN_VAL((rc == ACCOUNT_ERROR_NONE), {}, rc, ("finalize error"));
                hstmt = NULL;
        }
 
@@ -2934,6 +3528,35 @@ ACCOUNT_API int account_query_account_by_account_id(int account_db_id, account_h
        char                    query[ACCOUNT_SQL_LEN_MAX] = {0, };
        int                             rc = 0;
 
+       int res;
+       int process_uid = getuid();
+       char subject_label[SMACK_LABEL_LEN + 1] = {0,};
+
+       if(process_uid != 0) {
+               int fd = open("/proc/self/attr/current", O_RDONLY);
+               if(fd < 0)
+               {
+                       ACCOUNT_ERROR("file open fail :: /proc/self/attr/current");
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+
+               res = read(fd, subject_label, SMACK_LABEL_LEN);
+               if(res < 0)
+               {
+                       ACCOUNT_ERROR("file read fail :: /proc/self/attr/current");
+                       close(fd);
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+
+               res = smack_have_access(subject_label, "libaccounts-svc::check_read", "r");
+               if(res != 1) {
+                       ACCOUNT_ERROR("Account permission denied :: This API can not be used without account.read privilege");
+                       close(fd);
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+               close(fd);
+       }
+
        ACCOUNT_RETURN_VAL((account_db_id > 0), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("ACCOUNT INDEX IS LESS THAN 0"));
        ACCOUNT_RETURN_VAL((*account != NULL), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("ACCOUNT IS NULL"));
        ACCOUNT_RETURN_VAL((g_hAccountDB != NULL), {}, ACCOUNT_ERROR_DB_NOT_OPENED, ("The database isn't connected."));
@@ -2943,6 +3566,11 @@ ACCOUNT_API int account_query_account_by_account_id(int account_db_id, account_h
        ACCOUNT_SNPRINTF(query, sizeof(query), "SELECT * FROM %s WHERE _id = %d", ACCOUNT_TABLE, account_db_id);
        hstmt = _account_prepare_query(query);
 
+       if( _account_db_err_code() == SQLITE_PERM ){
+               ACCOUNT_ERROR( "Access failed(%s)", _account_db_err_msg());
+               return ACCOUNT_ERROR_PERMISSION_DENIED;
+       }
+
        rc = _account_query_step(hstmt);
        ACCOUNT_CATCH_ERROR(rc == SQLITE_ROW, {}, ACCOUNT_ERROR_RECORD_NOT_FOUND, ("The record isn't found.\n"));
 
@@ -2950,11 +3578,12 @@ ACCOUNT_API int account_query_account_by_account_id(int account_db_id, account_h
 
        while (rc == SQLITE_ROW) {
                _account_convert_column_to_account(hstmt, account_record);
-               ACCOUNT_VERBOSE("get account info by id %p\n", account_record);
                rc = _account_query_step(hstmt);
        }
 
-       _account_query_finalize(hstmt);
+       rc = _account_query_finalize(hstmt);
+       ACCOUNT_RETURN_VAL((rc == ACCOUNT_ERROR_NONE), {}, rc, ("finalize error"));
+
        account_query_capability_by_account_id(_account_get_capability_text_cb, account_record->id, (void*)account_record);
        _account_query_custom_by_account_id(_account_get_custom_text_cb, account_record->id, (void*)account_record);
 
@@ -2963,7 +3592,8 @@ ACCOUNT_API int account_query_account_by_account_id(int account_db_id, account_h
 
 CATCH:
        if (hstmt != NULL) {
-               _account_query_finalize(hstmt);
+               rc = _account_query_finalize(hstmt);
+               ACCOUNT_RETURN_VAL((rc == ACCOUNT_ERROR_NONE), {}, rc, ("finalize error"));
                hstmt = NULL;
        }
 
@@ -2971,15 +3601,44 @@ CATCH:
        return error_code;
 }
 
-ACCOUNT_API int account_query_account_by_user_name(account_cb cb_func, const char *user_name, void *user_data)
+ACCOUNT_API int account_query_account_by_user_name(account_cb callback, const char *user_name, void *user_data)
 {
        int                             error_code = ACCOUNT_ERROR_NONE;
        account_stmt    hstmt = NULL;
        char                    query[ACCOUNT_SQL_LEN_MAX] = {0, };
        int                             rc = 0;
 
+       int res;
+       int process_uid = getuid();
+       char subject_label[SMACK_LABEL_LEN + 1] = {0,};
+
+       if(process_uid != 0) {
+               int fd = open("/proc/self/attr/current", O_RDONLY);
+               if(fd < 0)
+               {
+                       ACCOUNT_ERROR("file open fail :: /proc/self/attr/current");
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+
+               res = read(fd, subject_label, SMACK_LABEL_LEN);
+               if(res < 0)
+               {
+                       ACCOUNT_ERROR("file read fail :: /proc/self/attr/current");
+                       close(fd);
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+
+               res = smack_have_access(subject_label, "libaccounts-svc::check_read", "r");
+               if(res != 1) {
+                       ACCOUNT_ERROR("Account permission denied :: This API can not be used without account.read privilege");
+                       close(fd);
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+               close(fd);
+       }
+
        ACCOUNT_RETURN_VAL((user_name != NULL), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("USER NAME IS NULL"));
-       ACCOUNT_RETURN_VAL((cb_func != NULL), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("CALL BACK IS NULL"));
+       ACCOUNT_RETURN_VAL((callback != NULL), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("CALL BACK IS NULL"));
 
        ACCOUNT_MEMSET(query, 0x00, ACCOUNT_SQL_LEN_MAX);
 
@@ -2987,6 +3646,11 @@ ACCOUNT_API int account_query_account_by_user_name(account_cb cb_func, const cha
 
        hstmt = _account_prepare_query(query);
 
+       if( _account_db_err_code() == SQLITE_PERM ){
+               ACCOUNT_ERROR( "Access failed(%s)", _account_db_err_msg());
+               return ACCOUNT_ERROR_PERMISSION_DENIED;
+       }
+
        int binding_count = 1;
        _account_query_bind_text(hstmt, binding_count++, user_name);
 
@@ -3002,7 +3666,8 @@ ACCOUNT_API int account_query_account_by_user_name(account_cb cb_func, const cha
        if (account_head == NULL) {
                ACCOUNT_FATAL("malloc Failed");
                if (hstmt != NULL) {
-                       _account_query_finalize(hstmt);
+                       rc = _account_query_finalize(hstmt);
+                       ACCOUNT_RETURN_VAL((rc == ACCOUNT_ERROR_NONE), {}, rc, ("finalize error"));
                        hstmt = NULL;
                }
                return ACCOUNT_ERROR_OUT_OF_MEMORY;
@@ -3026,17 +3691,16 @@ ACCOUNT_API int account_query_account_by_user_name(account_cb cb_func, const cha
 
                rc = _account_query_step(hstmt);
                tmp++;
-               ACCOUNT_DEBUG("DETECTED COUNT %d\n", tmp);
        }
 
-       _account_query_finalize(hstmt);
+       rc = _account_query_finalize(hstmt);
+       ACCOUNT_CATCH_ERROR((rc == ACCOUNT_ERROR_NONE), {}, rc, ("finalize error"));
        hstmt = NULL;
 
        GList *iter;
 
 
        tmp = g_list_length(account_head->account_list);
-       ACCOUNT_VERBOSE("GLIST LEN %d\n", tmp);
 
        for (iter = account_head->account_list; iter != NULL; iter = g_list_next(iter)) {
                account_h account;
@@ -3044,36 +3708,15 @@ ACCOUNT_API int account_query_account_by_user_name(account_cb cb_func, const cha
 
                account_s *testaccount = (account_s*)account;
 
-               ACCOUNT_VERBOSE("id = %d", testaccount->id);
-               ACCOUNT_VERBOSE("user_name = %s", testaccount->user_name);
-               ACCOUNT_VERBOSE("email_address = %s", testaccount->email_address);
-               ACCOUNT_VERBOSE("display_name = %s", testaccount->display_name);
-               ACCOUNT_VERBOSE("icon_path = %s", testaccount->icon_path);
-               ACCOUNT_VERBOSE("source = %s", testaccount->source);
-               ACCOUNT_VERBOSE("package_name = %s", testaccount->package_name);
-               ACCOUNT_VERBOSE("access_token = %s", testaccount->access_token);
-               ACCOUNT_VERBOSE("domain_name = %s", testaccount->domain_name);
-               ACCOUNT_VERBOSE("auth_type = %d", testaccount->auth_type);
-               ACCOUNT_VERBOSE("secret = %d", testaccount->secret);
-               ACCOUNT_VERBOSE("sync_support = %d", testaccount->sync_support);
-
                account_query_capability_by_account_id(_account_get_capability_text_cb, testaccount->id, (void*)testaccount);
                _account_query_custom_by_account_id(_account_get_custom_text_cb, testaccount->id, (void*)testaccount);
 
-               ACCOUNT_VERBOSE("capability_list address = %p", testaccount->capablity_list);
-
-               //cb_func(account, user_data);
-               ACCOUNT_CATCH_ERROR(cb_func(account, user_data) == TRUE, {}, ACCOUNT_ERROR_NONE, ("cb_func returns false, it is stopped.\n"));
-
+               ACCOUNT_CATCH_ERROR(callback(account, user_data) == TRUE, {}, ACCOUNT_ERROR_NONE, ("callback returns false, it is stopped.\n"));
        }
 
        error_code = ACCOUNT_ERROR_NONE;
 
 CATCH:
-       if (hstmt != NULL) {
-               _account_query_finalize(hstmt);
-               hstmt = NULL;
-       }
        if (account_head) {
                if (account_head->account_list) {
                        _account_glist_free(account_head->account_list);
@@ -3082,26 +3725,60 @@ CATCH:
                }
                _ACCOUNT_FREE(account_head);
        }
+       if (hstmt != NULL) {
+               rc = _account_query_finalize(hstmt);
+               ACCOUNT_RETURN_VAL((rc == ACCOUNT_ERROR_NONE), {}, rc, ("finalize error"));
+               hstmt = NULL;
+       }
 
        pthread_mutex_unlock(&account_mutex);
        return error_code;
 }
 
-ACCOUNT_API int account_query_account_by_capability(account_cb cb_func, const char* capability_type, account_capability_state_e capability_value, void* user_data)
+ACCOUNT_API int account_query_account_by_capability(account_cb callback, const char* capability_type, account_capability_state_e capability_value, void* user_data)
 {
        int                     error_code = ACCOUNT_ERROR_NONE;
        account_stmt    hstmt = NULL;
        char                    query[ACCOUNT_SQL_LEN_MAX] = {0, };
        int                     rc = 0;
 
+       int res;
+       int process_uid = getuid();
+       char subject_label[SMACK_LABEL_LEN + 1] = {0,};
+
+       if(process_uid != 0) {
+               int fd = open("/proc/self/attr/current", O_RDONLY);
+               if(fd < 0)
+               {
+                       ACCOUNT_ERROR("file open fail :: /proc/self/attr/current");
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+
+               res = read(fd, subject_label, SMACK_LABEL_LEN);
+               if(res < 0)
+               {
+                       ACCOUNT_ERROR("file read fail :: /proc/self/attr/current");
+                       close(fd);
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+
+               res = smack_have_access(subject_label, "libaccounts-svc::check_read", "r");
+               if(res != 1) {
+                       ACCOUNT_ERROR("Account permission denied :: This API can not be used without account.read privilege");
+                       close(fd);
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+               close(fd);
+       }
+
        ACCOUNT_RETURN_VAL((capability_type != NULL), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("capability_type IS NULL"));
 
-       if ((capability_value  < 0) || (capability_value > ACCOUNT_CAPABILITY_ENABLED)) {
-               ACCOUNT_ERROR("(%s)-(%d) capability_value is not equal to 0 or 1.\n", __FUNCTION__, __LINE__);
+       if (((int)capability_value  < 0) || (capability_value > ACCOUNT_CAPABILITY_STATE_MAX)) {
+               ACCOUNT_SLOGE("(%s)-(%d) capability_value is not equal to 0 or 1.\n", __FUNCTION__, __LINE__);
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
 
-       ACCOUNT_RETURN_VAL((cb_func != NULL), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("CALL BACK IS NULL"));
+       ACCOUNT_RETURN_VAL((callback != NULL), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("CALL BACK IS NULL"));
        ACCOUNT_RETURN_VAL((g_hAccountDB != NULL), {}, ACCOUNT_ERROR_DB_NOT_OPENED, ("The database isn't connected."));
 
        ACCOUNT_MEMSET(query, 0x00, ACCOUNT_SQL_LEN_MAX);
@@ -3110,8 +3787,13 @@ ACCOUNT_API int account_query_account_by_capability(account_cb cb_func, const ch
 
        hstmt = _account_prepare_query(query);
 
+       if( _account_db_err_code() == SQLITE_PERM ){
+               ACCOUNT_ERROR( "Access failed(%s)", _account_db_err_msg());
+               return ACCOUNT_ERROR_PERMISSION_DENIED;
+       }
+
        int binding_count = 1;
-       _account_query_bind_text(hstmt, binding_count++, (char*)capability_type);
+       _account_query_bind_text(hstmt, binding_count++, capability_type);
        _account_query_bind_int(hstmt, binding_count++, (int)capability_value);
 
        rc = _account_query_step(hstmt);
@@ -3126,7 +3808,8 @@ ACCOUNT_API int account_query_account_by_capability(account_cb cb_func, const ch
        if (account_head == NULL) {
                ACCOUNT_FATAL("malloc Failed");
                if (hstmt != NULL) {
-                       _account_query_finalize(hstmt);
+                       rc = _account_query_finalize(hstmt);
+                       ACCOUNT_RETURN_VAL((rc == ACCOUNT_ERROR_NONE), {}, rc, ("finalize error"));
                        hstmt = NULL;
                }
                return ACCOUNT_ERROR_OUT_OF_MEMORY;
@@ -3150,17 +3833,16 @@ ACCOUNT_API int account_query_account_by_capability(account_cb cb_func, const ch
 
                rc = _account_query_step(hstmt);
                tmp++;
-               ACCOUNT_VERBOSE("DETECTED COUNT %d\n", tmp);
        }
 
-       _account_query_finalize(hstmt);
+       rc = _account_query_finalize(hstmt);
+       ACCOUNT_CATCH_ERROR((rc == ACCOUNT_ERROR_NONE), {}, rc, ("finalize error"));
        hstmt = NULL;
 
        GList *iter;
 
 
        tmp = g_list_length(account_head->account_list);
-       ACCOUNT_VERBOSE("GLIST LEN %d\n", tmp);
 
        for (iter = account_head->account_list; iter != NULL; iter = g_list_next(iter)) {
                account_h account = NULL;
@@ -3170,20 +3852,13 @@ ACCOUNT_API int account_query_account_by_capability(account_cb cb_func, const ch
                account_query_capability_by_account_id(_account_get_capability_text_cb, testaccount->id, (void*)testaccount);
                _account_query_custom_by_account_id(_account_get_custom_text_cb, testaccount->id, (void*)testaccount);
 
-               ACCOUNT_VERBOSE("capability_list address = %p", testaccount->capablity_list);
-
-               //cb_func(account, user_data);
-               ACCOUNT_CATCH_ERROR(cb_func(account, user_data) == TRUE, {}, ACCOUNT_ERROR_NONE, ("cb_func returns false, it is stopped.\n"));
+               ACCOUNT_CATCH_ERROR(callback(account, user_data) == TRUE, {}, ACCOUNT_ERROR_NONE, ("callback returns false, it is stopped.\n"));
        }
 
 
        error_code = ACCOUNT_ERROR_NONE;
 
 CATCH:
-       if (hstmt != NULL) {
-               _account_query_finalize(hstmt);
-               hstmt = NULL;
-       }
        if (account_head) {
                if (account_head->account_list) {
                        _account_glist_free(account_head->account_list);
@@ -3193,19 +3868,54 @@ CATCH:
                _ACCOUNT_FREE(account_head);
        }
 
+       if (hstmt != NULL) {
+               rc = _account_query_finalize(hstmt);
+               ACCOUNT_RETURN_VAL((rc == ACCOUNT_ERROR_NONE), {}, rc, ("finalize error"));
+               hstmt = NULL;
+       }
+
        pthread_mutex_unlock(&account_mutex);
        return error_code;
 }
 
-ACCOUNT_API int account_query_account_by_capability_type(account_cb cb_func, const char* capability_type, void* user_data)
+ACCOUNT_API int account_query_account_by_capability_type(account_cb callback, const char* capability_type, void* user_data)
 {
        int                     error_code = ACCOUNT_ERROR_NONE;
        account_stmt    hstmt = NULL;
        char                    query[ACCOUNT_SQL_LEN_MAX] = {0, };
        int                     rc = 0;
 
+       int res;
+       int process_uid = getuid();
+       char subject_label[SMACK_LABEL_LEN + 1] = {0,};
+
+       if(process_uid != 0) {
+               int fd = open("/proc/self/attr/current", O_RDONLY);
+               if(fd < 0)
+               {
+                       ACCOUNT_ERROR("file open fail :: /proc/self/attr/current");
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+
+               res = read(fd, subject_label, SMACK_LABEL_LEN);
+               if(res < 0)
+               {
+                       ACCOUNT_ERROR("file read fail :: /proc/self/attr/current");
+                       close(fd);
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+
+               res = smack_have_access(subject_label, "libaccounts-svc::check_read", "r");
+               if(res != 1) {
+                       ACCOUNT_ERROR("Account permission denied :: This API can not be used without account.read privilege");
+                       close(fd);
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+               close(fd);
+       }
+
        ACCOUNT_RETURN_VAL((capability_type != NULL), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("capability_type IS NULL"));
-       ACCOUNT_RETURN_VAL((cb_func != NULL), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("CALL BACK IS NULL"));
+       ACCOUNT_RETURN_VAL((callback != NULL), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("CALL BACK IS NULL"));
        ACCOUNT_RETURN_VAL((g_hAccountDB != NULL), {}, ACCOUNT_ERROR_DB_NOT_OPENED, ("The database isn't connected."));
 
        ACCOUNT_MEMSET(query, 0x00, ACCOUNT_SQL_LEN_MAX);
@@ -3214,8 +3924,13 @@ ACCOUNT_API int account_query_account_by_capability_type(account_cb cb_func, con
 
        hstmt = _account_prepare_query(query);
 
+       if( _account_db_err_code() == SQLITE_PERM ){
+               ACCOUNT_ERROR( "Access failed(%s)", _account_db_err_msg());
+               return ACCOUNT_ERROR_PERMISSION_DENIED;
+       }
+
        int binding_count = 1;
-       _account_query_bind_text(hstmt, binding_count++, (char*)capability_type);
+       _account_query_bind_text(hstmt, binding_count++, capability_type);
 
        rc = _account_query_step(hstmt);
 
@@ -3229,7 +3944,8 @@ ACCOUNT_API int account_query_account_by_capability_type(account_cb cb_func, con
        if (account_head == NULL) {
                ACCOUNT_FATAL("malloc Failed");
                if (hstmt != NULL) {
-                       _account_query_finalize(hstmt);
+                       rc = _account_query_finalize(hstmt);
+                       ACCOUNT_RETURN_VAL((rc == ACCOUNT_ERROR_NONE), {}, rc, ("finalize error"));
                        hstmt = NULL;
                }
                return ACCOUNT_ERROR_OUT_OF_MEMORY;
@@ -3253,17 +3969,16 @@ ACCOUNT_API int account_query_account_by_capability_type(account_cb cb_func, con
 
                rc = _account_query_step(hstmt);
                tmp++;
-               ACCOUNT_VERBOSE("DETECTED COUNT %d\n", tmp);
        }
 
-       _account_query_finalize(hstmt);
+       rc = _account_query_finalize(hstmt);
+       ACCOUNT_CATCH_ERROR((rc == ACCOUNT_ERROR_NONE), {}, rc, ("finalize error"));
        hstmt = NULL;
 
        GList *iter;
 
 
        tmp = g_list_length(account_head->account_list);
-       ACCOUNT_VERBOSE("GLIST LEN %d\n", tmp);
 
        for (iter = account_head->account_list; iter != NULL; iter = g_list_next(iter)) {
                account_h account = NULL;
@@ -3273,20 +3988,13 @@ ACCOUNT_API int account_query_account_by_capability_type(account_cb cb_func, con
                account_query_capability_by_account_id(_account_get_capability_text_cb, testaccount->id, (void*)testaccount);
                _account_query_custom_by_account_id(_account_get_custom_text_cb, testaccount->id, (void*)testaccount);
 
-               ACCOUNT_VERBOSE("capability_list address = %p", testaccount->capablity_list);
-
-               //cb_func(account, user_data);
-               ACCOUNT_CATCH_ERROR(cb_func(account, user_data) == TRUE, {}, ACCOUNT_ERROR_NONE, ("The record isn't found.\n"));
+               ACCOUNT_CATCH_ERROR(callback(account, user_data) == TRUE, {}, ACCOUNT_ERROR_NONE, ("The record isn't found.\n"));
 
        }
 
        error_code = ACCOUNT_ERROR_NONE;
 
 CATCH:
-       if (hstmt != NULL) {
-               _account_query_finalize(hstmt);
-               hstmt = NULL;
-       }
        if (account_head) {
                if (account_head->account_list) {
                        _account_glist_free(account_head->account_list);
@@ -3296,19 +4004,54 @@ CATCH:
                _ACCOUNT_FREE(account_head);
        }
 
+       if (hstmt != NULL) {
+               rc = _account_query_finalize(hstmt);
+               ACCOUNT_RETURN_VAL((rc == ACCOUNT_ERROR_NONE), {}, rc, ("finalize error"));
+               hstmt = NULL;
+       }
+
        pthread_mutex_unlock(&account_mutex);
        return error_code;
 }
 
-ACCOUNT_API int account_query_account_by_package_name(account_cb cb_func, const char* package_name, void* user_data)
+ACCOUNT_API int account_query_account_by_package_name(account_cb callback, const char* package_name, void* user_data)
 {
        int                     error_code = ACCOUNT_ERROR_NONE;
        account_stmt    hstmt = NULL;
        char                    query[ACCOUNT_SQL_LEN_MAX] = {0, };
        int                     rc = 0;
 
+       int res;
+       int process_uid = getuid();
+       char subject_label[SMACK_LABEL_LEN + 1] = {0,};
+
+       if(process_uid != 0) {
+               int fd = open("/proc/self/attr/current", O_RDONLY);
+               if(fd < 0)
+               {
+                       ACCOUNT_ERROR("file open fail :: /proc/self/attr/current");
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+
+               res = read(fd, subject_label, SMACK_LABEL_LEN);
+               if(res < 0)
+               {
+                       ACCOUNT_ERROR("file read fail :: /proc/self/attr/current");
+                       close(fd);
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+
+               res = smack_have_access(subject_label, "libaccounts-svc::check_read", "r");
+               if(res != 1) {
+                       ACCOUNT_ERROR("Account permission denied :: This API can not be used without account.read privilege");
+                       close(fd);
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+               close(fd);
+       }
+
        ACCOUNT_RETURN_VAL((package_name != NULL), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("PACKAGE NAME IS NULL"));
-       ACCOUNT_RETURN_VAL((cb_func != NULL), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("CALL BACK IS NULL"));
+       ACCOUNT_RETURN_VAL((callback != NULL), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("CALL BACK IS NULL"));
        ACCOUNT_RETURN_VAL((g_hAccountDB != NULL), {}, ACCOUNT_ERROR_DB_NOT_OPENED, ("The database isn't connected."));
 
        ACCOUNT_MEMSET(query, 0x00, ACCOUNT_SQL_LEN_MAX);
@@ -3317,6 +4060,11 @@ ACCOUNT_API int account_query_account_by_package_name(account_cb cb_func, const
 
        hstmt = _account_prepare_query(query);
 
+       if( _account_db_err_code() == SQLITE_PERM ){
+               ACCOUNT_ERROR( "Access failed(%s)", _account_db_err_msg());
+               return ACCOUNT_ERROR_PERMISSION_DENIED;
+       }
+
        int binding_count = 1;
        _account_query_bind_text(hstmt, binding_count++, package_name);
 
@@ -3332,7 +4080,8 @@ ACCOUNT_API int account_query_account_by_package_name(account_cb cb_func, const
        if (account_head == NULL) {
                ACCOUNT_FATAL("malloc Failed");
                if (hstmt != NULL) {
-                       _account_query_finalize(hstmt);
+                       rc = _account_query_finalize(hstmt);
+                       ACCOUNT_RETURN_VAL((rc == ACCOUNT_ERROR_NONE), {}, rc, ("finalize error"));
                        hstmt = NULL;
                }
                return ACCOUNT_ERROR_OUT_OF_MEMORY;
@@ -3356,16 +4105,15 @@ ACCOUNT_API int account_query_account_by_package_name(account_cb cb_func, const
 
                rc = _account_query_step(hstmt);
                tmp++;
-               ACCOUNT_VERBOSE("DETECTED COUNT %d\n", tmp);
        }
 
-       _account_query_finalize(hstmt);
+       rc = _account_query_finalize(hstmt);
+       ACCOUNT_CATCH_ERROR((rc == ACCOUNT_ERROR_NONE), {}, rc, ("finalize error"));
        hstmt = NULL;
 
        GList *iter;
 
        tmp = g_list_length(account_head->account_list);
-       ACCOUNT_DEBUG("GLIST LEN %d\n", tmp);
 
        for (iter = account_head->account_list; iter != NULL; iter = g_list_next(iter)) {
                account_h account = NULL;
@@ -3373,36 +4121,16 @@ ACCOUNT_API int account_query_account_by_package_name(account_cb cb_func, const
 
                account_s* testaccount = (account_s*)account;
 
-               ACCOUNT_VERBOSE("id = %d", testaccount->id);
-               ACCOUNT_VERBOSE("user_name = %s", testaccount->user_name);
-               ACCOUNT_VERBOSE("email_address = %s", testaccount->email_address);
-               ACCOUNT_VERBOSE("display_name = %s", testaccount->display_name);
-               ACCOUNT_VERBOSE("icon_path = %s", testaccount->icon_path);
-               ACCOUNT_VERBOSE("source = %s", testaccount->source);
-               ACCOUNT_VERBOSE("package_name = %s", testaccount->package_name);
-               ACCOUNT_VERBOSE("access_token = %s", testaccount->access_token);
-               ACCOUNT_VERBOSE("domain_name = %s", testaccount->domain_name);
-               ACCOUNT_VERBOSE("auth_type = %d", testaccount->auth_type);
-               ACCOUNT_VERBOSE("secret = %d", testaccount->secret);
-               ACCOUNT_VERBOSE("sync_support = %d", testaccount->sync_support);
-
                account_query_capability_by_account_id(_account_get_capability_text_cb, testaccount->id, (void*)testaccount);
                _account_query_custom_by_account_id(_account_get_custom_text_cb, testaccount->id, (void*)testaccount);
 
-               ACCOUNT_VERBOSE("capability_list address = %p", testaccount->capablity_list);
-
-               //cb_func(account, user_data);
-               ACCOUNT_CATCH_ERROR(cb_func(account, user_data) == TRUE, {}, ACCOUNT_ERROR_NONE, ("The record isn't found.\n"));
+               ACCOUNT_CATCH_ERROR(callback(account, user_data) == TRUE, {}, ACCOUNT_ERROR_NONE, ("The record isn't found.\n"));
 
        }
 
        error_code = ACCOUNT_ERROR_NONE;
 
 CATCH:
-       if (hstmt != NULL) {
-               _account_query_finalize(hstmt);
-               hstmt = NULL;
-       }
        if (account_head) {
                if (account_head->account_list) {
                        _account_glist_free(account_head->account_list);
@@ -3412,6 +4140,12 @@ CATCH:
                _ACCOUNT_FREE(account_head);
        }
 
+       if (hstmt != NULL) {
+               rc = _account_query_finalize(hstmt);
+               ACCOUNT_RETURN_VAL((rc == ACCOUNT_ERROR_NONE), {}, rc, ("finalize error"));
+               hstmt = NULL;
+       }
+
        pthread_mutex_unlock(&account_mutex);
        return error_code;
 }
@@ -3425,43 +4159,95 @@ ACCOUNT_API int account_delete(int account_id)
        int                             ret_transaction = 0;
        bool                    is_success = FALSE;
 
+       int res;
+       int process_uid = getuid();
+       char subject_label[SMACK_LABEL_LEN + 1] = {0,};
+
+       if(process_uid != 0) {
+               int fd = open("/proc/self/attr/current", O_RDONLY);
+               if(fd < 0)
+               {
+                       ACCOUNT_ERROR("file open fail :: /proc/self/attr/current");
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+
+               res = read(fd, subject_label, SMACK_LABEL_LEN);
+               if(res < 0)
+               {
+                       ACCOUNT_ERROR("file read fail :: /proc/self/attr/current");
+                       close(fd);
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+
+               res = smack_have_access(subject_label, "libaccounts-svc::check_read", "r");
+               if(res != 1) {
+                       ACCOUNT_ERROR("Account permission denied :: This API can not be used without account.read privilege");
+                       close(fd);
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+               close(fd);
+       }
+
        ACCOUNT_RETURN_VAL((g_hAccountDB != NULL), {}, ACCOUNT_ERROR_DB_NOT_OPENED, ("The database isn't connected."));
 
        int count = -1;
-       account_h               account = NULL;
        /* Check requested ID to delete */
        ACCOUNT_SNPRINTF(query, sizeof(query), "SELECT COUNT(*) FROM %s WHERE _id=%d", ACCOUNT_TABLE, account_id);
 
        count = _account_get_record_count(query);
+
+       if( _account_db_err_code() == SQLITE_PERM ){
+               pthread_mutex_unlock(&account_mutex);
+               ACCOUNT_ERROR( "Access failed(%s)", _account_db_err_msg());
+               return ACCOUNT_ERROR_PERMISSION_DENIED;
+       }
+
        if (count <= 0) {
                ACCOUNT_ERROR("account id(%d) is not exist. count(%d)\n", account_id, count);
                return ACCOUNT_ERROR_RECORD_NOT_FOUND;
        }
 
        /* Check permission of requested appid */
-       account_create(&account);
-       account_query_account_by_account_id(account_id, &account);
-
        char* current_appid = NULL;
-       char* verified_appid = NULL;
+       char *package_name = NULL;
 
        current_appid = _account_get_current_appid();
-       error_code = _account_check_account_type_with_appid_group(current_appid, &verified_appid);
+
+       error_code = _account_get_package_name_from_account_id(account_id, &package_name);
+
+       if(error_code != ACCOUNT_ERROR_NONE){
+               ACCOUNT_ERROR("No package name with account_id\n");
+               _ACCOUNT_FREE(current_appid);
+               _ACCOUNT_FREE(package_name);
+               return ACCOUNT_ERROR_RECORD_NOT_FOUND;
+       }
+       ACCOUNT_DEBUG( "DELETE:account_id[%d],current_appid[%s]package_name[%s]", account_id, current_appid, package_name);
+
+       error_code = _account_check_appid_group_with_package_name(current_appid, package_name);
 
        _ACCOUNT_FREE(current_appid);
-       _ACCOUNT_FREE(verified_appid);
+       _ACCOUNT_FREE(package_name);
 
        if(error_code != ACCOUNT_ERROR_NONE){
                ACCOUNT_ERROR("No permission to delete\n");
-               account_destroy(account);
                return ACCOUNT_ERROR_PERMISSION_DENIED;
        }
 
-       account_destroy(account);
-
        /* transaction control required*/
        ret_transaction = _account_begin_transaction();
 
+       if( _account_db_err_code() == SQLITE_PERM ){
+               pthread_mutex_unlock(&account_mutex);
+               ACCOUNT_ERROR( "Access failed(%s)", _account_db_err_msg());
+               return ACCOUNT_ERROR_PERMISSION_DENIED;
+       }
+
+       if( ret_transaction == ACCOUNT_ERROR_DATABASE_BUSY ){
+               ACCOUNT_ERROR( "database busy(%s)", _account_db_err_msg());
+               pthread_mutex_unlock(&account_mutex);
+               return ACCOUNT_ERROR_DATABASE_BUSY;
+       }
+
        if (ret_transaction != ACCOUNT_ERROR_NONE) {
                ACCOUNT_ERROR("account_delete:_account_begin_transaction fail %d\n", ret_transaction);
                pthread_mutex_unlock(&account_mutex);
@@ -3472,13 +4258,22 @@ ACCOUNT_API int account_delete(int account_id)
        ACCOUNT_SNPRINTF(query, sizeof(query), "DELETE FROM %s WHERE account_id = %d", CAPABILITY_TABLE, account_id);
 
        hstmt = _account_prepare_query(query);
+
+       if( _account_db_err_code() == SQLITE_PERM ){
+               pthread_mutex_unlock(&account_mutex);
+               ACCOUNT_ERROR( "Access failed(%s)", _account_db_err_msg());
+               return ACCOUNT_ERROR_PERMISSION_DENIED;
+       }
+
        ACCOUNT_CATCH_ERROR(hstmt != NULL, {}, ACCOUNT_ERROR_DB_FAILED,
                        ("_account_svc_query_prepare(%s) failed(%s).\n", query, _account_db_err_msg()));
 
        rc = _account_query_step(hstmt);
        ACCOUNT_CATCH_ERROR(rc == SQLITE_DONE, {}, ACCOUNT_ERROR_RECORD_NOT_FOUND, ("The record isn't found.\n"));
 
-       _account_query_finalize(hstmt);
+       rc = _account_query_finalize(hstmt);
+
+       ACCOUNT_RETURN_VAL((rc == ACCOUNT_ERROR_NONE), {}, rc, ("finalize error"));
        hstmt = NULL;
 
        ACCOUNT_MEMSET(query, 0, sizeof(query));
@@ -3492,7 +4287,8 @@ ACCOUNT_API int account_delete(int account_id)
        rc = _account_query_step(hstmt);
        ACCOUNT_CATCH_ERROR(rc == SQLITE_DONE, {}, ACCOUNT_ERROR_RECORD_NOT_FOUND, ("The record isn't found. id=%d, rc=%d\n", account_id, rc));
 
-       _account_query_finalize(hstmt);
+       rc = _account_query_finalize(hstmt);
+       ACCOUNT_RETURN_VAL((rc == ACCOUNT_ERROR_NONE), {}, rc, ("finalize error"));
        hstmt = NULL;
 
        /* delete custom data */
@@ -3501,26 +4297,34 @@ ACCOUNT_API int account_delete(int account_id)
        ACCOUNT_SNPRINTF(query, sizeof(query), "DELETE FROM %s WHERE AccountId = %d", ACCOUNT_CUSTOM_TABLE, account_id);
 
        hstmt = _account_prepare_query(query);
+
        ACCOUNT_CATCH_ERROR(hstmt != NULL, {}, ACCOUNT_ERROR_DB_FAILED,
                        ("_account_svc_query_prepare(%s) failed(%s).\n", query, _account_db_err_msg()));
 
        rc = _account_query_step(hstmt);
        ACCOUNT_CATCH_ERROR(rc == SQLITE_DONE, {}, ACCOUNT_ERROR_RECORD_NOT_FOUND, ("The record isn't found. id=%d, rc=%d\n", account_id, rc));
 
-       _account_query_finalize(hstmt);
+       rc = _account_query_finalize(hstmt);
+       ACCOUNT_CATCH_ERROR(rc == ACCOUNT_ERROR_NONE, {}, rc, ("finalize error", account_id, rc));
+       hstmt = NULL;
 
        is_success = TRUE;
 
 CATCH:
        if (hstmt != NULL) {
-               _account_query_finalize(hstmt);
+               rc = _account_query_finalize(hstmt);
+               if(rc != ACCOUNT_ERROR_NONE ){
+                       ACCOUNT_ERROR("rc (%d)", rc);
+                       is_success = FALSE;
+               }
+
                hstmt = NULL;
        }
 
        ret_transaction = _account_end_transaction(is_success);
 
        if (ret_transaction != ACCOUNT_ERROR_NONE) {
-               ACCOUNT_ERROR("account_svc_delete:_account_svc_end_transaction fail %d, is_success=%d\n", ret_transaction, is_success);
+               ACCOUNT_ERROR("account_delete:_account_end_transaction fail %d, is_success=%d\n", ret_transaction, is_success);
        } else {
                if (is_success == true) {
                        char buf[64]={0,};
@@ -3560,6 +4364,11 @@ static int _account_query_account_by_username_and_package(const char* username,
        ACCOUNT_SNPRINTF(query, sizeof(query), "SELECT * FROM %s WHERE user_name = ? and package_name = ?", ACCOUNT_TABLE);
        hstmt = _account_prepare_query(query);
 
+       if( _account_db_err_code() == SQLITE_PERM ){
+               ACCOUNT_ERROR( "Access failed(%s)", _account_db_err_msg());
+               return ACCOUNT_ERROR_PERMISSION_DENIED;
+       }
+
        _account_query_bind_text(hstmt, binding_count++, username);
        _account_query_bind_text(hstmt, binding_count++, package_name);
 
@@ -3570,11 +4379,11 @@ static int _account_query_account_by_username_and_package(const char* username,
 
        while (rc == SQLITE_ROW) {
                _account_convert_column_to_account(hstmt, account_record);
-               ACCOUNT_VERBOSE("get account info by id %p\n", account_record);
                rc = _account_query_step(hstmt);
        }
 
-       _account_query_finalize(hstmt);
+       rc = _account_query_finalize(hstmt);
+       ACCOUNT_RETURN_VAL((rc == ACCOUNT_ERROR_NONE), {}, rc, ("finalize error"));
        account_query_capability_by_account_id(_account_get_capability_text_cb, account_record->id, (void*)account_record);
        _account_query_custom_by_account_id(_account_get_custom_text_cb, account_record->id, (void*)account_record);
 
@@ -3583,7 +4392,8 @@ static int _account_query_account_by_username_and_package(const char* username,
 
 CATCH:
        if (hstmt != NULL) {
-               _account_query_finalize(hstmt);
+               rc = _account_query_finalize(hstmt);
+               ACCOUNT_RETURN_VAL((rc == ACCOUNT_ERROR_NONE), {}, rc, ("finalize error"));
                hstmt = NULL;
        }
 
@@ -3603,6 +4413,35 @@ ACCOUNT_API int account_delete_from_db_by_user_name(char *user_name, char *packa
        int                     binding_count = 1;
        int                             account_id = -1;
 
+       int res;
+       int process_uid = getuid();
+       char subject_label[SMACK_LABEL_LEN + 1] = {0,};
+
+       if(process_uid != 0) {
+               int fd = open("/proc/self/attr/current", O_RDONLY);
+               if(fd < 0)
+               {
+                       ACCOUNT_ERROR("file open fail :: /proc/self/attr/current");
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+
+               res = read(fd, subject_label, SMACK_LABEL_LEN);
+               if(res < 0)
+               {
+                       ACCOUNT_ERROR("file read fail :: /proc/self/attr/current");
+                       close(fd);
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+
+               res = smack_have_access(subject_label, "libaccounts-svc::check_read", "r");
+               if(res != 1) {
+                       ACCOUNT_ERROR("Account permission denied :: This API can not be used without account.read privilege");
+                       close(fd);
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+               close(fd);
+       }
+
        ACCOUNT_RETURN_VAL((user_name != NULL), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("user_name is null!"));
        ACCOUNT_RETURN_VAL((package_name != NULL), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("package_name is null!"));
        ACCOUNT_RETURN_VAL((g_hAccountDB != NULL), {}, ACCOUNT_ERROR_DB_NOT_OPENED, ("The database isn't connected."));
@@ -3610,6 +4449,13 @@ ACCOUNT_API int account_delete_from_db_by_user_name(char *user_name, char *packa
        rc = account_create(&account);
        rc = _account_query_account_by_username_and_package(user_name, package_name, &account);
 
+
+       if( _account_db_err_code() == SQLITE_PERM ){
+               account_destroy(account);
+               ACCOUNT_ERROR( "Access failed(%s)", _account_db_err_msg());
+               return ACCOUNT_ERROR_PERMISSION_DENIED;
+       }
+
        rc = account_get_account_id(account, &account_id);
 
        rc = account_destroy(account);
@@ -3617,7 +4463,17 @@ ACCOUNT_API int account_delete_from_db_by_user_name(char *user_name, char *packa
        /* transaction control required*/
        ret_transaction = _account_begin_transaction();
 
-       if (ret_transaction != ACCOUNT_ERROR_NONE) {
+       if( _account_db_err_code() == SQLITE_PERM ){
+               ACCOUNT_ERROR( "Access failed(%s)", _account_db_err_msg());
+               pthread_mutex_unlock(&account_mutex);
+               return ACCOUNT_ERROR_PERMISSION_DENIED;
+       }
+
+       if( ret_transaction == ACCOUNT_ERROR_DATABASE_BUSY ){
+               ACCOUNT_ERROR( "database busy(%s)", _account_db_err_msg());
+               pthread_mutex_unlock(&account_mutex);
+               return ACCOUNT_ERROR_DATABASE_BUSY;
+       }else if (ret_transaction != ACCOUNT_ERROR_NONE) {
                ACCOUNT_ERROR("account_delete:_account_begin_transaction fail %d\n", ret_transaction);
                pthread_mutex_unlock(&account_mutex);
                return ret_transaction;
@@ -3629,6 +4485,13 @@ ACCOUNT_API int account_delete_from_db_by_user_name(char *user_name, char *packa
 
        hstmt = _account_prepare_query(query);
 
+       if( _account_db_err_code() == SQLITE_PERM ){
+               _account_end_transaction(FALSE);
+               pthread_mutex_unlock(&account_mutex);
+               ACCOUNT_ERROR( "Access failed(%s)", _account_db_err_msg());
+               return ACCOUNT_ERROR_PERMISSION_DENIED;
+       }
+
        ACCOUNT_CATCH_ERROR(hstmt != NULL, {}, ACCOUNT_ERROR_DB_FAILED,
                        ("_account_svc_query_prepare(%s) failed(%s).\n", query, _account_db_err_msg()));
 
@@ -3637,7 +4500,8 @@ ACCOUNT_API int account_delete_from_db_by_user_name(char *user_name, char *packa
        rc = _account_query_step(hstmt);
        ACCOUNT_CATCH_ERROR(rc == SQLITE_DONE, {}, ACCOUNT_ERROR_RECORD_NOT_FOUND, ("The record isn't found.\n"));
 
-       _account_query_finalize(hstmt);
+       rc = _account_query_finalize(hstmt);
+       ACCOUNT_RETURN_VAL((rc == ACCOUNT_ERROR_NONE), {}, rc, ("finalize error"));
        hstmt = NULL;
 
        /* delete capability */
@@ -3655,7 +4519,8 @@ ACCOUNT_API int account_delete_from_db_by_user_name(char *user_name, char *packa
        rc = _account_query_step(hstmt);
        ACCOUNT_CATCH_ERROR(rc == SQLITE_DONE, {}, ACCOUNT_ERROR_RECORD_NOT_FOUND, ("The record isn't found.\n"));
 
-       _account_query_finalize(hstmt);
+       rc = _account_query_finalize(hstmt);
+       ACCOUNT_RETURN_VAL((rc == ACCOUNT_ERROR_NONE), {}, rc, ("finalize error"));
        hstmt = NULL;
 
        ACCOUNT_MEMSET(query, 0, sizeof(query));
@@ -3673,14 +4538,16 @@ ACCOUNT_API int account_delete_from_db_by_user_name(char *user_name, char *packa
        rc = _account_query_step(hstmt);
        ACCOUNT_CATCH_ERROR(rc == SQLITE_DONE, {}, ACCOUNT_ERROR_RECORD_NOT_FOUND, ("The record isn't found. user_name=%s, package_name=%s, rc=%d\n", user_name, package_name, rc));
 
-       _account_query_finalize(hstmt);
+       rc = _account_query_finalize(hstmt);
+       ACCOUNT_RETURN_VAL((rc == ACCOUNT_ERROR_NONE), {}, rc, ("finalize error"));
        is_success = TRUE;
 
        hstmt = NULL;
 
 CATCH:
        if (hstmt != NULL) {
-               _account_query_finalize(hstmt);
+               rc = _account_query_finalize(hstmt);
+               ACCOUNT_RETURN_VAL((rc == ACCOUNT_ERROR_NONE), {}, rc, ("finalize error"));
                hstmt = NULL;
        }
 
@@ -3713,6 +4580,8 @@ static bool _account_delete_from_db_by_package_name_cb(account_h account, void *
 
        tmp_ptr = strdup(id_buf);
 
+       ACCOUNT_SLOGD("id = %s", id_buf);
+
        *account_id_list = g_slist_append(*account_id_list, tmp_ptr);
 
        return TRUE;
@@ -3728,16 +4597,65 @@ ACCOUNT_API int account_delete_from_db_by_package_name(const char *package_name)
        bool                    is_success = FALSE;
        int                     binding_count = 1;
        GSList                  *account_id_list = NULL;
+       int                             ret = -1;
+
+       int res;
+       int process_uid = getuid();
+       char subject_label[SMACK_LABEL_LEN + 1] = {0,};
+
+       if(process_uid != 0) {
+               int fd = open("/proc/self/attr/current", O_RDONLY);
+               if(fd < 0)
+               {
+                       ACCOUNT_ERROR("file open fail :: /proc/self/attr/current");
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+
+               res = read(fd, subject_label, SMACK_LABEL_LEN);
+               if(res < 0)
+               {
+                       ACCOUNT_ERROR("file read fail :: /proc/self/attr/current");
+                       close(fd);
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+
+               res = smack_have_access(subject_label, "libaccounts-svc::check_read", "r");
+               if(res != 1) {
+                       ACCOUNT_ERROR("Account permission denied :: This API can not be used without account.read privilege");
+                       close(fd);
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+               close(fd);
+       }
 
        ACCOUNT_RETURN_VAL((package_name != NULL), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("package_name is null!"));
        ACCOUNT_RETURN_VAL((g_hAccountDB != NULL), {}, ACCOUNT_ERROR_DB_NOT_OPENED, ("The database isn't connected."));
 
-       account_query_account_by_package_name(_account_delete_from_db_by_package_name_cb, package_name, (void*)&account_id_list);
+       ret = account_query_account_by_package_name(_account_delete_from_db_by_package_name_cb, package_name, (void*)&account_id_list);
+
+       if( _account_db_err_code() == SQLITE_PERM ){
+               ACCOUNT_ERROR( "Access failed(%s)", _account_db_err_msg());
+               return ACCOUNT_ERROR_PERMISSION_DENIED;
+       }
+
+       if(ret != ACCOUNT_ERROR_NONE){
+               return ret;
+       }
 
        /* transaction control required*/
        ret_transaction = _account_begin_transaction();
 
-       if (ret_transaction != ACCOUNT_ERROR_NONE) {
+       if( _account_db_err_code() == SQLITE_PERM ){
+               pthread_mutex_unlock(&account_mutex);
+               ACCOUNT_ERROR( "Access failed(%s)", _account_db_err_msg());
+               return ACCOUNT_ERROR_PERMISSION_DENIED;
+       }
+
+       if( ret_transaction == ACCOUNT_ERROR_DATABASE_BUSY ){
+               ACCOUNT_ERROR( "database busy(%s)", _account_db_err_msg());
+               pthread_mutex_unlock(&account_mutex);
+               return ACCOUNT_ERROR_DATABASE_BUSY;
+       }else if (ret_transaction != ACCOUNT_ERROR_NONE) {
                ACCOUNT_ERROR("account_delete:_account_begin_transaction fail %d\n", ret_transaction);
                pthread_mutex_unlock(&account_mutex);
                return ret_transaction;
@@ -3749,6 +4667,13 @@ ACCOUNT_API int account_delete_from_db_by_package_name(const char *package_name)
 
        hstmt = _account_prepare_query(query);
 
+       if( _account_db_err_code() == SQLITE_PERM ){
+               _account_end_transaction(FALSE);
+               pthread_mutex_unlock(&account_mutex);
+               ACCOUNT_ERROR( "Access failed(%s)", _account_db_err_msg());
+               return ACCOUNT_ERROR_PERMISSION_DENIED;
+       }
+
        ACCOUNT_CATCH_ERROR(hstmt != NULL, {}, ACCOUNT_ERROR_DB_FAILED,
                        ("_account_svc_query_prepare(%s) failed(%s).\n", query, _account_db_err_msg()));
 
@@ -3758,7 +4683,8 @@ ACCOUNT_API int account_delete_from_db_by_package_name(const char *package_name)
        rc = _account_query_step(hstmt);
        ACCOUNT_CATCH_ERROR(rc == SQLITE_DONE, {}, ACCOUNT_ERROR_RECORD_NOT_FOUND, ("The record isn't found.\n"));
 
-       _account_query_finalize(hstmt);
+       rc = _account_query_finalize(hstmt);
+       ACCOUNT_RETURN_VAL((rc == ACCOUNT_ERROR_NONE), {}, rc, ("finalize error"));
        hstmt = NULL;
 
        /* delete capability table */
@@ -3776,7 +4702,8 @@ ACCOUNT_API int account_delete_from_db_by_package_name(const char *package_name)
        rc = _account_query_step(hstmt);
        ACCOUNT_CATCH_ERROR(rc == SQLITE_DONE, {}, ACCOUNT_ERROR_RECORD_NOT_FOUND, ("The record isn't found.\n"));
 
-       _account_query_finalize(hstmt);
+       rc = _account_query_finalize(hstmt);
+       ACCOUNT_RETURN_VAL((rc == ACCOUNT_ERROR_NONE), {}, rc, ("finalize error"));
        hstmt = NULL;
 
        /* delete account table */
@@ -3794,31 +4721,33 @@ ACCOUNT_API int account_delete_from_db_by_package_name(const char *package_name)
        rc = _account_query_step(hstmt);
        ACCOUNT_CATCH_ERROR(rc == SQLITE_DONE, {}, ACCOUNT_ERROR_RECORD_NOT_FOUND, ("The record isn't found. package_name=%s, rc=%d\n", package_name, rc));
 
-       _account_query_finalize(hstmt);
+       rc = _account_query_finalize(hstmt);
+       ACCOUNT_RETURN_VAL((rc == ACCOUNT_ERROR_NONE), {}, rc, ("finalize error"));
        is_success = TRUE;
 
        hstmt = NULL;
 
 CATCH:
        if (hstmt != NULL) {
-               _account_query_finalize(hstmt);
+               rc = _account_query_finalize(hstmt);
+               ACCOUNT_RETURN_VAL((rc == ACCOUNT_ERROR_NONE), {}, rc, ("finalize error"));
                hstmt = NULL;
        }
 
        ret_transaction = _account_end_transaction(is_success);
 
        if (ret_transaction != ACCOUNT_ERROR_NONE) {
-               ACCOUNT_ERROR("account_svc_delete:_account_svc_end_transaction fail %d, is_success=%d\n", ret_transaction, is_success);
+               ACCOUNT_ERROR("account_delete:_account_end_transaction fail %d, is_success=%d\n", ret_transaction, is_success);
        } else {
                if (is_success == true) {
                        GSList* iter;
                        for (iter = account_id_list; iter != NULL; iter = g_slist_next(iter)) {
                                char* p_tmpid = NULL;
                                p_tmpid = (char*)iter->data;
-                       char buf[64]={0,};
+                               char buf[64]={0,};
                                ACCOUNT_SNPRINTF(buf, sizeof(buf), "%s:%s", ACCOUNT_NOTI_NAME_DELETE, p_tmpid);
-                               ACCOUNT_VERBOSE("%s", buf);
-                       _account_insert_delete_update_notification_send(buf);
+                               ACCOUNT_SLOGD("%s", buf);
+                               _account_insert_delete_update_notification_send(buf);
                                _ACCOUNT_FREE(p_tmpid);
                        }
                        g_slist_free(account_id_list);
@@ -3827,26 +4756,72 @@ CATCH:
 
        pthread_mutex_unlock(&account_mutex);
 
-       return error_code;
-}
+       return error_code;
+}
+
+ACCOUNT_API int account_get_total_count_from_db(int *count)
+{
+       int res;
+       int process_uid = getuid();
+       char subject_label[SMACK_LABEL_LEN + 1] = {0,};
+
+       if(process_uid != 0) {
+               int fd = open("/proc/self/attr/current", O_RDONLY);
+               if(fd < 0)
+               {
+                       ACCOUNT_ERROR("file open fail :: /proc/self/attr/current");
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+
+               res = read(fd, subject_label, SMACK_LABEL_LEN);
+               if(res < 0)
+               {
+                       ACCOUNT_ERROR("file read fail :: /proc/self/attr/current");
+                       close(fd);
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+
+               res = smack_have_access(subject_label, "libaccounts-svc::check_read", "r");
+               if(res != 1) {
+                       ACCOUNT_ERROR("Account permission denied :: This API can not be used without account.read privilege");
+                       close(fd);
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+               close(fd);
+       }
 
-ACCOUNT_API int account_get_total_count_from_db(int *count)
-{
        if (!count) {
-               ACCOUNT_ERROR("(%s)-(%d) count is NULL.\n", __FUNCTION__, __LINE__);
+               ACCOUNT_SLOGE("(%s)-(%d) count is NULL.\n", __FUNCTION__, __LINE__);
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
+
+       if(!g_hAccountDB){
+               ACCOUNT_ERROR("DB is not opened\n");
+               return ACCOUNT_ERROR_DB_NOT_OPENED;
+       }
+
        char query[1024] = {0, };
        ACCOUNT_MEMSET(query, 0x00, sizeof(query));
        ACCOUNT_SNPRINTF(query, sizeof(query), "select count(*) from %s", ACCOUNT_TABLE);
 
        *count = _account_get_record_count(query);
+
+       if( _account_db_err_code() == SQLITE_PERM ){
+               pthread_mutex_unlock(&account_mutex);
+               ACCOUNT_ERROR( "Access failed(%s)", _account_db_err_msg());
+               return ACCOUNT_ERROR_PERMISSION_DENIED;
+       }
+
        int rc = -1;
        int ncount = 0;
        account_stmt pStmt = NULL;
 
-       assert(NULL != g_hAccountDB);
        rc = sqlite3_prepare_v2(g_hAccountDB, query, strlen(query), &pStmt, NULL);
+       if (SQLITE_OK != rc) {
+               ACCOUNT_SLOGE("sqlite3_prepare_v2() failed(%d, %s).", rc, _account_db_err_msg());
+               sqlite3_finalize(pStmt);
+               return ACCOUNT_ERROR_DB_FAILED;
+       }
 
        rc = sqlite3_step(pStmt);
        if (SQLITE_ROW != rc) {
@@ -3859,7 +4834,6 @@ ACCOUNT_API int account_get_total_count_from_db(int *count)
 
        *count = ncount;
 
-       ACCOUNT_VERBOSE("Number of account : %d", ncount);
        sqlite3_finalize(pStmt);
 
        if (ncount < 0) {
@@ -3876,8 +4850,6 @@ ACCOUNT_API int account_destroy(account_h account)
 
        ACCOUNT_RETURN_VAL((data != NULL), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("Account handle is null!"));
 
-       ACCOUNT_INFO("destroy handle=%p\n", data);
-
        _account_free_account_items(data);
        _ACCOUNT_FREE(data);
 
@@ -3960,7 +4932,7 @@ static int _account_type_free_account_type_items(account_type_s *data)
 ACCOUNT_API int account_type_create(account_type_h *account_type)
 {
        if (!account_type) {
-               ACCOUNT_ERROR("(%s)-(%d) account type handle is NULL.\n", __FUNCTION__, __LINE__);
+               ACCOUNT_SLOGE("(%s)-(%d) account type handle is NULL.\n", __FUNCTION__, __LINE__);
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
 
@@ -3973,8 +4945,6 @@ ACCOUNT_API int account_type_create(account_type_h *account_type)
 
        ACCOUNT_MEMSET(data, 0, sizeof(account_type_s));
 
-       ACCOUNT_VERBOSE("create handle=%p\n", *account_type);
-
        *account_type = (account_type_h)data;
 
        return ACCOUNT_ERROR_NONE;
@@ -3986,8 +4956,6 @@ ACCOUNT_API int account_type_destroy(account_type_h account_type)
 
        ACCOUNT_RETURN_VAL((data != NULL), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("Account type handle is null!"));
 
-       ACCOUNT_VERBOSE("destroy handle=%p\n", data);
-
        _account_type_free_account_type_items(data);
        _ACCOUNT_FREE(data);
 
@@ -3998,12 +4966,12 @@ ACCOUNT_API int account_type_destroy(account_type_h account_type)
 ACCOUNT_API int account_type_set_app_id(account_type_h account_type, const char *app_id)
 {
        if (!account_type) {
-               ACCOUNT_ERROR("(%s)-(%d) account_type handle is NULL.\n", __FUNCTION__, __LINE__);
+               ACCOUNT_SLOGE("(%s)-(%d) account_type handle is NULL.\n", __FUNCTION__, __LINE__);
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
 
        if (!app_id) {
-               ACCOUNT_ERROR("(%s)-(%d) app_id is NULL.\n", __FUNCTION__, __LINE__);
+               ACCOUNT_SLOGE("(%s)-(%d) app_id is NULL.\n", __FUNCTION__, __LINE__);
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
 
@@ -4012,7 +4980,6 @@ ACCOUNT_API int account_type_set_app_id(account_type_h account_type, const char
        _ACCOUNT_FREE(data->app_id);
        data->app_id = _account_get_text(app_id);
 
-       ACCOUNT_VERBOSE("(%s)-(%d) %s, %s\n", __FUNCTION__, __LINE__ , data->app_id, app_id);
        return ACCOUNT_ERROR_NONE;
 }
 
@@ -4020,12 +4987,10 @@ ACCOUNT_API int account_type_set_app_id(account_type_h account_type, const char
 ACCOUNT_API int account_type_set_service_provider_id(account_type_h account_type, const char *service_provider_id)
 {
        if (!account_type) {
-               ACCOUNT_ERROR("(%s)-(%d) account_type handle is NULL.\n", __FUNCTION__, __LINE__);
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
 
        if (!service_provider_id) {
-               ACCOUNT_ERROR("(%s)-(%d) service_provider_id is NULL.\n", __FUNCTION__, __LINE__);
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
 
@@ -4034,19 +4999,16 @@ ACCOUNT_API int account_type_set_service_provider_id(account_type_h account_type
        _ACCOUNT_FREE(data->service_provider_id);
        data->service_provider_id = _account_get_text(service_provider_id);
 
-       ACCOUNT_VERBOSE("(%s)-(%d) %s, %s\n", __FUNCTION__, __LINE__ , data->service_provider_id, service_provider_id);
        return ACCOUNT_ERROR_NONE;
 }
 
 ACCOUNT_API int account_type_set_icon_path(account_type_h account_type, const char *icon_path)
 {
        if (!account_type) {
-               ACCOUNT_ERROR("(%s)-(%d) account_type handle is NULL.\n", __FUNCTION__, __LINE__);
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
 
        if (!icon_path) {
-               ACCOUNT_ERROR("(%s)-(%d) icon_path is NULL.\n", __FUNCTION__, __LINE__);
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
 
@@ -4055,19 +5017,16 @@ ACCOUNT_API int account_type_set_icon_path(account_type_h account_type, const ch
        _ACCOUNT_FREE(data->icon_path);
        data->icon_path = _account_get_text(icon_path);
 
-       ACCOUNT_VERBOSE("(%s)-(%d) %s, %s\n", __FUNCTION__, __LINE__ , data->icon_path, icon_path);
        return ACCOUNT_ERROR_NONE;
 }
 
 ACCOUNT_API int account_type_set_small_icon_path(account_type_h account_type, const char *small_icon_path)
 {
        if (!account_type) {
-               ACCOUNT_ERROR("(%s)-(%d) account_type handle is NULL.\n", __FUNCTION__, __LINE__);
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
 
        if (!small_icon_path) {
-               ACCOUNT_ERROR("(%s)-(%d) small_icon_path is NULL.\n", __FUNCTION__, __LINE__);
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
 
@@ -4076,7 +5035,6 @@ ACCOUNT_API int account_type_set_small_icon_path(account_type_h account_type, co
        _ACCOUNT_FREE(data->small_icon_path);
        data->small_icon_path = _account_get_text(small_icon_path);
 
-       ACCOUNT_VERBOSE("(%s)-(%d) %s, %s\n", __FUNCTION__, __LINE__ , data->small_icon_path, small_icon_path);
        return ACCOUNT_ERROR_NONE;
 }
 
@@ -4095,12 +5053,11 @@ ACCOUNT_API int account_type_set_multiple_account_support(account_type_h account
 ACCOUNT_API int account_type_set_label(account_type_h account_type, const char* label, const char* locale)
 {
        if (!account_type) {
-               ACCOUNT_ERROR("(%s)-(%d) account_type handle is NULL.\n", __FUNCTION__, __LINE__);
+               ACCOUNT_SLOGE("(%s)-(%d) account_type handle is NULL.\n", __FUNCTION__, __LINE__);
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
 
        if(!label || !locale) {
-               ACCOUNT_ERROR("(%s)-(%d) label(%p) or locale(%p) is NULL.\n", __FUNCTION__, __LINE__, label, locale);
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
 
@@ -4108,7 +5065,6 @@ ACCOUNT_API int account_type_set_label(account_type_h account_type, const char*
        label_s *label_data = (label_s*)malloc(sizeof(label_s));
 
        if (label_data == NULL) {
-               ACCOUNT_FATAL("(%s)-(%d) Malloc fail. label_data is NULL.\n", __FUNCTION__, __LINE__);
                return ACCOUNT_ERROR_OUT_OF_MEMORY;
        }
        ACCOUNT_MEMSET(label_data, 0, sizeof(label_s));
@@ -4124,12 +5080,10 @@ ACCOUNT_API int account_type_set_label(account_type_h account_type, const char*
 ACCOUNT_API int account_type_get_app_id(account_type_h account_type, char **app_id)
 {
        if (!account_type) {
-               ACCOUNT_ERROR("(%s)-(%d) account type handle is NULL.\n", __FUNCTION__, __LINE__);
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
 
        if (!app_id) {
-               ACCOUNT_ERROR("(%s)-(%d) app id is NULL.\n", __FUNCTION__, __LINE__);
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
 
@@ -4144,12 +5098,10 @@ ACCOUNT_API int account_type_get_app_id(account_type_h account_type, char **app_
 ACCOUNT_API int account_type_get_service_provider_id(account_type_h account_type, char **service_provider_id)
 {
        if (!account_type) {
-               ACCOUNT_ERROR("(%s)-(%d) account type handle is NULL.\n", __FUNCTION__, __LINE__);
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
 
        if (!service_provider_id) {
-               ACCOUNT_ERROR("(%s)-(%d) service provider id is NULL.\n", __FUNCTION__, __LINE__);
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
 
@@ -4164,12 +5116,10 @@ ACCOUNT_API int account_type_get_service_provider_id(account_type_h account_type
 ACCOUNT_API int account_type_get_icon_path(account_type_h account_type, char **icon_path)
 {
        if (!account_type) {
-               ACCOUNT_ERROR("(%s)-(%d) account type handle is NULL.\n", __FUNCTION__, __LINE__);
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
 
        if (!icon_path) {
-               ACCOUNT_ERROR("(%s)-(%d) icon path is NULL.\n", __FUNCTION__, __LINE__);
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
 
@@ -4184,12 +5134,10 @@ ACCOUNT_API int account_type_get_icon_path(account_type_h account_type, char **i
 ACCOUNT_API int account_type_get_small_icon_path(account_type_h account_type, char **small_icon_path)
 {
        if (!account_type) {
-               ACCOUNT_ERROR("(%s)-(%d) account type handle is NULL.\n", __FUNCTION__, __LINE__);
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
 
        if (!small_icon_path) {
-               ACCOUNT_ERROR("(%s)-(%d) icon path is NULL.\n", __FUNCTION__, __LINE__);
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
 
@@ -4204,11 +5152,9 @@ ACCOUNT_API int account_type_get_small_icon_path(account_type_h account_type, ch
 ACCOUNT_API int account_type_get_multiple_account_support(account_type_h account_type, int *multiple_account_support)
 {
        if (!account_type) {
-               ACCOUNT_ERROR("(%s)-(%d) account_type handle is NULL.\n", __FUNCTION__, __LINE__);
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
        if (!multiple_account_support) {
-               ACCOUNT_ERROR("(%s)-(%d) multiple_account_support is NULL.\n", __FUNCTION__, __LINE__);
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
 
@@ -4232,23 +5178,40 @@ ACCOUNT_API int account_type_get_label_by_locale(account_type_h account_type, co
 
                label_data = (label_s*)iter->data;
 
-               ACCOUNT_VERBOSE("account_type_get_label :: app_id=%s, label=%s, locale=%s", label_data->app_id, label_data->label, label_data->locale);
-
                *label = NULL;
 
                if(!strcmp(locale, label_data->locale)) {
                        *label = _account_get_text(label_data->label);
                        return ACCOUNT_ERROR_NONE;
                }
+               gchar** tokens = g_strsplit(locale, "-", 2);
+               if(tokens != NULL) {
+            if((char*)(tokens[1]) != NULL) {
+                char* upper_token = g_ascii_strup(tokens[1], strlen(tokens[1]));
+                if(upper_token != NULL) {
+                                       char* converted_locale = g_strdup_printf("%s_%s", tokens[0], upper_token);
+                                       if(!strcmp(converted_locale, label_data->locale)) {
+                                               _ACCOUNT_FREE(converted_locale);
+                                               _ACCOUNT_FREE(upper_token);
+                                               g_strfreev(tokens);
+                                               *label = _account_get_text(label_data->label);
+                                               return ACCOUNT_ERROR_NONE;
+                                       }
+                                       _ACCOUNT_FREE(converted_locale);
+                               }
+                               _ACCOUNT_FREE(upper_token);
+                       }
+               }
+               g_strfreev(tokens);
        }
 
        return ACCOUNT_ERROR_RECORD_NOT_FOUND;
 }
 
-ACCOUNT_API int account_type_get_label(account_type_h account_type, account_label_cb cb_func, void *user_data)
+ACCOUNT_API int account_type_get_label(account_type_h account_type, account_label_cb callback, void *user_data)
 {
        ACCOUNT_RETURN_VAL((account_type != NULL), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("ACCOUNT HANDLE IS NULL"));
-       ACCOUNT_RETURN_VAL((cb_func != NULL), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("NO CALLBACK FUNCTION"));
+       ACCOUNT_RETURN_VAL((callback != NULL), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("NO CALLBACK FUNCTION"));
 
        GSList *iter;
        account_type_s *data = (account_type_s*)account_type;
@@ -4258,10 +5221,7 @@ ACCOUNT_API int account_type_get_label(account_type_h account_type, account_labe
 
                label_data = (label_s*)iter->data;
 
-               ACCOUNT_VERBOSE("account_type_get_label :: app_id=%s, label=%s, locale=%s", label_data->app_id, label_data->label, label_data->locale);
-
-               //cb_func(label_data->app_id, label_data->label, label_data->locale, user_data);
-               if(cb_func(label_data->app_id, label_data->label, label_data->locale, user_data)!=TRUE) {
+               if(callback(label_data->app_id, label_data->label, label_data->locale, user_data)!=TRUE) {
                        ACCOUNT_DEBUG("Callback func returs FALSE, its iteration is stopped!!!!\n");
                        return ACCOUNT_ERROR_NONE;
                }
@@ -4282,8 +5242,6 @@ static gboolean _account_type_check_duplicated(account_type_s *data)
 
        count = _account_get_record_count(query);
        if (count > 0) {
-               ACCOUNT_VERBOSE("_account_type_check_duplicated : duplicated %d account type(s) exist!, app_id=%s, service_provider_id=%s\n",
-                       count, data->app_id, data->service_provider_id);
                return TRUE;
        }
 
@@ -4325,7 +5283,6 @@ static int _account_type_execute_insert_query(account_type_s *account_type)
        /* check mandatory field */
        // app id & service provider id
        if (!account_type->app_id) {
-               ACCOUNT_ERROR("App id is mandetory field, it can not be NULL!!!!\n");
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
 
@@ -4334,17 +5291,30 @@ static int _account_type_execute_insert_query(account_type_s *account_type)
                        "(?, ?, ?, ?, ?)",      ACCOUNT_TYPE_TABLE);
 
        hstmt = _account_prepare_query(query);
+
+       if( _account_db_err_code() == SQLITE_PERM ){
+               ACCOUNT_ERROR( "Access failed(%s)", _account_db_err_msg());
+               return ACCOUNT_ERROR_PERMISSION_DENIED;
+       } else if( _account_db_err_code() == SQLITE_BUSY ){
+               ACCOUNT_ERROR( "Database Busy(%s)", _account_db_err_msg());
+               return ACCOUNT_ERROR_DATABASE_BUSY;
+       }
+
        ACCOUNT_RETURN_VAL((hstmt != NULL), {}, ACCOUNT_ERROR_DB_FAILED, ("_account_prepare_query() failed(%s).\n", _account_db_err_msg()));
 
        _account_type_convert_account_to_sql(account_type, hstmt, query);
 
        rc = _account_query_step(hstmt);
-       if (rc != SQLITE_DONE) {
-               ACCOUNT_FATAL( "account_db_query_step() failed(%d, %s)", rc, _account_db_err_msg());
+       if (rc == SQLITE_BUSY) {
+               ACCOUNT_ERROR( "account_db_query_step() failed(%d, %s)", rc, _account_db_err_msg());
+               error_code = ACCOUNT_ERROR_DATABASE_BUSY;
+       } else if (rc != SQLITE_DONE) {
+               ACCOUNT_ERROR( "account_db_query_step() failed(%d, %s)", rc, _account_db_err_msg());
                error_code = ACCOUNT_ERROR_DB_FAILED;
        }
 
-       _account_query_finalize(hstmt);
+       rc = _account_query_finalize(hstmt);
+       ACCOUNT_RETURN_VAL((rc == ACCOUNT_ERROR_NONE), {}, rc, ("finalize error"));
        hstmt = NULL;
 
        return error_code;
@@ -4367,8 +5337,12 @@ static int _account_type_insert_label(account_type_s *account_type)
 
        rc = _account_get_record_count(query);
 
+       if( _account_db_err_code() == SQLITE_PERM ){
+               ACCOUNT_ERROR( "Access failed(%s)", _account_db_err_msg());
+               return ACCOUNT_ERROR_PERMISSION_DENIED;
+       }
+
        if (rc <= 0) {
-               ACCOUNT_ERROR( "_account_insert_label : related account item is not existed rc=%d , %s", rc, _account_db_err_msg());
                return ACCOUNT_ERROR_RECORD_NOT_FOUND;
        }
 
@@ -4376,7 +5350,7 @@ static int _account_type_insert_label(account_type_s *account_type)
        GSList *iter;
 
        for (iter = account_type->label_list; iter != NULL; iter = g_slist_next(iter)) {
-               int rc, ret;
+               int ret;
                count = 1;
                ACCOUNT_MEMSET(query, 0x00, sizeof(query));
                ACCOUNT_SNPRINTF(query, sizeof(query), "INSERT INTO %s(AppId, Label, Locale) VALUES "
@@ -4388,7 +5362,6 @@ static int _account_type_insert_label(account_type_s *account_type)
 
                label_s* label_data = NULL;
                label_data = (label_s*)iter->data;
-               ACCOUNT_VERBOSE( "label_data->appid = %s, label_data->label = %s, label_data->locale \n", label_data->app_id, label_data->label, label_data->locale);
 
                ret = _account_query_bind_text(hstmt, count++, account_type->app_id);
                ACCOUNT_RETURN_VAL((ret == ACCOUNT_ERROR_NONE), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("Text binding fail"));
@@ -4400,23 +5373,22 @@ static int _account_type_insert_label(account_type_s *account_type)
                rc = _account_query_step(hstmt);
 
                if (rc != SQLITE_DONE) {
-                       ACCOUNT_FATAL( "_account_query_step() failed(%d, %s)", rc, _account_db_err_msg());
+                       ACCOUNT_ERROR( "_account_query_step() failed(%d, %s)", rc, _account_db_err_msg());
                        break;
                }
 
-               _account_query_finalize(hstmt);
+               rc = _account_query_finalize(hstmt);
+               ACCOUNT_RETURN_VAL((rc == ACCOUNT_ERROR_NONE), {}, rc, ("finalize error"));
                hstmt = NULL;
 
        }
 
-       ACCOUNT_VERBOSE( "_account_type_insert_label() DONE\n");
-
        return ACCOUNT_ERROR_NONE;
 }
 
 static void _account_type_convert_column_to_provider_feature(account_stmt hstmt, provider_feature_s *feature_record)
 {
-       char *textbuf = NULL;
+       const char *textbuf = NULL;
 
        textbuf = _account_query_table_column_text(hstmt, PROVIDER_FEATURE_FIELD_APP_ID);
        _account_db_data_to_text(textbuf, &(feature_record->app_id));
@@ -4424,27 +5396,58 @@ static void _account_type_convert_column_to_provider_feature(account_stmt hstmt,
        textbuf = _account_query_table_column_text(hstmt, PROVIDER_FEATURE_FIELD_KEY);
        _account_db_data_to_text(textbuf, &(feature_record->key));
 
-       ACCOUNT_VERBOSE("END _account_type_convert_column_to_provider_feature");
 }
 
-ACCOUNT_API int account_type_query_provider_feature_by_app_id(provider_feature_cb cb_func, const char* app_id, void *user_data )
+ACCOUNT_API int account_type_query_provider_feature_by_app_id(provider_feature_cb callback, const char* app_id, void *user_data )
 {
        int                     error_code = ACCOUNT_ERROR_NONE;
        account_stmt    hstmt = NULL;
        char                    query[ACCOUNT_SQL_LEN_MAX] = {0, };
        int                     rc = 0, binding_count = 1;
 
+       int res;
+       int process_uid = getuid();
+       char subject_label[SMACK_LABEL_LEN + 1] = {0,};
+
+       if(process_uid != 0) {
+               int fd = open("/proc/self/attr/current", O_RDONLY);
+               if(fd < 0)
+               {
+                       ACCOUNT_ERROR("file open fail :: /proc/self/attr/current");
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+
+               res = read(fd, subject_label, SMACK_LABEL_LEN);
+               if(res < 0)
+               {
+                       ACCOUNT_ERROR("file read fail :: /proc/self/attr/current");
+                       close(fd);
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+
+               res = smack_have_access(subject_label, "libaccounts-svc::check_read", "r");
+               if(res != 1) {
+                       ACCOUNT_ERROR("Account permission denied :: This API can not be used without account.read privilege");
+                       close(fd);
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+               close(fd);
+       }
+
        ACCOUNT_RETURN_VAL((app_id != NULL), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("APP ID IS NULL"));
-       ACCOUNT_RETURN_VAL((cb_func != NULL), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("NO CALLBACK FUNCTION"));
+       ACCOUNT_RETURN_VAL((callback != NULL), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("NO CALLBACK FUNCTION"));
        ACCOUNT_RETURN_VAL((g_hAccountDB != NULL), {}, ACCOUNT_ERROR_DB_NOT_OPENED, ("The database isn't connected."));
 
-       ACCOUNT_VERBOSE("app_id = %s", app_id);
-
        ACCOUNT_MEMSET(query, 0x00, ACCOUNT_SQL_LEN_MAX);
 
        ACCOUNT_SNPRINTF(query, sizeof(query), "SELECT * FROM %s WHERE app_id = ?", PROVIDER_FEATURE_TABLE);
        hstmt = _account_prepare_query(query);
 
+       if( _account_db_err_code() == SQLITE_PERM ){
+               ACCOUNT_ERROR( "Access failed(%s)", _account_db_err_msg());
+               return ACCOUNT_ERROR_PERMISSION_DENIED;
+       }
+
        _account_query_bind_text(hstmt, binding_count++, app_id);
 
        rc = _account_query_step(hstmt);
@@ -4465,7 +5468,7 @@ ACCOUNT_API int account_type_query_provider_feature_by_app_id(provider_feature_c
 
                _account_type_convert_column_to_provider_feature(hstmt, feature_record);
 
-               cb_ret = cb_func(feature_record->app_id, feature_record->key, user_data);
+               cb_ret = callback(feature_record->app_id, feature_record->key, user_data);
 
                _account_type_free_feature_items(feature_record);
                _ACCOUNT_FREE(feature_record);
@@ -4475,14 +5478,16 @@ ACCOUNT_API int account_type_query_provider_feature_by_app_id(provider_feature_c
                rc = _account_query_step(hstmt);
        }
 
-       _account_query_finalize(hstmt);
+       rc = _account_query_finalize(hstmt);
+       ACCOUNT_RETURN_VAL((rc == ACCOUNT_ERROR_NONE), {}, rc, ("finalize error"));
        hstmt = NULL;
 
        error_code = ACCOUNT_ERROR_NONE;
 
 CATCH:
        if (hstmt != NULL) {
-               _account_query_finalize(hstmt);
+               rc = _account_query_finalize(hstmt);
+               ACCOUNT_RETURN_VAL((rc == ACCOUNT_ERROR_NONE), {}, rc, ("finalize error"));
                hstmt = NULL;
        }
 
@@ -4495,27 +5500,65 @@ ACCOUNT_API bool account_type_query_supported_feature(const char* app_id, const
        char                    query[ACCOUNT_SQL_LEN_MAX] = {0, };
        int                     record_count = 0;
 
-       ACCOUNT_RETURN_VAL((app_id != NULL), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("APP ID IS NULL"));
-       ACCOUNT_RETURN_VAL((capability != NULL), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("NO CAPABILITY"));
+       int res;
+       int process_uid = getuid();
+       char subject_label[SMACK_LABEL_LEN + 1] = {0,};
+
+       if(process_uid != 0) {
+               int fd = open("/proc/self/attr/current", O_RDONLY);
+               if(fd < 0)
+               {
+                       ACCOUNT_ERROR("file open fail :: /proc/self/attr/current");
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+
+               res = read(fd, subject_label, SMACK_LABEL_LEN);
+               if(res < 0)
+               {
+                       ACCOUNT_ERROR("file read fail :: /proc/self/attr/current");
+                       close(fd);
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+
+               res = smack_have_access(subject_label, "libaccounts-svc::check_read", "r");
+               if(res != 1) {
+                       ACCOUNT_ERROR("Account permission denied :: This API can not be used without account.read privilege");
+                       close(fd);
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+               close(fd);
+       }
+
+       if (app_id == NULL || capability == NULL) {
+               set_last_result(ACCOUNT_ERROR_INVALID_PARAMETER);
+               return ACCOUNT_ERROR_INVALID_PARAMETER;
+       }
 
        ACCOUNT_SNPRINTF(query, sizeof(query), "SELECT COUNT(*) FROM %s where app_id='%s' and key='%s'", PROVIDER_FEATURE_TABLE, app_id, capability);
 
        record_count = _account_get_record_count(query);
 
+       if( _account_db_err_code() == SQLITE_PERM ){
+               ACCOUNT_ERROR( "Access failed(%s)", _account_db_err_msg());
+               set_last_result(ACCOUNT_ERROR_PERMISSION_DENIED);
+               return ACCOUNT_ERROR_PERMISSION_DENIED;
+       }
+
        if (record_count <= 0) {
-               ACCOUNT_WARNING( "related capability type item is not existed rc=%d , %s", record_count, _account_db_err_msg());
+               set_last_result(ACCOUNT_ERROR_RECORD_NOT_FOUND);
                return FALSE;
        }
 
+       set_last_result(ACCOUNT_ERROR_NONE);
        return TRUE;
 
 }
 
 
-ACCOUNT_API int account_type_get_provider_feature_all(account_type_h account_type, provider_feature_cb cb_func, void* user_data)
+ACCOUNT_API int account_type_get_provider_feature_all(account_type_h account_type, provider_feature_cb callback, void* user_data)
 {
        ACCOUNT_RETURN_VAL((account_type != NULL), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("ACCOUNT HANDLE IS NULL"));
-       ACCOUNT_RETURN_VAL((cb_func != NULL), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("NO CALLBACK FUNCTION"));
+       ACCOUNT_RETURN_VAL((callback != NULL), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("NO CALLBACK FUNCTION"));
 
        GSList *iter;
        account_type_s *data = (account_type_s*)account_type;
@@ -4525,10 +5568,7 @@ ACCOUNT_API int account_type_get_provider_feature_all(account_type_h account_typ
 
                feature_data = (provider_feature_s*)iter->data;
 
-               ACCOUNT_VERBOSE("appid = %s, key = %s", feature_data->key, feature_data->app_id);
-
-               //cb_func(feature_data->app_id, feature_data->key, user_data);
-               if(cb_func(feature_data->app_id, feature_data->key, user_data)!=TRUE) {
+               if(callback(feature_data->app_id, feature_data->key, user_data)!=TRUE) {
                        ACCOUNT_DEBUG("Callback func returs FALSE, its iteration is stopped!!!!\n");
                        return ACCOUNT_ERROR_NONE;
                }
@@ -4589,8 +5629,13 @@ static int _account_type_insert_provider_feature(account_type_s *account_type, c
 
        rc = _account_get_record_count(query);
 
+       if( _account_db_err_code() == SQLITE_PERM ){
+               ACCOUNT_ERROR( "Access failed(%s)", _account_db_err_msg());
+               return ACCOUNT_ERROR_PERMISSION_DENIED;
+       }
+
        if (rc <= 0) {
-               ACCOUNT_WARNING( "related account type item is not existed rc=%d , %s", rc, _account_db_err_msg());
+               ACCOUNT_SLOGI( "related account type item is not existed rc=%d , %s", rc, _account_db_err_msg());
                return ACCOUNT_ERROR_RECORD_NOT_FOUND;
        }
 
@@ -4599,7 +5644,7 @@ static int _account_type_insert_provider_feature(account_type_s *account_type, c
        GSList *iter;
 
        for (iter = account_type->provider_feature_list; iter != NULL; iter = g_slist_next(iter)) {
-               int rc, ret;
+               int ret;
                count = 1;
                ACCOUNT_MEMSET(query, 0x00, sizeof(query));
                ACCOUNT_SNPRINTF(query, sizeof(query), "INSERT INTO %s(app_id, key) VALUES "
@@ -4611,7 +5656,6 @@ static int _account_type_insert_provider_feature(account_type_s *account_type, c
 
                provider_feature_s* feature_data = NULL;
                feature_data = (provider_feature_s*)iter->data;
-               ACCOUNT_VERBOSE("key = %s, app_id = %s \n", feature_data->key, app_id);
 
                ret = _account_query_bind_text(hstmt, count++, app_id);
                ACCOUNT_RETURN_VAL((ret == ACCOUNT_ERROR_NONE), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("Text binding fail"));
@@ -4621,17 +5665,16 @@ static int _account_type_insert_provider_feature(account_type_s *account_type, c
                rc = _account_query_step(hstmt);
 
                if (rc != SQLITE_DONE) {
-                       ACCOUNT_FATAL( "_account_query_step() failed(%d, %s)", rc, _account_db_err_msg());
+                       ACCOUNT_ERROR( "_account_query_step() failed(%d, %s)", rc, _account_db_err_msg());
                        break;
                }
 
-               _account_query_finalize(hstmt);
+               rc = _account_query_finalize(hstmt);
+               ACCOUNT_RETURN_VAL((rc == ACCOUNT_ERROR_NONE), {}, rc, ("finalize error"));
                hstmt = NULL;
 
        }
 
-       ACCOUNT_VERBOSE( "_account_type_insert_provider_feature() DONE\n");
-
        return ACCOUNT_ERROR_NONE;
 }
 
@@ -4639,6 +5682,35 @@ ACCOUNT_API int account_type_insert_to_db(account_type_h account_type, int* acco
 {
        int             error_code = ACCOUNT_ERROR_NONE, ret_transaction = 0;
 
+       int res;
+       int process_uid = getuid();
+       char subject_label[SMACK_LABEL_LEN + 1] = {0,};
+
+       if(process_uid != 0) {
+               int fd = open("/proc/self/attr/current", O_RDONLY);
+               if(fd < 0)
+               {
+                       ACCOUNT_ERROR("file open fail :: /proc/self/attr/current");
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+
+               res = read(fd, subject_label, SMACK_LABEL_LEN);
+               if(res < 0)
+               {
+                       ACCOUNT_ERROR("file read fail :: /proc/self/attr/current");
+                       close(fd);
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+
+               res = smack_have_access(subject_label, "libaccounts-svc::check_read", "r");
+               if(res != 1) {
+                       ACCOUNT_ERROR("Account permission denied :: This API can not be used without account.read privilege");
+                       close(fd);
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+               close(fd);
+       }
+
        ACCOUNT_RETURN_VAL((g_hAccountDB != NULL), {}, ACCOUNT_ERROR_DB_NOT_OPENED, ("The database isn't connected."));
        ACCOUNT_RETURN_VAL((account_type != NULL), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("ACCOUNT TYPE HANDLE IS NULL"));
        ACCOUNT_RETURN_VAL((account_type_id != NULL), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("ACCOUNT TYPE ID POINTER IS NULL"));
@@ -4651,7 +5723,17 @@ ACCOUNT_API int account_type_insert_to_db(account_type_h account_type, int* acco
        /* transaction control required*/
        ret_transaction = _account_begin_transaction();
 
-       if (ret_transaction != ACCOUNT_ERROR_NONE) {
+       if( _account_db_err_code() == SQLITE_PERM ){
+               pthread_mutex_unlock(&account_mutex);
+               ACCOUNT_ERROR( "Access failed(%s)", _account_db_err_msg());
+               return ACCOUNT_ERROR_PERMISSION_DENIED;
+       }
+
+       if( ret_transaction == ACCOUNT_ERROR_DATABASE_BUSY ){
+               ACCOUNT_ERROR( "database busy(%s)", _account_db_err_msg());
+               pthread_mutex_unlock(&account_mutex);
+               return ACCOUNT_ERROR_DATABASE_BUSY;
+       } else if (ret_transaction != ACCOUNT_ERROR_NONE) {
                ACCOUNT_ERROR("_account_begin_transaction fail %d\n", ret_transaction);
                pthread_mutex_unlock(&account_mutex);
                return ret_transaction;
@@ -4678,8 +5760,6 @@ ACCOUNT_API int account_type_insert_to_db(account_type_h account_type, int* acco
                }
        }
 
-       ACCOUNT_INFO( "_account_type_execute_insert_query, insert error_code : %d", error_code);
-
        error_code = _account_type_insert_provider_feature(data, data->app_id);
        if(error_code != ACCOUNT_ERROR_NONE) {
                ret_transaction = _account_end_transaction(FALSE);
@@ -4696,7 +5776,6 @@ ACCOUNT_API int account_type_insert_to_db(account_type_h account_type, int* acco
        }
 
        ret_transaction = _account_end_transaction(TRUE);
-       ACCOUNT_DEBUG("Insert success(%x), commit insert query(%x)!!!!\n", error_code, ret_transaction);
 
        pthread_mutex_unlock(&account_mutex);
 
@@ -4722,21 +5801,28 @@ static int _account_type_update_provider_feature(account_type_s *account_type, c
 
        ACCOUNT_SNPRINTF(query, sizeof(query), "DELETE FROM %s WHERE app_id=? ", PROVIDER_FEATURE_TABLE);
        hstmt = _account_prepare_query(query);
+
+       if( _account_db_err_code() == SQLITE_PERM ){
+               ACCOUNT_ERROR( "Access failed(%s)", _account_db_err_msg());
+               return ACCOUNT_ERROR_PERMISSION_DENIED;
+       }
+
        count = 1;
        _account_query_bind_text(hstmt, count++, app_id);
        rc = _account_query_step(hstmt);
 
        if (rc != SQLITE_DONE) {
-               ACCOUNT_FATAL( "_account_query_step() failed(%d, %s)", rc, _account_db_err_msg());
+               ACCOUNT_ERROR( "_account_query_step() failed(%d, %s)", rc, _account_db_err_msg());
                return ACCOUNT_ERROR_DB_FAILED;
        }
-       _account_query_finalize(hstmt);
+       rc = _account_query_finalize(hstmt);
+       ACCOUNT_RETURN_VAL((rc == ACCOUNT_ERROR_NONE), {}, rc, ("finalize error"));
        hstmt = NULL;
 
        GSList *iter;
 
        for (iter = account_type->provider_feature_list; iter != NULL; iter = g_slist_next(iter)) {
-               int rc, ret;
+               int ret;
                count = 1;
                ACCOUNT_MEMSET(query, 0x00, sizeof(query));
                ACCOUNT_SNPRINTF(query, sizeof(query), "INSERT INTO %s(app_id, key) VALUES "
@@ -4757,15 +5843,14 @@ static int _account_type_update_provider_feature(account_type_s *account_type, c
                rc = _account_query_step(hstmt);
 
                if (rc != SQLITE_DONE) {
-                       ACCOUNT_FATAL( "_account_query_step() failed(%d, %s)", rc, _account_db_err_msg());
+                       ACCOUNT_ERROR( "_account_query_step() failed(%d, %s)", rc, _account_db_err_msg());
                        break;
                }
-               _account_query_finalize(hstmt);
+               rc = _account_query_finalize(hstmt);
+               ACCOUNT_RETURN_VAL((rc == ACCOUNT_ERROR_NONE), {}, rc, ("finalize error"));
                hstmt = NULL;
        }
 
-       ACCOUNT_VERBOSE( "_account_type_update_label() DONE\n");
-
        return ACCOUNT_ERROR_NONE;
 }
 
@@ -4778,7 +5863,6 @@ static int _account_type_update_label(account_type_s *account_type, const char*
        ACCOUNT_RETURN_VAL((account_type != NULL), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("ACCOUNT HANDLE IS NULL"));
 
        if (g_slist_length( account_type->label_list)==0) {
-               ACCOUNT_ERROR( "_account_type_update_label, no label\n");
                return ACCOUNT_ERROR_NONE;
        }
 
@@ -4786,21 +5870,28 @@ static int _account_type_update_label(account_type_s *account_type, const char*
 
        ACCOUNT_SNPRINTF(query, sizeof(query), "DELETE FROM %s WHERE AppId=? ", LABEL_TABLE);
        hstmt = _account_prepare_query(query);
+
+       if( _account_db_err_code() == SQLITE_PERM ){
+               ACCOUNT_ERROR( "Access failed(%s)", _account_db_err_msg());
+               return ACCOUNT_ERROR_PERMISSION_DENIED;
+       }
+
        count = 1;
        _account_query_bind_text(hstmt, count++, app_id);
        rc = _account_query_step(hstmt);
 
        if (rc != SQLITE_DONE) {
-               ACCOUNT_FATAL( "_account_query_step() failed(%d, %s)", rc, _account_db_err_msg());
+               ACCOUNT_ERROR( "_account_query_step() failed(%d, %s)", rc, _account_db_err_msg());
                return ACCOUNT_ERROR_DB_FAILED;
        }
-       _account_query_finalize(hstmt);
+       rc = _account_query_finalize(hstmt);
+       ACCOUNT_RETURN_VAL((rc == ACCOUNT_ERROR_NONE), {}, rc, ("finalize error"));
        hstmt = NULL;
 
        GSList *iter;
 
        for (iter = account_type->label_list; iter != NULL; iter = g_slist_next(iter)) {
-               int rc, ret;
+               int ret;
                count = 1;
                ACCOUNT_MEMSET(query, 0x00, sizeof(query));
                ACCOUNT_SNPRINTF(query, sizeof(query), "INSERT INTO %s(AppId, Label, Locale) VALUES "
@@ -4823,15 +5914,14 @@ static int _account_type_update_label(account_type_s *account_type, const char*
                rc = _account_query_step(hstmt);
 
                if (rc != SQLITE_DONE) {
-                       ACCOUNT_FATAL( "_account_query_step() failed(%d, %s)", rc, _account_db_err_msg());
+                       ACCOUNT_ERROR( "_account_query_step() failed(%d, %s)", rc, _account_db_err_msg());
                        break;
                }
-               _account_query_finalize(hstmt);
+               rc = _account_query_finalize(hstmt);
+               ACCOUNT_RETURN_VAL((rc == ACCOUNT_ERROR_NONE), {}, rc, ("finalize error"));
                hstmt = NULL;
        }
 
-       ACCOUNT_VERBOSE( "_account_type_update_label() DONE\n");
-
        return ACCOUNT_ERROR_NONE;
 }
 
@@ -4853,6 +5943,15 @@ static int _account_type_update_account(account_type_s *account_type, const char
                        "SmallIconPath=?, MultipleAccountSupport=? WHERE AppId=? ", ACCOUNT_TYPE_TABLE);
 
        hstmt = _account_prepare_query(query);
+
+       if( _account_db_err_code() == SQLITE_PERM ){
+               ACCOUNT_ERROR( "Access failed(%s)", _account_db_err_msg());
+               return ACCOUNT_ERROR_PERMISSION_DENIED;
+       } else if (_account_db_err_code() == SQLITE_BUSY){
+               ACCOUNT_ERROR( "database busy(%s)", _account_db_err_msg());
+               return ACCOUNT_ERROR_DATABASE_BUSY;
+       }
+
        ACCOUNT_RETURN_VAL((hstmt != NULL), {}, ACCOUNT_ERROR_DB_FAILED, ("_account_svc_query_prepare() failed(%s).\n", _account_db_err_msg()));
 
        binding_count = _account_type_convert_account_to_sql(account_type, hstmt, query);
@@ -4860,10 +5959,11 @@ static int _account_type_update_account(account_type_s *account_type, const char
 
        rc = _account_query_step(hstmt);
        if (rc != SQLITE_DONE) {
-               ACCOUNT_FATAL( "account_db_query_step() failed(%d, %s)", rc, _account_db_err_msg());
+               ACCOUNT_ERROR( "account_db_query_step() failed(%d, %s)", rc, _account_db_err_msg());
        }
 
-       _account_query_finalize(hstmt);
+       rc = _account_query_finalize(hstmt);
+       ACCOUNT_RETURN_VAL((rc == ACCOUNT_ERROR_NONE), {}, rc, ("finalize error"));
        hstmt = NULL;
 
        /*update label*/
@@ -4876,6 +5976,35 @@ static int _account_type_update_account(account_type_s *account_type, const char
 
 ACCOUNT_API int account_type_update_to_db_by_app_id(account_type_h account_type, const char* app_id)
 {
+       int res;
+       int process_uid = getuid();
+       char subject_label[SMACK_LABEL_LEN + 1] = {0,};
+
+       if(process_uid != 0) {
+               int fd = open("/proc/self/attr/current", O_RDONLY);
+               if(fd < 0)
+               {
+                       ACCOUNT_ERROR("file open fail :: /proc/self/attr/current");
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+
+               res = read(fd, subject_label, SMACK_LABEL_LEN);
+               if(res < 0)
+               {
+                       ACCOUNT_ERROR("file read fail :: /proc/self/attr/current");
+                       close(fd);
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+
+               res = smack_have_access(subject_label, "libaccounts-svc::check_read", "r");
+               if(res != 1) {
+                       ACCOUNT_ERROR("Account permission denied :: This API can not be used without account.read privilege");
+                       close(fd);
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+               close(fd);
+       }
+
        ACCOUNT_RETURN_VAL((account_type != NULL), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("DATA IS NULL"));
        ACCOUNT_RETURN_VAL((app_id != NULL), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("APP ID IS NULL"));
        ACCOUNT_RETURN_VAL((g_hAccountDB != NULL), {}, ACCOUNT_ERROR_DB_NOT_OPENED, ("The database isn't connected."));
@@ -4902,6 +6031,35 @@ ACCOUNT_API int account_type_delete_by_app_id(const char* app_id)
        int                             binding_count = 1;
        bool                    is_success = FALSE;
 
+       int res;
+       int process_uid = getuid();
+       char subject_label[SMACK_LABEL_LEN + 1] = {0,};
+
+       if(process_uid != 0) {
+               int fd = open("/proc/self/attr/current", O_RDONLY);
+               if(fd < 0)
+               {
+                       ACCOUNT_ERROR("file open fail :: /proc/self/attr/current");
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+
+               res = read(fd, subject_label, SMACK_LABEL_LEN);
+               if(res < 0)
+               {
+                       ACCOUNT_ERROR("file read fail :: /proc/self/attr/current");
+                       close(fd);
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+
+               res = smack_have_access(subject_label, "libaccounts-svc::check_read", "r");
+               if(res != 1) {
+                       ACCOUNT_ERROR("Account permission denied :: This API can not be used without account.read privilege");
+                       close(fd);
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+               close(fd);
+       }
+
        ACCOUNT_RETURN_VAL((g_hAccountDB != NULL), {}, ACCOUNT_ERROR_DB_NOT_OPENED, ("The database isn't connected."));
        ACCOUNT_RETURN_VAL((app_id != NULL), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("The database isn't connected."));
 
@@ -4909,16 +6067,26 @@ ACCOUNT_API int account_type_delete_by_app_id(const char* app_id)
        ACCOUNT_SNPRINTF(query, sizeof(query), "SELECT COUNT(*) FROM %s WHERE AppId = '%s'", ACCOUNT_TYPE_TABLE, app_id);
 
        count = _account_get_record_count(query);
+
+       if( _account_db_err_code() == SQLITE_PERM ){
+               ACCOUNT_ERROR( "Access failed(%s)", _account_db_err_msg());
+               return ACCOUNT_ERROR_PERMISSION_DENIED;
+       }
+
        if (count <= 0) {
-               ACCOUNT_ERROR("app id(%s) is not exist. count(%d)\n", app_id, count);
+               ACCOUNT_SLOGE("app id(%s) is not exist. count(%d)\n", app_id, count);
                return ACCOUNT_ERROR_RECORD_NOT_FOUND;
        }
 
        /* transaction control required*/
        ret_transaction = _account_begin_transaction();
 
-       if (ret_transaction != ACCOUNT_ERROR_NONE) {
-               ACCOUNT_FATAL("account_delete:_account_begin_transaction fail %d\n", ret_transaction);
+       if( ret_transaction == ACCOUNT_ERROR_DATABASE_BUSY ){
+               ACCOUNT_ERROR( "database busy(%s)", _account_db_err_msg());
+               pthread_mutex_unlock(&account_mutex);
+               return ACCOUNT_ERROR_DATABASE_BUSY;
+       }else if (ret_transaction != ACCOUNT_ERROR_NONE) {
+               ACCOUNT_ERROR("account_delete:_account_begin_transaction fail %d\n", ret_transaction);
                pthread_mutex_unlock(&account_mutex);
                return ret_transaction;
        }
@@ -4926,6 +6094,13 @@ ACCOUNT_API int account_type_delete_by_app_id(const char* app_id)
        ACCOUNT_SNPRINTF(query, sizeof(query), "DELETE FROM %s WHERE AppId = ?", LABEL_TABLE);
 
        hstmt = _account_prepare_query(query);
+
+       if( _account_db_err_code() == SQLITE_PERM ){
+               ACCOUNT_ERROR( "Access failed(%s)", _account_db_err_msg());
+               pthread_mutex_unlock(&account_mutex);
+               return ACCOUNT_ERROR_PERMISSION_DENIED;
+       }
+
        ACCOUNT_CATCH_ERROR(hstmt != NULL, {}, ACCOUNT_ERROR_DB_FAILED,
                        ("_account_svc_query_prepare(%s) failed(%s).\n", query, _account_db_err_msg()));
 
@@ -4934,7 +6109,8 @@ ACCOUNT_API int account_type_delete_by_app_id(const char* app_id)
        rc = _account_query_step(hstmt);
        ACCOUNT_CATCH_ERROR(rc == SQLITE_DONE, {}, ACCOUNT_ERROR_RECORD_NOT_FOUND, ("The record isn't found.\n"));
 
-       _account_query_finalize(hstmt);
+       rc = _account_query_finalize(hstmt);
+       ACCOUNT_RETURN_VAL((rc == ACCOUNT_ERROR_NONE), {}, rc, ("finalize error"));
        hstmt = NULL;
 
        binding_count = 1;
@@ -4951,7 +6127,8 @@ ACCOUNT_API int account_type_delete_by_app_id(const char* app_id)
        rc = _account_query_step(hstmt);
        ACCOUNT_CATCH_ERROR(rc == SQLITE_DONE, {}, ACCOUNT_ERROR_RECORD_NOT_FOUND, ("The record isn't found. AppId=%s, rc=%d\n", app_id, rc));
 
-       _account_query_finalize(hstmt);
+       rc = _account_query_finalize(hstmt);
+       ACCOUNT_RETURN_VAL((rc == ACCOUNT_ERROR_NONE), {}, rc, ("finalize error"));
        is_success = TRUE;
 
        hstmt = NULL;
@@ -4970,21 +6147,23 @@ ACCOUNT_API int account_type_delete_by_app_id(const char* app_id)
        rc = _account_query_step(hstmt);
        ACCOUNT_CATCH_ERROR(rc == SQLITE_DONE, {}, ACCOUNT_ERROR_RECORD_NOT_FOUND, ("The record isn't found. AppId=%s, rc=%d\n", app_id, rc));
 
-       _account_query_finalize(hstmt);
+       rc = _account_query_finalize(hstmt);
+       ACCOUNT_RETURN_VAL((rc == ACCOUNT_ERROR_NONE), {}, rc, ("finalize error"));
        is_success = TRUE;
 
        hstmt = NULL;
 
        CATCH:
        if (hstmt != NULL) {
-               _account_query_finalize(hstmt);
+               rc = _account_query_finalize(hstmt);
+               ACCOUNT_RETURN_VAL((rc == ACCOUNT_ERROR_NONE), {}, rc, ("finalize error"));
                hstmt = NULL;
        }
 
        ret_transaction = _account_end_transaction(is_success);
 
        if (ret_transaction != ACCOUNT_ERROR_NONE) {
-               ACCOUNT_FATAL("account_svc_delete:_account_svc_end_transaction fail %d, is_success=%d\n", ret_transaction, is_success);
+               ACCOUNT_ERROR("account_svc_delete:_account_svc_end_transaction fail %d, is_success=%d\n", ret_transaction, is_success);
        }
 
        pthread_mutex_unlock(&account_mutex);
@@ -4994,7 +6173,7 @@ ACCOUNT_API int account_type_delete_by_app_id(const char* app_id)
 
 static void _account_type_convert_column_to_account_type(account_stmt hstmt, account_type_s *account_type_record)
 {
-       char    *textbuf = NULL;
+       const char *textbuf = NULL;
 
        account_type_record->id = _account_query_table_column_int(hstmt, ACCOUNT_TYPE_FIELD_ID);
 
@@ -5012,12 +6191,11 @@ static void _account_type_convert_column_to_account_type(account_stmt hstmt, acc
 
        account_type_record->multiple_account_support = _account_query_table_column_int(hstmt, ACCOUNT_TYPE_FIELD_MULTIPLE_ACCOUNT_SUPPORT);
 
-       ACCOUNT_VERBOSE("END _account_type_convert_column_to_account_type");
 }
 
 static void _account_type_convert_column_to_label(account_stmt hstmt, label_s *label_record)
 {
-       char *textbuf = NULL;
+       const char *textbuf = NULL;
 
        textbuf = _account_query_table_column_text(hstmt, LABEL_FIELD_APP_ID);
        _account_db_data_to_text(textbuf, &(label_record->app_id));
@@ -5028,18 +6206,46 @@ static void _account_type_convert_column_to_label(account_stmt hstmt, label_s *l
        textbuf = _account_query_table_column_text(hstmt, LABEL_FIELD_LOCALE);
        _account_db_data_to_text(textbuf, &(label_record->locale));
 
-       ACCOUNT_VERBOSE("END _account_type_convert_column_to_label");
 }
 
-ACCOUNT_API int account_type_query_label_by_app_id(account_label_cb cb_func, const char* app_id, void *user_data )
+ACCOUNT_API int account_type_query_label_by_app_id(account_label_cb callback, const char* app_id, void *user_data )
 {
        int                     error_code = ACCOUNT_ERROR_NONE;
        account_stmt    hstmt = NULL;
        char                    query[ACCOUNT_SQL_LEN_MAX] = {0, };
        int                     rc = 0, binding_count = 1;
 
+       int res;
+       int process_uid = getuid();
+       char subject_label[SMACK_LABEL_LEN + 1] = {0,};
+
+       if(process_uid != 0) {
+               int fd = open("/proc/self/attr/current", O_RDONLY);
+               if(fd < 0)
+               {
+                       ACCOUNT_ERROR("file open fail :: /proc/self/attr/current");
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+
+               res = read(fd, subject_label, SMACK_LABEL_LEN);
+               if(res < 0)
+               {
+                       ACCOUNT_ERROR("file read fail :: /proc/self/attr/current");
+                       close(fd);
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+
+               res = smack_have_access(subject_label, "libaccounts-svc::check_read", "r");
+               if(res != 1) {
+                       ACCOUNT_ERROR("Account permission denied :: This API can not be used without account.read privilege");
+                       close(fd);
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+               close(fd);
+       }
+
        ACCOUNT_RETURN_VAL((app_id != NULL), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("APP ID IS NULL"));
-       ACCOUNT_RETURN_VAL((cb_func != NULL), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("NO CALLBACK FUNCTION"));
+       ACCOUNT_RETURN_VAL((callback != NULL), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("NO CALLBACK FUNCTION"));
        ACCOUNT_RETURN_VAL((g_hAccountDB != NULL), {}, ACCOUNT_ERROR_DB_NOT_OPENED, ("The database isn't connected."));
 
        ACCOUNT_MEMSET(query, 0x00, ACCOUNT_SQL_LEN_MAX);
@@ -5047,6 +6253,11 @@ ACCOUNT_API int account_type_query_label_by_app_id(account_label_cb cb_func, con
        ACCOUNT_SNPRINTF(query, sizeof(query), "SELECT * FROM %s WHERE AppId = ?", LABEL_TABLE);
        hstmt = _account_prepare_query(query);
 
+       if( _account_db_err_code() == SQLITE_PERM ){
+               ACCOUNT_ERROR( "Access failed(%s)", _account_db_err_msg());
+               return ACCOUNT_ERROR_PERMISSION_DENIED;
+       }
+
        _account_query_bind_text(hstmt, binding_count++, app_id);
 
        rc = _account_query_step(hstmt);
@@ -5067,7 +6278,7 @@ ACCOUNT_API int account_type_query_label_by_app_id(account_label_cb cb_func, con
 
                _account_type_convert_column_to_label(hstmt, label_record);
 
-               cb_ret = cb_func(label_record->app_id, label_record->label , label_record->locale, user_data);
+               cb_ret = callback(label_record->app_id, label_record->label , label_record->locale, user_data);
 
                _account_type_free_label_items(label_record);
                _ACCOUNT_FREE(label_record);
@@ -5077,14 +6288,16 @@ ACCOUNT_API int account_type_query_label_by_app_id(account_label_cb cb_func, con
                rc = _account_query_step(hstmt);
        }
 
-       _account_query_finalize(hstmt);
+       rc = _account_query_finalize(hstmt);
+       ACCOUNT_RETURN_VAL((rc == ACCOUNT_ERROR_NONE), {}, rc, ("finalize error"));
        hstmt = NULL;
 
        error_code = ACCOUNT_ERROR_NONE;
 
 CATCH:
        if (hstmt != NULL) {
-               _account_query_finalize(hstmt);
+               rc = _account_query_finalize(hstmt);
+               ACCOUNT_RETURN_VAL((rc == ACCOUNT_ERROR_NONE), {}, rc, ("finalize error"));
                hstmt = NULL;
        }
 
@@ -5095,12 +6308,10 @@ CATCH:
 int _account_type_label_get_app_id(label_h label, char **app_id)
 {
        if (!label) {
-               ACCOUNT_ERROR("(%s)-(%d) label handle is NULL.\n", __FUNCTION__, __LINE__);
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
 
        if (!app_id) {
-               ACCOUNT_ERROR("(%s)-(%d) app_id is NULL.\n", __FUNCTION__, __LINE__);
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
 
@@ -5131,8 +6342,6 @@ bool _account_get_label_text_cb(char* app_id, char* label, char* locale, void *u
 
        data->label_list = g_slist_append(data->label_list, (gpointer)label_data);
 
-       ACCOUNT_VERBOSE("_account_get_label_text_cb :: appid=%s, label=%s\n", label_data->app_id, label_data->label);
-
        return TRUE;
 }
 
@@ -5153,8 +6362,6 @@ bool _account_get_provider_feature_cb(char* app_id, char* key, void* user_data)
 
        data->provider_feature_list = g_slist_append(data->provider_feature_list, (gpointer)feature_data);
 
-       ACCOUNT_VERBOSE("appid=%s, key=%s\n", feature_data->app_id, feature_data->key);
-
        return TRUE;
 }
 
@@ -5165,16 +6372,49 @@ ACCOUNT_API int account_type_query_by_app_id(const char* app_id, account_type_h
        char                    query[ACCOUNT_SQL_LEN_MAX] = {0, };
        int                     rc = 0, binding_count = 1;
 
+       int res;
+       int process_uid = getuid();
+       char subject_label[SMACK_LABEL_LEN + 1] = {0,};
+
+       if(process_uid != 0) {
+               int fd = open("/proc/self/attr/current", O_RDONLY);
+               if(fd < 0)
+               {
+                       ACCOUNT_ERROR("file open fail :: /proc/self/attr/current");
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+
+               res = read(fd, subject_label, SMACK_LABEL_LEN);
+               if(res < 0)
+               {
+                       ACCOUNT_ERROR("file read fail :: /proc/self/attr/current");
+                       close(fd);
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+
+               res = smack_have_access(subject_label, "libaccounts-svc::check_read", "r");
+               if(res != 1) {
+                       ACCOUNT_ERROR("Account permission denied :: This API can not be used without account.read privilege");
+                       close(fd);
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+               close(fd);
+       }
+
        ACCOUNT_RETURN_VAL((app_id != 0), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("APP ID IS NULL"));
        ACCOUNT_RETURN_VAL((*account_type != NULL), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("ACCOUNT TYPE IS NULL"));
        ACCOUNT_RETURN_VAL((g_hAccountDB != NULL), {}, ACCOUNT_ERROR_DB_NOT_OPENED, ("The database isn't connected."));
 
        ACCOUNT_MEMSET(query, 0x00, ACCOUNT_SQL_LEN_MAX);
 
-       ACCOUNT_DEBUG("app id (%s)\n", app_id);
        ACCOUNT_SNPRINTF(query, sizeof(query), "SELECT * FROM %s WHERE AppId = ?", ACCOUNT_TYPE_TABLE);
        hstmt = _account_prepare_query(query);
 
+       if( _account_db_err_code() == SQLITE_PERM ){
+               ACCOUNT_ERROR( "Access failed(%s)", _account_db_err_msg());
+               return ACCOUNT_ERROR_PERMISSION_DENIED;
+       }
+
        _account_query_bind_text(hstmt, binding_count++, app_id);
 
        rc = _account_query_step(hstmt);
@@ -5184,11 +6424,11 @@ ACCOUNT_API int account_type_query_by_app_id(const char* app_id, account_type_h
 
        while (rc == SQLITE_ROW) {
                _account_type_convert_column_to_account_type(hstmt, account_type_record);
-               ACCOUNT_DEBUG("get account info by id %p\n", account_type_record);
                rc = _account_query_step(hstmt);
        }
 
-       _account_query_finalize(hstmt);
+       rc = _account_query_finalize(hstmt);
+       ACCOUNT_RETURN_VAL((rc == ACCOUNT_ERROR_NONE), {}, rc, ("finalize error"));
        account_type_query_label_by_app_id(_account_get_label_text_cb, app_id, (void*)account_type_record);
        account_type_query_provider_feature_by_app_id(_account_get_provider_feature_cb, app_id,(void*)account_type_record);
 
@@ -5197,7 +6437,8 @@ ACCOUNT_API int account_type_query_by_app_id(const char* app_id, account_type_h
 
        CATCH:
        if (hstmt != NULL) {
-               _account_query_finalize(hstmt);
+               rc = _account_query_finalize(hstmt);
+               ACCOUNT_RETURN_VAL((rc == ACCOUNT_ERROR_NONE), {}, rc, ("finalize error"));
                hstmt = NULL;
        }
 
@@ -5210,25 +6451,56 @@ ACCOUNT_API int account_type_query_app_id_exist(const char* app_id)
        char                    query[ACCOUNT_SQL_LEN_MAX] = {0, };
        int                     rc = 0;
 
+       int res;
+       int process_uid = getuid();
+       char subject_label[SMACK_LABEL_LEN + 1] = {0,};
+
+       if(process_uid != 0) {
+               int fd = open("/proc/self/attr/current", O_RDONLY);
+               if(fd < 0)
+               {
+                       ACCOUNT_ERROR("file open fail :: /proc/self/attr/current");
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+
+               res = read(fd, subject_label, SMACK_LABEL_LEN);
+               if(res < 0)
+               {
+                       ACCOUNT_ERROR("file read fail :: /proc/self/attr/current");
+                       close(fd);
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+
+               res = smack_have_access(subject_label, "libaccounts-svc::check_read", "r");
+               if(res != 1) {
+                       ACCOUNT_ERROR("Account permission denied :: This API can not be used without account.read privilege");
+                       close(fd);
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+               close(fd);
+       }
+
        ACCOUNT_RETURN_VAL((app_id != 0), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("APP ID IS NULL"));
        ACCOUNT_RETURN_VAL((g_hAccountDB != NULL), {}, ACCOUNT_ERROR_DB_NOT_OPENED, ("The database isn't connected."));
 
        ACCOUNT_MEMSET(query, 0x00, ACCOUNT_SQL_LEN_MAX);
 
-       ACCOUNT_DEBUG("app id (%s)\n", app_id);
-
        ACCOUNT_SNPRINTF(query, sizeof(query), "SELECT COUNT(*) FROM %s WHERE AppId = '%s'", ACCOUNT_TYPE_TABLE, app_id);
        rc = _account_get_record_count(query);
 
+       if( _account_db_err_code() == SQLITE_PERM ){
+               ACCOUNT_ERROR( "Access failed(%s)", _account_db_err_msg());
+               return ACCOUNT_ERROR_PERMISSION_DENIED;
+       }
+
        if (rc <= 0) {
-               ACCOUNT_DEBUG("(%s) not exist in account type db");
                return ACCOUNT_ERROR_RECORD_NOT_FOUND;
        }
 
        return ACCOUNT_ERROR_NONE;
 }
 
-ACCOUNT_API int account_type_query_by_provider_feature(account_type_cb cb_func, const char* key, void* user_data)
+ACCOUNT_API int account_type_query_by_provider_feature(account_type_cb callback, const char* key, void* user_data)
 {
        int                     error_code = ACCOUNT_ERROR_NONE;
        account_stmt    hstmt = NULL;
@@ -5236,8 +6508,37 @@ ACCOUNT_API int account_type_query_by_provider_feature(account_type_cb cb_func,
        int                     rc = 0;
        GList                   *account_type_list = NULL;
 
+       int res;
+       int process_uid = getuid();
+       char subject_label[SMACK_LABEL_LEN + 1] = {0,};
+
+       if(process_uid != 0) {
+               int fd = open("/proc/self/attr/current", O_RDONLY);
+               if(fd < 0)
+               {
+                       ACCOUNT_ERROR("file open fail :: /proc/self/attr/current");
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+
+               res = read(fd, subject_label, SMACK_LABEL_LEN);
+               if(res < 0)
+               {
+                       ACCOUNT_ERROR("file read fail :: /proc/self/attr/current");
+                       close(fd);
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+
+               res = smack_have_access(subject_label, "libaccounts-svc::check_read", "r");
+               if(res != 1) {
+                       ACCOUNT_ERROR("Account permission denied :: This API can not be used without account.read privilege");
+                       close(fd);
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+               close(fd);
+       }
+
        ACCOUNT_RETURN_VAL((key != NULL), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("capability_type IS NULL"));
-       ACCOUNT_RETURN_VAL((cb_func != NULL), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("CALL BACK IS NULL"));
+       ACCOUNT_RETURN_VAL((callback != NULL), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("CALL BACK IS NULL"));
        ACCOUNT_RETURN_VAL((g_hAccountDB != NULL), {}, ACCOUNT_ERROR_DB_NOT_OPENED, ("The database isn't connected."));
 
        ACCOUNT_MEMSET(query, 0x00, ACCOUNT_SQL_LEN_MAX);
@@ -5246,8 +6547,13 @@ ACCOUNT_API int account_type_query_by_provider_feature(account_type_cb cb_func,
 
        hstmt = _account_prepare_query(query);
 
+       if( _account_db_err_code() == SQLITE_PERM ){
+               ACCOUNT_ERROR( "Access failed(%s)", _account_db_err_msg());
+               return ACCOUNT_ERROR_PERMISSION_DENIED;
+       }
+
        int binding_count = 1;
-       _account_query_bind_text(hstmt, binding_count++, (char*)key);
+       _account_query_bind_text(hstmt, binding_count++, key);
 
        rc = _account_query_step(hstmt);
 
@@ -5271,7 +6577,8 @@ ACCOUNT_API int account_type_query_by_provider_feature(account_type_cb cb_func,
                k++;
        }
 
-       _account_query_finalize(hstmt);
+       rc = _account_query_finalize(hstmt);
+       ACCOUNT_RETURN_VAL((rc == ACCOUNT_ERROR_NONE), {_account_type_glist_free(account_type_list);}, rc, ("finalize error"));
        hstmt = NULL;
 
        GList* iter;
@@ -5282,7 +6589,7 @@ ACCOUNT_API int account_type_query_by_provider_feature(account_type_cb cb_func,
                account_type_query_label_by_app_id(_account_get_label_text_cb,account_type->app_id,(void*)account_type);
                account_type_query_provider_feature_by_app_id(_account_get_provider_feature_cb, account_type->app_id,(void*)account_type);
                //cb_func((account_type_h)account_type, user_data);
-               ACCOUNT_CATCH_ERROR(cb_func((account_type_h)account_type, user_data) == TRUE, {}, ACCOUNT_ERROR_NONE, ("Callback func returs FALSE, its iteration is stopped!!!!\n"));
+               ACCOUNT_CATCH_ERROR(callback((account_type_h)account_type, user_data) == TRUE, {}, ACCOUNT_ERROR_NONE, ("Callback func returs FALSE, its iteration is stopped!!!!\n"));
                k++;
        }
 
@@ -5290,7 +6597,8 @@ ACCOUNT_API int account_type_query_by_provider_feature(account_type_cb cb_func,
 
 CATCH:
        if (hstmt != NULL) {
-               _account_query_finalize(hstmt);
+               rc = _account_query_finalize(hstmt);
+               ACCOUNT_RETURN_VAL((rc == ACCOUNT_ERROR_NONE), {}, rc, ("finalize error"));
                hstmt = NULL;
        }
        if (account_type_list) {
@@ -5310,6 +6618,35 @@ ACCOUNT_API int account_type_foreach_account_type_from_db(account_type_cb callba
        int                     rc = 0;
        GList                   *account_type_list = NULL;
 
+       int res;
+       int process_uid = getuid();
+       char subject_label[SMACK_LABEL_LEN + 1] = {0,};
+
+       if(process_uid != 0) {
+               int fd = open("/proc/self/attr/current", O_RDONLY);
+               if(fd < 0)
+               {
+                       ACCOUNT_ERROR("file open fail :: /proc/self/attr/current");
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+
+               res = read(fd, subject_label, SMACK_LABEL_LEN);
+               if(res < 0)
+               {
+                       ACCOUNT_ERROR("file read fail :: /proc/self/attr/current");
+                       close(fd);
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+
+               res = smack_have_access(subject_label, "libaccounts-svc::check_read", "r");
+               if(res != 1) {
+                       ACCOUNT_ERROR("Account permission denied :: This API can not be used without account.read privilege");
+                       close(fd);
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+               close(fd);
+       }
+
        ACCOUNT_RETURN_VAL((callback != NULL), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("ACCOUNT INFO IS NULL"));
        ACCOUNT_RETURN_VAL((g_hAccountDB != NULL), {}, ACCOUNT_ERROR_DB_NOT_OPENED, ("The database isn't connected."));
 
@@ -5320,6 +6657,11 @@ ACCOUNT_API int account_type_foreach_account_type_from_db(account_type_cb callba
 
        rc = _account_query_step(hstmt);
 
+       if( _account_db_err_code() == SQLITE_PERM ){
+               ACCOUNT_ERROR( "Access failed(%s)", _account_db_err_msg());
+               return ACCOUNT_ERROR_PERMISSION_DENIED;
+       }
+
        account_type_s *account_type_record = NULL;
 
        ACCOUNT_CATCH_ERROR(rc == SQLITE_ROW, {}, ACCOUNT_ERROR_RECORD_NOT_FOUND, ("The record isn't found.\n"));
@@ -5340,7 +6682,8 @@ ACCOUNT_API int account_type_foreach_account_type_from_db(account_type_cb callba
                k++;
        }
 
-       _account_query_finalize(hstmt);
+       rc = _account_query_finalize(hstmt);
+       ACCOUNT_RETURN_VAL((rc == ACCOUNT_ERROR_NONE), {_account_type_glist_free(account_type_list);}, rc, ("finalize error"));
        hstmt = NULL;
 
        GList* iter;
@@ -5358,7 +6701,8 @@ ACCOUNT_API int account_type_foreach_account_type_from_db(account_type_cb callba
 
 CATCH:
        if (hstmt != NULL) {
-               _account_query_finalize(hstmt);
+               rc = _account_query_finalize(hstmt);
+               ACCOUNT_RETURN_VAL((rc == ACCOUNT_ERROR_NONE), {}, rc, ("finalize error"));
                hstmt = NULL;
        }
        if (account_type_list) {
@@ -5377,15 +6721,68 @@ ACCOUNT_API int account_type_query_label_by_locale(const char* app_id, const cha
        char                    query[ACCOUNT_SQL_LEN_MAX] = {0, };
        int                     rc = 0, binding_count = 1;
 
+       int res;
+       int process_uid = getuid();
+       char subject_label[SMACK_LABEL_LEN + 1] = {0,};
+       char* converted_locale = NULL;
+
+       if(process_uid != 0) {
+               int fd = open("/proc/self/attr/current", O_RDONLY);
+               if(fd < 0)
+               {
+                       ACCOUNT_ERROR("file open fail :: /proc/self/attr/current");
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+
+               res = read(fd, subject_label, SMACK_LABEL_LEN);
+               if(res < 0)
+               {
+                       ACCOUNT_ERROR("file read fail :: /proc/self/attr/current");
+                       close(fd);
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+
+               res = smack_have_access(subject_label, "libaccounts-svc::check_read", "r");
+               if(res != 1) {
+                       ACCOUNT_ERROR("Account permission denied :: This API can not be used without account.read privilege");
+                       close(fd);
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+               close(fd);
+       }
+
        ACCOUNT_RETURN_VAL((app_id != NULL), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("NO APP ID"));
        ACCOUNT_RETURN_VAL((g_hAccountDB != NULL), {}, ACCOUNT_ERROR_DB_NOT_OPENED, ("The database isn't connected."));
        ACCOUNT_RETURN_VAL((label != NULL), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("label char is null"));
+       ACCOUNT_RETURN_VAL((locale != NULL), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("locale char is null"));
 
        ACCOUNT_MEMSET(query, 0x00, ACCOUNT_SQL_LEN_MAX);
 
-       ACCOUNT_SNPRINTF(query, sizeof(query), "SELECT * FROM %s WHERE AppId = ? AND Locale = '%s' ", LABEL_TABLE, locale);
+       converted_locale = _account_get_text(locale);
+       gchar** tokens = g_strsplit(converted_locale, "-", 2);
+
+       if(tokens != NULL) {
+               if((char*)(tokens[1]) != NULL) {
+                       char* upper_token = g_ascii_strup(tokens[1], strlen(tokens[1]));
+                       if(upper_token != NULL) {
+                               _ACCOUNT_FREE(converted_locale);
+                               converted_locale = g_strdup_printf("%s_%s", tokens[0], upper_token);
+                       }
+                       _ACCOUNT_FREE(upper_token);
+               }
+       }
+       g_strfreev(tokens);
+
+       ACCOUNT_SNPRINTF(query, sizeof(query), "SELECT * FROM %s WHERE AppId = ? AND Locale = '%s' ", LABEL_TABLE, converted_locale);
+       _ACCOUNT_FREE(converted_locale);
+
        hstmt = _account_prepare_query(query);
 
+       if( _account_db_err_code() == SQLITE_PERM ){
+               ACCOUNT_ERROR( "Access failed(%s)", _account_db_err_msg());
+               return ACCOUNT_ERROR_PERMISSION_DENIED;
+       }
+
        _account_query_bind_text(hstmt, binding_count++, app_id);
 
        rc = _account_query_step(hstmt);
@@ -5405,6 +6802,7 @@ ACCOUNT_API int account_type_query_label_by_locale(const char* app_id, const cha
 
                _account_type_convert_column_to_label(hstmt,label_record);
 
+               _ACCOUNT_FREE(*label);
                *label = _account_get_text(label_record->label);
 
                _account_type_free_label_items(label_record);
@@ -5413,14 +6811,16 @@ ACCOUNT_API int account_type_query_label_by_locale(const char* app_id, const cha
                rc = _account_query_step(hstmt);
        }
 
-       _account_query_finalize(hstmt);
+       rc = _account_query_finalize(hstmt);
+       ACCOUNT_RETURN_VAL((rc == ACCOUNT_ERROR_NONE), {}, rc, ("finalize error"));
        hstmt = NULL;
 
        error_code = ACCOUNT_ERROR_NONE;
 
        CATCH:
        if (hstmt != NULL) {
-               _account_query_finalize(hstmt);
+               rc = _account_query_finalize(hstmt);
+               ACCOUNT_RETURN_VAL((rc == ACCOUNT_ERROR_NONE), {}, rc, ("finalize error"));
                hstmt = NULL;
        }
 
@@ -5437,7 +6837,7 @@ static int _account_insert_custom(account_s *account, int account_id)
        ACCOUNT_RETURN_VAL((account != NULL), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("ACCOUNT HANDLE IS NULL"));
 
        if (g_slist_length( account->custom_list)==0) {
-               ACCOUNT_ERROR( "_account_insert_custom, no custom data\n");
+               ACCOUNT_DEBUG( "_account_insert_custom, no custom data\n");
                return ACCOUNT_ERROR_NONE;
        }
 
@@ -5445,8 +6845,13 @@ static int _account_insert_custom(account_s *account, int account_id)
 
        rc = _account_get_record_count(query);
 
+       if( _account_db_err_code() == SQLITE_PERM ){
+               ACCOUNT_ERROR( "Access failed(%d, %s)", _account_db_err_msg());
+               return ACCOUNT_ERROR_PERMISSION_DENIED;
+       }
+
        if (rc <= 0) {
-               ACCOUNT_ERROR( "_account_insert_custom : related account item is not existed rc=%d , %s", rc, _account_db_err_msg());
+               ACCOUNT_SLOGE( "_account_insert_custom : related account item is not existed rc=%d , %s", rc, _account_db_err_msg());
                return ACCOUNT_ERROR_RECORD_NOT_FOUND;
        }
 
@@ -5455,7 +6860,7 @@ static int _account_insert_custom(account_s *account, int account_id)
        GSList *iter;
 
        for (iter = account->custom_list; iter != NULL; iter = g_slist_next(iter)) {
-               int rc, ret;
+               int ret;
                count = 1;
                ACCOUNT_MEMSET(query, 0x00, sizeof(query));
                ACCOUNT_SNPRINTF(query, sizeof(query), "INSERT INTO %s (AccountId, AppId, Key, Value) VALUES "
@@ -5463,11 +6868,15 @@ static int _account_insert_custom(account_s *account, int account_id)
 
                hstmt = _account_prepare_query(query);
 
+               if( _account_db_err_code() == SQLITE_PERM ){
+                       ACCOUNT_ERROR( "Access failed(%s)", _account_db_err_msg());
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+
                ACCOUNT_RETURN_VAL((hstmt != NULL), {}, ACCOUNT_ERROR_DB_FAILED, ("_account_prepare_query() failed(%s).\n", _account_db_err_msg()));
 
                account_custom_s* custom_data = NULL;
                custom_data = (account_custom_s*)iter->data;
-               ACCOUNT_VERBOSE( "account_custom_s->key = %s, account_custom_s->value = %s \n", custom_data->key, custom_data->value);
 
                ret = _account_query_bind_int(hstmt, count++, account_id);
                ACCOUNT_RETURN_VAL((ret == ACCOUNT_ERROR_NONE), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("Int binding fail"));
@@ -5481,17 +6890,16 @@ static int _account_insert_custom(account_s *account, int account_id)
                rc = _account_query_step(hstmt);
 
                if (rc != SQLITE_DONE) {
-                       ACCOUNT_FATAL( "_account_query_step() failed(%d, %s)", rc, _account_db_err_msg());
+                       ACCOUNT_ERROR( "_account_query_step() failed(%d, %s)", rc, _account_db_err_msg());
                        break;
                }
 
-               _account_query_finalize(hstmt);
+               rc = _account_query_finalize(hstmt);
+               ACCOUNT_RETURN_VAL((rc == ACCOUNT_ERROR_NONE), {}, rc, ("finalize error"));
                hstmt = NULL;
 
        }
 
-       ACCOUNT_VERBOSE( "_account_insert_custom() DONE\n");
-
        return ACCOUNT_ERROR_NONE;
 }
 
@@ -5503,10 +6911,8 @@ static int _account_update_custom(account_s *account, int account_id)
 
        ACCOUNT_RETURN_VAL((account != NULL), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("ACCOUNT HANDLE IS NULL"));
 
-       ACCOUNT_INFO( "account handle=%p, account_id=%d", account, account_id);
-
        if (g_slist_length( account->custom_list)==0) {
-               ACCOUNT_ERROR( "_account_update_custom, no custom data\n");
+               ACCOUNT_DEBUG( "_account_update_custom, no custom data\n");
                return ACCOUNT_ERROR_NONE;
        }
 
@@ -5514,8 +6920,18 @@ static int _account_update_custom(account_s *account, int account_id)
 
        rc = _account_get_record_count(query);
 
+       if( _account_db_err_code() == SQLITE_PERM ){
+               ACCOUNT_ERROR( "Access failed(%s)", _account_db_err_msg());
+               pthread_mutex_unlock(&account_mutex);
+               return ACCOUNT_ERROR_PERMISSION_DENIED;
+       } else if( _account_db_err_code() == SQLITE_BUSY ){
+               ACCOUNT_ERROR( "database busy(%s)", _account_db_err_msg());
+               pthread_mutex_unlock(&account_mutex);
+               return ACCOUNT_ERROR_DATABASE_BUSY;
+       }
+
        if (rc <= 0) {
-               ACCOUNT_ERROR( "_account_update_custom : related account item is not existed rc=%d , %s", rc, _account_db_err_msg());
+               ACCOUNT_SLOGE( "_account_update_custom : related account item is not existed rc=%d , %s", rc, _account_db_err_msg());
                return ACCOUNT_ERROR_RECORD_NOT_FOUND;
        }
 
@@ -5527,17 +6943,22 @@ static int _account_update_custom(account_s *account, int account_id)
        _account_query_bind_int(hstmt, count++, (int)account_id);
        rc = _account_query_step(hstmt);
 
-       if (rc != SQLITE_DONE) {
-               ACCOUNT_FATAL( "_account_query_step() failed(%d, %s)", rc, _account_db_err_msg());
+       if (rc == SQLITE_BUSY) {
+               ACCOUNT_ERROR( "_account_query_step() failed(%d, %s)", rc, _account_db_err_msg());
+               return ACCOUNT_ERROR_DATABASE_BUSY;
+       } else if (rc != SQLITE_DONE) {
+               ACCOUNT_ERROR( "_account_query_step() failed(%d, %s)", rc, _account_db_err_msg());
                return ACCOUNT_ERROR_DB_FAILED;
        }
-       _account_query_finalize(hstmt);
+
+       rc = _account_query_finalize(hstmt);
+       ACCOUNT_RETURN_VAL((rc == ACCOUNT_ERROR_NONE), {}, rc, ("finalize error"));
        hstmt = NULL;
 
        GSList *iter;
 
        for (iter = account->custom_list; iter != NULL; iter = g_slist_next(iter)) {
-               int rc, ret;
+               int ret;
                count = 1;
                ACCOUNT_MEMSET(query, 0x00, sizeof(query));
                ACCOUNT_SNPRINTF(query, sizeof(query), "INSERT INTO %s(AccountId, AppId, Key, Value) VALUES "
@@ -5545,6 +6966,11 @@ static int _account_update_custom(account_s *account, int account_id)
 
                hstmt = _account_prepare_query(query);
 
+               if( _account_db_err_code() == SQLITE_PERM ){
+                       ACCOUNT_ERROR( "Access failed(%s)", _account_db_err_msg());
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+
                ACCOUNT_RETURN_VAL((hstmt != NULL), {}, ACCOUNT_ERROR_DB_FAILED, ("_account_prepare_query() failed(%s).\n", _account_db_err_msg()));
 
                account_custom_s* custom_data = NULL;
@@ -5562,21 +6988,20 @@ static int _account_update_custom(account_s *account, int account_id)
                rc = _account_query_step(hstmt);
 
                if (rc != SQLITE_DONE) {
-                       ACCOUNT_FATAL( "_account_query_step() failed(%d, %s)", rc, _account_db_err_msg());
+                       ACCOUNT_ERROR( "_account_query_step() failed(%d, %s)", rc, _account_db_err_msg());
                        break;
                }
 
-               _account_query_finalize(hstmt);
+               rc = _account_query_finalize(hstmt);
+               ACCOUNT_RETURN_VAL((rc == ACCOUNT_ERROR_NONE), {}, rc, ("finalize error"));
                hstmt = NULL;
 
        }
 
-       ACCOUNT_VERBOSE( "_account_update_custom() DONE\n");
-
        return ACCOUNT_ERROR_NONE;
 }
 
-static int _account_query_custom_by_account_id(account_custom_cb cb_func, int account_id, void *user_data )
+static int _account_query_custom_by_account_id(account_custom_cb callback, int account_id, void *user_data )
 {
        int                     error_code = ACCOUNT_ERROR_NONE;
        account_stmt    hstmt = NULL;
@@ -5584,7 +7009,7 @@ static int _account_query_custom_by_account_id(account_custom_cb cb_func, int ac
        int                     rc = 0;
 
        ACCOUNT_RETURN_VAL((account_id > 0), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("ACCOUNT INDEX IS LESS THAN 0"));
-       ACCOUNT_RETURN_VAL((cb_func != NULL), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("NO CALLBACK FUNCTION"));
+       ACCOUNT_RETURN_VAL((callback != NULL), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("NO CALLBACK FUNCTION"));
        ACCOUNT_RETURN_VAL((g_hAccountDB != NULL), {}, ACCOUNT_ERROR_DB_NOT_OPENED, ("The database isn't connected."));
 
        ACCOUNT_MEMSET(query, 0x00, ACCOUNT_SQL_LEN_MAX);
@@ -5592,7 +7017,13 @@ static int _account_query_custom_by_account_id(account_custom_cb cb_func, int ac
        ACCOUNT_SNPRINTF(query, sizeof(query), "SELECT * FROM %s WHERE AccountId = %d", ACCOUNT_CUSTOM_TABLE, account_id);
        hstmt = _account_prepare_query(query);
 
+       if( _account_db_err_code() == SQLITE_PERM ){
+               ACCOUNT_ERROR( "Access failed(%s)", _account_db_err_msg());
+               return ACCOUNT_ERROR_PERMISSION_DENIED;
+       }
+
        rc = _account_query_step(hstmt);
+
        ACCOUNT_CATCH_ERROR(rc == SQLITE_ROW, {}, ACCOUNT_ERROR_RECORD_NOT_FOUND, ("The record isn't found.\n"));
 
        account_custom_s* custom_record = NULL;
@@ -5610,7 +7041,7 @@ static int _account_query_custom_by_account_id(account_custom_cb cb_func, int ac
 
                _account_convert_column_to_custom(hstmt, custom_record);
 
-               cb_ret = cb_func(custom_record->key, custom_record->value, user_data);
+               cb_ret = callback(custom_record->key, custom_record->value, user_data);
 
                _account_custom_item_free(custom_record);
                _ACCOUNT_FREE(custom_record);
@@ -5620,14 +7051,16 @@ static int _account_query_custom_by_account_id(account_custom_cb cb_func, int ac
                rc = _account_query_step(hstmt);
        }
 
-       _account_query_finalize(hstmt);
+       rc = _account_query_finalize(hstmt);
+       ACCOUNT_RETURN_VAL((rc == ACCOUNT_ERROR_NONE), {}, rc, ("finalize error"));
        hstmt = NULL;
 
        error_code = ACCOUNT_ERROR_NONE;
 
 CATCH:
        if (hstmt != NULL) {
-               _account_query_finalize(hstmt);
+               rc = _account_query_finalize(hstmt);
+               ACCOUNT_RETURN_VAL((rc == ACCOUNT_ERROR_NONE), {}, rc, ("finalize error"));
                hstmt = NULL;
        }
 
@@ -5642,8 +7075,6 @@ static void _account_subscribe_vconf_callback(keynode_t *key, void *user_data)
        char event_msg[256] ={0, };
        int account_id = -1;
 
-       ACCOUNT_DEBUG("START\n");
-
        if(!key) {
                ACCOUNT_ERROR("No subscribtion msg !!!!!\n");
                return;
@@ -5657,6 +7088,11 @@ static void _account_subscribe_vconf_callback(keynode_t *key, void *user_data)
        if(!memcmp(vconf_keynode_get_name(key), VCONFKEY_ACCOUNT_MSG_STR, strlen(VCONFKEY_ACCOUNT_MSG_STR)))
        {
                vconf_key = vconf_keynode_get_str(key);
+
+               if( vconf_key == NULL){
+                       ACCOUNT_ERROR("vconf key is NULL.\n");
+                       return;
+               }
                msg = strdup(vconf_key);
 
                char* event_type = NULL;
@@ -5666,7 +7102,7 @@ static void _account_subscribe_vconf_callback(keynode_t *key, void *user_data)
                event_type = strtok_r(msg, ":", &ptr);
                id = strtok_r(NULL, ":", &ptr);
 
-               ACCOUNT_DEBUG("msg(%s), event_type(%s), id(%s)\n", msg, event_type, id);
+               ACCOUNT_SLOGD("msg(%s), event_type(%s), id(%s)", msg, event_type, id);
 
                ACCOUNT_SNPRINTF(event_msg,sizeof(event_msg),"%s", event_type);
 
@@ -5678,13 +7114,12 @@ static void _account_subscribe_vconf_callback(keynode_t *key, void *user_data)
 
        _ACCOUNT_FREE(msg);
 
-       ACCOUNT_DEBUG("END\n");
 }
 
 ACCOUNT_API int account_subscribe_create(account_subscribe_h* account_subscribe)
 {
        if (!account_subscribe) {
-               ACCOUNT_ERROR("(%s)-(%d) account is NULL.\n", __FUNCTION__, __LINE__);
+               ACCOUNT_SLOGE("account is NULL.\n", __FUNCTION__, __LINE__);
                return ACCOUNT_ERROR_INVALID_PARAMETER;
        }
 
@@ -5695,37 +7130,95 @@ ACCOUNT_API int account_subscribe_create(account_subscribe_h* account_subscribe)
                return ACCOUNT_ERROR_OUT_OF_MEMORY;
        }
 
-       ACCOUNT_VERBOSE("create handle=%p\n", *data);
-
        *account_subscribe = (account_subscribe_h)data;
 
        return ACCOUNT_ERROR_NONE;
 }
 
-ACCOUNT_API int account_subscribe_notification(account_subscribe_h account_subscribe, account_event_cb cb_func, void* user_data)
+ACCOUNT_API int account_subscribe_notification(account_subscribe_h account_subscribe, account_event_cb callback, void* user_data)
 {
-       ACCOUNT_DEBUG("START\n");
+       int res;
+       int process_uid = getuid();
+       char subject_label[SMACK_LABEL_LEN + 1] = {0,};
+
+       if(process_uid != 0) {
+               int fd = open("/proc/self/attr/current", O_RDONLY);
+               if(fd < 0)
+               {
+                       ACCOUNT_ERROR("file open fail :: /proc/self/attr/current");
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+
+               res = read(fd, subject_label, SMACK_LABEL_LEN);
+               if(res < 0)
+               {
+                       ACCOUNT_ERROR("file read fail :: /proc/self/attr/current");
+                       close(fd);
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+
+               res = smack_have_access(subject_label, "libaccounts-svc::check_read", "r");
+               if(res != 1) {
+                       ACCOUNT_ERROR("Account permission denied :: This API can not be used without account.read privilege");
+                       close(fd);
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+               close(fd);
+       }
 
        ACCOUNT_RETURN_VAL((account_subscribe != NULL), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("(%s)-(%d) account subscribe handle is NULL.\n",  __FUNCTION__, __LINE__));
 
        account_subscribe_s* tmp =(account_subscribe_s*)account_subscribe;
 
-       tmp->account_subscription_callback = cb_func;
+       tmp->account_subscription_callback = callback;
        tmp->user_data = user_data;
 
-       if (vconf_notify_key_changed(VCONFKEY_ACCOUNT_MSG_STR,
+       int ret = -1;
+       ret = vconf_notify_key_changed(VCONFKEY_ACCOUNT_MSG_STR,
                                (vconf_callback_fn)_account_subscribe_vconf_callback,
-                               (void*)tmp) != 0) {
-               ACCOUNT_FATAL("Vconf Subscription Failed !!!!!\n");
+                               (void*)tmp);
+
+       ACCOUNT_SLOGI("vconf_notify_key_changed ret = %d", ret);
+
+       if(ret != VCONF_OK) {
+               ACCOUNT_ERROR("Vconf Subscription Failed ret = %d", ret);
                return ACCOUNT_ERROR_EVENT_SUBSCRIPTION_FAIL;
        }
 
-       ACCOUNT_DEBUG("Vconf Subscription Success!!!!\n");
        return ACCOUNT_ERROR_NONE;
 }
 
 ACCOUNT_API int account_unsubscribe_notification(account_subscribe_h account_subscribe)
 {
+       int res;
+       int process_uid = getuid();
+       char subject_label[SMACK_LABEL_LEN + 1] = {0,};
+
+       if(process_uid != 0) {
+               int fd = open("/proc/self/attr/current", O_RDONLY);
+               if(fd < 0)
+               {
+                       ACCOUNT_ERROR("file open fail :: /proc/self/attr/current");
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+
+               res = read(fd, subject_label, SMACK_LABEL_LEN);
+               if(res < 0)
+               {
+                       ACCOUNT_ERROR("file read fail :: /proc/self/attr/current");
+                       close(fd);
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+
+               res = smack_have_access(subject_label, "libaccounts-svc::check_read", "r");
+               if(res != 1) {
+                       ACCOUNT_ERROR("Account permission denied :: This API can not be used without account.read privilege");
+                       close(fd);
+                       return ACCOUNT_ERROR_PERMISSION_DENIED;
+               }
+               close(fd);
+       }
+
        ACCOUNT_RETURN_VAL((account_subscribe != NULL), {}, ACCOUNT_ERROR_INVALID_PARAMETER, ("(%s)-(%d) account subscribe handle is NULL.\n",  __FUNCTION__, __LINE__));
 
        account_subscribe_s* tmp =(account_subscribe_s*)account_subscribe;
@@ -5734,11 +7227,9 @@ ACCOUNT_API int account_unsubscribe_notification(account_subscribe_h account_sub
 
        if (vconf_ignore_key_changed(VCONFKEY_ACCOUNT_MSG_STR,
           (vconf_callback_fn)_account_subscribe_vconf_callback) != 0) {
-               ACCOUNT_FATAL("Vconf Subscription Failed !!!!!\n");
+               ACCOUNT_ERROR("Vconf Subscription Failed !!!!!\n");
                return ACCOUNT_ERROR_EVENT_SUBSCRIPTION_FAIL;
        }
 
-       ACCOUNT_DEBUG("Vconf Unsubscription Success!!!!\n");
        return ACCOUNT_ERROR_NONE;
 }
-
index c4a01aa..85de29c 100755 (executable)
@@ -21,6 +21,7 @@
 
 #include <stdio.h>
 #include "account.h"
+#include "account-private.h"
 #include <string.h>
 //#include <dbus/dbus.h>
 
@@ -39,54 +40,54 @@ bool _capability_get_callback(const char* capability_type, account_capability_st
        char* test_type = (char*)capability_type;
        int test_value = capability_value;
 
-       printf("_capability_get_callback test_type = : %s\n", test_type);
-       printf("_capability_get_callback test_value = : %d\n", test_value);
+       ACCOUNT_SLOGD("_capability_get_callback test_type = : %s\n", test_type);
+       ACCOUNT_SLOGD("_capability_get_callback test_value = : %d\n", test_value);
        return TRUE;
 }
 
 int _account_get_account_info(account_h handle)
 {
-       printf("_account_get_callback\n");
+       ACCOUNT_SLOGD("_account_get_callback\n");
 
        char *test_text = NULL;
 
        account_get_user_name(handle, &test_text);
-       printf("_account_get_callback : %s\n", test_text);
+       ACCOUNT_SLOGD("_account_get_callback : %s\n", test_text);
 
        _account_free_text(test_text);
 
        account_get_display_name(handle, &test_text);
-       printf("_account_get_callback : %s\n", test_text);
+       ACCOUNT_SLOGD("_account_get_callback : %s\n", test_text);
 
        _account_free_text(test_text);
 
        account_get_email_address(handle, &test_text);
-       printf("_account_get_callback : %s\n", test_text);
+       ACCOUNT_SLOGD("_account_get_callback : %s\n", test_text);
 
        _account_free_text(test_text);
 
        account_get_icon_path(handle, &test_text);
-       printf("_account_get_callback : %s\n", test_text);
+       ACCOUNT_SLOGD("_account_get_callback : %s\n", test_text);
 
        _account_free_text(test_text);
 
        account_get_source(handle, &test_text);
-       printf("_account_get_callback : %s\n", test_text);
+       ACCOUNT_SLOGD("_account_get_callback : %s\n", test_text);
 
        _account_free_text(test_text);
 
        account_get_package_name(handle, &test_text);
-       printf("_account_get_callback : %s\n", test_text);
+       ACCOUNT_SLOGD("_account_get_callback : %s\n", test_text);
 
        _account_free_text(test_text);
 
        account_get_domain_name(handle, &test_text);
-       printf("_account_get_callback : %s\n", test_text);
+       ACCOUNT_SLOGD("_account_get_callback : %s\n", test_text);
 
        _account_free_text(test_text);
 
        account_get_access_token(handle, &test_text);
-       printf("_account_get_callback : %s\n", test_text);
+       ACCOUNT_SLOGD("_account_get_callback : %s\n", test_text);
 
 
        int i;
@@ -96,28 +97,28 @@ int _account_get_account_info(account_h handle)
                _account_free_text(test_text);
 
                account_get_user_text(handle, i, &test_text);
-               printf("_account_get_callback : %s\n", test_text);
+               ACCOUNT_SLOGD("_account_get_callback : %s\n", test_text);
        }
 
        int test_int  = -1;
 
        account_auth_type_e auth_type;
        account_get_auth_type(handle, &auth_type);
-       printf("account_get_auth_type : %d\n", auth_type);
+       ACCOUNT_SLOGD("account_get_auth_type : %d\n", auth_type);
 
        account_secrecy_state_e secret;
        account_get_secret(handle, &secret);
-       printf("account_get_secret : %d\n", secret);
+       ACCOUNT_SLOGD("account_get_secret : %d\n", secret);
 
        account_sync_state_e sync_support;
        account_get_sync_support(handle, &sync_support);
-       printf("account_get_sync_support : %d\n", sync_support);
+       ACCOUNT_SLOGD("account_get_sync_support : %d\n", sync_support);
 
        for(i=0;i<USER_INT_CNT;i++)
        {
                test_int  = -1;
                account_get_user_int(handle, i, &test_int);
-               printf("_account_get_callback : %d\n", test_int);
+               ACCOUNT_SLOGD("_account_get_callback : %d\n", test_int);
        }
 
        account_get_capability_all(handle, _capability_get_callback, NULL);
@@ -128,47 +129,47 @@ int _account_get_account_info(account_h handle)
 
 bool _account_get_callback(account_h handle, void* user_data)
 {
-       printf("_account_get_callback\n");
+       ACCOUNT_SLOGD("_account_get_callback\n");
 
        char *test_text = NULL;
 
        account_get_user_name(handle, &test_text);
-       printf("_account_get_callback : %s\n", test_text);
+       ACCOUNT_SLOGD("_account_get_callback : %s\n", test_text);
 
        _account_free_text(test_text);
 
        account_get_display_name(handle, &test_text);
-       printf("_account_get_callback : %s\n", test_text);
+       ACCOUNT_SLOGD("_account_get_callback : %s\n", test_text);
 
        _account_free_text(test_text);
 
        account_get_email_address(handle, &test_text);
-       printf("_account_get_callback : %s\n", test_text);
+       ACCOUNT_SLOGD("_account_get_callback : %s\n", test_text);
 
        _account_free_text(test_text);
 
        account_get_icon_path(handle, &test_text);
-       printf("_account_get_callback : %s\n", test_text);
+       ACCOUNT_SLOGD("_account_get_callback : %s\n", test_text);
 
        _account_free_text(test_text);
 
        account_get_source(handle, &test_text);
-       printf("_account_get_callback : %s\n", test_text);
+       ACCOUNT_SLOGD("_account_get_callback : %s\n", test_text);
 
        _account_free_text(test_text);
 
        account_get_package_name(handle, &test_text);
-       printf("_account_get_callback : %s\n", test_text);
+       ACCOUNT_SLOGD("_account_get_callback : %s\n", test_text);
 
        _account_free_text(test_text);
 
        account_get_domain_name(handle, &test_text);
-       printf("_account_get_callback : %s\n", test_text);
+       ACCOUNT_SLOGD("_account_get_callback : %s\n", test_text);
 
        _account_free_text(test_text);
 
        account_get_access_token(handle, &test_text);
-       printf("_account_get_callback : %s\n", test_text);
+       ACCOUNT_SLOGD("_account_get_callback : %s\n", test_text);
 
        int i;
 
@@ -177,28 +178,28 @@ bool _account_get_callback(account_h handle, void* user_data)
                _account_free_text(test_text);
 
                account_get_user_text(handle, i, &test_text);
-               printf("_account_get_callback : %s\n", test_text);
+               ACCOUNT_SLOGD("_account_get_callback : %s\n", test_text);
        }
 
        int test_int  = -1;
 
        account_auth_type_e auth_type;
        account_get_auth_type(handle, &auth_type);
-       printf("account_get_auth_type : %d\n", auth_type);
+       ACCOUNT_SLOGD("account_get_auth_type : %d\n", auth_type);
 
        account_secrecy_state_e secret;
        account_get_secret(handle, &secret);
-       printf("account_get_secret : %d\n", secret);
+       ACCOUNT_SLOGD("account_get_secret : %d\n", secret);
 
        account_sync_state_e sync_support;
        account_get_sync_support(handle, &sync_support);
-       printf("account_get_sync_support : %d\n", sync_support);
+       ACCOUNT_SLOGD("account_get_sync_support : %d\n", sync_support);
 
        for(i=0;i<USER_INT_CNT;i++)
        {
                test_int  = -1;
                account_get_user_int(handle, i, &test_int);
-               printf("_account_get_callback : %d\n", test_int);
+               ACCOUNT_SLOGD("_account_get_callback : %d\n", test_int);
        }
 
        account_get_capability_all(handle, _capability_get_callback, NULL);
@@ -217,27 +218,27 @@ static int _account_insert_test_new(void)
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        char temp[128];
        memset(temp, 0x00, sizeof(temp));
 
        ret = account_create(&account);
-       printf("account_set_user_name: Enter User Name to be set \n");
+       ACCOUNT_SLOGD("account_set_user_name: Enter User Name to be set \n");
        if (scanf("%s", temp) != 1) {
-               printf("scanf Failed !!!! \n");
+               ACCOUNT_SLOGD("scanf Failed !!!! \n");
                ret = account_destroy(account);
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                }
 
                ret = account_disconnect();
 
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                }
                return ret;
        }
@@ -246,23 +247,23 @@ static int _account_insert_test_new(void)
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        memset(temp, 0x00, sizeof(temp));
-       printf("account_set_display_name: Enter display Name to be set \n");
+       ACCOUNT_SLOGD("account_set_display_name: Enter display Name to be set \n");
        if (scanf("%s", temp) != 1) {
-               printf("scanf Failed !!!! \n");
+               ACCOUNT_SLOGD("scanf Failed !!!! \n");
                ret = account_destroy(account);
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                }
 
                ret = account_disconnect();
 
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                }
                return ret;
        }
@@ -271,23 +272,23 @@ static int _account_insert_test_new(void)
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        memset(temp, 0x00, sizeof(temp));
-       printf("account_set_domain_name: Enter domain Name to be set \n");
+       ACCOUNT_SLOGD("account_set_domain_name: Enter domain Name to be set \n");
        if (scanf("%s", temp) != 1) {
-               printf("scanf Failed !!!! \n");
+               ACCOUNT_SLOGD("scanf Failed !!!! \n");
                ret = account_destroy(account);
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                }
 
                ret = account_disconnect();
 
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                }
                return ret;
        }
@@ -295,47 +296,47 @@ static int _account_insert_test_new(void)
        ret = account_set_domain_name(account, temp);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        memset(temp, 0x00, sizeof(temp));
-       printf("account_set_email_address: Enter email Name to be set \n");
+       ACCOUNT_SLOGD("account_set_email_address: Enter email Name to be set \n");
        if (scanf("%s", temp) != 1) {
-               printf("scanf Failed !!!! \n");
+               ACCOUNT_SLOGD("scanf Failed !!!! \n");
                ret = account_destroy(account);
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                }
 
                ret = account_disconnect();
 
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                }
                return ret;
        }
        ret = account_set_email_address(account, temp);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        memset(temp, 0x00, sizeof(temp));
-       printf("account_set_package_name: Enter package Name to be set \n");
+       ACCOUNT_SLOGD("account_set_package_name: Enter package Name to be set \n");
        if (scanf("%s", temp) != 1) {
-               printf("scanf Failed !!!! \n");
+               ACCOUNT_SLOGD("scanf Failed !!!! \n");
                ret = account_destroy(account);
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                }
 
                ret = account_disconnect();
 
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                }
                return ret;
        }
@@ -343,23 +344,23 @@ static int _account_insert_test_new(void)
        ret = account_set_package_name(account, temp);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        memset(temp, 0x00, sizeof(temp));
-       printf("account_set_icon_path: Enter icon path to be set \n");
+       ACCOUNT_SLOGD("account_set_icon_path: Enter icon path to be set \n");
        if (scanf("%s", temp) != 1) {
-               printf("scanf Failed !!!! \n");
+               ACCOUNT_SLOGD("scanf Failed !!!! \n");
                ret = account_destroy(account);
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                }
 
                ret = account_disconnect();
 
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                }
                return ret;
        }
@@ -367,24 +368,24 @@ static int _account_insert_test_new(void)
        ret = account_set_icon_path(account, temp);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        memset(temp, 0x00, sizeof(temp));
 
-       printf("account_set_access_token: Enter access token to be set \n");
+       ACCOUNT_SLOGD("account_set_access_token: Enter access token to be set \n");
        if (scanf("%s", temp) != 1) {
-               printf("scanf Failed !!!! \n");
+               ACCOUNT_SLOGD("scanf Failed !!!! \n");
                ret = account_destroy(account);
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                }
 
                ret = account_disconnect();
 
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                }
                return ret;
        }
@@ -392,23 +393,23 @@ static int _account_insert_test_new(void)
        ret = account_set_access_token(account, temp);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        memset(temp, 0x00, sizeof(temp));
-       printf("account_set_auth_type: Enter auth type to be set \n");
+       ACCOUNT_SLOGD("account_set_auth_type: Enter auth type to be set \n");
        if (scanf("%d", &temp_int) != 1) {
-               printf("scanf Failed !!!! \n");
+               ACCOUNT_SLOGD("scanf Failed !!!! \n");
                ret = account_destroy(account);
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                }
 
                ret = account_disconnect();
 
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                }
                return ret;
        }
@@ -416,23 +417,23 @@ static int _account_insert_test_new(void)
        ret = account_set_auth_type( account, temp_int );
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        temp_int = -1;
-       printf("account_set_secret: Enter secret to be set \n");
+       ACCOUNT_SLOGD("account_set_secret: Enter secret to be set \n");
        if (scanf("%d", &temp_int) != 1) {
-               printf("scanf Failed !!!! \n");
+               ACCOUNT_SLOGD("scanf Failed !!!! \n");
                ret = account_destroy(account);
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                }
 
                ret = account_disconnect();
 
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                }
                return ret;
        }
@@ -440,23 +441,23 @@ static int _account_insert_test_new(void)
        ret = account_set_secret( account, temp_int );
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        temp_int = -1;
-       printf("account_set_sync_support: Enter sync support state \n");
+       ACCOUNT_SLOGD("account_set_sync_support: Enter sync support state \n");
        if (scanf("%d", &temp_int) != 1) {
-               printf("scanf Failed !!!! \n");
+               ACCOUNT_SLOGD("scanf Failed !!!! \n");
                ret = account_destroy(account);
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                }
 
                ret = account_disconnect();
 
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                }
                return ret;
        }
@@ -464,24 +465,24 @@ static int _account_insert_test_new(void)
        ret = account_set_sync_support( account, temp_int );
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        memset(temp, 0x00, sizeof(temp));
-       printf("account_set_source: Enter source to be set \n");
+       ACCOUNT_SLOGD("account_set_source: Enter source to be set \n");
        if (scanf("%s", temp) != 1) {
-               printf("scanf Failed !!!! \n");
+               ACCOUNT_SLOGD("scanf Failed !!!! \n");
                ret = account_destroy(account);
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                }
 
                ret = account_disconnect();
 
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                }
                return ret;
        }
@@ -492,27 +493,27 @@ static int _account_insert_test_new(void)
        for(i=0;i<USER_TXT_CNT;i++)
        {
                memset(temp, 0x00, sizeof(temp));
-               printf("account_set_user_text [%d]: Enter user text to be set \n", i);
+               ACCOUNT_SLOGD("account_set_user_text [%d]: Enter user text to be set \n", i);
                if (scanf("%s", temp) != 1) {
-                       printf("scanf Failed !!!! \n");
+                       ACCOUNT_SLOGD("scanf Failed !!!! \n");
                        ret = account_destroy(account);
                        if(ret != ACCOUNT_ERROR_NONE)
                        {
-                               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                        }
 
                        ret = account_disconnect();
 
                        if(ret != ACCOUNT_ERROR_NONE)
                        {
-                               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                        }
                        return ret;
                }
                ret = account_set_user_text(account, i, temp);
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p, i=%d\n", __LINE__, ret, account, i);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p, i=%d\n", __LINE__, ret, account, i);
                }
 
        }
@@ -520,27 +521,27 @@ static int _account_insert_test_new(void)
        for(i=0;i<USER_INT_CNT;i++)
        {
                temp_int = -1;
-               printf("account_set_user_int [%d]: Enter user int to be set \n", i);
+               ACCOUNT_SLOGD("account_set_user_int [%d]: Enter user int to be set \n", i);
                if (scanf("%d", &temp_int) != 1) {
-                       printf("scanf Failed !!!! \n");
+                       ACCOUNT_SLOGD("scanf Failed !!!! \n");
                        ret = account_destroy(account);
                        if(ret != ACCOUNT_ERROR_NONE)
                        {
-                               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                        }
 
                        ret = account_disconnect();
 
                        if(ret != ACCOUNT_ERROR_NONE)
                        {
-                               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                        }
                        return ret;
                }
                ret = account_set_user_int(account, i, temp_int);
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p, i=%d\n", __LINE__, ret, account, i);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p, i=%d\n", __LINE__, ret, account, i);
                }
        }
 
@@ -548,35 +549,35 @@ static int _account_insert_test_new(void)
        int cap_value = -1;
        int want_to_enter_more_cap = 1;
        while (want_to_enter_more_cap){
-               printf("account_set_capability: Enter capability key to set \n");
+               ACCOUNT_SLOGD("account_set_capability: Enter capability key to set \n");
                if (scanf("%d", &cap_key) != 1) {
-                               printf("Scanf Failed!!!\n");
+                               ACCOUNT_SLOGD("Scanf Failed!!!\n");
                                exit(0);
                }
-               printf("account_set_capability: Enter capability value to set \n");
+               ACCOUNT_SLOGD("account_set_capability: Enter capability value to set \n");
                if (scanf("%d", &cap_value) != 1 ) {
-                               printf("Scanf Failed!!!\n");
+                               ACCOUNT_SLOGD("Scanf Failed!!!\n");
                                exit(0);
                        }
                ret = account_set_capability(account, ACCOUNT_SUPPORTS_CAPABILITY_TIZEN_EMAIL, cap_value);
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                }
-               printf("account_set_capability: Want to set more capabilitiy key value then enter 1 else 0 \n");
+               ACCOUNT_SLOGD("account_set_capability: Want to set more capabilitiy key value then enter 1 else 0 \n");
                if (scanf("%d", &temp_int) != 1) {
-                       printf("scanf Failed !!!! \n");
+                       ACCOUNT_SLOGD("scanf Failed !!!! \n");
                        ret = account_destroy(account);
                        if(ret != ACCOUNT_ERROR_NONE)
                        {
-                               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                        }
 
                        ret = account_disconnect();
 
                        if(ret != ACCOUNT_ERROR_NONE)
                        {
-                               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                        }
                        return ret;
                }
@@ -589,17 +590,17 @@ static int _account_insert_test_new(void)
        ret = account_insert_to_db(account, &account_id);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                ret = account_destroy(account);
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                }
                ret = account_disconnect();
 
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                }
                return -1;
        }
@@ -607,14 +608,14 @@ static int _account_insert_test_new(void)
        ret = account_destroy(account);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_disconnect();
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        return account_id;
 }
@@ -626,62 +627,62 @@ static int _account_insert_test(void)
 
        account_h account = NULL;
 
-       printf("account_connect returns %d\n", ret);
+       ACCOUNT_SLOGD("account_connect returns %d\n", ret);
 
        ret = account_create(&account);
 
-       printf("account = %p\n", account);
+       ACCOUNT_SLOGD("account = %p\n", account);
 
        ret = account_set_user_name(account, "wy1115.lee");
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_display_name(account, "Wonyoung Lee");
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_domain_name(account, "Samsung electronics");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_email_address(account, "urusa77@gmail.com");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_package_name(account, "com.samsung.account");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_icon_path(account, "icon-path");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_access_token(account, "ACCESSTOKEN");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_auth_type( account, ACCOUNT_AUTH_TYPE_OAUTH );
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_secret( account, ACCOUNT_SECRECY_INVISIBLE);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_source(account, "URUSA inc.");
 
@@ -692,7 +693,7 @@ static int _account_insert_test(void)
                ret = account_set_user_text(account, i, "user txt");
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p, i=%d\n", __LINE__, ret, account, i);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p, i=%d\n", __LINE__, ret, account, i);
                }
 
        }
@@ -702,7 +703,7 @@ static int _account_insert_test(void)
                ret = account_set_user_int(account, i, 888);
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p, i=%d\n", __LINE__, ret, account, i);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p, i=%d\n", __LINE__, ret, account, i);
                }
        }
 
@@ -721,19 +722,19 @@ static int _account_insert_test(void)
        ret = account_insert_to_db(account, &account_id);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                return -1;
        }
 
        ret = account_destroy(account);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        account=NULL;
 
-       printf("account_connect returns %d\n", ret);
+       ACCOUNT_SLOGD("account_connect returns %d\n", ret);
 
        ret = account_create(&account);
 
@@ -745,13 +746,13 @@ static int _account_insert_test(void)
        ret = account_destroy(account);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
 
        account=NULL;
 
-       printf("account_connect returns %d\n", ret);
+       ACCOUNT_SLOGD("account_connect returns %d\n", ret);
 
        ret = account_create(&account);
 
@@ -760,7 +761,7 @@ static int _account_insert_test(void)
        ret = account_destroy(account);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        return account_id;
@@ -780,24 +781,24 @@ static int _account_update_test_new_by_user_name(char *user_name, char *package_
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_create(&account);
-       printf("account_set_user_name: Enter User Name to be set \n");
+       ACCOUNT_SLOGD("account_set_user_name: Enter User Name to be set \n");
        if (scanf("%s", temp) != 1) {
-               printf("scanf Failed !!!! \n");
+               ACCOUNT_SLOGD("scanf Failed !!!! \n");
                ret = account_destroy(account);
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                }
 
                ret = account_disconnect();
 
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                }
                return ret;
        }
@@ -806,24 +807,24 @@ static int _account_update_test_new_by_user_name(char *user_name, char *package_
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        memset(temp, 0x00, sizeof(temp));
 
-       printf("account_set_display_name: Enter display Name to be set \n");
+       ACCOUNT_SLOGD("account_set_display_name: Enter display Name to be set \n");
        if (scanf("%s", temp) != 1) {
-               printf("scanf Failed !!!! \n");
+               ACCOUNT_SLOGD("scanf Failed !!!! \n");
                ret = account_destroy(account);
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                }
 
                ret = account_disconnect();
 
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                }
                return ret;
        }
@@ -832,24 +833,24 @@ static int _account_update_test_new_by_user_name(char *user_name, char *package_
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        memset(temp, 0x00, sizeof(temp));
 
-       printf("account_set_domain_name: Enter domain Name to be set \n");
+       ACCOUNT_SLOGD("account_set_domain_name: Enter domain Name to be set \n");
        if (scanf("%s", temp) != 1) {
-               printf("scanf Failed !!!! \n");
+               ACCOUNT_SLOGD("scanf Failed !!!! \n");
                ret = account_destroy(account);
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                }
 
                ret = account_disconnect();
 
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                }
                return ret;
        }
@@ -857,49 +858,49 @@ static int _account_update_test_new_by_user_name(char *user_name, char *package_
        ret = account_set_domain_name(account, temp);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        memset(temp, 0x00, sizeof(temp));
 
-       printf("account_set_email_address: Enter email Name to be set \n");
+       ACCOUNT_SLOGD("account_set_email_address: Enter email Name to be set \n");
        if (scanf("%s", temp) != 1) {
-               printf("scanf Failed !!!! \n");
+               ACCOUNT_SLOGD("scanf Failed !!!! \n");
                ret = account_destroy(account);
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                }
 
                ret = account_disconnect();
 
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                }
                return ret;
        }
        ret = account_set_email_address(account, temp);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        memset(temp, 0x00, sizeof(temp));
 
-       printf("account_set_package_name: Enter package Name to be set \n");
+       ACCOUNT_SLOGD("account_set_package_name: Enter package Name to be set \n");
        if (scanf("%s", temp) != 1) {
-               printf("scanf Failed !!!! \n");
+               ACCOUNT_SLOGD("scanf Failed !!!! \n");
                ret = account_destroy(account);
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                }
 
                ret = account_disconnect();
 
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                }
                return ret;
        }
@@ -907,24 +908,24 @@ static int _account_update_test_new_by_user_name(char *user_name, char *package_
        ret = account_set_package_name(account, temp);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        memset(temp, 0x00, sizeof(temp));
 
-       printf("account_set_icon_path: Enter icon path to be set \n");
+       ACCOUNT_SLOGD("account_set_icon_path: Enter icon path to be set \n");
        if (scanf("%s", temp) != 1) {
-               printf("scanf Failed !!!! \n");
+               ACCOUNT_SLOGD("scanf Failed !!!! \n");
                ret = account_destroy(account);
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                }
 
                ret = account_disconnect();
 
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                }
                return ret;
        }
@@ -932,24 +933,24 @@ static int _account_update_test_new_by_user_name(char *user_name, char *package_
        ret = account_set_icon_path(account, temp);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        memset(temp, 0x00, sizeof(temp));
 
-       printf("account_set_access_token: Enter access token to be set \n");
+       ACCOUNT_SLOGD("account_set_access_token: Enter access token to be set \n");
        if (scanf("%s", temp) != 1) {
-               printf("scanf Failed !!!! \n");
+               ACCOUNT_SLOGD("scanf Failed !!!! \n");
                ret = account_destroy(account);
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                }
 
                ret = account_disconnect();
 
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                }
                return ret;
        }
@@ -957,24 +958,24 @@ static int _account_update_test_new_by_user_name(char *user_name, char *package_
        ret = account_set_access_token(account, temp);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        memset(temp, 0x00, sizeof(temp));
 
-       printf("account_set_auth_type: Enter auth type to be set \n");
+       ACCOUNT_SLOGD("account_set_auth_type: Enter auth type to be set \n");
        if (scanf("%d", &temp_int) != 1) {
-               printf("scanf Failed !!!! \n");
+               ACCOUNT_SLOGD("scanf Failed !!!! \n");
                ret = account_destroy(account);
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                }
 
                ret = account_disconnect();
 
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                }
                return ret;
        }
@@ -982,23 +983,23 @@ static int _account_update_test_new_by_user_name(char *user_name, char *package_
        ret = account_set_auth_type( account, temp_int );
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        temp_int = -1;
-       printf("account_set_secret: Enter secret to be set \n");
+       ACCOUNT_SLOGD("account_set_secret: Enter secret to be set \n");
        if (scanf("%d", &temp_int) != 1) {
-               printf("scanf Failed !!!! \n");
+               ACCOUNT_SLOGD("scanf Failed !!!! \n");
                ret = account_destroy(account);
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                }
 
                ret = account_disconnect();
 
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                }
                return ret;
        }
@@ -1006,24 +1007,24 @@ static int _account_update_test_new_by_user_name(char *user_name, char *package_
        ret = account_set_secret( account, temp_int );
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        temp_int = -1;
-       printf("account_set_sync_support: Enter sync support state \n");
+       ACCOUNT_SLOGD("account_set_sync_support: Enter sync support state \n");
        if (scanf("%d", &temp_int) != 1) {
-               printf("scanf Failed !!!! \n");
+               ACCOUNT_SLOGD("scanf Failed !!!! \n");
                ret = account_destroy(account);
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                }
 
                ret = account_disconnect();
 
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                }
                return ret;
        }
@@ -1031,25 +1032,25 @@ static int _account_update_test_new_by_user_name(char *user_name, char *package_
        ret = account_set_sync_support( account, temp_int );
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        memset(temp, 0x00, sizeof(temp));
 
-       printf("account_set_source: Enter source to be set \n");
+       ACCOUNT_SLOGD("account_set_source: Enter source to be set \n");
        if (scanf("%s", temp) != 1) {
-               printf("scanf Failed !!!! \n");
+               ACCOUNT_SLOGD("scanf Failed !!!! \n");
                ret = account_destroy(account);
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                }
 
                ret = account_disconnect();
 
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                }
                return ret;
        }
@@ -1061,27 +1062,27 @@ static int _account_update_test_new_by_user_name(char *user_name, char *package_
        {
                memset(temp, 0x00, sizeof(temp));
 
-               printf("account_set_user_text [%d]: Enter user text to be set \n", i);
+               ACCOUNT_SLOGD("account_set_user_text [%d]: Enter user text to be set \n", i);
                if (scanf("%s", temp) != 1) {
-                       printf("scanf Failed !!!! \n");
+                       ACCOUNT_SLOGD("scanf Failed !!!! \n");
                        ret = account_destroy(account);
                        if(ret != ACCOUNT_ERROR_NONE)
                        {
-                               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                        }
 
                        ret = account_disconnect();
 
                        if(ret != ACCOUNT_ERROR_NONE)
                        {
-                               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                        }
                        return ret;
                }
                ret = account_set_user_text(account, i, temp);
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p, i=%d\n", __LINE__, ret, account, i);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p, i=%d\n", __LINE__, ret, account, i);
                }
 
        }
@@ -1089,27 +1090,27 @@ static int _account_update_test_new_by_user_name(char *user_name, char *package_
        for(i=0;i<USER_INT_CNT;i++)
        {
                temp_int = -1;
-               printf("account_set_user_int [%d]: Enter user int to be set \n", i);
+               ACCOUNT_SLOGD("account_set_user_int [%d]: Enter user int to be set \n", i);
                if (scanf("%d", &temp_int) != 1) {
-                       printf("scanf Failed !!!! \n");
+                       ACCOUNT_SLOGD("scanf Failed !!!! \n");
                        ret = account_destroy(account);
                        if(ret != ACCOUNT_ERROR_NONE)
                        {
-                               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                        }
 
                        ret = account_disconnect();
 
                        if(ret != ACCOUNT_ERROR_NONE)
                        {
-                               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                        }
                        return ret;
                }
                ret = account_set_user_int(account, i, temp_int);
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p, i=%d\n", __LINE__, ret, account, i);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p, i=%d\n", __LINE__, ret, account, i);
                }
        }
 
@@ -1117,35 +1118,35 @@ static int _account_update_test_new_by_user_name(char *user_name, char *package_
        int cap_value = -1;
        int want_to_enter_more_cap = 1;
        while (want_to_enter_more_cap){
-               printf("account_set_capability: Enter capability key to set \n");
+               ACCOUNT_SLOGD("account_set_capability: Enter capability key to set \n");
                if (scanf("%d", &cap_key) != 1 ) {
-                       printf("Scanf Failed!!!\n");
+                       ACCOUNT_SLOGD("Scanf Failed!!!\n");
                        exit(0);
                }
-               printf("account_set_capability: Enter capability value to set \n");
+               ACCOUNT_SLOGD("account_set_capability: Enter capability value to set \n");
                if (scanf("%d", &cap_value) != 1) {
-                       printf("Scanf Failed!!!\n");
+                       ACCOUNT_SLOGD("Scanf Failed!!!\n");
                        exit(0);
                }
                ret = account_set_capability(account, ACCOUNT_SUPPORTS_CAPABILITY_TIZEN_EMAIL, cap_value);
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                }
-               printf("account_set_capability: Want to set more capabilitiy key value then enter 1 else 0 \n");
+               ACCOUNT_SLOGD("account_set_capability: Want to set more capabilitiy key value then enter 1 else 0 \n");
                if (scanf("%d", &temp_int) != 1) {
-                       printf("scanf Failed !!!! \n");
+                       ACCOUNT_SLOGD("scanf Failed !!!! \n");
                        ret = account_destroy(account);
                        if(ret != ACCOUNT_ERROR_NONE)
                        {
-                               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                        }
 
                        ret = account_disconnect();
 
                        if(ret != ACCOUNT_ERROR_NONE)
                        {
-                               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                        }
                        return ret;
                }
@@ -1161,19 +1162,19 @@ static int _account_update_test_new_by_user_name(char *user_name, char *package_
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_destroy(account);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_disconnect();
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        return ret;
@@ -1195,25 +1196,25 @@ static int _account_update_test_new(int account_id)
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
 
        ret = account_create(&account);
-       printf("account_set_user_name: Enter User Name to be set \n");
+       ACCOUNT_SLOGD("account_set_user_name: Enter User Name to be set \n");
        if (scanf("%s", temp) != 1) {
-               printf("scanf Failed !!!! \n");
+               ACCOUNT_SLOGD("scanf Failed !!!! \n");
                ret = account_destroy(account);
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                }
 
                ret = account_disconnect();
 
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                }
                return ret;
        }
@@ -1222,24 +1223,24 @@ static int _account_update_test_new(int account_id)
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        memset(temp, 0x00, sizeof(temp));
 
-       printf("account_set_display_name: Enter display Name to be set \n");
+       ACCOUNT_SLOGD("account_set_display_name: Enter display Name to be set \n");
        if (scanf("%s", temp) != 1) {
-               printf("scanf Failed !!!! \n");
+               ACCOUNT_SLOGD("scanf Failed !!!! \n");
                ret = account_destroy(account);
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                }
 
                ret = account_disconnect();
 
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                }
                return ret;
        }
@@ -1248,23 +1249,23 @@ static int _account_update_test_new(int account_id)
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        memset(temp, 0x00, sizeof(temp));
-       printf("account_set_domain_name: Enter domain Name to be set \n");
+       ACCOUNT_SLOGD("account_set_domain_name: Enter domain Name to be set \n");
        if (scanf("%s", temp) != 1) {
-               printf("scanf Failed !!!! \n");
+               ACCOUNT_SLOGD("scanf Failed !!!! \n");
                ret = account_destroy(account);
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                }
 
                ret = account_disconnect();
 
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                }
                return ret;
        }
@@ -1272,48 +1273,48 @@ static int _account_update_test_new(int account_id)
        ret = account_set_domain_name(account, temp);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        memset(temp, 0x00, sizeof(temp));
-       printf("account_set_email_address: Enter email Name to be set \n");
+       ACCOUNT_SLOGD("account_set_email_address: Enter email Name to be set \n");
        if (scanf("%s", temp) != 1) {
-               printf("scanf Failed !!!! \n");
+               ACCOUNT_SLOGD("scanf Failed !!!! \n");
                ret = account_destroy(account);
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                }
 
                ret = account_disconnect();
 
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                }
                return ret;
        }
        ret = account_set_email_address(account, temp);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        memset(temp, 0x00, sizeof(temp));
 
-       printf("account_set_package_name: Enter package Name to be set \n");
+       ACCOUNT_SLOGD("account_set_package_name: Enter package Name to be set \n");
        if (scanf("%s", temp) != 1) {
-               printf("scanf Failed !!!! \n");
+               ACCOUNT_SLOGD("scanf Failed !!!! \n");
                ret = account_destroy(account);
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                }
 
                ret = account_disconnect();
 
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                }
                return ret;
        }
@@ -1321,24 +1322,24 @@ static int _account_update_test_new(int account_id)
        ret = account_set_package_name(account, temp);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        memset(temp, 0x00, sizeof(temp));
 
-       printf("account_set_icon_path: Enter icon path to be set \n");
+       ACCOUNT_SLOGD("account_set_icon_path: Enter icon path to be set \n");
        if (scanf("%s", temp) != 1) {
-               printf("scanf Failed !!!! \n");
+               ACCOUNT_SLOGD("scanf Failed !!!! \n");
                ret = account_destroy(account);
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                }
 
                ret = account_disconnect();
 
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                }
                return ret;
        }
@@ -1346,24 +1347,24 @@ static int _account_update_test_new(int account_id)
        ret = account_set_icon_path(account, temp);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        memset(temp, 0x00, sizeof(temp));
 
-       printf("account_set_access_token: Enter access token to be set \n");
+       ACCOUNT_SLOGD("account_set_access_token: Enter access token to be set \n");
        if (scanf("%s", temp) != 1) {
-               printf("scanf Failed !!!! \n");
+               ACCOUNT_SLOGD("scanf Failed !!!! \n");
                ret = account_destroy(account);
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                }
 
                ret = account_disconnect();
 
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                }
                return ret;
        }
@@ -1371,24 +1372,24 @@ static int _account_update_test_new(int account_id)
        ret = account_set_access_token(account, temp);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        memset(temp, 0x00, sizeof(temp));
 
-       printf("account_set_auth_type: Enter auth type to be set \n");
+       ACCOUNT_SLOGD("account_set_auth_type: Enter auth type to be set \n");
        if (scanf("%d", &temp_int) != 1) {
-               printf("scanf Failed !!!! \n");
+               ACCOUNT_SLOGD("scanf Failed !!!! \n");
                ret = account_destroy(account);
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                }
 
                ret = account_disconnect();
 
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                }
                return ret;
        }
@@ -1396,23 +1397,23 @@ static int _account_update_test_new(int account_id)
        ret = account_set_auth_type( account, temp_int );
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        temp_int = -1;
-       printf("account_set_secret: Enter secret to be set \n");
+       ACCOUNT_SLOGD("account_set_secret: Enter secret to be set \n");
        if (scanf("%d", &temp_int) != 1) {
-               printf("scanf Failed !!!! \n");
+               ACCOUNT_SLOGD("scanf Failed !!!! \n");
                ret = account_destroy(account);
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                }
 
                ret = account_disconnect();
 
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                }
                return ret;
        }
@@ -1420,24 +1421,24 @@ static int _account_update_test_new(int account_id)
        ret = account_set_secret( account, temp_int );
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        temp_int = -1;
-       printf("account_set_sync_support: Enter sync support state \n");
+       ACCOUNT_SLOGD("account_set_sync_support: Enter sync support state \n");
        if (scanf("%d", &temp_int) != 1) {
-               printf("scanf Failed !!!! \n");
+               ACCOUNT_SLOGD("scanf Failed !!!! \n");
                ret = account_destroy(account);
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                }
 
                ret = account_disconnect();
 
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                }
                return ret;
        }
@@ -1445,25 +1446,25 @@ static int _account_update_test_new(int account_id)
        ret = account_set_sync_support( account, temp_int );
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        memset(temp, 0x00, sizeof(temp));
 
-       printf("account_set_source: Enter source to be set \n");
+       ACCOUNT_SLOGD("account_set_source: Enter source to be set \n");
        if (scanf("%s", temp) != 1) {
-               printf("scanf Failed !!!! \n");
+               ACCOUNT_SLOGD("scanf Failed !!!! \n");
                ret = account_destroy(account);
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                }
 
                ret = account_disconnect();
 
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                }
                return ret;
        }
@@ -1475,27 +1476,27 @@ static int _account_update_test_new(int account_id)
        {
                memset(temp, 0x00, sizeof(temp));
 
-               printf("account_set_user_text [%d]: Enter user text to be set \n", i);
+               ACCOUNT_SLOGD("account_set_user_text [%d]: Enter user text to be set \n", i);
                if (scanf("%s", temp) != 1) {
-                       printf("scanf Failed !!!! \n");
+                       ACCOUNT_SLOGD("scanf Failed !!!! \n");
                        ret = account_destroy(account);
                        if(ret != ACCOUNT_ERROR_NONE)
                        {
-                               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                        }
 
                        ret = account_disconnect();
 
                        if(ret != ACCOUNT_ERROR_NONE)
                        {
-                               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                        }
                        return ret;
                }
                ret = account_set_user_text(account, i, temp);
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p, i=%d\n", __LINE__, ret, account, i);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p, i=%d\n", __LINE__, ret, account, i);
                }
 
        }
@@ -1503,27 +1504,27 @@ static int _account_update_test_new(int account_id)
        for(i=0;i<USER_INT_CNT;i++)
        {
                temp_int = -1;
-               printf("account_set_user_int [%d]: Enter user int to be set \n", i);
+               ACCOUNT_SLOGD("account_set_user_int [%d]: Enter user int to be set \n", i);
                if (scanf("%d", &temp_int) != 1) {
-                       printf("scanf Failed !!!! \n");
+                       ACCOUNT_SLOGD("scanf Failed !!!! \n");
                        ret = account_destroy(account);
                        if(ret != ACCOUNT_ERROR_NONE)
                        {
-                               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                        }
 
                        ret = account_disconnect();
 
                        if(ret != ACCOUNT_ERROR_NONE)
                        {
-                               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                        }
                        return ret;
                }
                ret = account_set_user_int(account, i, temp_int);
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p, i=%d\n", __LINE__, ret, account, i);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p, i=%d\n", __LINE__, ret, account, i);
                }
        }
 
@@ -1531,35 +1532,35 @@ static int _account_update_test_new(int account_id)
        int cap_value = -1;
        int want_to_enter_more_cap = 1;
        while (want_to_enter_more_cap){
-               printf("account_set_capability: Enter capability key to set \n");
+               ACCOUNT_SLOGD("account_set_capability: Enter capability key to set \n");
                if (scanf("%d", &cap_key) != 1) {
-                       printf("Scanf Failed!!!\n");
+                       ACCOUNT_SLOGD("Scanf Failed!!!\n");
                        exit(0);
                }
-               printf("account_set_capability: Enter capability value to set \n");
+               ACCOUNT_SLOGD("account_set_capability: Enter capability value to set \n");
                if (scanf("%d", &cap_value) != 1) {
-                       printf("Scanf Failed!!!\n");
+                       ACCOUNT_SLOGD("Scanf Failed!!!\n");
                        exit(0);
                }
                ret = account_set_capability(account, ACCOUNT_SUPPORTS_CAPABILITY_TIZEN_EMAIL, cap_value);
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                }
-               printf("account_set_capability: Want to set more capabilitiy key value then enter 1 else 0 \n");
+               ACCOUNT_SLOGD("account_set_capability: Want to set more capabilitiy key value then enter 1 else 0 \n");
                if (scanf("%d", &temp_int) != 1) {
-                       printf("scanf Failed !!!! \n");
+                       ACCOUNT_SLOGD("scanf Failed !!!! \n");
                        ret = account_destroy(account);
                        if(ret != ACCOUNT_ERROR_NONE)
                        {
-                               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                        }
 
                        ret = account_disconnect();
 
                        if(ret != ACCOUNT_ERROR_NONE)
                        {
-                               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+                               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
                        }
                        return ret;
                }
@@ -1573,20 +1574,20 @@ static int _account_update_test_new(int account_id)
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_destroy(account);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_disconnect();
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        return ret;
@@ -1605,52 +1606,52 @@ static int _account_update_test(int account_id)
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_display_name(account, "updated-Wonyoung Lee");
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_domain_name(account, "updated-Samsung Facebook");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_email_address(account, "updated-urusa77@gmail.com");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_package_name(account, "updated-com.samsung.account");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_icon_path(account, "updated-icon-path");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_access_token(account, "updated-ACCESSTOKEN");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_auth_type( account, ACCOUNT_AUTH_TYPE_OAUTH );
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_secret( account, ACCOUNT_SECRECY_INVISIBLE);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_source(account, "updated-URUSA inc.");
 
@@ -1661,7 +1662,7 @@ static int _account_update_test(int account_id)
                ret = account_set_user_text(account, i, "updated-user txt");
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p, i=%d\n", __LINE__, ret, account, i);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p, i=%d\n", __LINE__, ret, account, i);
                }
 
        }
@@ -1671,7 +1672,7 @@ static int _account_update_test(int account_id)
                ret = account_set_user_int(account, i, 111);
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p, i=%d\n", __LINE__, ret, account, i);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p, i=%d\n", __LINE__, ret, account, i);
                }
        }
 
@@ -1687,13 +1688,13 @@ static int _account_update_test(int account_id)
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_destroy(account);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        return ret;
@@ -1712,52 +1713,52 @@ static int _account_update_test_by_username()
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_display_name(account, "usernamed-Wonyoung Lee");
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_domain_name(account, "usernamed-Samsung Facebook");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_email_address(account, "usernamed-urusa77@gmail.com");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_package_name(account, "usernamed-com.samsung.account");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_icon_path(account, "usernamed-icon-path");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_access_token(account, "usernamed-ACCESSTOKEN");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_auth_type( account, ACCOUNT_AUTH_TYPE_OAUTH );
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_secret( account, ACCOUNT_SECRECY_INVISIBLE);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_source(account, "updated-URUSA inc.");
 
@@ -1768,7 +1769,7 @@ static int _account_update_test_by_username()
                ret = account_set_user_text(account, i, "usernamed-user txt");
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p, i=%d\n", __LINE__, ret, account, i);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p, i=%d\n", __LINE__, ret, account, i);
                }
 
        }
@@ -1778,7 +1779,7 @@ static int _account_update_test_by_username()
                ret = account_set_user_int(account, i, 111);
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p, i=%d\n", __LINE__, ret, account, i);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p, i=%d\n", __LINE__, ret, account, i);
                }
        }
 
@@ -1794,13 +1795,13 @@ static int _account_update_test_by_username()
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_destroy(account);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        return ret;
@@ -1833,7 +1834,7 @@ static int _account_test_capability()
 
        binding_buf[binding_buf_index++]='(';
 
-       printf("(%d)Binding buf = %s\n", __LINE__,binding_buf);
+       ACCOUNT_SLOGD("(%d)Binding buf = %s\n", __LINE__,binding_buf);
 
        int i;
 
@@ -1843,20 +1844,20 @@ static int _account_test_capability()
                binding_buf[binding_buf_index++]='?';
                if(i != capability_count -1)
                        binding_buf[binding_buf_index++]=',';
-               printf("(%d)Binding buf = %s\n", __LINE__,binding_buf);
+               ACCOUNT_SLOGD("(%d)Binding buf = %s\n", __LINE__,binding_buf);
        }
 
        binding_buf[binding_buf_index]=')';
 
-       printf("(%d)Binding buf = %s\n", __LINE__,binding_buf);
+       ACCOUNT_SLOGD("(%d)Binding buf = %s\n", __LINE__,binding_buf);
 
-       printf("Length %d\n", glist_len);
+       ACCOUNT_SLOGD("Length %d\n", glist_len);
 
        for (iter = list; iter != NULL; iter = g_slist_next(iter))
        {
                char* capa;
                capa = (char *)iter->data;
-               printf("%s\n", (char *)iter->data);
+               ACCOUNT_SLOGD("%s\n", (char *)iter->data);
                g_free(capa);
        }
 
@@ -1876,37 +1877,37 @@ static int utc1_account_insert()
        ret = account_connect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        ret = account_create(&account);
 
-       printf("account = %p, ret = %d \n", account, ret);
+       ACCOUNT_SLOGD("account = %p, ret = %d \n", account, ret);
 
        ret = account_insert_to_db(account, &account_id);
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
        }
        else
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_destroy(account);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_disconnect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
        return account_id;
 }
@@ -1920,46 +1921,46 @@ static int utc2_account_insert()
        ret = account_connect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        ret = account_create(&account);
 
-       printf("account = %p, ret = %d \n", account, ret);
+       ACCOUNT_SLOGD("account = %p, ret = %d \n", account, ret);
 
        ret = account_set_user_name(account, NULL);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_insert_to_db(account, &account_id);
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_destroy(account);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_disconnect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
        return account_id;
 }
@@ -1976,12 +1977,12 @@ static int utc3_account_insert()
        ret = account_connect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        ret = account_create(&account);
 
-       printf("account = %p, ret = %d \n", account, ret);
+       ACCOUNT_SLOGD("account = %p, ret = %d \n", account, ret);
 
        ret = account_set_user_name(account, "11111111111111111111111111111111111 \
                2222222222222222222222222222222222222222222222222 \
@@ -2004,36 +2005,36 @@ static int utc3_account_insert()
                999999999999999999999999999999999999999999999999999999999999999999999999999999999999999999");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_insert_to_db(account, &account_id);
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_destroy(account);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_disconnect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
        return account_id;
 }
@@ -2047,58 +2048,58 @@ static int utc4_account_insert()
        ret = account_connect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        ret = account_create(&account);
 
-       printf("account = %p, ret = %d \n", account, ret);
+       ACCOUNT_SLOGD("account = %p, ret = %d \n", account, ret);
 
        ret = account_set_user_name(account, "tarun.kr");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_display_name(account, NULL);
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_insert_to_db(account, &account_id);
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_destroy(account);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_disconnect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
        return account_id;
 }
@@ -2112,67 +2113,67 @@ static int utc5_account_insert()
        ret = account_connect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        ret = account_create(&account);
 
-       printf("account = %p, ret = %d \n", account, ret);
+       ACCOUNT_SLOGD("account = %p, ret = %d \n", account, ret);
 
        ret = account_set_user_name(account, "tarun.kr");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_display_name(account, "tarun kumar");
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_domain_name(account, NULL);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_insert_to_db(account, &account_id);
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_destroy(account);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_disconnect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
        return account_id;
 }
@@ -2186,67 +2187,67 @@ static int utc6_account_insert()
        ret = account_connect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        ret = account_create(&account);
 
-       printf("account = %p, ret = %d \n", account, ret);
+       ACCOUNT_SLOGD("account = %p, ret = %d \n", account, ret);
 
        ret = account_set_user_name(account, "tarun.kr");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_display_name(account, "tarun kumar");
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_domain_name(account, "Samsung");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_insert_to_db(account, &account_id);
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_destroy(account);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_disconnect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
        return account_id;
 }
@@ -2260,78 +2261,78 @@ static int utc7_account_insert()
        ret = account_connect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        ret = account_create(&account);
 
-       printf("account = %p, ret = %d \n", account, ret);
+       ACCOUNT_SLOGD("account = %p, ret = %d \n", account, ret);
 
        ret = account_set_user_name(account, "tarun.kr");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_display_name(account, "tarun kumar");
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_domain_name(account, "Samsung");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_email_address(account, NULL);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_insert_to_db(account, &account_id);
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_destroy(account);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_disconnect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
        return account_id;
 }
@@ -2345,78 +2346,78 @@ static int utc8_account_insert()
        ret = account_connect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        ret = account_create(&account);
 
-       printf("account = %p, ret = %d \n", account, ret);
+       ACCOUNT_SLOGD("account = %p, ret = %d \n", account, ret);
 
        ret = account_set_user_name(account, "tarun.kr");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_display_name(account, "tarun kumar");
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_domain_name(account, "Samsung");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_email_address(account, "tarun.kr@samsung.com");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_insert_to_db(account, &account_id);
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_destroy(account);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_disconnect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
        return account_id;
 }
@@ -2430,87 +2431,87 @@ static int utc9_account_insert()
        ret = account_connect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        ret = account_create(&account);
 
-       printf("account = %p, ret = %d \n", account, ret);
+       ACCOUNT_SLOGD("account = %p, ret = %d \n", account, ret);
 
        ret = account_set_user_name(account, "tarun.kr");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_display_name(account, "tarun kumar");
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_domain_name(account, "Samsung");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_email_address(account, "tarun.kr@samsung.com");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_package_name(account, NULL);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_insert_to_db(account, &account_id);
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_destroy(account);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_disconnect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
        return account_id;
 }
@@ -2524,87 +2525,87 @@ static int utc10_account_insert()
        ret = account_connect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        ret = account_create(&account);
 
-       printf("account = %p, ret = %d \n", account, ret);
+       ACCOUNT_SLOGD("account = %p, ret = %d \n", account, ret);
 
        ret = account_set_user_name(account, "tarun.kr");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_display_name(account, "tarun kumar");
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_domain_name(account, "Samsung");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_email_address(account, "tarun.kr@samsung.com");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_package_name(account, "com.samsung.accounts");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_insert_to_db(account, &account_id);
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_destroy(account);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_disconnect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
        return account_id;
 }
@@ -2618,98 +2619,98 @@ static int utc11_account_insert()
        ret = account_connect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        ret = account_create(&account);
 
-       printf("account = %p, ret = %d \n", account, ret);
+       ACCOUNT_SLOGD("account = %p, ret = %d \n", account, ret);
 
        ret = account_set_user_name(account, "tarun.kr");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_display_name(account, "tarun kumar");
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_domain_name(account, "Samsung");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_email_address(account, "tarun.kr@samsung.com");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_package_name(account, "com.samsung.accounts");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_icon_path(account, NULL);
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_insert_to_db(account, &account_id);
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_destroy(account);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_disconnect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
        return account_id;
 }
@@ -2723,98 +2724,98 @@ static int utc12_account_insert()
        ret = account_connect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        ret = account_create(&account);
 
-       printf("account = %p, ret = %d \n", account, ret);
+       ACCOUNT_SLOGD("account = %p, ret = %d \n", account, ret);
 
        ret = account_set_user_name(account, "tarun.kr");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_display_name(account, "tarun kumar");
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_domain_name(account, "Samsung");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_email_address(account, "tarun.kr@samsung.com");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_package_name(account, "com.samsung.accounts");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_icon_path(account, "/test/test.jpg");
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_insert_to_db(account, &account_id);
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_destroy(account);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_disconnect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
        return account_id;
 }
@@ -2828,83 +2829,83 @@ static int utc13_account_insert()
        ret = account_connect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        ret = account_create(&account);
 
-       printf("account = %p, ret = %d \n", account, ret);
+       ACCOUNT_SLOGD("account = %p, ret = %d \n", account, ret);
 
        ret = account_set_user_name(account, "tarun.kr");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_display_name(account, "tarun kumar");
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_domain_name(account, "Samsung");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_email_address(account, "tarun.kr@samsung.com");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_package_name(account, "com.samsung.accounts");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_icon_path(account, "/test/test.jpg");
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_access_token(account, NULL);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
 
@@ -2912,26 +2913,26 @@ static int utc13_account_insert()
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_destroy(account);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_disconnect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
        return account_id;
 }
@@ -2945,83 +2946,83 @@ static int utc14_account_insert()
        ret = account_connect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        ret = account_create(&account);
 
-       printf("account = %p, ret = %d \n", account, ret);
+       ACCOUNT_SLOGD("account = %p, ret = %d \n", account, ret);
 
        ret = account_set_user_name(account, "tarun.kr");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_display_name(account, "tarun kumar");
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_domain_name(account, "Samsung");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_email_address(account, "tarun.kr@samsung.com");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_package_name(account, "com.samsung.accounts");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_icon_path(account, "/test/test.jpg");
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_access_token(account, "xxxx/yyyy/zzzz/-&abc");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
 
@@ -3029,26 +3030,26 @@ static int utc14_account_insert()
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_destroy(account);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_disconnect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
        return account_id;
 }
@@ -3062,127 +3063,127 @@ static int utc15_account_insert()
        ret = account_connect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        ret = account_create(&account);
 
-       printf("account = %p, ret = %d \n", account, ret);
+       ACCOUNT_SLOGD("account = %p, ret = %d \n", account, ret);
 
        ret = account_set_user_name(account, "tarun.kr");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_display_name(account, "tarun kumar");
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_domain_name(account, "Samsung");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_email_address(account, "tarun.kr@samsung.com");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_package_name(account, "com.samsung.accounts");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_icon_path(account, "/test/test.jpg");
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_access_token(account, "xxxx/yyyy/zzzz/-&abc");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_auth_type( account, ACCOUNT_AUTH_TYPE_OAUTH );
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_secret( account, ACCOUNT_SECRECY_INVISIBLE);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_insert_to_db(account, &account_id);
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_destroy(account);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_disconnect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
        return account_id;
 }
@@ -3196,127 +3197,127 @@ static int utc16_account_insert()
        ret = account_connect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        ret = account_create(&account);
 
-       printf("account = %p, ret = %d \n", account, ret);
+       ACCOUNT_SLOGD("account = %p, ret = %d \n", account, ret);
 
        ret = account_set_user_name(account, "tarun.kr");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_display_name(account, "tarun kumar");
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_domain_name(account, "Samsung");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_email_address(account, "tarun.kr@samsung.com");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_package_name(account, "com.samsung.accounts");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_icon_path(account, "/test/test.jpg");
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_access_token(account, "xxxx/yyyy/zzzz/-&abc");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_auth_type( account, ACCOUNT_AUTH_TYPE_OAUTH );
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_secret( account, ACCOUNT_SECRECY_INVISIBLE);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_insert_to_db(account, &account_id);
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_destroy(account);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_disconnect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
        return account_id;
 }
@@ -3330,137 +3331,137 @@ static int utc17_account_insert()
        ret = account_connect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        ret = account_create(&account);
 
-       printf("account = %p, ret = %d \n", account, ret);
+       ACCOUNT_SLOGD("account = %p, ret = %d \n", account, ret);
 
        ret = account_set_user_name(account, "tarun.kr");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_display_name(account, "tarun kumar");
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_domain_name(account, "Samsung");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_email_address(account, "tarun.kr@samsung.com");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_package_name(account, "com.samsung.accounts");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_icon_path(account, "/test/test.jpg");
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_access_token(account, "xxxx/yyyy/zzzz/-&abc");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_auth_type( account, ACCOUNT_AUTH_TYPE_OAUTH );
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_secret( account, ACCOUNT_SECRECY_INVISIBLE);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_source(account, NULL);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_insert_to_db(account, &account_id);
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_destroy(account);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_disconnect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
        return account_id;
 }
@@ -3474,137 +3475,137 @@ static int utc18_account_insert()
        ret = account_connect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        ret = account_create(&account);
 
-       printf("account = %p, ret = %d \n", account, ret);
+       ACCOUNT_SLOGD("account = %p, ret = %d \n", account, ret);
 
        ret = account_set_user_name(account, "tarun.kr");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_display_name(account, "tarun kumar");
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_domain_name(account, "Samsung");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_email_address(account, "tarun.kr@samsung.com");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_package_name(account, "com.samsung.accounts");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_icon_path(account, "/test/test.jpg");
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_access_token(account, "xxxx/yyyy/zzzz/-&abc");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_auth_type( account, ACCOUNT_AUTH_TYPE_OAUTH );
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_secret( account, ACCOUNT_SECRECY_INVISIBLE);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_source(account, "URUSA inc.");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_insert_to_db(account, &account_id);
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_destroy(account);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_disconnect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
        return account_id;
 }
@@ -3618,112 +3619,112 @@ static int utc19_account_insert()
        ret = account_connect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        ret = account_create(&account);
 
-       printf("account = %p, ret = %d \n", account, ret);
+       ACCOUNT_SLOGD("account = %p, ret = %d \n", account, ret);
 
        ret = account_set_user_name(account, "tarun.kr");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_display_name(account, "tarun kumar");
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_domain_name(account, "Samsung");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_email_address(account, "tarun.kr@samsung.com");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_package_name(account, "com.samsung.accounts");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_icon_path(account, "/test/test.jpg");
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_access_token(account, "xxxx/yyyy/zzzz/-&abc");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_auth_type( account, ACCOUNT_AUTH_TYPE_OAUTH );
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_secret( account, ACCOUNT_SECRECY_INVISIBLE);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_source(account, "URUSA inc.");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        int i;
@@ -3733,7 +3734,7 @@ static int utc19_account_insert()
                ret = account_set_user_text(account, i, NULL);
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p, i=%d\n", __LINE__, ret, account, i);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p, i=%d\n", __LINE__, ret, account, i);
                }
 
        }
@@ -3741,26 +3742,26 @@ static int utc19_account_insert()
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
        }
        else
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_destroy(account);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_disconnect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
        return account_id;
 }
@@ -3774,112 +3775,112 @@ static int utc20_account_insert()
        ret = account_connect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        ret = account_create(&account);
 
-       printf("account = %p, ret = %d \n", account, ret);
+       ACCOUNT_SLOGD("account = %p, ret = %d \n", account, ret);
 
        ret = account_set_user_name(account, "tarun.kr");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
        }
        else
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_display_name(account, "tarun kumar");
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_domain_name(account, "Samsung");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_email_address(account, "tarun.kr@samsung.com");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_package_name(account, "com.samsung.accounts");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_icon_path(account, "/test/test.jpg");
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_access_token(account, "xxxx/yyyy/zzzz/-&abc");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_auth_type( account, ACCOUNT_AUTH_TYPE_OAUTH );
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_secret( account, ACCOUNT_SECRECY_INVISIBLE);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_source(account, "URUSA inc.");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        int i;
@@ -3889,7 +3890,7 @@ static int utc20_account_insert()
                ret = account_set_user_text(account, i, "user txt");
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account-else loop] ret = %d, account=%p, i=%d\n", __LINE__, ret, account, i);
+                       ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p, i=%d\n", __LINE__, ret, account, i);
                }
 
        }
@@ -3897,26 +3898,26 @@ static int utc20_account_insert()
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_destroy(account);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_disconnect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
        return account_id;
 }
@@ -3930,112 +3931,112 @@ static int utc21_account_insert()
        ret = account_connect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        ret = account_create(&account);
 
-       printf("account = %p, ret = %d \n", account, ret);
+       ACCOUNT_SLOGD("account = %p, ret = %d \n", account, ret);
 
        ret = account_set_user_name(account, "tarun.kr");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_display_name(account, "tarun kumar");
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_domain_name(account, "Samsung");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_email_address(account, "tarun.kr@samsung.com");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_package_name(account, "com.samsung.accounts");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_icon_path(account, "/test/test.jpg");
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_access_token(account, "xxxx/yyyy/zzzz/-&abc");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_auth_type( account, ACCOUNT_AUTH_TYPE_OAUTH );
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_secret( account, ACCOUNT_SECRECY_INVISIBLE);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_source(account, "URUSA inc.");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        int i;
@@ -4045,7 +4046,7 @@ static int utc21_account_insert()
                ret = account_set_user_text(account, i, "user txt");
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p, i=%d\n", __LINE__, ret, account, i);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p, i=%d\n", __LINE__, ret, account, i);
                }
 
        }
@@ -4054,33 +4055,33 @@ static int utc21_account_insert()
                ret = account_set_user_int(account, i, 000);
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p, i=%d\n", __LINE__, ret, account, i);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p, i=%d\n", __LINE__, ret, account, i);
                }
        }
        ret = account_insert_to_db(account, &account_id);
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_destroy(account);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_disconnect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
        return account_id;
 }
@@ -4094,112 +4095,112 @@ static int utc22_account_insert()
        ret = account_connect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        ret = account_create(&account);
 
-       printf("account = %p, ret = %d \n", account, ret);
+       ACCOUNT_SLOGD("account = %p, ret = %d \n", account, ret);
 
        ret = account_set_user_name(account, "tarun.kr");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_display_name(account, "tarun kumar");
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_domain_name(account, "Samsung");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_email_address(account, "tarun.kr@samsung.com");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_package_name(account, "com.samsung.accounts");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_icon_path(account, "/test/test.jpg");
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_access_token(account, "xxxx/yyyy/zzzz/-&abc");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_auth_type( account, ACCOUNT_AUTH_TYPE_OAUTH );
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_secret( account, ACCOUNT_SECRECY_INVISIBLE);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_source(account, "URUSA inc.");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        int i;
@@ -4209,7 +4210,7 @@ static int utc22_account_insert()
                ret = account_set_user_text(account, i, "user txt");
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p, i=%d\n", __LINE__, ret, account, i);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p, i=%d\n", __LINE__, ret, account, i);
                }
 
        }
@@ -4219,33 +4220,33 @@ static int utc22_account_insert()
                ret = account_set_user_int(account, i, 888);
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p, i=%d\n", __LINE__, ret, account, i);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p, i=%d\n", __LINE__, ret, account, i);
                }
        }
        ret = account_insert_to_db(account, &account_id);
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_destroy(account);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_disconnect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
        return account_id;
 }
@@ -4259,112 +4260,112 @@ static int utc23_account_insert()
        ret = account_connect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        ret = account_create(&account);
 
-       printf("account = %p, ret = %d \n", account, ret);
+       ACCOUNT_SLOGD("account = %p, ret = %d \n", account, ret);
 
        ret = account_set_user_name(account, "tarun.kr");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_display_name(account, "tarun kumar");
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_domain_name(account, "Samsung");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_email_address(account, "tarun.kr@samsung.com");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_package_name(account, "com.samsung.accounts");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_icon_path(account, "/test/test.jpg");
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_access_token(account, "xxxx/yyyy/zzzz/-&abc");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_auth_type( account, ACCOUNT_AUTH_TYPE_OAUTH );
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_secret( account, ACCOUNT_SECRECY_INVISIBLE);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_set_source(account, "URUSA inc.");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        int i;
@@ -4374,7 +4375,7 @@ static int utc23_account_insert()
                ret = account_set_user_text(account, i, "user txt");
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p, i=%d\n", __LINE__, ret, account, i);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p, i=%d\n", __LINE__, ret, account, i);
                }
 
        }
@@ -4384,53 +4385,53 @@ static int utc23_account_insert()
                ret = account_set_user_int(account, i, 888);
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p, i=%d\n", __LINE__, ret, account, i);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p, i=%d\n", __LINE__, ret, account, i);
                }
        }
 
        ret = account_set_capability(account, ACCOUNT_SUPPORTS_CAPABILITY_CONTACT, ACCOUNT_CAPABILITY_ENABLED);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_capability(account, ACCOUNT_SUPPORTS_CAPABILITY_POST, ACCOUNT_CAPABILITY_ENABLED);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_insert_to_db(account, &account_id);
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p , account_id = %d\n", __LINE__, ret, account, account_id);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_destroy(account);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_disconnect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        return account_id;
@@ -4444,43 +4445,43 @@ static int utc1_account_update()
        ret = account_connect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        ret = account_create(&account);
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_update_to_db_by_id(account, 0);
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_destroy(account);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_disconnect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        return 1;
@@ -4494,44 +4495,44 @@ static int utc2_account_update()
        ret = account_connect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        ret = account_create(&account);
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_update_to_db_by_id(account, -999);
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_destroy(account);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_disconnect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        return 1;
@@ -4545,44 +4546,44 @@ static int utc3_account_update()
        ret = account_connect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        ret = account_create(&account);
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_update_to_db_by_id(account, 555);
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_destroy(account);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_disconnect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        return 1;
@@ -4596,55 +4597,55 @@ static int utc4_account_update()
        ret = account_connect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        ret = account_create(&account);
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        account_set_user_name(account, NULL);
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_update_to_db_by_id(account, account_id);
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_destroy(account);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_disconnect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        return 1;
@@ -4658,55 +4659,55 @@ static int utc5_account_update()
        ret = account_connect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        ret = account_create(&account);
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        account_set_user_name(account, "updated-tarun.kr");
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_update_to_db_by_id(account, account_id);
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_destroy(account);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_disconnect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        return 1;
@@ -4720,64 +4721,64 @@ static int utc6_account_update()
        ret = account_connect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        ret = account_create(&account);
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        account_set_user_name(account, "updated-tarun.kr");
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_display_name(account, NULL);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_update_to_db_by_id(account, account_id);
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_destroy(account);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_disconnect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        return 1;
@@ -4791,38 +4792,38 @@ static int utc7_account_update()
        ret = account_connect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        ret = account_create(&account);
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        account_set_user_name(account, "updated-tarun.kr");
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_display_name(account, "updated-tarun kumar");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
 
@@ -4830,26 +4831,26 @@ static int utc7_account_update()
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_destroy(account);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_disconnect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        return 1;
@@ -4863,82 +4864,82 @@ static int utc8_account_update()
        ret = account_connect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        ret = account_create(&account);
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        account_set_user_name(account, "updated-tarun.kr");
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_display_name(account, "updated-tarun kumar");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_domain_name(account, NULL);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_domain_name(account, NULL);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_update_to_db_by_id(account, account_id);
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_destroy(account);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_disconnect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        return 1;
@@ -4951,73 +4952,73 @@ static int utc9_account_update()
        ret = account_connect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        ret = account_create(&account);
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        account_set_user_name(account, "updated-tarun.kr");
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_display_name(account, "updated-tarun kumar");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_domain_name(account, "updated-Samsung Facebook");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_update_to_db_by_id(account, account_id);
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_destroy(account);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_disconnect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        return 1;
@@ -5031,82 +5032,82 @@ static int utc10_account_update()
        ret = account_connect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        ret = account_create(&account);
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        account_set_user_name(account, "updated-tarun.kr");
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_display_name(account, "updated-tarun kumar");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_domain_name(account, "updated-Samsung Facebook");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_email_address(account, NULL);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_update_to_db_by_id(account, account_id);
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_destroy(account);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_disconnect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        return 1;
@@ -5120,82 +5121,82 @@ static int utc11_account_update()
        ret = account_connect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        ret = account_create(&account);
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        account_set_user_name(account, "updated-tarun.kr");
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_display_name(account, "updated-tarun kumar");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_domain_name(account, "updated-Samsung Facebook");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_email_address(account, "updated-urusa77@gmail.com");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_update_to_db_by_id(account, account_id);
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_destroy(account);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_disconnect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        return 1;
@@ -5209,91 +5210,91 @@ static int utc12_account_update()
        ret = account_connect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        ret = account_create(&account);
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        account_set_user_name(account, "updated-tarun.kr");
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_display_name(account, "updated-tarun kumar");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_domain_name(account, "updated-Samsung Facebook");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_email_address(account, "updated-urusa77@gmail.com");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_package_name(account, NULL);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_update_to_db_by_id(account, account_id);
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_destroy(account);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_disconnect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        return 1;
@@ -5307,91 +5308,91 @@ static int utc13_account_update()
        ret = account_connect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        ret = account_create(&account);
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        account_set_user_name(account, "updated-tarun.kr");
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_display_name(account, "updated-tarun kumar");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_domain_name(account, "updated-Samsung Facebook");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_email_address(account, "updated-urusa77@gmail.com");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_package_name(account, "updated-com.samsung.account");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_update_to_db_by_id(account, account_id);
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_destroy(account);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_disconnect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        return 1;
@@ -5405,100 +5406,100 @@ static int utc14_account_update()
        ret = account_connect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        ret = account_create(&account);
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        account_set_user_name(account, "updated-tarun.kr");
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_display_name(account, "updated-tarun kumar");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_domain_name(account, "updated-Samsung Facebook");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_email_address(account, "updated-urusa77@gmail.com");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_package_name(account, "updated-com.samsung.account");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_icon_path(account, NULL);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_update_to_db_by_id(account, account_id);
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_destroy(account);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_disconnect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        return 1;
@@ -5512,100 +5513,100 @@ static int utc15_account_update()
        ret = account_connect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        ret = account_create(&account);
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        account_set_user_name(account, "updated-tarun.kr");
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_display_name(account, "updated-tarun kumar");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_domain_name(account, "updated-Samsung Facebook");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_email_address(account, "updated-urusa77@gmail.com");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_package_name(account, "updated-com.samsung.account");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_icon_path(account, "updated-icon-path");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_update_to_db_by_id(account, account_id);
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_destroy(account);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_disconnect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        return 1;
@@ -5619,109 +5620,109 @@ static int utc16_account_update()
        ret = account_connect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        ret = account_create(&account);
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        account_set_user_name(account, "updated-tarun.kr");
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_display_name(account, "updated-tarun kumar");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_domain_name(account, "updated-Samsung Facebook");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_email_address(account, "updated-urusa77@gmail.com");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_package_name(account, "updated-com.samsung.account");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_icon_path(account, "updated-icon-path");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_access_token(account, NULL);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_update_to_db_by_id(account, account_id);
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_destroy(account);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_disconnect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        return 1;
@@ -5735,109 +5736,109 @@ static int utc17_account_update()
        ret = account_connect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        ret = account_create(&account);
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        account_set_user_name(account, "updated-tarun.kr");
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_display_name(account, "updated-tarun kumar");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_domain_name(account, "updated-Samsung Facebook");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_email_address(account, "updated-urusa77@gmail.com");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_package_name(account, "updated-com.samsung.account");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_icon_path(account, "updated-icon-path");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_access_token(account, "updated-ACCESSTOKEN");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_update_to_db_by_id(account, account_id);
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_destroy(account);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_disconnect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        return 1;
@@ -5851,127 +5852,127 @@ static int utc18_account_update()
        ret = account_connect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        ret = account_create(&account);
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        account_set_user_name(account, "updated-tarun.kr");
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_display_name(account, "updated-tarun kumar");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_domain_name(account, "updated-Samsung Facebook");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_email_address(account, "updated-urusa77@gmail.com");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_package_name(account, "updated-com.samsung.account");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_icon_path(account, "updated-icon-path");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_access_token(account, "updated-ACCESSTOKEN");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_auth_type( account, ACCOUNT_AUTH_TYPE_OAUTH );
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_secret( account, ACCOUNT_SECRECY_INVISIBLE);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_update_to_db_by_id(account, account_id);
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_destroy(account);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_disconnect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        return 1;
@@ -5985,118 +5986,118 @@ static int utc19_account_update()
        ret = account_connect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        ret = account_create(&account);
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        account_set_user_name(account, "updated-tarun.kr");
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_display_name(account, "updated-tarun kumar");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_domain_name(account, "updated-Samsung Facebook");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_email_address(account, "updated-urusa77@gmail.com");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_package_name(account, "updated-com.samsung.account");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_icon_path(account, "updated-icon-path");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_access_token(account, "updated-ACCESSTOKEN");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_source(account, NULL);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_update_to_db_by_id(account, account_id);
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_destroy(account);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_disconnect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        return 1;
@@ -6110,118 +6111,118 @@ static int utc20_account_update()
        ret = account_connect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        ret = account_create(&account);
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        account_set_user_name(account, "updated-tarun.kr");
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_display_name(account, "updated-tarun kumar");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_domain_name(account, "updated-Samsung Facebook");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_email_address(account, "updated-urusa77@gmail.com");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_package_name(account, "updated-com.samsung.account");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_icon_path(account, "updated-icon-path");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_access_token(account, "updated-ACCESSTOKEN");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_source(account, "updated-URUSA inc.");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_update_to_db_by_id(account, account_id);
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_destroy(account);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_disconnect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        return 1;
@@ -6235,92 +6236,92 @@ static int utc21_account_update()
        ret = account_connect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        ret = account_create(&account);
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        account_set_user_name(account, "updated-tarun.kr");
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_display_name(account, "updated-tarun kumar");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_domain_name(account, "updated-Samsung Facebook");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_email_address(account, "updated-urusa77@gmail.com");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_package_name(account, "updated-com.samsung.account");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_icon_path(account, "updated-icon-path");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_access_token(account, "updated-ACCESSTOKEN");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_source(account, "updated-URUSA inc.");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        int i;
 
@@ -6329,7 +6330,7 @@ static int utc21_account_update()
                ret = account_set_user_text(account, i, NULL);
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p, i=%d\n", __LINE__, ret, account, i);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p, i=%d\n", __LINE__, ret, account, i);
                }
 
        }
@@ -6338,26 +6339,26 @@ static int utc21_account_update()
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_destroy(account);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_disconnect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        return 1;
@@ -6371,92 +6372,92 @@ static int utc22_account_update()
        ret = account_connect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        ret = account_create(&account);
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        account_set_user_name(account, "updated-tarun.kr");
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_display_name(account, "updated-tarun kumar");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_domain_name(account, "updated-Samsung Facebook");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_email_address(account, "updated-urusa77@gmail.com");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_package_name(account, "updated-com.samsung.account");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_icon_path(account, "updated-icon-path");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_access_token(account, "updated-ACCESSTOKEN");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_source(account, "updated-URUSA inc.");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        int i;
        for(i=0;i<USER_TXT_CNT;i++)
@@ -6464,7 +6465,7 @@ static int utc22_account_update()
                ret = account_set_user_text(account, i, "updated-user txt");
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p, i=%d\n", __LINE__, ret, account, i);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p, i=%d\n", __LINE__, ret, account, i);
                }
 
        }
@@ -6473,26 +6474,26 @@ static int utc22_account_update()
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_destroy(account);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_disconnect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        return 1;
@@ -6506,92 +6507,92 @@ static int utc23_account_update()
        ret = account_connect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        ret = account_create(&account);
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        account_set_user_name(account, "updated-tarun.kr");
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_display_name(account, "updated-tarun kumar");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_domain_name(account, "updated-Samsung Facebook");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_email_address(account, "updated-urusa77@gmail.com");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_package_name(account, "updated-com.samsung.account");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_icon_path(account, "updated-icon-path");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_access_token(account, "updated-ACCESSTOKEN");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_source(account, "updated-URUSA inc.");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        int i;
        for(i=0;i<USER_TXT_CNT;i++)
@@ -6599,7 +6600,7 @@ static int utc23_account_update()
                ret = account_set_user_text(account, i, "updated-user txt");
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p, i=%d\n", __LINE__, ret, account, i);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p, i=%d\n", __LINE__, ret, account, i);
                }
 
        }
@@ -6608,7 +6609,7 @@ static int utc23_account_update()
                ret = account_set_user_int(account, i, -111);
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p, i=%d\n", __LINE__, ret, account, i);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p, i=%d\n", __LINE__, ret, account, i);
                }
        }
 
@@ -6616,26 +6617,26 @@ static int utc23_account_update()
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_destroy(account);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_disconnect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        return 1;
@@ -6649,92 +6650,92 @@ static int utc24_account_update()
        ret = account_connect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        ret = account_create(&account);
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        account_set_user_name(account, "updated-tarun.kr");
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_display_name(account, "updated-tarun kumar");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_domain_name(account, "updated-Samsung Facebook");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_email_address(account, "updated-urusa77@gmail.com");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_package_name(account, "updated-com.samsung.account");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_icon_path(account, "updated-icon-path");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_access_token(account, "updated-ACCESSTOKEN");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_source(account, "updated-URUSA inc.");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        int i;
        for(i=0;i<USER_TXT_CNT;i++)
@@ -6742,7 +6743,7 @@ static int utc24_account_update()
                ret = account_set_user_text(account, i, "updated-user txt");
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p, i=%d\n", __LINE__, ret, account, i);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p, i=%d\n", __LINE__, ret, account, i);
                }
 
        }
@@ -6751,7 +6752,7 @@ static int utc24_account_update()
                ret = account_set_user_int(account, i, 0);
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p, i=%d\n", __LINE__, ret, account, i);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p, i=%d\n", __LINE__, ret, account, i);
                }
        }
 
@@ -6759,26 +6760,26 @@ static int utc24_account_update()
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_destroy(account);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_disconnect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        return 1;
@@ -6792,92 +6793,92 @@ static int utc25_account_update()
        ret = account_connect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        ret = account_create(&account);
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        account_set_user_name(account, "updated-tarun.kr");
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_display_name(account, "updated-tarun kumar");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_domain_name(account, "updated-Samsung Facebook");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_email_address(account, "updated-urusa77@gmail.com");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_package_name(account, "updated-com.samsung.account");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_icon_path(account, "updated-icon-path");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_access_token(account, "updated-ACCESSTOKEN");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_source(account, "updated-URUSA inc.");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        int i;
        for(i=0;i<USER_TXT_CNT;i++)
@@ -6885,7 +6886,7 @@ static int utc25_account_update()
                ret = account_set_user_text(account, i, "updated-user txt");
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p, i=%d\n", __LINE__, ret, account, i);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p, i=%d\n", __LINE__, ret, account, i);
                }
 
        }
@@ -6894,7 +6895,7 @@ static int utc25_account_update()
                ret = account_set_user_int(account, i, 111);
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p, i=%d\n", __LINE__, ret, account, i);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p, i=%d\n", __LINE__, ret, account, i);
                }
        }
 
@@ -6902,26 +6903,26 @@ static int utc25_account_update()
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_destroy(account);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_disconnect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        return 1;
@@ -6935,92 +6936,92 @@ static int utc26_account_update()
        ret = account_connect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        ret = account_create(&account);
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        account_set_user_name(account, "updated-tarun.kr");
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_display_name(account, "updated-tarun kumar");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_domain_name(account, "updated-Samsung Facebook");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_email_address(account, "updated-urusa77@gmail.com");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_package_name(account, "updated-com.samsung.account");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_icon_path(account, "updated-icon-path");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_access_token(account, "updated-ACCESSTOKEN");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_source(account, "updated-URUSA inc.");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        int i;
        for(i=0;i<USER_TXT_CNT;i++)
@@ -7028,7 +7029,7 @@ static int utc26_account_update()
                ret = account_set_user_text(account, i, "updated-user txt");
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p, i=%d\n", __LINE__, ret, account, i);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p, i=%d\n", __LINE__, ret, account, i);
                }
 
        }
@@ -7037,7 +7038,7 @@ static int utc26_account_update()
                ret = account_set_user_int(account, i, 111);
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p, i=%d\n", __LINE__, ret, account, i);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p, i=%d\n", __LINE__, ret, account, i);
                }
        }
 
@@ -7045,26 +7046,26 @@ static int utc26_account_update()
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_destroy(account);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_disconnect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        return 1;
@@ -7078,92 +7079,92 @@ static int utc27_account_update()
        ret = account_connect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        ret = account_create(&account);
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        account_set_user_name(account, "updated-tarun.kr");
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_display_name(account, "updated-tarun kumar");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_domain_name(account, "updated-Samsung Facebook");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_email_address(account, "updated-urusa77@gmail.com");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_package_name(account, "updated-com.samsung.account");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_icon_path(account, "updated-icon-path");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_access_token(account, "updated-ACCESSTOKEN");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_set_source(account, "updated-URUSA inc.");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        int i;
        for(i=0;i<USER_TXT_CNT;i++)
@@ -7171,7 +7172,7 @@ static int utc27_account_update()
                ret = account_set_user_text(account, i, "updated-user txt");
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p, i=%d\n", __LINE__, ret, account, i);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p, i=%d\n", __LINE__, ret, account, i);
                }
 
        }
@@ -7180,7 +7181,7 @@ static int utc27_account_update()
                ret = account_set_user_int(account, i, 111);
                if(ret != ACCOUNT_ERROR_NONE)
                {
-                       printf("(%d)-[Account] ret = %d, account=%p, i=%d\n", __LINE__, ret, account, i);
+                       ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p, i=%d\n", __LINE__, ret, account, i);
                }
        }
        ret = account_set_capability(account, ACCOUNT_SUPPORTS_CAPABILITY_CONTACT, ACCOUNT_CAPABILITY_ENABLED);
@@ -7197,26 +7198,26 @@ static int utc27_account_update()
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_destroy(account);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_disconnect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        return 1;
@@ -7224,67 +7225,67 @@ static int utc27_account_update()
 
 bool _utc1_account_get_callback(account_h handle, void* user_data)
 {
-       printf("_account_get_callback handle = %s , user_data = %s \n", (char *)handle, (char *)user_data);
+       ACCOUNT_SLOGD("_account_get_callback handle = %s , user_data = %s \n", (char *)handle, (char *)user_data);
 
        char *test_text = NULL;
 
        account_get_user_name(handle, &test_text);
-       printf("_account_get_callback : %s\n", test_text);
+       ACCOUNT_SLOGD("_account_get_callback : %s\n", test_text);
 
        _account_free_text(test_text);
 
        account_get_display_name(handle, &test_text);
-       printf("_account_get_callback : %s\n", test_text);
+       ACCOUNT_SLOGD("_account_get_callback : %s\n", test_text);
 
        _account_free_text(test_text);
 
        account_get_email_address(handle, &test_text);
-       printf("_account_get_callback : %s\n", test_text);
+       ACCOUNT_SLOGD("_account_get_callback : %s\n", test_text);
 
        _account_free_text(test_text);
 
        account_get_icon_path(handle, &test_text);
-       printf("_account_get_callback : %s\n", test_text);
+       ACCOUNT_SLOGD("_account_get_callback : %s\n", test_text);
 
        _account_free_text(test_text);
 
        account_get_source(handle, &test_text);
-       printf("_account_get_callback : %s\n", test_text);
+       ACCOUNT_SLOGD("_account_get_callback : %s\n", test_text);
 
        _account_free_text(test_text);
 
        account_get_package_name(handle, &test_text);
-       printf("_account_get_callback : %s\n", test_text);
+       ACCOUNT_SLOGD("_account_get_callback : %s\n", test_text);
 
        _account_free_text(test_text);
 
        account_get_domain_name(handle, &test_text);
-       printf("_account_get_callback : %s\n", test_text);
+       ACCOUNT_SLOGD("_account_get_callback : %s\n", test_text);
 
        _account_free_text(test_text);
 
        account_get_access_token(handle, &test_text);
-       printf("_account_get_callback : %s\n", test_text);
+       ACCOUNT_SLOGD("_account_get_callback : %s\n", test_text);
        _account_free_text(test_text);
 
        int i=0, test_int=0;
 
        account_auth_type_e auth_type;
        account_get_auth_type(handle, &auth_type);
-       printf("account_get_auth_type : %d\n", auth_type);
+       ACCOUNT_SLOGD("account_get_auth_type : %d\n", auth_type);
 
        account_secrecy_state_e secret;
        account_get_secret(handle, &secret);
-       printf("account_get_secret : %d\n", secret);
+       ACCOUNT_SLOGD("account_get_secret : %d\n", secret);
 
        account_sync_state_e sync_support;
        account_get_sync_support(handle, &sync_support);
-       printf("account_get_sync_support : %d\n", sync_support);
+       ACCOUNT_SLOGD("account_get_sync_support : %d\n", sync_support);
 
        for(i=0;i<USER_INT_CNT;i++)
        {
                account_get_user_int(handle, i, &test_int);
-               printf("_account_get_callback : %d\n", test_int);
+               ACCOUNT_SLOGD("_account_get_callback : %d\n", test_int);
        }
 
        account_get_capability_all(handle, _capability_get_callback, NULL);
@@ -7301,29 +7302,29 @@ static int utc1_get_account_by_id()
        ret = account_connect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        ret = account_create(&account);
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_query_account_by_account_id(account_id, &account);
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        _account_get_account_info(account);
@@ -7331,16 +7332,16 @@ static int utc1_get_account_by_id()
        ret = account_destroy(account);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_disconnect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        return 1;
@@ -7354,18 +7355,18 @@ static int utc2_get_account_by_id()
        ret = account_connect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        ret = account_create(&account);
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_query_account_by_account_id(account_id, &account);
@@ -7374,26 +7375,26 @@ static int utc2_get_account_by_id()
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_destroy(account);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        ret = account_disconnect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        return 1;
@@ -7407,24 +7408,24 @@ static int utc1_get_account_by_user_name()
        ret = account_connect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        ret = account_query_account_by_user_name(_account_get_callback, "usernamed-wy1115", NULL);
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_disconnect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        return 1;
@@ -7438,7 +7439,7 @@ static int utc2_get_account_by_user_name()
        ret = account_connect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        char *user_data = "test user_data";
@@ -7447,17 +7448,17 @@ static int utc2_get_account_by_user_name()
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_disconnect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        return 1;
@@ -7471,24 +7472,24 @@ static int utc1_get_account_by_capability()
        ret = account_connect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        ret = account_query_account_by_capability(_account_get_callback, ACCOUNT_SUPPORTS_CAPABILITY_PHOTO, ACCOUNT_CAPABILITY_ENABLED, NULL);
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_disconnect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        return 1;
@@ -7502,24 +7503,24 @@ static int utc2_get_account_by_capability()
        ret = account_connect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        ret = account_query_account_by_capability(_account_get_callback, ACCOUNT_SUPPORTS_CAPABILITY_PHOTO, ACCOUNT_CAPABILITY_DISABLED, NULL);
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_disconnect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        return 1;
@@ -7533,24 +7534,24 @@ static int utc3_get_account_by_capability()
        ret = account_connect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        ret = account_query_account_by_capability(_account_get_callback, ACCOUNT_SUPPORTS_CAPABILITY_PHOTO, -1, NULL);
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_disconnect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        return 1;
@@ -7564,24 +7565,24 @@ static int utc4_get_account_by_capability()
        ret = account_connect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        ret = account_query_account_by_capability(_account_get_callback, ACCOUNT_SUPPORTS_CAPABILITY_PHOTO, ACCOUNT_CAPABILITY_DISABLED, NULL);
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_disconnect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        return 1;
@@ -7595,24 +7596,24 @@ static int utc5_get_account_by_capability()
        ret = account_connect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        ret = account_query_account_by_capability(_account_get_callback, ACCOUNT_SUPPORTS_CAPABILITY_PHOTO, -1, NULL);
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, account=%p\n", __LINE__, ret, account);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, account=%p\n", __LINE__, ret, account);
        }
 
        ret = account_disconnect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        return 1;
@@ -7625,24 +7626,24 @@ static int utc1_get_all_accounts()
        ret = account_connect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        ret = account_foreach_account_from_db(_account_get_callback, NULL);
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, \n", __LINE__, ret);
        }
 
        ret = account_disconnect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        return 1;
@@ -7655,7 +7656,7 @@ static int utc2_get_all_accounts()
        ret = account_connect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        char *user_data = "test user_data";
@@ -7664,17 +7665,17 @@ static int utc2_get_all_accounts()
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d \n", __LINE__, ret);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d \n", __LINE__, ret);
        }
 
        ret = account_disconnect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        return 1;
@@ -7685,8 +7686,8 @@ bool _utc_capability_get_callback(const char* capability_type, account_capabilit
        char* test_type = (char*)capability_type;
        int test_value = capability_value;
 
-       printf("_capability_get_callback test_type = : %s\n", test_type);
-       printf("_capability_get_callback test_value = : %d\n", test_value);
+       ACCOUNT_SLOGD("_capability_get_callback test_type = : %s\n", test_type);
+       ACCOUNT_SLOGD("_capability_get_callback test_value = : %d\n", test_value);
        return TRUE;
 
 }
@@ -7697,23 +7698,23 @@ static int utc1_account_get_capability_by_account_id()
        ret = account_connect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        ret = account_query_capability_by_account_id(_utc_capability_get_callback, account_id, NULL);
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d,\n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d,\n", __LINE__, ret);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, \n", __LINE__, ret);
        }
        ret = account_disconnect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
        return 1;
 }
@@ -7726,23 +7727,23 @@ static int utc2_account_get_capability_by_account_id()
        ret = account_connect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        ret = account_query_capability_by_account_id(_utc_capability_get_callback, account_id, (void *)user_data);
 
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, \n", __LINE__, ret);
        }
        ret = account_disconnect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
        return 1;
 }
@@ -7754,22 +7755,22 @@ static int utc_account_delete_by_id()
        ret = account_connect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        ret = account_delete_from_db_by_id(account_id);
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d, \n", __LINE__, ret);
        }
        ret = account_disconnect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
        return 1;
 }
@@ -7780,22 +7781,22 @@ static int utc_account_delete_by_user_name()
        ret = account_connect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        ret = account_delete_from_db_by_user_name("usernamed-wy1115", "usernamed-com.samsung.account");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d \n", __LINE__, ret);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d \n", __LINE__, ret);
        }
        ret = account_disconnect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
        return 1;
 }
@@ -7806,22 +7807,22 @@ static int utc_account_delete_by_package_name()
        ret = account_connect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
 
        ret = account_delete_from_db_by_package_name("usernamed-com.samsung.account");
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d\n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d\n", __LINE__, ret);
        }
        else
        {
-               printf("(%d)-[Account-else loop] ret = %d\n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account-else loop] ret = %d\n", __LINE__, ret);
        }
        ret = account_disconnect();
        if(ret != ACCOUNT_ERROR_NONE)
        {
-               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
        }
        return 1;
 }
@@ -7833,19 +7834,19 @@ static int utc_account_update_sync_status_by_id()
    ret = account_connect();
    if(ret != ACCOUNT_ERROR_NONE)
    {
-          printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+          ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
    }
 
    ret = account_update_sync_status_by_id(account_id, ACCOUNT_SYNC_STATUS_IDLE);
    if(ret != ACCOUNT_ERROR_NONE)
    {
-          printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+          ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
    }
 
    ret = account_disconnect();
    if(ret != ACCOUNT_ERROR_NONE)
    {
-          printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+          ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
    }
    return ret;
 }
@@ -7858,19 +7859,19 @@ static int utc_account_get_application_capability_support()
    ret = account_connect();
    if(ret != ACCOUNT_ERROR_NONE)
    {
-          printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+          ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
    }
 
    ret = account_get_application_capability_support("com.samsung.facebook", ACCOUNT_SUPPORTS_CAPABILITY_CONTACT, &test);
    if(ret != ACCOUNT_ERROR_NONE)
    {
-          printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+          ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
    }
 
    ret = account_disconnect();
    if(ret != ACCOUNT_ERROR_NONE)
    {
-          printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+          ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
    }
    return ret;
 }
@@ -7881,170 +7882,29 @@ static int utc_account_get_and_update()
        account_h account = NULL;
 
        ret = account_connect();
-       printf("%s(%d) ret=%x\n", __FUNCTION__, __LINE__, ret);
+       ACCOUNT_SLOGD("%s(%d) ret=%x\n", __FUNCTION__, __LINE__, ret);
 
        ret = account_create(&account);
-       printf("%s(%d) ret=%x\n", __FUNCTION__, __LINE__, ret);
+       ACCOUNT_SLOGD("%s(%d) ret=%x\n", __FUNCTION__, __LINE__, ret);
 
        ret = account_query_account_by_account_id( 2, &account);
-       printf("%s(%d) ret=%x\n", __FUNCTION__, __LINE__, ret);
+       ACCOUNT_SLOGD("%s(%d) ret=%x\n", __FUNCTION__, __LINE__, ret);
 
        ret = account_set_access_token(account, "ACCESSSSSSSSSSSSSSSSSSSFASFASDGDSFFASDFASFDSDGAASDFASDGDFDFGAFASDFASFASDFASASGSGASDFASFSADDSGASGASGGASDFASDFASGSAASDFAAAG");
-       printf("%s(%d) ret=%x\n", __FUNCTION__, __LINE__, ret);
+       ACCOUNT_SLOGD("%s(%d) ret=%x\n", __FUNCTION__, __LINE__, ret);
 
        ret = account_update_to_db_by_id( account, 2);
-       printf("%s(%d) ret=%x\n", __FUNCTION__, __LINE__, ret);
+       ACCOUNT_SLOGD("%s(%d) ret=%x\n", __FUNCTION__, __LINE__, ret);
 
        ret = account_destroy(account);
-       printf("%s(%d) ret=%x\n", __FUNCTION__, __LINE__, ret);
+       ACCOUNT_SLOGD("%s(%d) ret=%x\n", __FUNCTION__, __LINE__, ret);
 
        ret = account_disconnect();
-       printf("%s(%d) ret=%x\n", __FUNCTION__, __LINE__, ret);
+       ACCOUNT_SLOGD("%s(%d) ret=%x\n", __FUNCTION__, __LINE__, ret);
 
        return 1;
 }
 
-#if 0
-
-static int utc_account_type_test()
-{
-       int ret;
-       account_connect();
-       ret = account_type_create(&account_type);
-       MYACCOUNT_DBUG("account_type_create %d ret = %d", __LINE__, ret);
-
-       ret = account_type_set_app_id(account_type, "com.samsung.urusa");
-       ret = account_type_set_icon_path(account_type, "urusa/iconpath");
-       ret = account_type_set_small_icon_path(account_type, "urusa/smalliconpath");
-       ret = account_type_set_service_provider_id(account_type,"http://org.tizen.urusa.com");
-       ret = account_type_set_multiple_account_support(account_type, 1);
-
-       ret = account_type_set_label(account_type, "urusa", "en_US");
-       ret = account_type_set_label(account_type, "urusa-fr_FR", "fr_FR");
-       ret = account_type_set_label(account_type, "urusa-ge_GE", "ge_GE");
-
-       ret = account_type_insert_to_db(account_type,&account_type_id);
-       MYACCOUNT_DBUG("account_type_insert_to_db ret = %d", ret);
-
-       ret = account_type_destroy(account_type);
-
-       ret = account_type_create(&account_type);
-       ret = account_type_set_app_id(account_type, "com.tizen.urusa");
-       ret = account_type_set_icon_path(account_type, "1111urusa/iconpath");
-       ret = account_type_set_small_icon_path(account_type, "1111urusa/smalliconpath");
-       ret = account_type_set_service_provider_id(account_type,"1111http://org.tizen.urusa.com");
-       ret = account_type_set_multiple_account_support(account_type, 0);
-
-       ret = account_type_set_label(account_type, "1111urusa", "en_US");
-       ret = account_type_set_label(account_type, "1111urusa-fr_FR", "fr_FR");
-       ret = account_type_set_label(account_type, "1111urusa-ge_GE", "ge_GE");
-
-       ret = account_type_update_to_db_by_app_id(account_type, "com.samsung.urusa");
-       MYACCOUNT_DBUG("account_type_update_to_db_by_app_id ret = %d", ret);
-       ret = account_type_destroy(account_type);
-
-       ret = account_type_create(&account_type);
-       ret = account_type_query_by_app_id("com.tizen.urusa", &account_type);
-       MYACCOUNT_DBUG("account_type_update_to_db_by_app_id ret = %d", ret);
-
-       char* tmptxt = NULL;
-       int tmpint = -1 ;
-       ret = account_type_get_app_id(account_type, &tmptxt);
-       MYACCOUNT_DBUG("account_type_get ret = %d, %s", ret, tmptxt);
-       free(tmptxt);
-
-       ret = account_type_get_icon_path(account_type, &tmptxt);
-       MYACCOUNT_DBUG("account_type_get ret = %d, %s", ret, tmptxt);
-       free(tmptxt);
-
-       ret = account_type_get_small_icon_path(account_type, &tmptxt);
-       MYACCOUNT_DBUG("account_type_get ret = %d, %s", ret, tmptxt);
-       free(tmptxt);
-
-       ret = account_type_get_service_provider_id(account_type, &tmptxt);
-       MYACCOUNT_DBUG("account_type_get ret = %d, %s", ret, tmptxt);
-       free(tmptxt);
-
-       ret = account_type_get_multiple_account_support(account_type, &tmpint);
-       MYACCOUNT_DBUG("account_type_get ret = %d, %d", ret, tmpint);
-
-       ret = account_type_get_label(account_type, label_cb_func, NULL);
-
-       ret = account_type_destroy(account_type);
-
-
-       ret = account_type_foreach_account_type_from_db( account_type_callback,NULL);
-
-       ret = account_type_delete_by_app_id("com.tizen.urusa");
-       MYACCOUNT_DBUG("account_type_delete_by_app_id ret = %d", ret);
-       account_disconnect();
-
-       return ret;
-}
-
-static int utc_notify_account_insert_update_delete()
-{
-       DBusMessage* msg;
-       DBusConnection* conn;
-       DBusError err;
-
-       printf("Listening for signals\n");
-
-       /*initialise the errors */
-       dbus_error_init(&err);
-
-       /* connect to the bus and check for errors*/
-       conn = dbus_bus_get(DBUS_BUS_SYSTEM, &err);
-       if  (dbus_error_is_set(&err)) {
-               fprintf(stderr, "Connection Error (%s)\n", err.message);
-               dbus_error_free(&err);
-       }
-       if (NULL == conn) {
-               exit(1);
-       }
-
-       /* add a rule for which messages we want to see*/
-       dbus_bus_add_match(conn, "type='signal',interface='account.signal.Type'", &err); /* see signals from the given interface*/
-       dbus_connection_flush(conn);
-       if  (dbus_error_is_set(&err)) {
-               fprintf(stderr, "Match Error (%s)\n", err.message);
-               exit(1);
-       }
-       printf("Match rule sent\n");
-
-       /* loop listening for signals being emmitted*/
-       while (true) {
-
-               /* non blocking read of the next available message*/
-               dbus_connection_read_write(conn, 0);
-               msg = dbus_connection_pop_message(conn);
-
-               /* loop again if we haven't read a message*/
-               if  (NULL == msg) {
-                       sleep(1);
-                       continue;
-               }
-
-               /* check if the message is a signal from the correct interface and with the correct name*/
-               if (dbus_message_is_signal(msg, ACCOUNT_DBUS_SIGNAL_INTERFACE, ACCOUNT_DBUS_NOTI_NAME_INSERT)) {
-                       printf("Got Signal with name insert\n");
-               }
-
-               if (dbus_message_is_signal(msg, ACCOUNT_DBUS_SIGNAL_INTERFACE, ACCOUNT_DBUS_NOTI_NAME_UPDATE)) {
-                       printf("Got Signal with name update\n");
-               }
-
-               if (dbus_message_is_signal(msg, ACCOUNT_DBUS_SIGNAL_INTERFACE, ACCOUNT_DBUS_NOTI_NAME_DELETE)) {
-                       printf("Got Signal with name delete\n");
-               }
-               /* free the message*/
-               dbus_message_unref(msg);
-       }
-       /*close the connection*/
-       dbus_connection_close(conn);
-}
-#endif
-
 int main(int argc, char** argv)
 {
 #if 0
@@ -8057,247 +7917,247 @@ int main(int argc, char** argv)
        char temp[128];
        memset(temp, 0x00, sizeof(temp));
 
-       printf("\n\n**************************** Account Unit Test case Execution Suite ************************************ \n\n");
-       printf("1. Press 1 for account insert test \n");
-       printf("2. Press 2 for account update test \n");
-       printf("3. Press 3 for account delete test \n");
-       printf("4. Press 4 for query account test \n");
+       ACCOUNT_SLOGD("\n\n**************************** Account Unit Test case Execution Suite ************************************ \n\n");
+       ACCOUNT_SLOGD("1. Press 1 for account insert test \n");
+       ACCOUNT_SLOGD("2. Press 2 for account update test \n");
+       ACCOUNT_SLOGD("3. Press 3 for account delete test \n");
+       ACCOUNT_SLOGD("4. Press 4 for query account test \n");
        if (scanf("%d", &user_resp) != 1) {
-               printf("Scanf Failed!!!\n");
+               ACCOUNT_SLOGD("Scanf Failed!!!\n");
                exit(0);
        }
 
        if (user_resp == 1) {
-               printf("In Account Insert Test Mode \n");
+               ACCOUNT_SLOGD("In Account Insert Test Mode \n");
                account_id = _account_insert_test_new();
                if(account_id > 0)
                {
-                       printf("(%d)-[Account] account insert test Success!! account id = %d\n", __LINE__, account_id);
+                       ACCOUNT_SLOGD("(%d)-[Account] account insert test Success!! account id = %d\n", __LINE__, account_id);
                }
                utc_account_get_and_update();
        } else if (user_resp == 2) {
-               printf("In Account Update Test Mode \n");
-               printf("1. Press 1 to upadte account by id test \n");
-               printf("2. Press 2 for update account by user name test \n");
+               ACCOUNT_SLOGD("In Account Update Test Mode \n");
+               ACCOUNT_SLOGD("1. Press 1 to upadte account by id test \n");
+               ACCOUNT_SLOGD("2. Press 2 for update account by user name test \n");
                if (scanf("%d", &user_resp) != 1) {
-                       printf("Scanf Failed!!!\n");
+                       ACCOUNT_SLOGD("Scanf Failed!!!\n");
                        exit(0);
                }
                if (user_resp == 1) {
-                       printf("Enter Account Id to be Updated \n");
+                       ACCOUNT_SLOGD("Enter Account Id to be Updated \n");
                        if (scanf("%d", &account_id) != 1){
-                               printf("Scanf Failed!!!\n");
+                               ACCOUNT_SLOGD("Scanf Failed!!!\n");
                                exit(0);
                        }
                        if (_account_update_test_new(account_id) == ACCOUNT_ERROR_NONE)
-                               printf("Account update Success \n");
+                               ACCOUNT_SLOGD("Account update Success \n");
                        else
-                               printf("Account update Failed \n");
+                               ACCOUNT_SLOGD("Account update Failed \n");
                } else if (user_resp == 2) {
-                       printf("Enter Account user name to be Updated \n");
+                       ACCOUNT_SLOGD("Enter Account user name to be Updated \n");
                        memset(temp, 0x00, sizeof(temp));
                        if (scanf("%s", temp) != 1) {
-                               printf("Scanf Failed!!!\n");
+                               ACCOUNT_SLOGD("Scanf Failed!!!\n");
                                exit(0);
                        }
                        char temp2[128];
                        memset(temp2, 0x00, sizeof(temp2));
-                       printf("Enter Account package name to be Updated \n");
+                       ACCOUNT_SLOGD("Enter Account package name to be Updated \n");
                        if (scanf("%s", temp2) != 1) {
-                               printf("Scanf Failed!!!\n");
+                               ACCOUNT_SLOGD("Scanf Failed!!!\n");
                                exit(0);
                        }
                        if (_account_update_test_new_by_user_name(temp, temp2) == ACCOUNT_ERROR_NONE)
-                               printf("Account update Success \n");
+                               ACCOUNT_SLOGD("Account update Success \n");
                        else
-                               printf("Account update Failed \n");
+                               ACCOUNT_SLOGD("Account update Failed \n");
                } else {
-                       printf("Wrong info entered \n");
+                       ACCOUNT_SLOGD("Wrong info entered \n");
                        exit(0);
                }
        } else if (user_resp == 3) {
-               printf("In Account Delete Test Mode \n");
-               printf("1. Press 1 to delete account by id test \n");
-               printf("2. Press 2 to delete account by user name test \n");
-               printf("3. Press 3 to delete account by package name test \n");
+               ACCOUNT_SLOGD("In Account Delete Test Mode \n");
+               ACCOUNT_SLOGD("1. Press 1 to delete account by id test \n");
+               ACCOUNT_SLOGD("2. Press 2 to delete account by user name test \n");
+               ACCOUNT_SLOGD("3. Press 3 to delete account by package name test \n");
                if (scanf("%d", &user_resp) != 1) {
-                       printf("Scanf Failed!!!\n");
+                       ACCOUNT_SLOGD("Scanf Failed!!!\n");
                        exit(0);
                }
                if (user_resp == 1) {
-                       printf("Enter Account Id to be Deleted \n");
+                       ACCOUNT_SLOGD("Enter Account Id to be Deleted \n");
                        if (scanf("%d", &account_id) != 1) {
-                               printf("Scanf Failed!!!\n");
+                               ACCOUNT_SLOGD("Scanf Failed!!!\n");
                                exit(0);
                        }
                        int ret = account_connect();
                        if(ret != ACCOUNT_ERROR_NONE)
                        {
-                               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+                               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
                        }
                        if (account_delete_from_db_by_id(account_id) == ACCOUNT_ERROR_NONE)
-                               printf("Account delete Success \n");
+                               ACCOUNT_SLOGD("Account delete Success \n");
                        else
-                               printf("Account delete Failed \n");
+                               ACCOUNT_SLOGD("Account delete Failed \n");
 
                        ret = account_disconnect();
                        if(ret != ACCOUNT_ERROR_NONE)
                        {
-                               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+                               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
                        }
                } else if (user_resp == 2) {
-                       printf("Enter Account user name to be Deleted \n");
+                       ACCOUNT_SLOGD("Enter Account user name to be Deleted \n");
                        memset(temp, 0x00, sizeof(temp));
                        if (scanf("%s", temp) != 1) {
-                               printf("Scanf Failed!!!\n");
+                               ACCOUNT_SLOGD("Scanf Failed!!!\n");
                                exit(0);
                        }
                        char temp2[128];
                        memset(temp2, 0x00, sizeof(temp2));
-                       printf("Enter Account package name to be Deleted \n");
+                       ACCOUNT_SLOGD("Enter Account package name to be Deleted \n");
                        if (scanf("%s", temp2) != 1) {
-                               printf("Scanf Failed!!!\n");
+                               ACCOUNT_SLOGD("Scanf Failed!!!\n");
                                exit(0);
                        }
                        int ret = account_connect();
                        if(ret != ACCOUNT_ERROR_NONE)
                        {
-                               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+                               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
                        }
                        if (account_delete_from_db_by_user_name(temp, temp2) == ACCOUNT_ERROR_NONE)
-                               printf("Account delete Success \n");
+                               ACCOUNT_SLOGD("Account delete Success \n");
                        else
-                               printf("Account delete Failed \n");
+                               ACCOUNT_SLOGD("Account delete Failed \n");
                        ret = account_disconnect();
                        if(ret != ACCOUNT_ERROR_NONE)
                        {
-                               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+                               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
                        }
                } else if (user_resp == 3) {
-                       printf("Enter Account package name to be Deleted \n");
+                       ACCOUNT_SLOGD("Enter Account package name to be Deleted \n");
                        memset(temp, 0x00, sizeof(temp));
                        if (scanf("%s", temp) != 1) {
-                               printf("Scanf Failed!!!\n");
+                               ACCOUNT_SLOGD("Scanf Failed!!!\n");
                                exit(0);
                        }
                        int ret = account_connect();
                        if(ret != ACCOUNT_ERROR_NONE)
                        {
-                               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+                               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
                        }
                        if (account_delete_from_db_by_package_name(temp) == ACCOUNT_ERROR_NONE )
-                               printf("Account delete Success \n");
+                               ACCOUNT_SLOGD("Account delete Success \n");
                        else
-                               printf("Account delete Failed \n");
+                               ACCOUNT_SLOGD("Account delete Failed \n");
                        ret = account_disconnect();
                        if(ret != ACCOUNT_ERROR_NONE)
                        {
-                               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+                               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
                        }
 
                } else {
-                       printf("Wrong info entered \n");
+                       ACCOUNT_SLOGD("Wrong info entered \n");
                        exit(0);
                }
 
        } else if (user_resp == 4) {
-               printf("In Account Query Test Mode \n");
-               printf("1. Press 1 to Query account by id test \n");
-               printf("2. Press 2 to Query account by user name test \n");
-               printf("3. Press 3 to Query account by package name test \n");
-               printf("4. Press 4 to Query account by capability test \n");
+               ACCOUNT_SLOGD("In Account Query Test Mode \n");
+               ACCOUNT_SLOGD("1. Press 1 to Query account by id test \n");
+               ACCOUNT_SLOGD("2. Press 2 to Query account by user name test \n");
+               ACCOUNT_SLOGD("3. Press 3 to Query account by package name test \n");
+               ACCOUNT_SLOGD("4. Press 4 to Query account by capability test \n");
                if (scanf("%d", &user_resp) != 1) {
-                       printf("Scanf Failed!!!\n");
+                       ACCOUNT_SLOGD("Scanf Failed!!!\n");
                        exit(0);
                }
                if (user_resp == 1) {
-                       printf("Enter Account Id to be Queried \n");
+                       ACCOUNT_SLOGD("Enter Account Id to be Queried \n");
                        if (scanf("%d", &account_id) != 1) {
-                               printf("Scanf Failed!!!\n");
+                               ACCOUNT_SLOGD("Scanf Failed!!!\n");
                                exit(0);
                        }
                        account_h account = NULL;
                        account_connect();
                        account_create(&account);
                        if (account_query_account_by_account_id(account_id, &account) == ACCOUNT_ERROR_NONE)
-                               printf("Account Queried Successfully \n");
+                               ACCOUNT_SLOGD("Account Queried Successfully \n");
                        else
-                               printf("Account Queried failed \n");
+                               ACCOUNT_SLOGD("Account Queried failed \n");
                        account_destroy(account);
                        account_disconnect();
                } else if (user_resp == 2) {
-                       printf("Enter Account user name to be Queried \n");
+                       ACCOUNT_SLOGD("Enter Account user name to be Queried \n");
                        if (scanf("%s", temp) != 1) {
-                               printf("Scanf Failed!!!\n");
+                               ACCOUNT_SLOGD("Scanf Failed!!!\n");
                                exit(0);
                        }
                        int ret = account_connect();
                        if(ret != ACCOUNT_ERROR_NONE)
                        {
-                               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+                               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
                        }
                        if (account_query_account_by_user_name(_account_get_callback, temp, NULL) == ACCOUNT_ERROR_NONE)
-                               printf("Account Queried Successfully \n");
+                               ACCOUNT_SLOGD("Account Queried Successfully \n");
                        else
-                               printf("Account Queried failed \n");
+                               ACCOUNT_SLOGD("Account Queried failed \n");
 
                        ret = account_disconnect();
                        if(ret != ACCOUNT_ERROR_NONE)
                        {
-                               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+                               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
                        }
                } else if (user_resp == 3) {
-                       printf("Enter Account package name to be Queried \n");
+                       ACCOUNT_SLOGD("Enter Account package name to be Queried \n");
                        if (scanf("%s", temp) != 1) {
-                               printf("Scanf Failed!!!\n");
+                               ACCOUNT_SLOGD("Scanf Failed!!!\n");
                                exit(0);
                        }
                        int ret = account_connect();
                        if(ret != ACCOUNT_ERROR_NONE)
                        {
-                               printf("(%d)-[Account] ret = %d\n", __LINE__, ret);
+                               ACCOUNT_SLOGD("(%d)-[Account] ret = %d\n", __LINE__, ret);
                        }
                        if (account_query_account_by_package_name(_account_get_callback, temp, NULL) == ACCOUNT_ERROR_NONE)
-                               printf("Account Queried Successfully \n");
+                               ACCOUNT_SLOGD("Account Queried Successfully \n");
                        else
-                               printf("Account Queried failed \n");
+                               ACCOUNT_SLOGD("Account Queried failed \n");
                        ret = account_disconnect();
                        if(ret != ACCOUNT_ERROR_NONE)
                        {
-                               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+                               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
                        }
                } else if (user_resp == 4) {
-                       printf("Enter Account capability key to be Queried \n");
+                       ACCOUNT_SLOGD("Enter Account capability key to be Queried \n");
                        if (scanf("%d", &cap_key) != 1) {
-                               printf("Scanf Failed!!!\n");
+                               ACCOUNT_SLOGD("Scanf Failed!!!\n");
                                exit(0);
                        }
-                       printf("Enter Account capability key's value to be Queried \n");
+                       ACCOUNT_SLOGD("Enter Account capability key's value to be Queried \n");
                        if (scanf("%d", &cap_value) != 1) {
-                               printf("Scanf Failed!!!\n");
+                               ACCOUNT_SLOGD("Scanf Failed!!!\n");
                                exit(0);
                        }
                        int ret = account_connect();
                        if(ret != ACCOUNT_ERROR_NONE)
                        {
-                               printf("(%d)-[Account] ret = %d\n", __LINE__, ret);
+                               ACCOUNT_SLOGD("(%d)-[Account] ret = %d\n", __LINE__, ret);
                        }
                        if (account_query_account_by_capability(_account_get_callback, ACCOUNT_SUPPORTS_CAPABILITY_PHOTO, cap_value, NULL) == ACCOUNT_ERROR_NONE)
-                               printf("Account Queried Successfully \n");
+                               ACCOUNT_SLOGD("Account Queried Successfully \n");
                        else
-                               printf("Account Queried failed \n");
+                               ACCOUNT_SLOGD("Account Queried failed \n");
                        ret = account_disconnect();
                        if(ret != ACCOUNT_ERROR_NONE)
                        {
-                               printf("(%d)-[Account] ret = %d, \n", __LINE__, ret);
+                               ACCOUNT_SLOGD("(%d)-[Account] ret = %d, \n", __LINE__, ret);
                        }
                } else {
-                       printf("Wrong info entered \n");
+                       ACCOUNT_SLOGD("Wrong info entered \n");
                        exit(0);
                }
 
        } else {
-                       printf("Wrong info entered \n");
+                       ACCOUNT_SLOGD("Wrong info entered \n");
                        exit(0);
        }