OLD | NEW |
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2012 The Chromium 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 syntax = "proto2"; | 5 syntax = "proto2"; |
6 | 6 |
7 option optimize_for = LITE_RUNTIME; | 7 option optimize_for = LITE_RUNTIME; |
8 | 8 |
9 package enterprise_management; | 9 package enterprise_management; |
10 | 10 |
(...skipping 85 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
96 | 96 |
97 // Request for a setting or with optional watermark on client side. | 97 // Request for a setting or with optional watermark on client side. |
98 // TODO(gfeher): remove this after Chrome OS TT is over. | 98 // TODO(gfeher): remove this after Chrome OS TT is over. |
99 message DevicePolicySettingRequest { | 99 message DevicePolicySettingRequest { |
100 // setting key | 100 // setting key |
101 required string key = 1; | 101 required string key = 1; |
102 // watermark last read from server if available. | 102 // watermark last read from server if available. |
103 optional string watermark = 2; | 103 optional string watermark = 2; |
104 } | 104 } |
105 | 105 |
| 106 // Request to access a Google service with the given scope. |
| 107 message DeviceServiceApiAccessRequest { |
| 108 // The list of auth scopes the device requests from DMServer. |
| 109 repeated string auth_scope = 1; |
| 110 |
| 111 // OAuth2 client ID to which the returned authorization code is bound. |
| 112 optional string oauth2_client_id = 2; |
| 113 } |
| 114 |
| 115 message DeviceServiceApiAccessResponse { |
| 116 // The OAuth2 authorization code for the requested scope(s). |
| 117 // This can be exchanged for a refresh token. |
| 118 optional string auth_code = 1; |
| 119 } |
| 120 |
106 message PolicyFetchRequest { | 121 message PolicyFetchRequest { |
107 // This is the policy type, which maps to D3 policy type internally. | 122 // This is the policy type, which maps to D3 policy type internally. |
108 // By convention, we use "/" as separator to create policy namespace. | 123 // By convention, we use "/" as separator to create policy namespace. |
109 // The policy type names are case insensitive. | 124 // The policy type names are case insensitive. |
110 // | 125 // |
111 // Possible values for Chrome OS are: | 126 // Possible values for Chrome OS are: |
112 // google/chromeos/device => ChromeDeviceSettingsProto | 127 // google/chromeos/device => ChromeDeviceSettingsProto |
113 // google/chromeos/user => ChromeSettingsProto | 128 // google/chromeos/user => ChromeSettingsProto |
114 // google/chromeos/publicaccount => ChromeSettingsProto | 129 // google/chromeos/publicaccount => ChromeSettingsProto |
115 // google/chrome/extension => ExternalPolicyData | 130 // google/chrome/extension => ExternalPolicyData |
(...skipping 323 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
439 // * Data mime type is application/x-protobuffer | 454 // * Data mime type is application/x-protobuffer |
440 // * HTTP parameters are (all required, all case sensitive): | 455 // * HTTP parameters are (all required, all case sensitive): |
441 // * request: MUST BE one of | 456 // * request: MUST BE one of |
442 // * cert_upload | 457 // * cert_upload |
443 // * enterprise_check | 458 // * enterprise_check |
444 // * ping | 459 // * ping |
445 // * policy | 460 // * policy |
446 // * register | 461 // * register |
447 // * status | 462 // * status |
448 // * unregister | 463 // * unregister |
| 464 // * api_authorization |
449 // | 465 // |
450 // * devicetype: MUST BE "1" for Android or "2" for Chrome OS. | 466 // * devicetype: MUST BE "1" for Android or "2" for Chrome OS. |
451 // * apptype: MUST BE Android or Chrome. | 467 // * apptype: MUST BE Android or Chrome. |
452 // * deviceid: MUST BE no more than 64-char in [\x21-\x7E]. | 468 // * deviceid: MUST BE no more than 64-char in [\x21-\x7E]. |
453 // * agent: MUST BE no more than 64-char long. | 469 // * agent: MUST BE no more than 64-char long. |
454 // * HTTP Authorization header MUST be in the following formats: | 470 // * HTTP Authorization header MUST be in the following formats: |
455 // * For register and ping requests | 471 // * For register and ping requests |
456 // Authorization: GoogleLogin auth=<auth cookie for Mobile Sync> | 472 // Authorization: GoogleLogin auth=<auth cookie for Mobile Sync> |
457 // | 473 // |
458 // * For unregister, policy, status, and cert_upload requests | 474 // * For unregister, policy, status, and cert_upload requests |
(...skipping 27 matching lines...) Expand all Loading... |
486 | 502 |
487 // Update status. | 503 // Update status. |
488 optional DeviceStatusReportRequest device_status_report_request = 4; | 504 optional DeviceStatusReportRequest device_status_report_request = 4; |
489 optional SessionStatusReportRequest session_status_report_request = 5; | 505 optional SessionStatusReportRequest session_status_report_request = 5; |
490 | 506 |
491 // Auto-enrollment detection. | 507 // Auto-enrollment detection. |
492 optional DeviceAutoEnrollmentRequest auto_enrollment_request = 6; | 508 optional DeviceAutoEnrollmentRequest auto_enrollment_request = 6; |
493 | 509 |
494 // EMCert upload (for remote attestation) | 510 // EMCert upload (for remote attestation) |
495 optional DeviceCertUploadRequest cert_upload_request = 7; | 511 optional DeviceCertUploadRequest cert_upload_request = 7; |
| 512 |
| 513 // Request for OAuth2 authorization codes to access Google services. |
| 514 optional DeviceServiceApiAccessRequest service_api_access_request = 8; |
496 } | 515 } |
497 | 516 |
498 // Response from server to device. | 517 // Response from server to device. |
499 // | 518 // |
500 // The server uses the following numbers as HTTP status codes | 519 // The server uses the following numbers as HTTP status codes |
501 // to report top-level errors. | 520 // to report top-level errors. |
502 // | 521 // |
503 // 200 OK: valid response is returned to client. | 522 // 200 OK: valid response is returned to client. |
504 // 400 Bad Request: invalid argument. | 523 // 400 Bad Request: invalid argument. |
505 // 401 Unauthorized: invalid auth cookie or DM token. | 524 // 401 Unauthorized: invalid auth cookie or DM token. |
(...skipping 22 matching lines...) Expand all Loading... |
528 optional DeviceStatusReportResponse device_status_report_response = 6; | 547 optional DeviceStatusReportResponse device_status_report_response = 6; |
529 | 548 |
530 // Session status report response. | 549 // Session status report response. |
531 optional SessionStatusReportResponse session_status_report_response = 7; | 550 optional SessionStatusReportResponse session_status_report_response = 7; |
532 | 551 |
533 // Auto-enrollment detection response. | 552 // Auto-enrollment detection response. |
534 optional DeviceAutoEnrollmentResponse auto_enrollment_response = 8; | 553 optional DeviceAutoEnrollmentResponse auto_enrollment_response = 8; |
535 | 554 |
536 // EMCert upload response. | 555 // EMCert upload response. |
537 optional DeviceCertUploadResponse cert_upload_response = 9; | 556 optional DeviceCertUploadResponse cert_upload_response = 9; |
| 557 |
| 558 // Response to OAuth2 authorization code request. |
| 559 optional DeviceServiceApiAccessResponse service_api_access_response = 10; |
538 } | 560 } |
OLD | NEW |