On Wed, Sep 10, 2014 at 03:26:10PM +0200, Michal Privoznik wrote:
So far no ConnectOpen() is introduced as it's not needed for
such
simple use case like this. It's crucial to separate this from
virLockSpace program that already exists. Not only it requires
virDomainObjPtr for its ConnectOpen() (subsequently all security
drivers would need rework as they use virDomainDefPtr), but from
nature of things it doesn't belong there either. virLockSpace handles
disk locking, not labeling and it's not clean to pollute its
namespace anyway.
Signed-off-by: Michal Privoznik <mprivozn(a)redhat.com>
---
.gitignore | 2 ++
src/Makefile.am | 27 ++++++++++++++----
src/lock_seclabel_protocol-structs | 21 ++++++++++++++
src/locking/lock_seclabel_protocol.x | 53 ++++++++++++++++++++++++++++++++++++
4 files changed, 98 insertions(+), 5 deletions(-)
create mode 100644 src/lock_seclabel_protocol-structs
create mode 100644 src/locking/lock_seclabel_protocol.x
diff --git a/src/lock_seclabel_protocol-structs
b/src/lock_seclabel_protocol-structs
new file mode 100644
index 0000000..46f1eae
--- /dev/null
+++ b/src/lock_seclabel_protocol-structs
@@ -0,0 +1,21 @@
+/* -*- c -*- */
+struct virLockSeclabelProtocolRememberSeclabelArgs {
+ virLockSeclabelProtocolNonNullString path;
+ virLockSeclabelProtocolNonNullString model;
+ virLockSeclabelProtocolNonNullString seclabel;
+};
+struct virLockSeclabelProtocolRememberSeclabelRet {
+ int ret;
What are the values of the 'ret' variable. Generally the
RPC methods deal with error status at the protocol header
level ?
+};
+struct virLockSeclabelProtocolRecallSeclabelArgs {
+ virLockSeclabelProtocolNonNullString path;
+ virLockSeclabelProtocolNonNullString model;
+};
+struct virLockSeclabelProtocolRecallSeclabelRet {
+ virLockSeclabelProtocolNonNullString seclabel;
+ int ret;
+};
+enum virLockSeclabelProtocolProcedure {
+ VIR_LOCK_SECLABEL_PROTOCOL_PROC_REMEMBER_SECLABEL = 1,
+ VIR_LOCK_SECLABEL_PROTOCOL_PROC_RECALL_SECLABEL = 2,
+};
Regards,
Daniel
--
|:
http://berrange.com -o-
http://www.flickr.com/photos/dberrange/ :|
|:
http://libvirt.org -o-
http://virt-manager.org :|
|:
http://autobuild.org -o-
http://search.cpan.org/~danberr/ :|
|:
http://entangle-photo.org -o-
http://live.gnome.org/gtk-vnc :|