aboutsummaryrefslogtreecommitdiff
path: root/gd/hci/facade.proto
blob: 4ccfccbd5481774c4dfe3e87c9973b258280239b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
syntax = "proto3";

package bluetooth.hci;

import "google/protobuf/empty.proto";
import "facade/common.proto";

service AclManagerFacade {
  rpc ReadLocalAddress(google.protobuf.Empty) returns (facade.BluetoothAddress) {}
  rpc SetPageScanMode(PageScanMode) returns (google.protobuf.Empty) {}
  rpc Connect(facade.BluetoothAddress) returns (google.protobuf.Empty) {}
  rpc Disconnect(facade.BluetoothAddress) returns (google.protobuf.Empty) {}
  rpc FetchConnectionComplete(facade.EventStreamRequest) returns (stream ConnectionEvent) {}
  rpc FetchDisconnection(facade.EventStreamRequest) returns (stream DisconnectionEvent) {}
  rpc FetchConnectionFailed(facade.EventStreamRequest) returns (stream ConnectionFailedEvent) {}
  rpc SendAclData(AclData) returns (google.protobuf.Empty) {}
  rpc FetchAclData(facade.EventStreamRequest) returns (stream AclData) {}
  rpc TestInternalHciCommands(google.protobuf.Empty) returns (google.protobuf.Empty) {}
  rpc TestInternalHciLeCommands(google.protobuf.Empty) returns (google.protobuf.Empty) {}
}

service ClassicSecurityManagerFacade {
  rpc LinkKeyRequestReply(LinkKeyRequestReplyMessage) returns (google.protobuf.Empty) {}
  rpc LinkKeyRequestNegativeReply(facade.BluetoothAddress) returns (google.protobuf.Empty) {}
  rpc PinCodeRequestReply(PinCodeRequestReplyMessage) returns (google.protobuf.Empty) {}
  rpc PinCodeRequestNegativeReply(facade.BluetoothAddress) returns (google.protobuf.Empty) {}
  rpc IoCapabilityRequestReply(IoCapabilityRequestReplyMessage) returns (google.protobuf.Empty) {}
  rpc IoCapabilityRequestNegativeReply(IoCapabilityRequestNegativeReplyMessage) returns (google.protobuf.Empty) {}
  rpc UserConfirmationRequestReply(facade.BluetoothAddress) returns (google.protobuf.Empty) {}
  rpc UserConfirmationRequestNegativeReply(facade.BluetoothAddress) returns (google.protobuf.Empty) {}
  rpc UserPasskeyRequestReply(UserPasskeyRequestReplyMessage) returns (google.protobuf.Empty) {}
  rpc UserPasskeyRequestNegativeReply(facade.BluetoothAddress) returns (google.protobuf.Empty) {}
  rpc RemoteOobDataRequestReply(RemoteOobDataRequestReplyMessage) returns (google.protobuf.Empty) {}
  rpc RemoteOobDataRequestNegativeReply(facade.BluetoothAddress) returns (google.protobuf.Empty) {}
  rpc ReadStoredLinkKey(ReadStoredLinkKeyMessage) returns (google.protobuf.Empty) {}
  rpc WriteStoredLinkKey(WriteStoredLinkKeyMessage) returns (google.protobuf.Empty) {}
  rpc DeleteStoredLinkKey(DeleteStoredLinkKeyMessage) returns (google.protobuf.Empty) {}
  rpc RefreshEncryptionKey(RefreshEncryptionKeyMessage) returns (google.protobuf.Empty) {}
  rpc ReadSimplePairingMode(google.protobuf.Empty) returns (google.protobuf.Empty) {}
  rpc WriteSimplePairingMode(WriteSimplePairingModeMessage) returns (google.protobuf.Empty) {}
  rpc ReadLocalOobData(google.protobuf.Empty) returns (google.protobuf.Empty) {}
  rpc SendKeypressNotification(SendKeypressNotificationMessage) returns (google.protobuf.Empty) {}
  rpc ReadLocalOobExtendedData(google.protobuf.Empty) returns (google.protobuf.Empty) {}
  rpc ReadEncryptionKeySize(ReadEncryptionKeySizeMessage) returns (google.protobuf.Empty) {}

  rpc FetchCommandCompleteEvent(facade.EventStreamRequest) returns (stream CommandCompleteEvent) {}

  rpc AuthenticationRequested(AuthenticationRequestedMessage) returns (google.protobuf.Empty) {}
}

message PageScanMode {
  bool enabled = 1;
}

message ConnectionEvent {
  facade.BluetoothAddress remote = 1;
  uint32 connection_handle = 2;
}

message DisconnectionEvent {
  facade.BluetoothAddress remote = 1;
  uint32 reason = 2;
}

message ConnectionFailedEvent {
  facade.BluetoothAddress remote = 1;
  uint32 reason = 2;
}

message AclData {
  facade.BluetoothAddress remote = 1;
  bytes payload = 2;
}

message CommandCompleteEvent {
  uint32 command_opcode = 1;
}

message LinkKeyRequestReplyMessage {
  facade.BluetoothAddress remote = 1;
  bytes link_key = 2;
}

message PinCodeRequestReplyMessage {
  facade.BluetoothAddress remote = 1;
  uint32 len = 2;
  bytes pin_code = 3;
}

message IoCapabilityRequestReplyMessage {
  facade.BluetoothAddress remote = 1;
  uint32 io_capability = 2;
  uint32 oob_present = 3;
  uint32 authentication_requirements = 4;
}

message IoCapabilityRequestNegativeReplyMessage {
  facade.BluetoothAddress remote = 1;
  uint32 reason = 2;
}

message UserPasskeyRequestReplyMessage {
  facade.BluetoothAddress remote = 1;
  uint32 passkey = 2;
}

message RemoteOobDataRequestReplyMessage {
  facade.BluetoothAddress remote = 1;
  bytes c = 2;
  bytes r = 3;
}

message ReadStoredLinkKeyMessage {
  facade.BluetoothAddress remote = 1;
  uint32 read_all_flag = 2;
}

message WriteStoredLinkKeyMessage {
  uint32 num_keys_to_write = 1;
  facade.BluetoothAddress remote = 2;
  bytes link_keys = 3;
}

message DeleteStoredLinkKeyMessage {
  facade.BluetoothAddress remote = 1;
  uint32 delete_all_flag = 2;
}

message RefreshEncryptionKeyMessage {
  uint32 connection_handle = 1;
}

message WriteSimplePairingModeMessage {
  uint32 simple_pairing_mode = 1;
}

message SendKeypressNotificationMessage {
  facade.BluetoothAddress remote = 1;
  uint32 notification_type = 2;
}

message ReadEncryptionKeySizeMessage {
  uint32 connection_handle = 1;
}

message AuthenticationRequestedMessage {
  uint32 connection_handle = 1;
}