What type of mask to be used in lead free soldering?
Is it safe to use mask for lead free soldering in solar string soldering? 


Yes. Not sure why you would because the terminals are generally far enough apart that solder bridges are unlikely. If the interest is for weather protection or aesthetic, you may be better served with a high temp conformal coating after the soldering is complete. 


  What type of mask to be used? 


Any mask designed to be RoHS compliant will be suitable. The most significant deciding factor being how it will be applied and if you want it to be permanent. Film masks are arguably the easiest to work with. Peelable masks are available if you only want it present during the soldering process. 


  What is the difference between lead based and lead free flux?


In general, flux for lead-free solder has a higher surface tension, slower wetting action, and higher temperature tolerance. They are better designed for the alloys and soldering conditions of lead-free solder. You can use flux somewhat univerally, but it works best with the alloy for which it was designed. 

There are dozens of flux varients for leaded and lead-free applications across a range of activation strengths and solubility options. A complete answer would be pages long. To the spirit of your question, any readily  available mask should be compatible with all commonly used solder/flux.