This should help you :
matches =[]
st = 'abababa baba alibababa'
needle = 'baba'
for i in xrange(len(st)-len(needle)+1):
i = st.find(needle,i,i+len(needle))
if(i >= 0):
matches.append(st.find(needle,i,i+len(needle)))
print(str(matches))
see it here : http://codepad.org/pmkKXmWB
Did not benchmark it for long strings, see if its efficient enough for your use.