1// Copyright (c) 2012 The Chromium OS 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#ifndef SYSTEM_API_DBUS_SERVICE_CONSTANTS_H_ 6#define SYSTEM_API_DBUS_SERVICE_CONSTANTS_H_ 7 8#include <stdint.h> // for uint32_t 9 10// We use relative includes here to make this compatible with both the 11// Chromium OS and Chromium environment. 12#include "apmanager/dbus-constants.h" 13#include "cros-disks/dbus-constants.h" 14#include "cryptohome/dbus-constants.h" 15#include "debugd/dbus-constants.h" 16#include "login_manager/dbus-constants.h" 17#include "lorgnette/dbus-constants.h" 18#include "permission_broker/dbus-constants.h" 19#include "power_manager/dbus-constants.h" 20#include "shill/dbus-constants.h" 21#include "update_engine/dbus-constants.h" 22 23namespace dbus { 24const char kDBusInterface[] = "org.freedesktop.DBus"; 25const char kDBusServiceName[] = "org.freedesktop.DBus"; 26const char kDBusServicePath[] = "/org/freedesktop/DBus"; 27 28// Object Manager interface 29const char kDBusObjectManagerInterface[] = "org.freedesktop.DBus.ObjectManager"; 30// Methods 31const char kDBusObjectManagerGetManagedObjects[] = "GetManagedObjects"; 32// Signals 33const char kDBusObjectManagerInterfacesAddedSignal[] = "InterfacesAdded"; 34const char kDBusObjectManagerInterfacesRemovedSignal[] = "InterfacesRemoved"; 35 36// Properties interface 37const char kDBusPropertiesInterface[] = "org.freedesktop.DBus.Properties"; 38// Methods 39const char kDBusPropertiesGet[] = "Get"; 40const char kDBusPropertiesSet[] = "Set"; 41const char kDBusPropertiesGetAll[] = "GetAll"; 42// Signals 43const char kDBusPropertiesChangedSignal[] = "PropertiesChanged"; 44} // namespace dbus 45 46namespace imageburn { 47const char kImageBurnServiceName[] = "org.chromium.ImageBurner"; 48const char kImageBurnServicePath[] = "/org/chromium/ImageBurner"; 49const char kImageBurnServiceInterface[] = "org.chromium.ImageBurnerInterface"; 50// Methods 51const char kBurnImage[] = "BurnImage"; 52// Signals 53const char kSignalBurnFinishedName[] = "burn_finished"; 54const char kSignalBurnUpdateName[] = "burn_progress_update"; 55} // namespace imageburn 56 57namespace speech_synthesis { 58const char kSpeechSynthesizerInterface[] = 59 "org.chromium.SpeechSynthesizerInterface"; 60const char kSpeechSynthesizerServicePath[] = "/org/chromium/SpeechSynthesizer"; 61const char kSpeechSynthesizerServiceName[] = "org.chromium.SpeechSynthesizer"; 62// Methods 63const char kSpeak[] = "Speak"; 64const char kStop[] = "Stop"; 65const char kIsSpeaking[] = "IsSpeaking"; 66const char kShutdown[] = "Shutdown"; 67} // namespace speech_synthesis 68 69namespace chromium { 70const char kChromiumInterface[] = "org.chromium.Chromium"; 71// Text-to-speech service signals. 72const char kTTSReadySignal[] = "TTSReady"; 73const char kTTSFailedSignal[] = "TTSFailed"; 74} // namespace chromium 75 76namespace chromeos { 77const char kLibCrosServiceName[] = "org.chromium.LibCrosService"; 78const char kLibCrosServicePath[] = "/org/chromium/LibCrosService"; 79const char kLibCrosServiceInterface[] = "org.chromium.LibCrosServiceInterface"; 80// Methods 81const char kResolveNetworkProxy[] = "ResolveNetworkProxy"; 82const char kCheckLiveness[] = "CheckLiveness"; 83const char kLockScreen[] = "LockScreen"; 84const char kSetDisplayPower[] = "SetDisplayPower"; 85const char kSetDisplaySoftwareDimming[] = "SetDisplaySoftwareDimming"; 86const char kTakeDisplayOwnership[] = "TakeDisplayOwnership"; 87const char kReleaseDisplayOwnership[] = "ReleaseDisplayOwnership"; 88// Values 89enum DisplayPowerState { 90 DISPLAY_POWER_ALL_ON = 0, 91 DISPLAY_POWER_ALL_OFF = 1, 92 DISPLAY_POWER_INTERNAL_OFF_EXTERNAL_ON = 2, 93 DISPLAY_POWER_INTERNAL_ON_EXTERNAL_OFF = 3, 94}; 95} // namespace chromeos 96 97namespace cromo { 98// cromo D-Bus service identifiers 99const char kCromoServiceName[] = "org.chromium.ModemManager"; 100const char kCromoServicePath[] = "/org/chromium/ModemManager"; 101 102// cromo D-Bus interfaces 103const char kModemInterface[] = "org.freedesktop.ModemManager.Modem"; 104const char kModemSimpleInterface[] = 105 "org.freedesktop.ModemManager.Modem.Simple"; 106const char kModemCdmaInterface[] = "org.freedesktop.ModemManager.Modem.Cdma"; 107const char kModemGsmInterface[] = "org.freedesktop.ModemManager.Modem.Gsm"; 108const char kModemGsmCardInterface[] = 109 "org.freedesktop.ModemManager.Modem.Gsm.Card"; 110const char kModemGsmNetworkInterface[] = 111 "org.freedesktop.ModemManager.Modem.Gsm.Network"; 112const char kModemGobiInterface[] = "org.chromium.ModemManager.Modem.Gobi"; 113} // namespace cromo 114 115namespace modemmanager { 116// ModemManager D-Bus service identifiers 117const char kModemManagerSMSInterface[] = 118 "org.freedesktop.ModemManager.Modem.Gsm.SMS"; 119 120// ModemManager function names. 121const char kSMSGetFunction[] = "Get"; 122const char kSMSDeleteFunction[] = "Delete"; 123const char kSMSListFunction[] = "List"; 124 125// ModemManager monitored signals 126const char kSMSReceivedSignal[] = "SmsReceived"; 127 128// ModemManager1 interfaces and signals 129// The canonical source for these constants is: 130// /usr/include/ModemManager/ModemManager-names.h 131const char kModemManager1ServiceName[] = "org.freedesktop.ModemManager1"; 132const char kModemManager1ServicePath[] = "/org/freedesktop/ModemManager1"; 133const char kModemManager1MessagingInterface[] = 134 "org.freedesktop.ModemManager1.Modem.Messaging"; 135const char kModemManager1SmsInterface[] = 136 "org.freedesktop.ModemManager1.Sms"; 137const char kSMSAddedSignal[] = "Added"; 138} // namespace modemmanager 139 140namespace wimax_manager { 141// WiMaxManager D-Bus service identifiers 142const char kWiMaxManagerServiceName[] = "org.chromium.WiMaxManager"; 143const char kWiMaxManagerServicePath[] = "/org/chromium/WiMaxManager"; 144const char kWiMaxManagerServiceError[] = "org.chromium.WiMaxManager.Error"; 145const char kWiMaxManagerInterface[] = "org.chromium.WiMaxManager"; 146const char kWiMaxManagerDeviceInterface[] = "org.chromium.WiMaxManager.Device"; 147const char kWiMaxManagerNetworkInterface[] = 148 "org.chromium.WiMaxManager.Network"; 149const char kDeviceObjectPathPrefix[] = "/org/chromium/WiMaxManager/Device/"; 150const char kNetworkObjectPathPrefix[] = "/org/chromium/WiMaxManager/Network/"; 151const char kDevicesProperty[] = "Devices"; 152const char kNetworksProperty[] = "Networks"; 153const char kEAPAnonymousIdentity[] = "EAPAnonymousIdentity"; 154const char kEAPUserIdentity[] = "EAPUserIdentity"; 155const char kEAPUserPassword[] = "EAPUserPassword"; 156 157enum DeviceStatus { 158 kDeviceStatusUninitialized, 159 kDeviceStatusDisabled, 160 kDeviceStatusReady, 161 kDeviceStatusScanning, 162 kDeviceStatusConnecting, 163 kDeviceStatusConnected 164}; 165} // namespace wimax_manager 166 167namespace bluetooth_plugin { 168// Service identifiers for the plugin interface added to the /org/bluez object. 169const char kBluetoothPluginServiceName[] = "org.bluez"; 170const char kBluetoothPluginInterface[] = "org.chromium.Bluetooth"; 171 172// Bluetooth plugin properties. 173const char kSupportsLEServices[] = "SupportsLEServices"; 174const char kSupportsConnInfo[] = "SupportsConnInfo"; 175} // namespace bluetooth_plugin 176 177namespace bluetooth_plugin_device { 178// Service identifiers for the plugin interface added to Bluetooth Device 179// objects. 180const char kBluetoothPluginServiceName[] = "org.bluez"; 181const char kBluetoothPluginInterface[] = "org.chromium.BluetoothDevice"; 182 183// Bluetooth Device plugin methods. 184const char kGetConnInfo[] = "GetConnInfo"; 185} // namespace bluetooth_plugin_device 186 187namespace bluetooth_adapter { 188// Bluetooth Adapter service identifiers. 189const char kBluetoothAdapterServiceName[] = "org.bluez"; 190const char kBluetoothAdapterInterface[] = "org.bluez.Adapter1"; 191 192// Bluetooth Adapter methods. 193const char kStartDiscovery[] = "StartDiscovery"; 194const char kSetDiscoveryFilter[] = "SetDiscoveryFilter"; 195const char kStopDiscovery[] = "StopDiscovery"; 196const char kRemoveDevice[] = "RemoveDevice"; 197 198// Bluetooth Adapter properties. 199const char kAddressProperty[] = "Address"; 200const char kNameProperty[] = "Name"; 201const char kAliasProperty[] = "Alias"; 202const char kClassProperty[] = "Class"; 203const char kPoweredProperty[] = "Powered"; 204const char kDiscoverableProperty[] = "Discoverable"; 205const char kPairableProperty[] = "Pairable"; 206const char kPairableTimeoutProperty[] = "PairableTimeout"; 207const char kDiscoverableTimeoutProperty[] = "DiscoverableTimeout"; 208const char kDiscoveringProperty[] = "Discovering"; 209const char kUUIDsProperty[] = "UUIDs"; 210const char kModaliasProperty[] = "Modalias"; 211 212// Bluetooth Adapter errors. 213const char kErrorNotReady[] = "org.bluez.Error.NotReady"; 214const char kErrorFailed[] = "org.bluez.Error.Failed"; 215const char kErrorNotAuthorized[] = "org.bluez.Error.NotAuthorized"; 216const char kErrorInvalidArguments[] = "org.bluez.Error.InvalidArguments"; 217 218// Bluetooth Adapter parameters supplied to SetDiscoveryFilter request. 219const char kDiscoveryFilterParameterUUIDs[] = "UUIDs"; 220const char kDiscoveryFilterParameterRSSI[] = "RSSI"; 221const char kDiscoveryFilterParameterPathloss[] = "Pathloss"; 222const char kDiscoveryFilterParameterTransport[] = "Transport"; 223} // namespace bluetooth_adapter 224 225namespace bluetooth_agent_manager { 226// Bluetooth Agent Manager service indentifiers 227const char kBluetoothAgentManagerServiceName[] = "org.bluez"; 228const char kBluetoothAgentManagerServicePath[] = "/org/bluez"; 229const char kBluetoothAgentManagerInterface[] = "org.bluez.AgentManager1"; 230 231// Bluetooth Agent Manager methods. 232const char kRegisterAgent[] = "RegisterAgent"; 233const char kUnregisterAgent[] = "UnregisterAgent"; 234const char kRequestDefaultAgent[] = "RequestDefaultAgent"; 235 236// Bluetooth capabilities. 237const char kNoInputNoOutputCapability[] = "NoInputNoOutput"; 238const char kDisplayOnlyCapability[] = "DisplayOnly"; 239const char kKeyboardOnlyCapability[] = "KeyboardOnly"; 240const char kDisplayYesNoCapability[] = "DisplayYesNo"; 241const char kKeyboardDisplayCapability[] = "KeyboardDisplay"; 242 243// Bluetooth Agent Manager errors. 244const char kErrorInvalidArguments[] = "org.bluez.Error.InvalidArguments"; 245const char kErrorAlreadyExists[] = "org.bluez.Error.AlreadyExists"; 246const char kErrorDoesNotExist[] = "org.bluez.Error.DoesNotExist"; 247} // namespace bluetooth_agent_manager 248 249 250namespace bluetooth_agent { 251// Bluetooth Agent service indentifiers 252const char kBluetoothAgentInterface[] = "org.bluez.Agent1"; 253 254// Bluetooth Agent methods. 255const char kRelease[] = "Release"; 256const char kRequestPinCode[] = "RequestPinCode"; 257const char kDisplayPinCode[] = "DisplayPinCode"; 258const char kRequestPasskey[] = "RequestPasskey"; 259const char kDisplayPasskey[] = "DisplayPasskey"; 260const char kRequestConfirmation[] = "RequestConfirmation"; 261const char kRequestAuthorization[] = "RequestAuthorization"; 262const char kAuthorizeService[] = "AuthorizeService"; 263const char kCancel[] = "Cancel"; 264 265// Bluetooth Agent errors. 266const char kErrorRejected[] = "org.bluez.Error.Rejected"; 267const char kErrorCanceled[] = "org.bluez.Error.Canceled"; 268} // namespace bluetooth_agent 269 270namespace bluetooth_device { 271// Bluetooth Device service identifiers. 272const char kBluetoothDeviceServiceName[] = "org.bluez"; 273const char kBluetoothDeviceInterface[] = "org.bluez.Device1"; 274 275// Bluetooth Device methods. 276const char kConnect[] = "Connect"; 277const char kDisconnect[] = "Disconnect"; 278const char kConnectProfile[] = "ConnectProfile"; 279const char kDisconnectProfile[] = "DisconnectProfile"; 280const char kPair[] = "Pair"; 281const char kCancelPairing[] = "CancelPairing"; 282// TODO(tengs): Remove deprecated constants after they are removed in the Chrome 283// codebase. (See crbug.com/430665). 284const char kStartConnectionMonitor[] = "StartConnectionMonitor"; // DEPRECATED 285const char kStopConnectionMonitor[] = "StopConnectionMonitor"; // DEPRECATED 286 287// Bluetooth Device properties. 288const char kAddressProperty[] = "Address"; 289const char kNameProperty[] = "Name"; 290const char kIconProperty[] = "Icon"; 291const char kClassProperty[] = "Class"; 292const char kAppearanceProperty[] = "Appearance"; 293const char kUUIDsProperty[] = "UUIDs"; 294const char kPairedProperty[] = "Paired"; 295const char kConnectedProperty[] = "Connected"; 296const char kTrustedProperty[] = "Trusted"; 297const char kBlockedProperty[] = "Blocked"; 298const char kAliasProperty[] = "Alias"; 299const char kAdapterProperty[] = "Adapter"; 300const char kLegacyPairingProperty[] = "LegacyPairing"; 301const char kModaliasProperty[] = "Modalias"; 302const char kRSSIProperty[] = "RSSI"; 303const char kTxPowerProperty[] = "TxPower"; 304const char kManufacturerDataProperty[] = "ManufacturerData"; 305const char kServiceDataProperty[] = "ServiceData"; 306const char kGattServicesProperty[] = "GattServices"; 307// TODO(tengs): Remove deprecated constants after they are removed in the Chrome 308// codebase. (See crbug.com/430665). 309const char kConnectionRSSI[] = "ConnectionRSSI"; // DEPRECATED 310const char kConnectionTXPower[] = "ConnectionTXPower"; // DEPRECATED 311const char kConnectionTXPowerMax[] = "ConnectionTXPowerMax"; // DEPRECATED 312 313// Bluetooth Device errors. 314const char kErrorNotReady[] = "org.bluez.Error.NotReady"; 315const char kErrorFailed[] = "org.bluez.Error.Failed"; 316const char kErrorInProgress[] = "org.bluez.Error.InProgress"; 317const char kErrorAlreadyConnected[] = "org.bluez.Error.AlreadyConnected"; 318const char kErrorNotConnected[] = "org.bluez.Error.NotConnected"; 319const char kErrorDoesNotExist[] = "org.bluez.Error.DoesNotExist"; 320const char kErrorInvalidArguments[] = "org.bluez.Error.InvalidArguments"; 321 322// Undocumented errors that we know BlueZ returns for Bluetooth Device methods. 323const char kErrorNotSupported[] = "org.bluez.Error.NotSupported"; 324const char kErrorAuthenticationCanceled[] = 325 "org.bluez.Error.AuthenticationCanceled"; 326const char kErrorAuthenticationFailed[] = 327 "org.bluez.Error.AuthenticationFailed"; 328const char kErrorAuthenticationRejected[] = 329 "org.bluez.Error.AuthenticationRejected"; 330const char kErrorAuthenticationTimeout[] = 331 "org.bluez.Error.AuthenticationTimeout"; 332const char kErrorConnectionAttemptFailed[] = 333 "org.bluez.Error.ConnectionAttemptFailed"; 334} // namespace bluetooth_device 335 336namespace bluetooth_gatt_characteristic { 337// Bluetooth GATT Characteristic service identifiers. The service name is used 338// only for characteristic objects hosted by bluetoothd. 339const char kBluetoothGattCharacteristicServiceName[] = "org.bluez"; 340const char kBluetoothGattCharacteristicInterface[] = 341 "org.bluez.GattCharacteristic1"; 342 343// Bluetooth GATT Characteristic methods. 344const char kReadValue[] = "ReadValue"; 345const char kWriteValue[] = "WriteValue"; 346const char kStartNotify[] = "StartNotify"; 347const char kStopNotify[] = "StopNotify"; 348 349// Bluetooth GATT Characteristic signals. 350const char kValueUpdatedSignal[] = "ValueUpdated"; 351 352// Bluetooth GATT Characteristic properties. 353const char kUUIDProperty[] = "UUID"; 354const char kServiceProperty[] = "Service"; 355const char kValueProperty[] = "Value"; 356const char kFlagsProperty[] = "Flags"; 357const char kNotifyingProperty[] = "Notifying"; 358const char kDescriptorsProperty[] = "Descriptors"; 359 360// Possible values for the "Flags" property. 361const char kFlagBroadcast[] = "broadcast"; 362const char kFlagRead[] = "read"; 363const char kFlagWriteWithoutResponse[] = "write-without-response"; 364const char kFlagWrite[] = "write"; 365const char kFlagNotify[] = "notify"; 366const char kFlagIndicate[] = "indicate"; 367const char kFlagAuthenticatedSignedWrites[] = "authenticated-signed-writes"; 368const char kFlagExtendedProperties[] = "extended-properties"; 369const char kFlagReliableWrite[] = "reliable-write"; 370const char kFlagWritableAuxiliaries[] = "writable-auxiliaries"; 371} // namespace bluetooth_gatt_characteristic 372 373namespace bluetooth_gatt_descriptor { 374// Bluetooth GATT Descriptor service identifiers. The service name is used 375// only for descriptor objects hosted by bluetoothd. 376const char kBluetoothGattDescriptorServiceName[] = "org.bluez"; 377const char kBluetoothGattDescriptorInterface[] = "org.bluez.GattDescriptor1"; 378 379// Bluetooth GATT Descriptor methods. 380const char kReadValue[] = "ReadValue"; 381const char kWriteValue[] = "WriteValue"; 382 383// Bluetooth GATT Descriptor properties. 384const char kUUIDProperty[] = "UUID"; 385const char kCharacteristicProperty[] = "Characteristic"; 386const char kValueProperty[] = "Value"; 387} // namespace bluetooth_gatt_descriptor 388 389namespace bluetooth_gatt_manager { 390// Bluetooth GATT Manager service identifiers. 391const char kBluetoothGattManagerServiceName[] = "org.bluez"; 392const char kBluetoothGattManagerInterface[] = "org.bluez.GattManager1"; 393 394// Bluetooth GATT Manager methods. 395const char kRegisterService[] = "RegisterService"; 396const char kUnregisterService[] = "UnregisterService"; 397 398// Bluetooth GATT Manager errors. 399const char kErrorInvalidArguments[] = "org.bluez.Error.InvalidArguments"; 400const char kErrorAlreadyExists[] = "org.bluez.Error.AlreadyExists"; 401const char kErrorDoesNotExist[] = "org.bluez.Error.DoesNotExist"; 402} // namespace bluetooth_gatt_manager 403 404namespace bluetooth_gatt_service { 405// Bluetooth GATT Service service identifiers. The service name is used 406// only for service objects hosted by bluetoothd. 407const char kBluetoothGattServiceServiceName[] = "org.bluez"; 408const char kBluetoothGattServiceInterface[] = "org.bluez.GattService1"; 409 410// Bluetooth GATT Service properties. 411const char kUUIDProperty[] = "UUID"; 412const char kDeviceProperty[] = "Device"; 413const char kPrimaryProperty[] = "Primary"; 414const char kIncludesProperty[] = "Includes"; 415const char kCharacteristicsProperty[] = "Characteristics"; 416 417// Bluetooth GATT Service errors. 418const char kErrorFailed[] = "org.bluez.Error.Failed"; 419const char kErrorInProgress[] = "org.bluez.Error.InProgress"; 420const char kErrorInvalidValueLength[] = "org.bluez.Error.InvalidValueLength"; 421const char kErrorNotAuthorized[] = "org.bluez.Error.NotAuthorized"; 422const char kErrorNotPaired[] = "org.bluez.Error.NotPaired"; 423const char kErrorNotSupported[] = "org.bluez.Error.NotSupported"; 424const char kErrorReadNotPermitted[] = "org.bluez.Error.ReadNotPermitted"; 425const char kErrorWriteNotPermitted[] = "org.bluez.Error.WriteNotPermitted"; 426} // namespace bluetooth_gatt_service 427 428namespace bluetooth_input { 429// Bluetooth Input service identifiers. 430const char kBluetoothInputServiceName[] = "org.bluez"; 431const char kBluetoothInputInterface[] = "org.bluez.Input1"; 432 433// Bluetooth Input properties. 434const char kReconnectModeProperty[] = "ReconnectMode"; 435 436// Bluetooth Input property values. 437const char kNoneReconnectModeProperty[] = "none"; 438const char kHostReconnectModeProperty[] = "host"; 439const char kDeviceReconnectModeProperty[] = "device"; 440const char kAnyReconnectModeProperty[] = "any"; 441} // namespace bluetooth_input 442 443namespace bluetooth_media { 444// Bluetooth Media service identifiers 445const char kBluetoothMediaServiceName[] = "org.bluez"; 446const char kBluetoothMediaInterface[] = "org.bluez.Media1"; 447 448// Bluetooth Media methods 449const char kRegisterEndpoint[] = "RegisterEndpoint"; 450const char kUnregisterEndpoint[] = "UnregisterEndpoint"; 451const char kRegisterPlayer[] = "RegisterPlayer"; 452const char kUnregisterPlayer[] = "UnregisterPlayer"; 453 454// Bluetooth Media errors 455const char kErrorFailed[] = "org.bluez.Error.Failed"; 456const char kErrorInvalidArguments[] = "org.bluez.Error.InvalidArguments"; 457const char kErrorNotSupported[] = "org.bluez.Error.NotSupported"; 458} // namespace bluetooth_media 459 460namespace bluetooth_media_endpoint { 461// Bluetooth Media Endpoint service identifiers 462const char kBluetoothMediaEndpointServiceName[] = "org.bluez"; 463const char kBluetoothMediaEndpointInterface[] = "org.bluez.MediaEndpoint1"; 464 465// Bluetooth Media Endpoint methods 466const char kSetConfiguration[] = "SetConfiguration"; 467const char kSelectConfiguration[] = "SelectConfiguration"; 468const char kClearConfiguration[] = "ClearConfiguration"; 469const char kRelease[] = "Release"; 470} // namespace bluetooth_media_endpoint 471 472namespace bluetooth_media_transport { 473// Bluetooth Media Transport service identifiers 474const char kBluetoothMediaTransportServiceName[] = "org.bluez"; 475const char kBluetoothMediaTransportInterface[] = "org.bluez.MediaTransport1"; 476 477// Bluetooth Media Transport methods 478const char kAcquire[] = "Acquire"; 479const char kTryAcquire[] = "TryAcquire"; 480const char kRelease[] = "Release"; 481 482// Bluetooth Media Transport property names. 483const char kDeviceProperty[] = "Device"; 484const char kUUIDProperty[] = "UUID"; 485const char kCodecProperty[] = "Codec"; 486const char kConfigurationProperty[] = "Configuration"; 487const char kStateProperty[] = "State"; 488const char kDelayProperty[] = "Delay"; 489const char kVolumeProperty[] = "Volume"; 490 491// Possible states for the "State" property 492const char kStateIdle[] = "idle"; 493const char kStatePending[] = "pending"; 494const char kStateActive[] = "active"; 495 496// Bluetooth Media Transport errors. 497const char kErrorFailed[] = "org.bluez.Error.Failed"; 498const char kErrorNotAuthorized[] = "org.bluez.Error.NotAuthorized"; 499const char kErrorNotAvailable[] = "org.bluez.Error.NotAvailable"; 500} // namespace bluetooth_media_transport 501 502namespace bluetooth_object_manager { 503// Bluetooth daemon Object Manager service identifiers. 504const char kBluetoothObjectManagerServiceName[] = "org.bluez"; 505const char kBluetoothObjectManagerServicePath[] = "/"; 506} // namespace bluetooth_object_manager 507 508namespace bluetooth_profile_manager { 509// Bluetooth Profile Manager service identifiers. 510const char kBluetoothProfileManagerServiceName[] = "org.bluez"; 511const char kBluetoothProfileManagerServicePath[] = "/org/bluez"; 512const char kBluetoothProfileManagerInterface[] = "org.bluez.ProfileManager1"; 513 514// Bluetooth Profile Manager methods. 515const char kRegisterProfile[] = "RegisterProfile"; 516const char kUnregisterProfile[] = "UnregisterProfile"; 517 518// Bluetooth Profile Manager option names. 519const char kNameOption[] = "Name"; 520const char kServiceOption[] = "Service"; 521const char kRoleOption[] = "Role"; 522const char kChannelOption[] = "Channel"; 523const char kPSMOption[] = "PSM"; 524const char kRequireAuthenticationOption[] = "RequireAuthentication"; 525const char kRequireAuthorizationOption[] = "RequireAuthorization"; 526const char kAutoConnectOption[] = "AutoConnect"; 527const char kServiceRecordOption[] = "ServiceRecord"; 528const char kVersionOption[] = "Version"; 529const char kFeaturesOption[] = "Features"; 530 531// Bluetooth Profile Manager option values. 532const char kClientRoleOption[] = "client"; 533const char kServerRoleOption[] = "server"; 534 535// Bluetooth Profile Manager errors. 536const char kErrorInvalidArguments[] = "org.bluez.Error.InvalidArguments"; 537const char kErrorAlreadyExists[] = "org.bluez.Error.AlreadyExists"; 538const char kErrorDoesNotExist[] = "org.bluez.Error.DoesNotExist"; 539} // namespace bluetooth_profile_manager 540 541namespace bluetooth_profile { 542// Bluetooth Profile service identifiers. 543const char kBluetoothProfileInterface[] = "org.bluez.Profile1"; 544 545// Bluetooth Profile methods. 546const char kRelease[] = "Release"; 547const char kNewConnection[] = "NewConnection"; 548const char kRequestDisconnection[] = "RequestDisconnection"; 549const char kCancel[] = "Cancel"; 550 551// Bluetooth Profile property names. 552const char kVersionProperty[] = "Version"; 553const char kFeaturesProperty[] = "Features"; 554 555// Bluetooth Profile errors. 556const char kErrorRejected[] = "org.bluez.Error.Rejected"; 557const char kErrorCanceled[] = "org.bluez.Error.Canceled"; 558} // namespace bluetooth_profile 559 560namespace bluetooth_advertisement { 561// Bluetooth LE Advertisement service identifiers. 562const char kBluetoothAdvertisementServiceName[] = "org.bluez"; 563const char kBluetoothAdvertisementInterface[] = 564 "org.bluez.LEAdvertisement1"; 565 566// Bluetooth Advertisement methods. 567const char kRelease[] = "Release"; 568 569// Bluetooth Advertisement properties. 570const char kManufacturerDataProperty[] = "ManufacturerData"; 571const char kServiceUUIDsProperty[] = "ServiceUUIDs"; 572const char kServiceDataProperty[] = "ServiceData"; 573const char kSolicitUUIDsProperty[] = "SolicitUUIDs"; 574const char kTypeProperty[] = "Type"; 575const char kIncludeTxPowerProperty[] = "IncludeTxPower"; 576 577// Possible values for the "Type" property. 578const char kTypeBroadcast[] = "broadcast"; 579const char kTypePeripheral[] = "peripheral"; 580 581} // namespace bluetooth_advertisement 582 583namespace bluetooth_advertising_manager { 584// Bluetooth LE Advertising Manager service identifiers. 585const char kBluetoothAdvertisingManagerServiceName[] = "org.bluez"; 586const char kBluetoothAdvertisingManagerInterface[] = 587 "org.bluez.LEAdvertisingManager1"; 588 589// Bluetooth LE Advertising Manager methods. 590const char kRegisterAdvertisement[] = "RegisterAdvertisement"; 591const char kUnregisterAdvertisement[] = "UnregisterAdvertisement"; 592 593// Bluetooth LE Advertising Manager errors. 594const char kErrorAlreadyExists[] = "org.bluez.Error.AlreadyExists"; 595const char kErrorDoesNotExist[] = "org.bluez.Error.DoesNotExist"; 596const char kErrorFailed[] = "org.bluez.Error.Failed"; 597const char kErrorInvalidArguments[] = "org.bluez.Error.InvalidArguments"; 598const char kErrorInvalidLength[] = "org.bluez.Error.InvalidLength"; 599} // namespace bluetooth_advertising_manager 600 601namespace nfc_adapter { 602// NFC Adapter service identifiers. 603const char kNfcAdapterServiceName[] = "org.neard"; 604const char kNfcAdapterInterface[] = "org.neard.Adapter"; 605 606// NFC Adapter methods. 607const char kStartEmulation[] = "StartEmulation"; 608const char kStartPollLoop[] = "StartPollLoop"; 609const char kStopEmulation[] = "StopEmulation"; 610const char kStopPollLoop[] = "StopPollLoop"; 611 612// NFC Adapter signals. 613const char kTagFoundSignal[] = "TagFound"; 614const char kTagLostSignal[] = "TagLost"; 615 616// NFC Adapter properties. 617const char kDevicesProperty[] = "Devices"; 618const char kModeProperty[] = "Mode"; 619const char kPollingProperty[] = "Polling"; 620const char kPoweredProperty[] = "Powered"; 621const char kProtocolsProperty[] = "Protocols"; 622const char kTagsProperty[] = "Tags"; 623 624// NFC Adapter mode values. 625const char kModeInitiator[] = "Initiator"; 626const char kModeTarget[] = "Target"; 627const char kModeIdle[] = "Idle"; 628 629} // namespace nfc_adapter 630 631namespace nfc_device { 632// NFC Device service identifiers. 633const char kNfcDeviceServiceName[] = "org.neard"; 634const char kNfcDeviceInterface[] = "org.neard.Device"; 635 636// NFC Device methods. 637const char kPush[] = "Push"; 638 639// NFC Device properties. 640const char kRecordsProperty[] = "Records"; 641 642} // namespace nfc_device 643 644namespace nfc_manager { 645// NFC Manager service identifiers. 646const char kNfcManagerServiceName[] = "org.neard"; 647const char kNfcManagerServicePath[] = "/"; 648const char kNfcManagerInterface[] = "org.neard.Manager"; 649 650// NFC Manager methods. 651const char kRegisterHandoverAgent[] = "RegisterHandoverAgent"; 652const char kUnregisterHandoverAgent[] = "UnregisterHandoverAgent"; 653const char kRegisterNDEFAgent[] = "RegisterNDEFAgent"; 654const char kUnregisterNDEFAgent[] = "UnregisterNDEFAgent"; 655 656// NFC Manager signals. 657const char kAdapterAddedSignal[] = "AdapterAdded"; 658const char kAdapterRemovedSignal[] = "AdapterRemoved"; 659 660// NFC Manager properties. 661const char kAdaptersProperty[] = "Adapters"; 662 663// NFC Manager handover carrier values. 664const char kCarrierBluetooth[] = "bluetooth"; 665const char kCarrierWifi[] = "wifi"; 666} // namespace nfc_manager 667 668namespace nfc_tag { 669// NFC Tag service identifiers. 670const char kNfcTagServiceName[] = "org.neard"; 671const char kNfcTagInterface[] = "org.neard.Tag"; 672 673// NFC Tag methods. 674const char kWrite[] = "Write"; 675 676// NFC Tag properties. 677const char kProtocolProperty[] = "Protocol"; 678const char kReadOnlyProperty[] = "ReadOnly"; 679const char kRecordsProperty[] = "Records"; 680const char kTypeProperty[] = "Type"; 681 682// NFC Tag type values. 683const char kTagType1[] = "Type 1"; 684const char kTagType2[] = "Type 2"; 685const char kTagType3[] = "Type 3"; 686const char kTagType4[] = "Type 4"; 687 688} // namespace nfc_tag 689 690namespace nfc_record { 691// NFC Record service identifiers. 692const char kNfcRecordServiceName[] = "org.neard"; 693const char kNfcRecordInterface[] = "org.neard.Record"; 694 695// NFC Record properties. 696const char kTypeProperty[] = "Type"; 697const char kEncodingProperty[] = "Encoding"; 698const char kLanguageProperty[] = "Language"; 699const char kRepresentationProperty[] = "Representation"; 700const char kUriProperty[] = "URI"; 701const char kMimeTypeProperty[] = "MIMEType"; 702const char kSizeProperty[] = "Size"; 703const char kActionProperty[] = "Action"; 704 705// NFC Record type values. 706const char kTypeSmartPoster[] = "SmartPoster"; 707const char kTypeText[] = "Text"; 708const char kTypeUri[] = "URI"; 709const char kTypeHandoverRequest[] = "HandoverRequest"; 710const char kTypeHandoverSelect[] = "HandoverSelect"; 711const char kTypeHandoverCarrier[] = "HandoverCarrier"; 712 713// NFC Record encoding values. 714const char kEncodingUtf8[] = "UTF-8"; 715const char kEncodingUtf16[] = "UTF-16"; 716} // namespace nfc_record 717 718namespace nfc_handover_agent { 719// NFC Handover Agent service identifiers. 720// TODO(armansito): Add the correct service name once the HandoverAgent feature 721// is fully implemented. 722const char kNfcHandoverAgentServiceName[] = ""; 723const char kNfcHandoverInterface[] = "org.neard.HandoverAgent"; 724 725// NFC Handover Agent methods. 726const char kRequestOOB[] = "RequestOOB"; 727const char kPushOOB[] = "PushOOB"; 728const char kRelease[] = "Release"; 729 730// NFC Handover Agent properties. 731const char kEIRProperty[] = "EIR"; 732const char kNokiaDotComBtProperty[] = "nokia.com:bt"; 733const char kWSCProperty[] = "WSC"; 734const char kStateProperty[] = "State"; 735} // namespace nfc_handover_agent 736 737namespace nfc_ndef_agent { 738// NFC NDEF Agent service identifiers. 739// TODO(armansito): Add the correct service name once the NDEFAgent feature 740// is fully implemented. 741const char kNfcNdefAgentServiceName[] = ""; 742const char kNfcNdefAgentInterface[] = "org.neard.NDEFAgent"; 743 744// NFC NDEF Agent methods. 745const char kGetNDEF[] = "GetNDEF"; 746const char kRelease[] = "Release"; 747 748// NFC NDEF properties. 749const char kNDEFProperty[] = "NDEF"; 750const char kRecordProperty[] = "Record"; 751} // namespace nfc_ndef_agent 752 753namespace nfc_common { 754// NFC Adapter/Tag protocol values. 755const char kProtocolFelica[] = "Felica"; 756const char kProtocolMifare[] = "MIFARE"; 757const char kProtocolJewel[] = "Jewel"; 758const char kProtocolIsoDep[] = "ISO-DEP"; 759const char kProtocolNfcDep[] = "NFC-DEP"; 760 761// Common methods for NFC property access and signals. 762const char kGetProperties[] = "GetProperties"; 763const char kSetProperty[] = "SetProperty"; 764const char kPropertyChangedSignal[] = "PropertyChanged"; 765} // namespace nfc_common 766 767namespace nfc_error { 768// NFC errors. 769const char kAlreadyExists[] = "org.neard.Error.AlreadyExists"; 770const char kDoesNotExist[] = "org.neard.Error.DoesNotExist"; 771const char kFailed[] = "org.neard.Error.Failed"; 772const char kInProgress[] = "org.neard.Error.InProgress"; 773const char kInvalidArguments[] = "org.neard.Error.InvalidArguments"; 774const char kNotReady[] = "org.neard.Error.NotReady"; 775const char kNotSupported[] = "org.neard.Error.NotSupported"; 776const char kPermissionDenied[] = "org.neard.Error.PermissionDenied"; 777 778// NFC Handover Agent errors. 779const char kHandoverAgentFailed[] = "org.neard.HandoverAgent.Error.Failed"; 780const char kHandoverAgentInProgress[] = 781 "org.neard.HandoverAgent.Error.InProgress"; 782} // namespace nfc_error 783 784namespace mtpd { 785const char kMtpdInterface[] = "org.chromium.Mtpd"; 786const char kMtpdServicePath[] = "/org/chromium/Mtpd"; 787const char kMtpdServiceName[] = "org.chromium.Mtpd"; 788const char kMtpdServiceError[] = "org.chromium.Mtpd.Error"; 789 790// Methods. 791const char kEnumerateStorages[] = "EnumerateStorages"; 792const char kGetStorageInfo[] = "GetStorageInfo"; 793const char kGetStorageInfoFromDevice[] = "GetStorageInfoFromDevice"; 794const char kOpenStorage[] = "OpenStorage"; 795const char kCloseStorage[] = "CloseStorage"; 796const char kReadDirectoryEntryIds[] = "ReadDirectoryEntryIds"; 797const char kGetFileInfo[] = "GetFileInfo"; 798const char kReadFileChunk[] = "ReadFileChunk"; 799const char kCopyFileFromLocal[] = "CopyFileFromLocal"; 800const char kDeleteObject[] = "DeleteObject"; 801const char kRenameObject[] = "RenameObject"; 802const char kCreateDirectory[] = "CreateDirectory"; 803 804// Signals. 805const char kMTPStorageAttached[] = "MTPStorageAttached"; 806const char kMTPStorageDetached[] = "MTPStorageDetached"; 807 808// For FileEntry struct: 809const uint32_t kInvalidFileId = 0xffffffff; 810 811// For OpenStorage method: 812const char kReadOnlyMode[] = "ro"; 813const char kReadWriteMode[] = "rw"; 814 815// For GetFileInfo() method: 816// The id of the root node in a storage, as defined by the PTP/MTP standards. 817// Use this when referring to the root node in the context of GetFileInfo(). 818const uint32_t kRootFileId = 0; 819} // namespace mtpd 820 821namespace system_clock { 822const char kSystemClockInterface[] = "org.torproject.tlsdate"; 823const char kSystemClockServicePath[] = "/org/torproject/tlsdate"; 824const char kSystemClockServiceName[] = "org.torproject.tlsdate"; 825 826// Methods. 827const char kSystemClockCanSet[] = "CanSetTime"; 828const char kSystemClockSet[] = "SetTime"; 829 830// Signals. 831const char kSystemClockUpdated[] = "TimeUpdated"; 832} // namespace system_clock 833 834namespace cras { 835const char kCrasServicePath[] = "/org/chromium/cras"; 836const char kCrasServiceName[] = "org.chromium.cras"; 837const char kCrasControlInterface[] = "org.chromium.cras.Control"; 838 839// Methods. 840const char kSetOutputVolume[] = "SetOutputVolume"; 841const char kSetOutputNodeVolume[] = "SetOutputNodeVolume"; 842const char kSwapLeftRight[] = "SwapLeftRight"; 843const char kSetOutputMute[] = "SetOutputMute"; 844const char kSetOutputUserMute[] = "SetOutputUserMute"; 845const char kSetSuspendAudio[] = "SetSuspendAudio"; 846const char kSetInputGain[] = "SetInputGain"; 847const char kSetInputNodeGain[] = "SetInputNodeGain"; 848const char kSetInputMute[] = "SetInputMute"; 849const char kGetVolumeState[] = "GetVolumeState"; 850const char kGetNodes[] = "GetNodes"; 851const char kSetActiveOutputNode[] = "SetActiveOutputNode"; 852const char kSetActiveInputNode[] = "SetActiveInputNode"; 853const char kAddActiveOutputNode[] = "AddActiveOutputNode"; 854const char kAddActiveInputNode[] = "AddActiveInputNode"; 855const char kRemoveActiveOutputNode[] = "RemoveActiveOutputNode"; 856const char kRemoveActiveInputNode[] = "RemoveActiveInputNode"; 857const char kGetNumberOfActiveStreams[] = "GetNumberOfActiveStreams"; 858const char kGetNumberOfActiveInputStreams[] = "GetNumberOfActiveInputStreams"; 859const char kGetNumberOfActiveOutputStreams[] = "GetNumberOfActiveOutputStreams"; 860 861// Names of properties returned by GetNodes() 862const char kIsInputProperty[] = "IsInput"; 863const char kIdProperty[] = "Id"; 864const char kTypeProperty[] = "Type"; 865const char kNameProperty[] = "Name"; 866const char kDeviceNameProperty[] = "DeviceName"; 867const char kActiveProperty[] = "Active"; 868const char kPluggedTimeProperty[] = "PluggedTime"; 869const char kMicPositionsProperty[] = "MicPositions"; 870const char kStableDeviceIdProperty[] = "StableDeviceId"; 871 872// Signals. 873const char kOutputVolumeChanged[] = "OutputVolumeChanged"; 874const char kOutputMuteChanged[] = "OutputMuteChanged"; 875const char kNodeLeftRightSwappedChanged[] = "NodeLeftRightSwappedChanged"; 876const char kInputGainChanged[] = "InputGainChanged"; 877const char kInputMuteChanged[] = "InputMuteChanged"; 878const char kNodesChanged[] = "NodesChanged"; 879const char kActiveOutputNodeChanged[] = "ActiveOutputNodeChanged"; 880const char kActiveInputNodeChanged[] = "ActiveInputNodeChanged"; 881const char kNumberOfActiveStreamsChanged[] = "NumberOfActiveStreamsChanged"; 882} // namespace cras 883 884namespace feedback { 885const char kFeedbackServicePath[] = "/org/chromium/feedback"; 886const char kFeedbackServiceName[] = "org.chromium.feedback"; 887 888// Methods. 889const char kSendFeedback[] = "SendFeedback"; 890} // namespace feedback 891 892namespace easy_unlock { 893const char kEasyUnlockServicePath[] = "/org/chromium/EasyUnlock"; 894const char kEasyUnlockServiceName[] = "org.chromium.EasyUnlock"; 895const char kEasyUnlockServiceInterface[] = "org.chromium.EasyUnlock"; 896 897// Values supplied as enrcryption type to CreateSecureMessage and 898// UnwrapSecureMessage methods. 899const char kEncryptionTypeNone[] = "NONE"; 900const char kEncryptionTypeAES256CBC[] = "AES_256_CBC"; 901 902// Values supplied as signature type to CreateSecureMessage and 903// UnwrapSecureMessage methods. 904const char kSignatureTypeECDSAP256SHA256[] = "ECDSA_P256_SHA256"; 905const char kSignatureTypeHMACSHA256[] = "HMAC_SHA256"; 906 907// Values supplied as key algorithm to WrapPublicKey method. 908const char kKeyAlgorithmRSA[] = "RSA"; 909const char kKeyAlgorithmECDSA[] = "ECDSA"; 910 911// Methods 912const char kPerformECDHKeyAgreementMethod[] = "PerformECDHKeyAgreement"; 913const char kWrapPublicKeyMethod[] = "WrapPublicKey"; 914const char kGenerateEcP256KeyPairMethod[] = "GenerateEcP256KeyPair"; 915const char kCreateSecureMessageMethod[] = "CreateSecureMessage"; 916const char kUnwrapSecureMessageMethod[] = "UnwrapSecureMessage"; 917} // namespace easy_unlock 918 919#endif // SYSTEM_API_DBUS_SERVICE_CONSTANTS_H_ 920