Various cryptographic methods rely on optimization techniques to find the key of a given cipher text. A fitness function is defined based on frequency analysis or any other known information. Vignere cipher was crypt analyzed using GA, PSO and other optimization techniques. Firefly algorithm is an optimization algorithm based on the brightness and attraction among fireflies. A fitness function is defined based on frequency of occurrence monograms and bigrams in English. Firefly algorithm is tried on 1 KB of Vignere cipher and it was seen that keyword length ranging from 5 to 20 were found without error and also with less time complexity than GA and PSO.