Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Cherrypick Apple Privacy Manifest changes to make these available in 25.x #15802

Merged
merged 6 commits into from
Feb 13, 2024

Conversation

zhangskz
Copy link
Member

No description provided.

dmaclach and others added 5 commits February 12, 2024 14:07

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature.
`mach_absolute_time` is one of Apple's required reason APIs (https://developer.apple.com/documentation/kernel/1462446-mach_absolute_time?language=objc). Replace it with the suggested `clock_gettime_nsec_np(CLOCK_UPTIME_RAW)` so that we don't need a RRA entry in a privacy manifest.

issue #15029

Closes #15554

COPYBARA_INTEGRATE_REVIEW=#15554 from protocolbuffers:dmaclach-mach_absolute_time 295d831
PiperOrigin-RevId: 601370915

Verified

This commit was created on GitHub.com and signed with GitHub’s verified signature.
issue##15029

As required by https://developer.apple.com/support/third-party-SDK-requirements/

Protos does not collect data.

Required reason APIs searched for using:
```
grep -ER 'NSFileCreationDate|NSFileModificationDate|fileModificationDate|NSURLContentModificationDateKey|NSURLCreationDateKey|getattrlist\(|getattrlistbulk\(|fgetattrlist\(|stat\(|fstat\(|fstatat\(|lstat\(|getattrlistat\(|systemUptime\(|mach_absolute_time\(|NSURLVolumeAvailableCapacityKey|NSURLVolumeAvailableCapacityForImportantUsageKey|NSURLVolumeAvailableCapacityForOpportunisticUsageKey|NSURLVolumeTotalCapacityKey|NSFileSystemFreeSize|NSFileSystemSize|statfs\(|statvfs\(|fstatfs\(|fstatvfs\(|getattrlist\(|fgetattrlist\(|getattrlistat\(|activeInputModes|NSUserDefaults' .
```

```
./third_party/utf8_range/utf8_to_utf16/main.c:    if (fstat(fd, &stat) == -1) {
./third_party/utf8_range/main.c:    if (fstat(fd, &stat) == -1) {
./src/google/protobuf/map.h:    s = mach_absolute_time();
./src/google/protobuf/io/io_win32.cc:int stat(const char* path, struct _stat* buffer) {
./src/google/protobuf/io/io_win32.cc:  return ::_wstat(wpath.c_str(), buffer);
./src/google/protobuf/io/io_win32.cc:  return ::_stat(path, buffer);
./src/google/protobuf/io/io_win32.h:PROTOBUF_EXPORT int stat(const char* path, struct _stat* buffer);
./src/google/protobuf/testing/file.cc:  if (lstat(name.c_str(), &stats) != 0) return;
./src/google/protobuf/compiler/importer.cc:    ret = stat(std::string(filename).c_str(), &sb);
```

`./third_party/utf8_range/...` - tool for utf that is not in user binaries
`./src/google/protobuf/map.h` - resolved with pull#15554
`./src/google/protobuf/io/io_win32.cc` - windows code
`./src/google/protobuf/testing/file.cc` - testing code not in user binaries
`./src/google/protobuf/compiler/importer.cc` - compiler code not in user binaries

So no required reason APIs.

Apple has not yet communicated how this is to be put into podspecs so saving for future commit.

Closes #15557

COPYBARA_INTEGRATE_REVIEW=#15557 from dmaclach:privacy 4c4e570
PiperOrigin-RevId: 601362376
There are no restrict calls, so the manifest asserts that.

The CocoaPods support now ensure you are using CocoaPods >= 1.12 as that
avoids all the know bugs in CocoaPods support needed to capture the
Privacy Manifest in a resource bundle.

PiperOrigin-RevId: 602433417
There are no restrict calls, so the manifest asserts that.

The CocoaPods support now ensures you are using CocoaPods >= 1.12 as that
avoids all the know bugs in CocoaPods support needed to capture the
Privacy Manifest in a resource bundle.

PiperOrigin-RevId: 602443703
CocoaPods fails spec validation for some warnings, so use a local
to avoid warnings for 64->32bit implicit conversions. This comes up
for watchOS builds.

PiperOrigin-RevId: 601849919
@zhangskz zhangskz requested a review from thomasvl February 12, 2024 19:13
@zhangskz zhangskz requested review from a team as code owners February 12, 2024 19:13
@zhangskz zhangskz requested review from deannagarcia and removed request for a team and deannagarcia February 12, 2024 19:13
@zhangskz zhangskz requested a review from a team as a code owner February 12, 2024 22:30
@zhangskz zhangskz requested review from acozzette and removed request for a team February 12, 2024 22:30
@zhangskz zhangskz merged commit 70e459f into 25.x Feb 13, 2024
@zhangskz zhangskz deleted the cp-25.x branch February 13, 2024 02:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

5 participants