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

Unified Diff: chrome/browser/chromeos/network_settings/onc_signature.h

Issue 10944009: Implementation of ONC signature, validator and normalizer. (Closed) Base URL: http://git.chromium.org/chromium/src.git@gperffix
Patch Set: Addressed comments (formatting, sorting). Minor change in policy.onc. Created 8 years, 2 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: chrome/browser/chromeos/network_settings/onc_signature.h
diff --git a/chrome/browser/chromeos/network_settings/onc_signature.h b/chrome/browser/chromeos/network_settings/onc_signature.h
new file mode 100644
index 0000000000000000000000000000000000000000..1f85d883307a6812b6f1a549f71a04222348df83
--- /dev/null
+++ b/chrome/browser/chromeos/network_settings/onc_signature.h
@@ -0,0 +1,45 @@
+// 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 CHROME_BROWSER_CHROMEOS_NETWORK_SETTINGS_ONC_SIGNATURE_H_
+#define CHROME_BROWSER_CHROMEOS_NETWORK_SETTINGS_ONC_SIGNATURE_H_
+
+#include <string>
+
+#include "base/values.h"
+
+namespace chromeos {
+namespace onc {
+
+struct OncValueSignature;
+
+struct OncFieldSignature {
+ const char* onc_field_name;
+ const char* shill_property_name;
+ const OncValueSignature* value_signature;
+};
+
+struct OncValueSignature {
+ base::Value::Type onc_type;
+ const OncFieldSignature* fields;
+ const OncValueSignature* onc_array_entry_signature;
+
+ const OncFieldSignature* GetFieldSignature(
+ const std::string& onc_field_name) const;
+};
+
+extern const OncValueSignature recommended_signature;
stevenjb 2012/10/11 19:54:00 These should use kRecommendedSignature style.
pneubeck (no reviews) 2012/10/15 13:57:44 Done.
+extern const OncValueSignature eap_signature;
+extern const OncValueSignature certificate_pattern_signature;
+extern const OncValueSignature ipsec_signature;
+extern const OncValueSignature openvpn_signature;
+extern const OncValueSignature vpn_signature;
+extern const OncValueSignature ethernet_signature;
+extern const OncValueSignature ipconfig_signature;
+extern const OncValueSignature network_configuration_signature;
+
+} // namespace onc
+} // namespace chromeos
+
+#endif // CHROME_BROWSER_CHROMEOS_NETWORK_SETTINGS_ONC_SIGNATURE_H_

Powered by Google App Engine
This is Rietveld 408576698