There are a few threads here and elsewhere on the internet discussing UniWB. Briefly, UniWB provides a mechanism that results in no (or very little) adjustment to the individual colour channels when the camera creates the embedded JPEG on which the camera's histogram is based.
This in theory provides a more accurate representation of what is actually happening with the raw data -- useful when trying to expose to the right.
Guillermo Luijk provides an excellent analysis at http://www.guillermoluijk.com/article/uniwb/index.htm.
Now if you run PhotoBola's Raw Image Analysis tool on the sample UniWB images in the above link you will notice that for the areas of interest the raw values for each of the channels are essentially equal.
This is effectively what we are striving for. When you set a custom WB in the camera, you are asking the camera to figure out how it needs to adjust the raw data for the provided custom WB image to make these channels equal (i.e. white/gray). If the channels equal each other in the CWB image, than the camera thinks it doesn't need to adjust anything as for the given "lighting condition" the image is already gray.
G. Luijk's method does work, but it requires a little effort to execute. I'm lazy, so I looked for an easier solution .
Now I can think of two other "naturally" occurring scenarios where channels will have equal values (or approximately equal): a dark frame and a completely saturated frame.
Using the PB Raw Image Analysis tool on a dark frame and saturated frame returned average RGGB values of (255, 255, 255, 255) and (4095, 4095, 4095, 4095) respectively. The dark frame had more variance in values whereas the saturated frame was 4095 all the way through.
So far so good. Now the only thing to see was if the camera would take these images for use as a custom WB. On the Rebel XT, the answer is yes in both cases.
Using the dark frame resulted in WB coefficients for an image of (1.006, 1.000, 1.006). The saturated frame resulted in WB coefficients for an image of (1.008, 1.000, 1.004).
The obvious benefit with the dark frame is that you can do it at any point in case you lost your UniWB image/setting -- just shoot a frame with the lens cap on. The saturation method is a little more difficult as sometimes it can be difficult to achieve full saturation in all channels for some lighting conditions. For mine, I used a flash.
I would be interested to know if any other camera models can apply the same method.
e-k