The question as stated is a little bit ambiguous, but it's not Porton's fault. The truth is the expression $a\times b$ may be interpreted either as a product object (which is defined only up to isomorphism) or as the result of a product bifunctor applied to objects $a$ and $b$, defined on a category with binary products. Ponton's question only makes sense if we consider the second interpretation.
In this sense the OP's question is roughly: under what circumstances/limitations is a product bifunctor injective on objects?
Crucial point to note: if you are given a category with binary products, you can define many products bifunctors. Any two of these bifunctors, $\times'$ and $\times''$, are related by natural isomorphisms.
Suppose you can state the following result for product $\times'$: $\forall(a,b,c,d): P(a,b,c,d)\implies ((a\times' b=c\times'd)\implies (a=c\wedge b=d))$
Where $P(a,b,c,d)$ means that $a,b,c,d$ satisfy predicate $P$ (eg. in $\mathcal{Set}$, $P(a,b,c,d)$ might be "a,b,c,d not empty" )
Can you conclude that the same statement holds for another product $\times''$? $\forall(a,b): P(a,b)\implies ((a\times'' b=c\times''d)\implies (a=c\wedge b=d))$
In general no (although I cannot present a concrete example). So whatever conclusion you may arrive at, it would depend not only on your particular category, but also on the particular product bifunctor you have decided to use in that particular category. This is not likely to be very useful/meaningful.