C ++中的Meltdown POC

时间:2018-01-07 14:37:55

标签: c++ exploit poc

我听说过Meltdown漏洞并阅读了paper,这很难,因为我不是母语人士,但我决定制作一个小概念证明c ++程序下面,我想知道代码不工作的原因。 我在AMD FX 8350 Eight Core和Intel I3处理器上进行了测试

    import mysql.connector
    import numpy as np
    conn= mysql.connector.connect 
    (user="root",password="",host="localhost",database="videojs")

    # prepare a cursor object using cursor() method
    cursor = conn.cursor()

    def read_from_db():

        cursor.execute("select time_arr from info where id ='52'")
        data=cursor.fetchall()
        print(data)
        #Open the file
        fobj = open("one.srt")  
        text = fobj.read().strip().split()

        #Conditions
        while True:
            s = input("Enter a string: ") #Takes input of a string from user
            if s == "": #if no value is entered for the string
                continue
            if s in text: #string in present in the text file
                print("Matched")
                break
            else: #string is absent in the text file
                print("No such string found,try again")
                continue
        fobj.close()


    read_from_db()

1 个答案:

答案 0 :(得分:0)

好的,所以我意识到如果我用汇编程序对它进行编程,那么这个测试会更准确。接下来我会尝试,但在此之前我将不得不学习一些东西。我认为这个问题已得到解答,但对c ++程序的建议仍然受到欢迎。 谢谢你的帮助