Git Product home page Git Product logo

Comments (8)

xwings avatar xwings commented on May 18, 2024

hi,

i dont think we have fcntl in windows. u can try to run it in WSL. please do taka note WSL2 might work better.

from qiling.

0xjacklove avatar 0xjacklove commented on May 18, 2024

https://stackoverflow.com/questions/1422368/fcntl-substitute-on-windows

from qiling.

xwings avatar xwings commented on May 18, 2024

as @0x1shyboy1 mention. yes, Windows does not comes with fcntl

from qiling.

xwings avatar xwings commented on May 18, 2024

Well,

being said, we need to find a way to work around it. Any suggestion?

from qiling.

0xjacklove avatar 0xjacklove commented on May 18, 2024

Windows : Create fcntl.py in the Lib directory of Python.
##fcntl.py
def fcntl(fd, op, arg=0):
return 0

def ioctl(fd, op, arg=0, mutable_flag=True):
if mutable_flag:
return 0
else:
return ""

def flock(fd, op):
return

def lockf(fd, operation, length=0, start=0, whence=0):
return


It work for me !!
however,if i run the example of linux,i will get
Traceback (most recent call last):
File "hello_x8664_linux.py", line 18, in
ql = Qiling(["rootfs/x8664_linux/bin/x8664_hello"], "rootfs/x8664_linux")
File "C:\ProgramData\Anaconda3\lib\site-packages\qiling-0.9-py3.7.egg\qiling\core.py", line 176, in init
self.run_exec()
File "C:\ProgramData\Anaconda3\lib\site-packages\qiling-0.9-py3.7.egg\qiling\core.py", line 184, in run_exec
loader_file = self.build_os_execution("loader_file")
File "C:\ProgramData\Anaconda3\lib\site-packages\qiling-0.9-py3.7.egg\qiling\core.py", line 179, in build_os_execution
self.runtype = ql_get_os_module_function(self.ostype, self.arch, "runner")
File "C:\ProgramData\Anaconda3\lib\site-packages\qiling-0.9-py3.7.egg\qiling\utils.py", line 31, in ql_get_os_module_function
return ql_get_module_function(module_name, function_name)
File "C:\ProgramData\Anaconda3\lib\site-packages\qiling-0.9-py3.7.egg\qiling\utils.py", line 60, in ql_get_module_function
raise QlErrorModuleNotFound(f"Unable to import module {module_name}")
qiling.exception.QlErrorModuleNotFound: Unable to import module qiling.os.linux.x8664

any example running on Ubuntu is normal.

from qiling.

xwings avatar xwings commented on May 18, 2024

Hi,

If you able to solve it. PR is appriciated

from qiling.

xwings avatar xwings commented on May 18, 2024

Just a note

This issue is related to issue #24

from qiling.

xwings avatar xwings commented on May 18, 2024

closed and conversation moved to issue #24

from qiling.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.