summaryrefslogtreecommitdiffstats
path: root/src/lib/idmap/sss_idmap.h
diff options
context:
space:
mode:
authorPavel Březina <pbrezina@redhat.com>2013-11-01 12:23:23 +0100
committerJakub Hrozek <jhrozek@redhat.com>2013-12-19 20:10:02 +0100
commit16c8b0e7a0ac40b078f98c9f8025d39a59dca9bb (patch)
tree2f5441db6f2611b4bb54f4b481ee185cf48ddcec /src/lib/idmap/sss_idmap.h
parent0324d31d0479e5de0d3aac05bf5fb922d84f84c4 (diff)
downloadsssd-16c8b0e7a0ac40b078f98c9f8025d39a59dca9bb.tar.gz
sssd-16c8b0e7a0ac40b078f98c9f8025d39a59dca9bb.tar.xz
sssd-16c8b0e7a0ac40b078f98c9f8025d39a59dca9bb.zip
idmap: add API to free allocated SIDs
Diffstat (limited to 'src/lib/idmap/sss_idmap.h')
-rw-r--r--src/lib/idmap/sss_idmap.h48
1 files changed, 48 insertions, 0 deletions
diff --git a/src/lib/idmap/sss_idmap.h b/src/lib/idmap/sss_idmap.h
index 4101fb9a5..1e1c9a5cf 100644
--- a/src/lib/idmap/sss_idmap.h
+++ b/src/lib/idmap/sss_idmap.h
@@ -504,6 +504,54 @@ enum idmap_error_code sss_idmap_unix_to_bin_sid(struct sss_idmap_ctx *ctx,
enum idmap_error_code sss_idmap_free(struct sss_idmap_ctx *ctx);
/**
+ * @brief Free mapped SID.
+ *
+ * @param[in] ctx Idmap context
+ * @param[in] sid SID to be freed.
+ *
+ * @return
+ * - #IDMAP_CONTEXT_INVALID: Provided context is invalid
+ */
+enum idmap_error_code sss_idmap_free_sid(struct sss_idmap_ctx *ctx,
+ char *sid);
+
+/**
+ * @brief Free mapped domain SID.
+ *
+ * @param[in] ctx Idmap context
+ * @param[in] dom_sid Domain SID to be freed.
+ *
+ * @return
+ * - #IDMAP_CONTEXT_INVALID: Provided context is invalid
+ */
+enum idmap_error_code sss_idmap_free_dom_sid(struct sss_idmap_ctx *ctx,
+ struct sss_dom_sid *dom_sid);
+
+/**
+ * @brief Free mapped Samba SID.
+ *
+ * @param[in] ctx Idmap context
+ * @param[in] smb_sid Samba SID to be freed.
+ *
+ * @return
+ * - #IDMAP_CONTEXT_INVALID: Provided context is invalid
+ */
+enum idmap_error_code sss_idmap_free_smb_sid(struct sss_idmap_ctx *ctx,
+ struct dom_sid *smb_sid);
+
+/**
+ * @brief Free mapped binary SID.
+ *
+ * @param[in] ctx Idmap context
+ * @param[in] smb_sid Binary SID to be freed.
+ *
+ * @return
+ * - #IDMAP_CONTEXT_INVALID: Provided context is invalid
+ */
+enum idmap_error_code sss_idmap_free_bin_sid(struct sss_idmap_ctx *ctx,
+ uint8_t *bin_sid);
+
+/**
* @brief Translate error code to a string
*
* @param[in] err Idmap error code