Sunglasses anti-fog solutions safe for cycling
The answer is "they are probably safe" and "they don't work for spit". 

Skiers have exactly this same problem with ski goggles and what I have learned in 50 years of skiing is that if the goggle has an built in anti-fog coating, cleaning it with anything but a mild soap will ruin what minimal anti fog coating 
it has. Sunglasses generally don't have much in the way of anti fog coating. I tried everything I could find and it was all a huge waste of money.

What I have found that has largely fixed the problem for me in skiing is two things. 


Wear a helmet. ( this probably doesn't apply to bike helmets, but ski helmets do a lot to keep the moist warm air from your head away from the goggles. )
Change your jacket. 


When I switched from skiing in a Goretex jacket to a jacket that actually breathes (soft shell) 99% of the goggle fogging problem disappeared. Anything that is a vapor barrier just funnels all the warm moist air from your body directly up into your face. The only WB fabric I've found that comes anywhere close to venting well enough to use with aerobic sports is eVent. 

Applying this to your situation, you need a face mask that breathes better. Either that or one that some how seals to your face at the top. There is no magic goop that will prevent fogging, the only solution is to keep the moist air away from the glasses. 

After you give up attempting to keep your current sunglasses from fogging, you might try a pair of these. 



http://www.xcskistore.com/casco-nordic-spirit-ii-white-nordic-ski-eyewear.html

They are very expensive, wierd looking, but they are by far and away the most fog resistant eyewear available. I've used them biking and for all kinds of skiing and  they just don't fog up ever.