Setting up a collision rule that stops collision detection between the two character controllers would work. They'd just go through each other completely. The
CollisionFilteringDemo shows an example of how to use that system.
If you want a different behavior where the characters still collide in some nondynamic sense but cannot push, that would require manual collision resolution to implement the desired arbitrary behavior. You could do this with collision rules too- use the NoSolver rule to allow contacts to be generated, and then examine the collision pair contacts to decide what to do with the collision.
(In v2, there is no 'collision rule' system, just callbacks that permit or deny collision detection and constraint generation. A similar system can be built on top of the callbacks- the
RagdollDemo shows one example implementation where connected body parts do not collide based on bitfields.)