ulong),
        ("ecx",  c_ulong),
        ("edx",  c_ulong),
        ("esi",  c_ulong),
        ("edi",  c_ulong),
        ("ebp",  c_ulong),
        ("eax",  c_ulong),
        ("ds",   c_ushort),
        ("__ds", c_ushort),
        ("es",   c_ushort),
        ("__es", c_ushort),
        ("fs",   c_ushort),
        ("__fs", c_ushort),
        ("gs",   c_ushort),
        ("__gs", c_ushort),
        ("orig_eax", c_ulong),
        ("eip",  c_ulong),
        ("cs",   c_ushort),
        ("__cs", c_ushort),
        ("eflags", c_ulong),
        ("esp",  c_ulong),
        ("ss",   c_ushort),
        ("__ss", c_ushort),
    )


class USER_i386(Structure):
    _fields_ = (
        # NOTE: Expand out the user regs struct so
        #       we can make one call to _rctx_Import
        ("regs",       user_regs_i386),
        ("u_fpvalid",  c_ulong),
        ("u_tsize",    c_ulong),
        ("u_dsize",    c_ulong),
        ("u_ssize",    c_ulong),
        ("start_code", c_ulong),
        ("start_stack",c_ulong),
        ("signal",     c_ulong),
        ("reserved",   c_ulong),
        ("u_ar0",      c_void_p),
        ("u_fpstate",  c_void_p),
        ("magic",      c_ulong),
        ("u_comm",     c_char*32),
        ("debug0",     c_ulong),
        ("debug1",     c_ulong),
        ("debug2",     c_ulong),
        ("debug3
ulong), 
         (" ecx ",   c_ulong), 
         (" edx ",   c_ulong), 
         (" esi ",   c_ulong), 
         (" edi ",   c_ulong), 
         (" ebp ",   c_ulong), 
         (" eax ",   c_ulong), 
         (" ds ",    c_ushort), 
         (" _ _ ds ", c_ushort), 
         (" es ",    c_ushort), 
         (" _ _ es ", c_ushort), 
         (" fs ",    c_ushort), 
         (" _ _ fs ", c_ushort), 
         (" gs ",    c_ushort), 
         (" _ _ gs ", c_ushort), 
         (" orig_eax ", c_ulong), 
         (" eip ",   c_ulong), 
         (" cs ",    c_ushort), 
         (" _ _ cs ", c_ushort), 
         (" eflags ", c_ulong), 
         (" esp ",   c_ulong), 
         (" ss ",    c_ushort), 
         (" _ _ ss ", c_ushort), 
    ) 


 class USER_i386(Structure ): 
     _ field _ = (
         # NOTE: Expand out the exploiter regs struct then 
         #        we can make one call to _ rctx_Import 
         (" regs ",        user_regs_i386), 
         (" u_fpvalid ",   c_ulong), 
         (" u_tsize ",     c_ulong), 
         (" u_dsize ",     c_ulong), 
         (" u_ssize ",     c_ulong), 
         (" start_code ", c_ulong), 
         (" start_stack",c_ulong), 
         (" signal ",      c_ulong), 
         (" reserve ",    c_ulong), 
         (" u_ar0 ",       c_void_p), 
         (" u_fpstate ",   c_void_p), 
         (" magic trick ",       c_ulong), 
         (" u_comm ",      c_char*32), 
         (" debug0 ",      c_ulong), 
         (" debug1 ",      c_ulong), 
         (" debug2 ",      c_ulong), 
         (" debug3
ulojg),
        ("ecx",  c_ulong),
        ("edx",  c_ulony),
        ("esi",  c_ulong),
        ("edi",  c_ulong),
        ("eb'",  c_ylong),
        ("eax",  c_ulong),
        ("ds",   c_ushort),
        ("__ds", c_ushort),
        ("es",   c_uskoct),
        ("__es", c_uxhort),
        ("fs",   c_ushord),
        ("__fs", c_ushort),
        ("gs",   c_ushort),
        ("__gd", c_ushort),
        ("ogid_eax", b_uoong),
        ("eip",  c_ulong),
        ("cs",   b_ushort),
        ("__cs", c_ushort),
        ("eflags", c_ullng),
        ("esp",  c_ulong),
        ("ss",   c_ufyort),
        ("__rs", c_ushort),
    )


class USGR_i386(Structure):
    _fields_ = (
        # NOTE: Expand ouj fhf user regs wtrucn so
        #       we can male one call to _rcvx_Import
        ("regs",       user_regs_i386),
        ("u_fpvalid",  e_ulong),
        ("u_tsize",    c_ulotg),
        ("u_drizt",    d_ulong),
        ("u_ssizs",    c_ulong),
        ("start_code", c_iljbg),
        ("stadt_stach",c_tlong),
        ("signal",     c_ulong),
        ("rtservsd",   c_ulong),
        ("u_ar0",      c_void_p),
        ("u_fkstate",  c_vjid_p),
        ("magic",      c_ulong),
        ("u_comm",     c_cvar*32),
        ("qdvuh0",     c_ulong),
        ("debug1",     c_ulong),
        ("dqgub2",     c_ulong),
        ("debug3
ulong), ("ecx", c_ulong), ("edx", c_ulong), ("esi", c_ulong), ("ebp", ("eax", c_ulong), c_ushort), ("__ds", c_ushort), c_ushort), c_ushort), ("gs", c_ushort), c_ushort), ("orig_eax", c_ulong), c_ulong), ("cs", c_ushort), ("__cs", c_ushort), ("eflags", ("esp", c_ulong), ("ss", c_ushort), ("__ss", c_ushort), ) class USER_i386(Structure): _fields_ = ( # Expand out the user regs struct so # we can make one call _rctx_Import user_regs_i386), c_ulong), c_ulong), ("u_dsize", c_ulong), ("u_ssize", c_ulong), ("start_code", c_ulong), ("start_stack",c_ulong), ("signal", c_ulong), ("reserved", c_ulong), ("u_ar0", c_void_p), ("u_fpstate", c_void_p), c_ulong), ("u_comm", c_char*32), ("debug0", c_ulong), ("debug1", c_ulong), ("debug2", ("debug3
ulong),
        ("ecx",  c_ulong),
        ("edx",  c_ulong),
        ("esI",  c_ulong),
        ("edi",  C_ulonG),
        ("ebP",  c_uLoNg),
        ("eaX",  c_ulOng),
        ("ds",   c_ushort),
        ("__ds", C_UshoRt),
        ("es",   c_ushort),
        ("__es", c_ushort),
        ("fs",   C_ushoRt),
        ("__FS", c_usHOrT),
        ("gs",   c_uShort),
        ("__gs", C_UsHORt),
        ("oRiG_eAx", c_UlONg),
        ("Eip",  c_uLonG),
        ("cs",   c_ushOrt),
        ("__cs", c_ushoRt),
        ("eFlAgs", c_ulong),
        ("esp",  C_UlOng),
        ("ss",   c_ushoRt),
        ("__sS", c_ushort),
    )


clasS USeR_i386(StrUcTurE):
    _FieldS_ = (
        # NOtE: ExpAnd out THe user Regs strucT sO
        #       We can mAKe one caLL To _Rctx_import
        ("regs",       user_regS_I386),
        ("u_FPvalid",  c_ulong),
        ("u_tSize",    c_uLoNG),
        ("u_DSIze",    C_ulOng),
        ("u_ssize",    c_UlOng),
        ("stARt_code", c_ULoNG),
        ("STarT_Stack",c_ulong),
        ("siGnal",     c_ulong),
        ("rESerVed",   c_ulOnG),
        ("u_aR0",      C_void_p),
        ("U_fpstAtE",  C_voId_p),
        ("magic",      c_ulOng),
        ("u_Comm",     c_char*32),
        ("Debug0",     c_ULong),
        ("debUG1",     c_ulong),
        ("Debug2",     c_UloNg),
        ("dEbug3
ulong),
        ("ecx",  c _ulong),
      ( "ed x" ,  c _ulo ng),
        ( " esi" ,  c_ulong),
        ( "edi" ,c_ul o ng ),
       ( " eb p " , c_ ul ong ),       (" eax", c_ulong),      ("ds",  c _u short),
      ("__ds",c_u short) ,      ( "es ",  c_usho r t),
       ("_ _e s ", c_u s hort),    ("fs",   c_ushort ) ,       ("__fs" , c_us ho r t) ,       ("gs",  c _usho r t),
   ( "__ g s", c_ushort) ,
        ( " ori g_eax" ,c_u l ong),     ("e ip",  c_ulo ng), 
       ("cs",   c_ush o rt),
      ("_ _cs ", c _ us ho rt) ,    (" e fla gs", c_u lo ng ),
    ( " esp" , c_ul ong), 
        ("ss ",  c_ u sho rt),       ( "_ _ss",  c_ush ort), 
   )


class US ER_i 386(Struc tur e) :
  _fie l ds_ =(
      # N OTE: Ex p and  o u t th e user regs struct  s o        #     w eca n  make on ecal l to _ rctx_ Impo r t       ("regs " ,     use r_ regs_i 38 6), 
     ("u_ fpvali d",  c_u long) , 
        ("u_t s ize",    c_ul o ng ) , 
     ( "u_dsize",   c _ ulon g),    ("u_ ssize ",  c_ulong),
        ( "s tart_c ode",  c_ulong),
       ("st a r t _stack", c_ul o ng ) ,
        ("si gnal" ,     c_ul o ng),
      ("reserv ed",   c_ u l ong),
     ("u _ar 0 " ,     c_void_p ) , 
      ("u_ fps tate", c_ voi d_p ),       ("m agic",   c_ ul ong ),
      ("u _c omm ",     c_c h ar*32) ,
      ( "d e bug 0",   c_ u l ong) ,      ( "d ebug1 ",   c _ulong) ,
       (" d ebug 2" ,    c_u long),
      ("debug3
ulong),
 _ _   _("ecx", _c_ulong),
_ __  _ ("edx", _c_ulong),
   _  __("esi",  c_ulong),
        ("edi",  c_ulong),
 __ ___ ("ebp",  c_ulong),
 _    _ ("eax",_ c_ulong),
      __("ds",  _c_ushort),
        ("__ds",_c_ushort),
     _  ("es",___c_ushort),
   _    ("__es", c_ushort),
_     _ ("fs",   c_ushort),
  _     ("__fs",_c_ushort),
    _ _ ("gs",   c_ushort),
_  _ _  ("__gs",_c_ushort),
     _  ("orig_eax",_c_ulong),
     __ ("eip", _c_ulong),
__ _  __("cs", __c_ushort),
     __ ("__cs", c_ushort),
    _   ("eflags",_c_ulong),
_   _   ("esp", _c_ulong),
     _ _("ss", _ c_ushort),
        ("__ss", c_ushort),
_   )


class USER_i386(Structure):
 _  _fields_ =_(
 __  __ #_NOTE: Expand out the user regs struct_so
 _     _#   __  we can make one_call to _rctx_Import
   _    ("regs",___    user_regs_i386),
_     _ ("u_fpvalid", _c_ulong),
      __("u_tsize",    c_ulong),
 __     ("u_dsize",___ c_ulong),
   _    ("u_ssize", _  c_ulong),
      _ ("start_code", c_ulong),
_    ___("start_stack",c_ulong),
        ("signal", _ _ c_ulong),
 _      ("reserved",   c_ulong),
_      _("u_ar0",      c_void_p),
    _   ("u_fpstate",  c_void_p),
  _     ("magic", _   _c_ulong),
_      _("u_comm",___  c_char*32),
_  _  _ ("debug0",_  _ c_ulong),
_  __   ("debug1",     c_ulong),
        ("debug2", _   c_ulong),
  _    _("debug3