Update final.py

parent e5bff446
......@@ -97,4 +97,18 @@ def steg(passphrase, template, payload):
# Similarity Scorer
def similarityScorer(refPayload, checkPayload):
return SequenceMatcher(None, refPayload, checkPayload).ratio()
\ No newline at end of file
return SequenceMatcher(None, refPayload, checkPayload).ratio()
# Authentication
def authenticate(checkPayload, refPayload):
thresholdScore = 0.889999
similarityScore = similarityScorer(refPayload, checkPayload)
if similarityScore >= thresholdScore:
print("Authentication Successful!")
else:
print("Unsuccessful Authentication!")
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment