summaryrefslogtreecommitdiff
path: root/usr/src/lib/libscf/common
diff options
context:
space:
mode:
Diffstat (limited to 'usr/src/lib/libscf/common')
-rw-r--r--usr/src/lib/libscf/common/libscf_impl.h16
-rw-r--r--usr/src/lib/libscf/common/lowlevel.c46
-rw-r--r--usr/src/lib/libscf/common/mapfile-vers1
3 files changed, 13 insertions, 50 deletions
diff --git a/usr/src/lib/libscf/common/libscf_impl.h b/usr/src/lib/libscf/common/libscf_impl.h
index b6efa98acd..6dfef8577c 100644
--- a/usr/src/lib/libscf/common/libscf_impl.h
+++ b/usr/src/lib/libscf/common/libscf_impl.h
@@ -2,8 +2,9 @@
* CDDL HEADER START
*
* The contents of this file are subject to the terms of the
- * Common Development and Distribution License (the "License").
- * You may not use this file except in compliance with the License.
+ * Common Development and Distribution License, Version 1.0 only
+ * (the "License"). You may not use this file except in compliance
+ * with the License.
*
* You can obtain a copy of the license at usr/src/OPENSOLARIS.LICENSE
* or http://www.opensolaris.org/os/licensing.
@@ -20,7 +21,7 @@
*/
/*
- * Copyright 2007 Sun Microsystems, Inc. All rights reserved.
+ * Copyright 2006 Sun Microsystems, Inc. All rights reserved.
* Use is subject to license terms.
*/
@@ -40,6 +41,15 @@
extern "C" {
#endif
+#define SCF_FMRI_SVC_PREFIX "svc:"
+#define SCF_FMRI_FILE_PREFIX "file:"
+#define SCF_FMRI_SCOPE_PREFIX "//"
+#define SCF_FMRI_LOCAL_SCOPE "localhost"
+#define SCF_FMRI_SCOPE_SUFFIX "@localhost"
+#define SCF_FMRI_SERVICE_PREFIX "/"
+#define SCF_FMRI_INSTANCE_PREFIX ":"
+#define SCF_FMRI_PROPERTYGRP_PREFIX "/:properties/"
+#define SCF_FMRI_PROPERTY_PREFIX "/"
/*
* This macro must be extended if additional FMRI prefixes are defined
*/
diff --git a/usr/src/lib/libscf/common/lowlevel.c b/usr/src/lib/libscf/common/lowlevel.c
index a31ff5205e..2e31aa6e1f 100644
--- a/usr/src/lib/libscf/common/lowlevel.c
+++ b/usr/src/lib/libscf/common/lowlevel.c
@@ -6871,49 +6871,3 @@ _scf_pg_is_read_protected(const scf_propertygroup_t *pg, boolean_t *out)
return (scf_set_error(SCF_ERROR_INTERNAL));
return (SCF_SUCCESS);
}
-
-/*
- * _scf_set_annotation: a wrapper to set the annotation fields for SMF
- * security auditing.
- *
- * Fails with following in scf_error_key thread specific data:
- * _INVALID_ARGUMENT - operation or file too large
- * _NOT_BOUND
- * _CONNECTION_BROKEN
- * _INTERNAL
- * _NO_RESOURCES
- */
-int
-_scf_set_annotation(scf_handle_t *h, const char *operation, const char *file)
-{
- struct rep_protocol_annotation request;
- struct rep_protocol_response response;
- size_t copied;
- int r;
-
- request.rpr_request = REP_PROTOCOL_SET_AUDIT_ANNOTATION;
- copied = strlcpy(request.rpr_operation,
- (operation == NULL) ? "" : operation,
- sizeof (request.rpr_operation));
- if (copied >= sizeof (request.rpr_operation))
- return (scf_set_error(SCF_ERROR_INVALID_ARGUMENT));
-
- copied = strlcpy(request.rpr_file,
- (file == NULL) ? "" : file,
- sizeof (request.rpr_file));
- if (copied >= sizeof (request.rpr_operation))
- return (scf_set_error(SCF_ERROR_INVALID_ARGUMENT));
-
- (void) pthread_mutex_lock(&h->rh_lock);
- r = make_door_call(h, &request, sizeof (request),
- &response, sizeof (response));
- (void) pthread_mutex_unlock(&h->rh_lock);
-
- if (r < 0) {
- DOOR_ERRORS_BLOCK(r);
- }
-
- if (response.rpr_response != REP_PROTOCOL_SUCCESS)
- return (scf_set_error(proto_error(response.rpr_response)));
- return (0);
-}
diff --git a/usr/src/lib/libscf/common/mapfile-vers b/usr/src/lib/libscf/common/mapfile-vers
index f625f15896..d64e43b026 100644
--- a/usr/src/lib/libscf/common/mapfile-vers
+++ b/usr/src/lib/libscf/common/mapfile-vers
@@ -216,7 +216,6 @@ SUNWprivate_1.1 {
scf_parse_svc_fmri;
_scf_pg_wait;
_scf_request_backup;
- _scf_set_annotation;
_scf_snapshot_attach;
_scf_snapshot_delete;
_scf_snapshot_take_attach;