resource is (practically) hardcoded to 'iPhone' instead of device name (#216)
Open
Unknown opened 1 year ago

Describe the bug

Siskin uses the device name in order to set the resource string (UIDevice.current.name). But in iOS 16, UIDevice.name has changed to only return the generic model of the device (e.g. 'iPhone'), not the user specified name. Hence in iOS 16 Siskin exclusively sets 'iPhone' as resource string, which is not unique per device and is also rather unhelpful when debugging the same username logged in into several devices.

Proposed solution com.apple.developer.device-information.user-assigned-device-name should be used, instead of UIDevice.current.name, cf. https://developer.apple.com/documentation/bundleresources/entitlements/com_apple_developer_device-information_user-assigned-device-name

Alternative solution proposal Let the server generate the resource, cf. https://wiki.xmpp.org/web/XMPP_IM_Client_Design_Guidelines#Do_not_to_encode_any_semantics_into_the_resource,_let_the_server_generate_a_resource_for_you

To Reproduce Steps to reproduce the behavior:

  1. Go to device settings and set a device name different than 'iPhone'
  2. Use Siskin
  3. See that Siskin only sets 'iPhone' as client resource

Expected behavior Siskin uses the device name as base for the resource so that different devices also get different resources.

cf. RFC 7622

Typically, a resourcepart uniquely identifies a specific connection

Details (please complete the following information):

  • Siskin Version: 7.3.3
  • iOS version: 16.4.1
  • iPhone model: iPhone XR
Unknown commented 1 year ago

In the future version, we will drop usage of device name at all as the resource. As new version will support SASL2 and Bind2 we will use similar way to generate resource for SASL1 and Bind1 (random opaque string).

issue 1 of 1
Type
Bug
Issue Votes (0)
Watchers (0)
Reference
tigase/_clients/siskin-im#216
Please wait...
Page is in error, reload to recover