OLD | NEW |
1 // Copyright (c) 2010 The Chromium OS Authors. All rights reserved. | 1 // Copyright (c) 2010 The Chromium OS Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #include <cstdio> | 5 #include <cstdio> |
6 #include <dlfcn.h> | 6 #include <dlfcn.h> |
7 #include <string.h> | 7 #include <string.h> |
8 #include <vector> | 8 #include <vector> |
9 | 9 |
10 #include <base/basictypes.h> | 10 #include <base/basictypes.h> |
(...skipping 183 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
194 | 194 |
195 // Synaptics | 195 // Synaptics |
196 DECL_FUNC_2(SetSynapticsParameter, void, SynapticsParameter, int); | 196 DECL_FUNC_2(SetSynapticsParameter, void, SynapticsParameter, int); |
197 | 197 |
198 // Touchpad | 198 // Touchpad |
199 DECL_FUNC_1(SetTouchpadSensitivity, void, int); | 199 DECL_FUNC_1(SetTouchpadSensitivity, void, int); |
200 DECL_FUNC_1(SetTouchpadTapToClick, void, bool); | 200 DECL_FUNC_1(SetTouchpadTapToClick, void, bool); |
201 | 201 |
202 // Login | 202 // Login |
203 DECL_FUNC_2(CheckWhitelist, bool, const char*, std::vector<uint8>*); | 203 DECL_FUNC_2(CheckWhitelist, bool, const char*, std::vector<uint8>*); |
| 204 DECL_FUNC_2(CheckWhitelistSafe, bool, const char*, CryptoBlob**); |
204 DECL_FUNC_0(EmitLoginPromptReady, bool); | 205 DECL_FUNC_0(EmitLoginPromptReady, bool); |
205 DECL_FUNC_1(EnumerateWhitelisted, bool, std::vector<std::string>*); | 206 DECL_FUNC_1(EnumerateWhitelisted, bool, std::vector<std::string>*); |
| 207 DECL_FUNC_1(EnumerateWhitelistedSafe, bool, UserList**); |
| 208 DECL_FUNC_2(CreateCryptoBlob, CryptoBlob*, const uint8*, const int); |
| 209 DECL_FUNC_4(CreateProperty, |
| 210 Property*, |
| 211 const char*, |
| 212 const char*, |
| 213 const uint8*, |
| 214 const int); |
| 215 DECL_FUNC_1(CreateUserList, UserList*, char**); |
| 216 DECL_FUNC_1(FreeCryptoBlob, void, CryptoBlob*); |
| 217 DECL_FUNC_1(FreeProperty, void, Property*); |
| 218 DECL_FUNC_1(FreeUserList, void, UserList*); |
206 DECL_FUNC_2(RestartJob, bool, int, const char*); | 219 DECL_FUNC_2(RestartJob, bool, int, const char*); |
207 DECL_FUNC_3(RetrieveProperty, | 220 DECL_FUNC_3(RetrieveProperty, |
208 bool, | 221 bool, |
209 const char*, | 222 const char*, |
210 std::string*, | 223 std::string*, |
211 std::vector<uint8>*); | 224 std::vector<uint8>*); |
| 225 DECL_FUNC_2(RetrievePropertySafe, bool, const char*, Property**); |
212 DECL_FUNC_1(SetOwnerKey, bool, const std::vector<uint8>&); | 226 DECL_FUNC_1(SetOwnerKey, bool, const std::vector<uint8>&); |
| 227 DECL_FUNC_1(SetOwnerKeySafe, bool, const CryptoBlob*); |
213 DECL_FUNC_2(StartSession, bool, const char*, const char*); | 228 DECL_FUNC_2(StartSession, bool, const char*, const char*); |
214 DECL_FUNC_1(StopSession, bool, const char*); | 229 DECL_FUNC_1(StopSession, bool, const char*); |
215 DECL_FUNC_3(StoreProperty, | 230 DECL_FUNC_3(StoreProperty, |
216 bool, | 231 bool, |
217 const char*, | 232 const char*, |
218 const char*, | 233 const char*, |
219 const std::vector<uint8>&); | 234 const std::vector<uint8>&); |
| 235 DECL_FUNC_1(StorePropertySafe, bool, const Property*); |
220 DECL_FUNC_2(Unwhitelist, bool, const char*, const std::vector<uint8>&); | 236 DECL_FUNC_2(Unwhitelist, bool, const char*, const std::vector<uint8>&); |
| 237 DECL_FUNC_2(UnwhitelistSafe, bool, const char*, const CryptoBlob*); |
221 DECL_FUNC_2(Whitelist, bool, const char*, const std::vector<uint8>&); | 238 DECL_FUNC_2(Whitelist, bool, const char*, const std::vector<uint8>&); |
| 239 DECL_FUNC_2(WhitelistSafe, bool, const char*, const CryptoBlob*); |
222 DECL_FUNC_2(MonitorSession, SessionConnection, SessionMonitor, void*); | 240 DECL_FUNC_2(MonitorSession, SessionConnection, SessionMonitor, void*); |
223 DECL_FUNC_1(DisconnectSession, void, SessionConnection); | 241 DECL_FUNC_1(DisconnectSession, void, SessionConnection); |
224 | 242 |
225 // Screen Lock | 243 // Screen Lock |
226 DECL_FUNC_2(MonitorScreenLock, | 244 DECL_FUNC_2(MonitorScreenLock, |
227 ScreenLockConnection, ScreenLockMonitor, void*); | 245 ScreenLockConnection, ScreenLockMonitor, void*); |
228 DECL_FUNC_1(DisconnectScreenLock, void, ScreenLockConnection); | 246 DECL_FUNC_1(DisconnectScreenLock, void, ScreenLockConnection); |
229 DECL_FUNC_0(NotifyScreenLockCompleted, void); | 247 DECL_FUNC_0(NotifyScreenLockCompleted, void); |
230 DECL_FUNC_0(NotifyScreenLockRequested, void); | 248 DECL_FUNC_0(NotifyScreenLockRequested, void); |
231 DECL_FUNC_0(NotifyScreenUnlockRequested, void); | 249 DECL_FUNC_0(NotifyScreenUnlockRequested, void); |
(...skipping 211 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
443 | 461 |
444 // Synaptics | 462 // Synaptics |
445 INIT_FUNC(SetSynapticsParameter); | 463 INIT_FUNC(SetSynapticsParameter); |
446 | 464 |
447 // Touchpad | 465 // Touchpad |
448 INIT_FUNC(SetTouchpadSensitivity); | 466 INIT_FUNC(SetTouchpadSensitivity); |
449 INIT_FUNC(SetTouchpadTapToClick); | 467 INIT_FUNC(SetTouchpadTapToClick); |
450 | 468 |
451 // Login | 469 // Login |
452 INIT_FUNC(CheckWhitelist); | 470 INIT_FUNC(CheckWhitelist); |
| 471 INIT_FUNC(CheckWhitelistSafe); |
453 INIT_FUNC(EmitLoginPromptReady); | 472 INIT_FUNC(EmitLoginPromptReady); |
454 INIT_FUNC(EnumerateWhitelisted); | 473 INIT_FUNC(EnumerateWhitelisted); |
| 474 INIT_FUNC(EnumerateWhitelistedSafe); |
| 475 INIT_FUNC(CreateCryptoBlob); |
| 476 INIT_FUNC(CreateProperty); |
| 477 INIT_FUNC(CreateUserList); |
| 478 INIT_FUNC(FreeCryptoBlob); |
| 479 INIT_FUNC(FreeProperty); |
| 480 INIT_FUNC(FreeUserList); |
455 INIT_FUNC(RestartJob); | 481 INIT_FUNC(RestartJob); |
456 INIT_FUNC(RetrieveProperty); | 482 INIT_FUNC(RetrieveProperty); |
| 483 INIT_FUNC(RetrievePropertySafe); |
457 INIT_FUNC(SetOwnerKey); | 484 INIT_FUNC(SetOwnerKey); |
| 485 INIT_FUNC(SetOwnerKeySafe); |
458 INIT_FUNC(StartSession); | 486 INIT_FUNC(StartSession); |
459 INIT_FUNC(StopSession); | 487 INIT_FUNC(StopSession); |
460 INIT_FUNC(StoreProperty); | 488 INIT_FUNC(StoreProperty); |
| 489 INIT_FUNC(StorePropertySafe); |
461 INIT_FUNC(Unwhitelist); | 490 INIT_FUNC(Unwhitelist); |
| 491 INIT_FUNC(UnwhitelistSafe); |
462 INIT_FUNC(Whitelist); | 492 INIT_FUNC(Whitelist); |
| 493 INIT_FUNC(WhitelistSafe); |
463 INIT_FUNC(MonitorSession); | 494 INIT_FUNC(MonitorSession); |
464 INIT_FUNC(DisconnectSession); | 495 INIT_FUNC(DisconnectSession); |
465 | 496 |
466 // Screen Lock | 497 // Screen Lock |
467 INIT_FUNC(MonitorScreenLock); | 498 INIT_FUNC(MonitorScreenLock); |
468 INIT_FUNC(DisconnectScreenLock); | 499 INIT_FUNC(DisconnectScreenLock); |
469 INIT_FUNC(NotifyScreenLockCompleted); | 500 INIT_FUNC(NotifyScreenLockCompleted); |
470 INIT_FUNC(NotifyScreenLockRequested); | 501 INIT_FUNC(NotifyScreenLockRequested); |
471 INIT_FUNC(NotifyScreenUnlockRequested); | 502 INIT_FUNC(NotifyScreenUnlockRequested); |
472 INIT_FUNC(NotifyScreenUnlockCompleted); | 503 INIT_FUNC(NotifyScreenUnlockCompleted); |
(...skipping 57 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
530 // System | 561 // System |
531 INIT_FUNC(GetTimezoneID); | 562 INIT_FUNC(GetTimezoneID); |
532 INIT_FUNC(SetTimezoneID); | 563 INIT_FUNC(SetTimezoneID); |
533 INIT_FUNC(GetMachineInfo); | 564 INIT_FUNC(GetMachineInfo); |
534 INIT_FUNC(FreeMachineInfo); | 565 INIT_FUNC(FreeMachineInfo); |
535 | 566 |
536 return error_string.empty(); | 567 return error_string.empty(); |
537 } | 568 } |
538 | 569 |
539 } // namespace chromeos | 570 } // namespace chromeos |
OLD | NEW |