libbinder: allow fd transport in trusty by default
Changes the default protocol version of 0 for trusty servers and keeps them in line with the latest stable RPC_WIRE_PROTOCOL_VERSION (currently 1). It seems that hardcoding to version 0 happened before aosp/2534786 where RPC_WIRE_PROTOCOL_VERSION_EXPERIMENTAL was the default. Version 1 allows parcels to contain FDs. This should be safe because rpc binder negotiates a protocol version using the min value of the client and server configurations. Older clients will be able to downgrade the protocol version (but not transact with fds in their parcels) and newer clients will see their protocol versions negotiated down to the server's version on connection. This change also adds supported file descriptor transport modes to servers by default. In trusty, tipc allows handles to be transmitted by default so this is in line with the current security posture. Bug: 377907450 Test: trusty/vendor/google/aosp/scripts/build.py \ --test "boot-test:com.android.trusty.binderRpcTest" \ qemu-generic-arm64-test-debug Test: trusty/vendor/google/aosp/scripts/build.py qemu-generic-arm64-test-debug \ --test="boot-test:com.android.trusty.rust.service_manager_tests.test Change-Id: I0efbd7781f0fd2bc81981b01ae1b1d0d149b12b6
Loading
Please register or sign in to comment