Personally, I like the lois6b solution (no need to use JavaScript), but it has the problem of that does not work at all in Firefox and IE / Edge, and also allows you to choose invalid colors (even in Chrome by clicking on the "Other ..." button). So I'm going to put an alternative with JavaScript, maybe if you combine this solution with that of lois6b, you could get something interesting.
The idea would be to add a handler for the onchange
event that, every time the field changes value, check if the new value is part of a list of valid colors; and if it is not, make the value of the field back to one by default.
Something like this:
// añadir un controlador del evento onChange
document.getElementById("colorElegido").addEventListener("change", function(e) {
// lista de colores válidos
var coloresValidos = ["#ffffff", "#000000"];
// si el nuevo valor no es válido, entonces poner el valor por defecto
if (coloresValidos.indexOf(e.target.value.toLowerCase()) < 0) {
e.target.value = "#000000";
}
}, false);
<div class="col-lg-6">
<div class="form-group">
<label>Elegircolor</label>
<input type="color" id="colorElegido" value="#000000" name="product_color" class="form-control">
</div>
</div>