How to determine r' in pederson commitment? Can someone help me with that question? Assuming that someone knows $log_g(h)$ so that he can calculate any message $m'$ for commitment $c$, how to determine $r'$ in?
Assuming that someone knows $log_g(h)$ so that he can calculate any message $m'$ for commitment $c$, how to determine $r'$ in? 


First, we assume that he already knows the 'true' value of the commitment $c = g^m h^r$ (as this is the prover who is cheating).  Then, assuming he knows the value $x$ s.t. $g^x = h$, then he sets $r' = r + x^{-1}(m - m')$; then, the pair $m', r'$ is a valid opening of the commitment, as $g^{m'}h^{r'} = g^m g^{m'-m}h^{r + x^{-1}(m - m')} = g^m g^{m'-m}h^r g^{(m'-m)} = g^m h^r = c$