Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(10344)

Unified Diff: cloud_print/service/win/local_security_policy.h

Issue 10824294: Changed Windows account to run service. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 4 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: cloud_print/service/win/local_security_policy.h
diff --git a/cloud_print/service/win/local_security_policy.h b/cloud_print/service/win/local_security_policy.h
new file mode 100644
index 0000000000000000000000000000000000000000..317536d3f260469e862c77985b955ab393fdc9aa
--- /dev/null
+++ b/cloud_print/service/win/local_security_policy.h
@@ -0,0 +1,32 @@
+// Copyright (c) 2012 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#ifndef CLOUD_PRINT_SERVICE_WIN_LOCAL_SECURITY_POLICY_H_
+#define CLOUD_PRINT_SERVICE_WIN_LOCAL_SECURITY_POLICY_H_
+
+#include <wtypes.h> // Has to be before ntsecapi.h
+#include <ntsecapi.h>
+
+#include "base/basictypes.h"
+
+extern const wchar_t kSeServiceLogonRight[];
+
+class LocalSecurityPolicy {
+ public:
+ LocalSecurityPolicy();
+ ~LocalSecurityPolicy();
+
+ bool Open();
+ void Close();
+
+ bool IsPrivilegeSet(const wchar_t* username, const wchar_t* privilage) const;
+ bool SetPrivilege(const wchar_t* username, const wchar_t* privilage);
+
+ private:
+ LSA_HANDLE policy_;
+
+ DISALLOW_COPY_AND_ASSIGN(LocalSecurityPolicy);
+};
+
+#endif // CLOUD_PRINT_SERVICE_WIN_LOCAL_SECURITY_POLICY_H_

Powered by Google App Engine
This is Rietveld 408576698