Non isomorphic finite rings with isomorphic additive and multiplicative structure About a year ago, a colleague asked me the following question:

Suppose $(R,+,\cdot)$ and $(S,\oplus,\odot)$ are two rings such that $(R,+)$ is isomorphic, as an abelian group, to $(S,\oplus)$, and $(R,\cdot)$ is isomorphic (as a semigroup/monoid) to $(S,\odot)$. Does it follow that $R$ and $S$ are isomorphic as rings?

I gave him the following counterexample: take your favorite field $F$, and let $R=F[x]$ and $S=F[x,y]$, the rings of polynomials in one and two (commuting) variables. They are not isomorphic as rings, yet $(R,+)$ and $(S,+)$ are both isomorphic to the direct sum of countably many copies of $F$, and $(R-\{0\},\cdot)$ and $(S-\{0\},\cdot)$ are both isomorphic to the direct product of $F-\{0\}$ and a direct sum of $\aleph_0|F|$ copies of the free monoid in one letter (and we can add a zero to both and maintain the isomorphism).
He mentioned this example in a colloquium yesterday, which got me to thinking: 

Question. Is there a counterexample with $R$ and $S$ finite?

 A: Here are some initial thoughts.  Put 
$$ X(R)=\{e\in R: e^2=e \text{ and } er=re \text{ for all } r\in R\} $$
We can partially order this by declaring that $e\leq f$ iff $ef=e$.  We then put 
$$ Y(R)=\{e\in X(R): 0\lt e \text{ and there is no } f\in X(R) \text{ with }
    0 \lt f \lt e \} 
$$
One can check that $X(R)$ is a finite Boolean algebra under this order (with meet operation $e\wedge f=ef$ and join $e\vee f=e+f-ef$) so it is isomorphic to the lattice of subsets of its set of atoms, which is $Y(R)$.  In particular, if $|Y(R)|=n$ then $|X(R)|=2^n$.  For $e\in Y(R)$ we put 
$$ R[e] = Re = \{ x\in R : ex=xe=x\} $$
We can then define $p:R\to\prod_{e\in Y(R)}R[e]$ by $p(x)_e=ex$.  It is standard that this is an isomorphism of rings.
Next, by hypothesis we have a bijection $f:R\to S$ that preserves multiplication.  It follows that $f$ gives an isomorphism $X(R)\to X(S)$ of posets, and thus a bijection $Y(R)\to Y(S)$.  As the sets $R[e]$ and the maps $p_e$ are defined using only the multiplicative structure, we see that $f$ gives an isomorphism $R[e]\to S[f(e)]$ of multiplicative monoids for each $e\in Y(R)$.  However, we do not obviously have an additive isomorphism from $R[e]$ to $S[f(e)]$, so this does not succeed in reducing the problem to the indecomposable case.
Nonetheless, it is worth thinking about the ring structure of $R[e]$.  The quotient by the Jacobson radical is a finite simple ring and so is a matrix algebra over a finite division ring, but finite division rings are fields by a theorem of Wedderburn, so this quotient is quite tractable.
A: There do exist pairs of finite unital rings whose additive structures
are isomorphic and whose multiplicative structures are isomorphic,
yet the rings themselves are not isomorphic. 
To see this, let $\mathbb F$ be a field and let $X = \{x_1,\ldots, x_n\}$
be a set of variables. The polynomial ring $\mathbb F[X]$
is graded by degree
$$
\mathbb F[X] = H_0\oplus H_1\oplus H_2\oplus\cdots.
$$
Let $Q(x_1,\ldots,x_n)$ be a quadratic form over $\mathbb F$.
Let
$$I = \mathbb F\cdot Q(X)\oplus H_3\oplus H_4\oplus\cdots$$
be the 
ideal generated by $Q(X)$ and the homogeneous components
of degree at least $3$.
Let $S_{\mathbb F,Q}$ denote the $\mathbb F$-algebra
$\mathbb F[X]/I$. It is a commutative, local ring, which encodes
properties of the quadratic form $Q$.
Two quadratic forms $Q_1$ and $Q_2$ are equivalent
if they differ by an invertible linear change of variables.
Claim.
  Let $\mathbb F$ be a finite field of odd characteristic $p$.
Let $Q_1(x_1,\ldots,x_n)$ and $Q_2(x_1,\ldots,x_n)$ be 
nonzero quadratic forms over $\mathbb F$.


*

*$S_{\mathbb F,Q_1}$ and $S_{\mathbb F,Q_2}$ have isomorphic
$\mathbb F$-space structures.

*If $n>4$ and $Q_1$ and $Q_2$ are nondegenerate, then
$S_{\mathbb F,Q_1}$ and $S_{\mathbb F,Q_2}$ have
isomorphic multiplicative monoids.

*$S_{\mathbb F,Q_1}\not\cong S_{\mathbb F,Q_2}$ as $\mathbb F$-algebras,
unless $Q_1$ is equivalent to a nonzero scalar multiple of $Q_2$.
Proof. Exercise! \\
So let $\mathbb F = \mathbb F_3$ be the $3$-element field.
It is known that over a finite field of odd characteristic
the quadratic forms are classified by the dimension
and by the determinant of the form modulo squares.
The determinant of 
$$
Q(x_1,\ldots,x_n)=a_1x_1^2+a_2x_2^2+\cdots+a_nx_n^2
$$
is $a_1\cdots a_n$. If
$\alpha\in \mathbb F_3^{\times}=\{\pm 1\}$,
then $\alpha\cdot Q$ has determinant
$\alpha^n a_1\cdots a_n=(\pm 1)^n a_1\cdots a_n$.
If $n$ is even, then the determinants of $Q$ and $\alpha\cdot Q$ will be equal,
so $Q$ will be equivalent 
to $\alpha\cdot Q$ for every $\alpha\in \mathbb F_3^{\times}$.
This implies that, when working over $\mathbb F_3$ in an even dimension,
if $Q_1$ is not equivalent to $Q_2$, $Q_1$ will also
not be equivalent to any nonzero scalar
multiple of $Q_2$.
In particular, no scalar multiple of
$$
Q_1 = x_1^2 + x_2^2 + x_3^2 + x_4^2 + x_5^2 + x_6^2,
$$
is equivalent to 
$$
Q_2 = x_1^2 + x_2^2 + x_3^2 + x_4^2 + x_5^2 - x_6^2
$$
over $\mathbb F_3$. For these forms we have
that $S_{\mathbb F,Q_1}$ and $S_{\mathbb F,Q_2}$ are nonisomorphic
finite unital rings with isomorphic additive and multiplicative structures.
(These rings have size $3^{27}$.)
Minor side comment 1: If you allow nonunital rings, there is a pair of nonisomorphic $8$-element rings whose additive and multiplicative structures are isomorphic.
Minor side comment 2:
The solution to the exercise above (that is, the proof of the Claim)
can be found here.
