OLD | NEW |
---|---|
(Empty) | |
1 // Copyright 2014 The Chromium Authors. All rights reserved. | |
2 // Use of this source code is governed by a BSD-style license that can be | |
3 // found in the LICENSE file. | |
4 | |
5 #include "components/wifi_sync/wifi_security_class.h" | |
6 | |
7 #include <string> | |
erikwright (departed)
2014/12/08 21:21:36
not needed (in header)
mukesh agrawal
2014/12/09 01:41:11
Done.
| |
8 | |
9 #include "third_party/cros_system_api/dbus/service_constants.h" | |
10 | |
11 namespace wifi_sync { | |
12 | |
13 WifiSecurityClass WifiSecurityClassFromShillSecurity( | |
14 const std::string& security_in) { | |
15 if (security_in == shill::kSecurityNone) | |
16 return SECURITY_CLASS_NONE; | |
17 else if (security_in == shill::kSecurityWep) | |
18 return SECURITY_CLASS_WEP; | |
19 else if (security_in == shill::kSecurityPsk) | |
20 return SECURITY_CLASS_PSK; | |
21 else if (security_in == shill::kSecurity8021x) | |
22 return SECURITY_CLASS_802_1X; | |
23 return SECURITY_CLASS_INVALID; | |
24 } | |
25 | |
26 } // namespace wifi_sync | |
OLD | NEW |