I do this with spec malts and add liquid to the cube, using the heat of the wort to sterilise. Haven't had any issues after doing on around 20 batches.
I currently get 3-4 cubes out of a batch, so with my last brew as an example, I used 100% munich as the base wort, one cube was left as is, one...