How to disable mobile app user actions "touch on" capture

Hi Community,

Kindly I am using android Gradle for mobile user experience, and we had a request to disable the capture of user touch on sensors due to security reasons from code level (and not using masking) for example I don’t want to capture actions like “touch on 1”

Can you please support with the exact Gradle configurations to disable touch on listener sensors?

Should the below configuration work:

---------
dynatrace {
    configurations {
        sampleConfig {
            userActions {
                sensors {

// fine-tune the sensors if necessary
                        UserActionSensors {
                            Click false
                            itemClick false
                            itemSelect false
                        }
                    }
                }
            }
        }
    }
---------

Thanks,
Ahmed

Hi @AhmedSamy ,

I’d highly recommend using user action masking as described here . 
You can also exclude certain classes from autoinstrumentation (PIN code entry for example).

Would that solve your case?

Hi @AhmedSamy ,

Here is an example for user action masking rule which wa mentioned by @Julius_Loman.

Both solutions are perfect.

I hope it helps. Have nice day

Best regards,

Mizső

@Mizső Well, the user action naming rule just renames the action. But the information is still capture. OneAgent SDK 1.249 includes a feature which masks automatically the user action names if the name may contain sensitive information - if content description (android)  or element text is about to be used in the captured name.

Hey @AhmedSamy,

When you want to only deactivate sensors that generate a “Touch on” user action (and keep the other user actions), then you have to use the following configuration:

dynatrace {
    configurations {
        sampleConfig {
            userActions {
                sensors {
                    click false
                    itemClick false
                    itemSelect false
                    menuClick false
                    optionSelect false
                }
            }
        }
    }
}

It almost has the same effect as deactivating user action monitoring completely, because the plugin only instruments OnPageChangeListener and OnRefreshListener classes.

But I would also recommend the option(s) suggested by @Julius_Loman. Masking via the “namePrivacy” options guarantees that the agent will not use any sensitive information for user action monitoring.

Hi @Julius_Loman,

Thanks for the clarification and the information.

Can you help me where can I find the release notes or documnetation for OneAgent SDK 1.249? I would like to forward it for the affected mobile app developers.

Thanks in adavence. Have nice day.

Best regards,

Mizső

@Mizső It’s already in my post :slightly_smiling_face: 

Hi @Julius_Loman,

I’am blind. I have to learn use the communtiy. :joy:

Thnaks.

Best regards,

Mizső

Hi @Julius_Loman,

Is there any similar solution for iOS?

Thanks in advance.

Best regards,

Mizső

there are 2 different ways to approach it on iOS:
* disable instrumentation of e.g. Button touches by configuring the controls you don not want to get touch actions from - see DTXExcludedControls in this help page: OneAgent for iOS configuration keys in RUM Classic — Dynatrace Docs
* use custom control titles for dedicated buttons instead of having them autogenerated: OneAgent SDK for iOS in RUM Classic — Dynatrace Docs

Hi @Patrick_H,

Thanks very much your swift reaction and the information.

Have a nince day.

Best regards,

Mizső