I'm writing a script that takes input from a software (Maltego), and using sys.argv[1] as a variable. When the information from Maltego is in Hebrew, I get question marks rather than the actual text. I tried encoding the text in different ways but everything failed.
I'm using Python 2.7.
Any idea for a solution will be greatly appreciated.
the script is being run from within Maltego:
# -*- coding: utf-8 -*-
import time
from selenium import webdriver
from selenium.webdriver.common.keys import Keys
from bs4 import BeautifulSoup
from MaltegoTransform import *
import codecs
import sys
reload(sys)
sys.setdefaultencoding('utf-8')
me = MaltegoTransform()
search_value = sys.argv[1].encode("utf-8")