summaryrefslogtreecommitdiff
path: root/include/session.h
diff options
context:
space:
mode:
authorSeonah Moon <seonah1.moon@samsung.com>2018-01-08 13:42:54 +0900
committerSeonah Moon <seonah1.moon@samsung.com>2018-01-08 13:43:31 +0900
commit9362752a471a5c892d679548fbf2828d5fc5684b (patch)
tree83c7d29a28556906938f5c2198d81e2d35f86f92 /include/session.h
parent22633ced6225d294ce8483efbf2b39ea0c0c1b65 (diff)
downloadconnman-9362752a471a5c892d679548fbf2828d5fc5684b.tar.gz
connman-9362752a471a5c892d679548fbf2828d5fc5684b.tar.bz2
connman-9362752a471a5c892d679548fbf2828d5fc5684b.zip
Imported Upstream version 1.35upstream/1.35
Change-Id: I174854914d9fd06a813270b57d1f7bc2bac63c6a Signed-off-by: Seonah Moon <seonah1.moon@samsung.com>
Diffstat (limited to 'include/session.h')
-rw-r--r--include/session.h14
1 files changed, 14 insertions, 0 deletions
diff --git a/include/session.h b/include/session.h
index 37dfc4e4..5106e886 100644
--- a/include/session.h
+++ b/include/session.h
@@ -22,6 +22,7 @@
#ifndef __CONNMAN_SESSION_H
#define __CONNMAN_SESSION_H
+#include <stdint.h>
#include <connman/service.h>
#ifdef __cplusplus
@@ -55,6 +56,12 @@ enum connman_session_id_type {
CONNMAN_SESSION_ID_TYPE_LSM = 3,
};
+enum connman_session_state {
+ CONNMAN_SESSION_STATE_DISCONNECTED = 0,
+ CONNMAN_SESSION_STATE_CONNECTED = 1,
+ CONNMAN_SESSION_STATE_ONLINE = 2,
+};
+
struct connman_session;
struct connman_session_config {
@@ -65,6 +72,8 @@ struct connman_session_config {
enum connman_session_type type;
bool ecall;
GSList *allowed_bearers;
+ char *allowed_interface;
+ bool source_ip_rule;
};
typedef int (* connman_session_config_func_t) (struct connman_session *session,
@@ -83,8 +92,13 @@ struct connman_session_policy {
GSList *bearers);
bool (*allowed)(struct connman_session *session,
struct connman_service *service);
+ void (*update_session_state)(struct connman_session* session,
+ enum connman_session_state state);
+ struct connman_service* (*get_service_for_session)(struct connman_session* session,
+ GSList* services);
};
+uint32_t connman_session_firewall_get_fwmark(struct connman_session *session);
int connman_session_policy_register(struct connman_session_policy *config);
void connman_session_policy_unregister(struct connman_session_policy *config);