Projects STRLCPY IDAGolangHelper Commits 01c323e7
🤬
  • ■ ■ ■ ■ ■ ■
    GO_Utils/Firstmoduledata.py
    1  -import Utils
     1 +from . import Utils
    2 2  import idautils
    3 3  import struct
    4 4   
    5 5  def findFirstModuleData(addr, bt):
     6 + # print(f"{addr:x}")
    6 7   possible_addr = [x for x in idautils.XrefsTo(addr)]
    7 8   for p_a in possible_addr:
     9 + # print(f"Checking addr: {p_a}")
    8 10   if Utils.is_hardcoded_slice(p_a.frm, bt):
     11 + return p_a.frm
     12 + elif Utils.is_hardcoded_slice(p_a.frm+bt.size, bt):
    9 13   return p_a.frm
    10 14   return None
    11 15   
    skipped 8 lines
    20 24   addr2 = addr + bt.size * 6 # for go1.8 this addr will be for itablinks
    21 25   return Utils.is_hardcoded_slice(addr, bt) and (Utils.is_hardcoded_slice(addr2, bt))
    22 26   
     27 +def isGo116(addr, bt):
     28 + addr += bt.size * 1
     29 + # addr2 = addr + bt.size * 6 # for go1.8 this addr will be for itablinks
     30 + return Utils.is_hardcoded_slice(addr, bt)
     31 + 
    23 32  def getTypeinfo17(addr, bt):
    24 33   addr2 = addr + bt.size * 25
    25 34   robase = bt.ptr(addr2)
    skipped 11 lines
    37 46   size = bt.ptr(addr+bt.size)
    38 47   return beg, beg+size*4, robase
    39 48   
     49 +def getTypeinfo116(addr, bt):
     50 + addr2 = addr + bt.size * 35
     51 + robase = bt.ptr(addr2)
     52 + addr += bt.size * 40
     53 + beg = bt.ptr(addr)
     54 + size = bt.ptr(addr+bt.size)
     55 + print(robase)
     56 + return beg, beg+size*4, robase
    40 57   
    41 58  def getTypeinfo(addr, bt):
    42 59   addr += bt.size * 25
    skipped 3 lines
    46 63   return beg, beg+size*bt.size
    47 64   
    48 65  """
     66 +1.16
     67 +type moduledata struct {
     68 +0 pcHeader *pcHeader
     69 +1 funcnametab []byte
     70 +4 cutab []uint32
     71 +7 filetab []byte
     72 +10 pctab []byte
     73 +13 pclntable []byte
     74 +16 ftab []functab
     75 +19 findfunctab uintptr
     76 +20 minpc, maxpc uintptr
     77 + 
     78 +22 text, etext uintptr
     79 +24 noptrdata, enoptrdata uintptr
     80 +26 data, edata uintptr
     81 +28 bss, ebss uintptr
     82 +30 noptrbss, enoptrbss uintptr
     83 +32 end, gcdata, gcbss uintptr
     84 +35 types, etypes uintptr
     85 + 
     86 +37 textsectmap []textsect
     87 +40 typelinks []int32 // offsets from types
     88 + itablinks []*itab
     89 + 
     90 + ptab []ptabEntry
     91 + 
     92 + pluginpath string
     93 + pkghashes []modulehash
     94 + 
     95 + modulename string
     96 + modulehashes []modulehash
     97 + 
     98 + hasmain uint8 // 1 if module contains the main function, 0 otherwise
     99 + 
     100 + gcdatamask, gcbssmask bitvector
     101 + 
     102 + typemap map[typeOff]*_type // offset to *_rtype in previous module
     103 + 
     104 + bad bool // module failed to load and should be ignored
     105 + 
     106 + next *moduledata
     107 +}
    49 108  1.10 - same as 1.10
    50 109  1.9 - same as 1.8
    51 110  1.8
    skipped 107 lines
  • ■ ■ ■ ■ ■ ■
    GO_Utils/GoStrings.py
    skipped 40 lines
    41 41   return False, 0
    42 42   
    43 43  def make_string(addr, siz):
    44  - print "Creating string at %x %d size" % (addr, siz)
     44 + print("Creating string at %x %d size" % (addr, siz))
    45 45   idc.MakeUnknown(addr, siz, idc.DOUNK_SIMPLE)
    46 46   ida_bytes.create_strlit(addr, siz, -1)
    47 47   
    skipped 12 lines
    60 60   while position < f.endEA:
    61 61   instr = idautils.DecodeInstruction(position)
    62 62   if instr is None:
    63  - print "%x: Not and instruction found" % position
     63 + print("%x: Not and instruction found" % position)
    64 64   break
    65 65   mnem = instr.get_canon_mnem()
    66 66   if mnem == "mov":
    skipped 11 lines
  • ■ ■ ■ ■ ■ ■
    GO_Utils/Gopclntab.py
    skipped 4 lines
    5 5  import ida_funcs
    6 6  import ida_search
    7 7  import ida_segment
    8  -import Utils
     8 +from . import Utils
    9 9   
    10 10  info = idaapi.get_inf_structure()
    11 11  try:
    skipped 2 lines
    14 14   is_be = info.mf
    15 15   
    16 16  lookup = "FF FF FF FB 00 00" if is_be else "FB FF FF FF 00 00"
     17 +lookup16 = "FF FF FF FA 00 00" if is_be else "FA FF FF FF 00 00"
    17 18   
    18 19  def check_is_gopclntab(addr):
    19 20   ptr = Utils.get_bitness(addr)
    skipped 5 lines
    25 26   return True
    26 27   return False
    27 28   
     29 +def check_is_gopclntab16(addr):
     30 + ptr = Utils.get_bitness(addr)
     31 + offset = 8 + ptr.size *6
     32 + # print(f"{addr+offset:x}")
     33 + first_entry = ptr.ptr(addr+offset) + addr
     34 + # print(f"{first_entry:x}")
     35 + func_loc = ptr.ptr(first_entry)
     36 + struct_ptr = ptr.ptr(first_entry+8) + first_entry
     37 + first_entry = ptr.ptr(struct_ptr)
     38 + if func_loc == first_entry:
     39 + return True
     40 + return False
    28 41   
    29 42  def findGoPcLn():
    30 43   possible_loc = ida_search.find_binary(0, idc.BADADDR, lookup, 16, idc.SEARCH_DOWN) #header of gopclntab
    skipped 3 lines
    34 47   else:
    35 48   #keep searching till we reach end of binary
    36 49   possible_loc = ida_search.find_binary(possible_loc+1, idc.BADADDR, lookup, 16, idc.SEARCH_DOWN)
     50 + possible_loc = ida_search.find_binary(0, idc.BADADDR, lookup16, 16, idc.SEARCH_DOWN) #header of gopclntab
     51 + while possible_loc != idc.BADADDR:
     52 + print(f"found possible 1.16 gopclntab")
     53 + if check_is_gopclntab16(possible_loc):
     54 + print("Looks like this is go1.16 binary")
     55 + return possible_loc
     56 + else:
     57 + #keep searching till we reach end of binary
     58 + possible_loc = ida_search.find_binary(possible_loc+1, idc.BADADDR, lookup16, 16, idc.SEARCH_DOWN)
    37 59   return None
    38 60   
    39 61   
    skipped 3 lines
    43 65   size = ptr.ptr(pos)
    44 66   pos += ptr.size
    45 67   end = pos + (size * ptr.size * 2)
    46  - print "%x" % end
     68 + print("%x" % end)
    47 69   while pos < end:
    48 70   offset = ptr.ptr(pos + ptr.size)
    49 71   ptr.maker(pos) #in order to get xrefs
    skipped 9 lines
    59 81   name = Utils.relaxName(name)
    60 82   Utils.rename(func_addr, name)
    61 83   
     84 + 
     85 +def rename16(beg, ptr, make_funcs = True):
     86 + base = beg
     87 + first_entry = ptr.ptr(base+ptr.size * 6 + 8) + base
     88 + 
     89 + cnt = ptr.ptr(base + 8)
     90 + funcname_start = base + 8 + ptr.size *7
     91 + for i in range(cnt):
     92 + struct_ptr = ptr.ptr(first_entry + i*ptr.size*2 + 8) + first_entry
     93 + # print(f"{struct_ptr:x}")
     94 + func_addr = ptr.ptr(first_entry + i*ptr.size*2)
     95 + str_val = ida_bytes.get_dword(struct_ptr+8) + funcname_start
     96 + name = ida_bytes.get_strlit_contents(str_val, -1, -1)
     97 + print(f"{func_addr:x} {name}")
     98 + if make_funcs == True:
     99 + ida_bytes.del_items(func_addr, 1, ida_bytes.DELIT_SIMPLE)
     100 + ida_funcs.add_func(func_addr)
     101 + # print(type(name))
     102 + name = Utils.relaxName(name.decode())
     103 + Utils.rename(func_addr, name)
     104 + 
     105 + # fcn_name_offset = ptr.ptr(strict)
     106 + # offset = ptr.ptr(pos + ptr.size)
     107 + # ptr.maker(pos) #in order to get xrefs
     108 + # ptr.maker(pos+ptr.size)
     109 + # pos += ptr.size * 2
     110 + # ptr.maker(base+offset)
     111 + # func_addr = ptr.ptr(base+offset)
     112 + # if make_funcs == True:
     113 + # ida_bytes.del_items(func_addr, 1, ida_bytes.DELIT_SIMPLE)
     114 + # ida_funcs.add_func(func_addr)
     115 + # name_offset = idc.get_wide_dword(base+offset+ptr.size)
     116 + # name = idc.get_strlit_contents(base + name_offset)
     117 + # name = Utils.relaxName(name)
     118 + # Utils.rename(func_addr, name)
     119 + 
  • ■ ■ ■ ■ ■
    GO_Utils/Types.py
    1  -import Utils
     1 +from . import Utils
    2 2  import ida_bytes
    3 3  import ida_struct
    4 4  import idc
    skipped 75 lines
    80 80   ]
    81 81   creator.createTypes(self.standardTypes)
    82 82   
     83 +class Go116Types(GoTypes_BASE):
     84 + def __init__(self, creator):
     85 + super(Go116Types, self).__init__(creator)
     86 + self.standardTypes = [
     87 + ("type", [
     88 + ("size", "uintptr"),
     89 + ("ptrdata", "uintptr"),
     90 + ("hash", "__int32"),
     91 + ("flag", "__int8"),
     92 + ("align", "__int8"),
     93 + ("fieldAlign", "__int8"),
     94 + ("kind", "kind"),
     95 + ("equal", "*void"),
     96 + ("gcdata", "*unsigned char"),
     97 + ("string", "__int32"),
     98 + ("ptrtothis", "__int32"),
     99 + ])
     100 + ]
     101 + 
     102 + #this types depends on type structure so should be created after
     103 + self.commonTypes += [
     104 + ("uncommonType", [("pkgPath", "__int32"), ("mcount", "__int16"), ("unused1", "__int16"),("moff", "__int32"), ("unused2", "__int16")]),
     105 + ("method__", [("name", "__int32"), ("mtyp", "__int32"),("ifn","__int32"), ("tfn", "__int32")]),
     106 + ("structField",[
     107 + ("Name", "void *"),
     108 + ("typ", "*type"),
     109 + ("offset", "uintptr"),
     110 + ]),
     111 + ("structType", [
     112 + ("type","type"),
     113 + ("pkgPath", "void *"),
     114 + ("fields", "slice")
     115 + ]),
     116 + ("imethod", [
     117 + ("name", "__int32"),
     118 + ("pkgPath", "__int32"),
     119 + ]),
     120 + ("interfaceType",[
     121 + ("type", "type"),
     122 + ("pkgPath", "void *"),
     123 + ("methods", "slice")
     124 + ]),
     125 + ("funcType", [
     126 + ("type", "type"),
     127 + ("incount","__int16"),
     128 + ("outcount", "__int16")
     129 + ]),
     130 + ("mapType", [
     131 + ("type", "type"),
     132 + ("key","*type"),
     133 + ("elem","*type"),
     134 + ("bucket", "*type"),
     135 + ("hasher", "void *"),
     136 + ("keysize","__int8"),
     137 + ("elemsize","__int8"),
     138 + ("bucketsize","__int16"),
     139 + ("flags","__int32"),
     140 + ])
     141 + ]
     142 + 
     143 + creator.createTypes(self.standardTypes)
     144 + creator.createTypes(self.commonTypes)
    83 145   
    84 146  class Go17Types(GoTypes_BASE):
    85 147   def __init__(self, creator):
    skipped 181 lines
    267 329   def __iter__(self):
    268 330   return self
    269 331   
    270  - def next(self):
     332 + def __next__(self):
    271 333   if self.pos >= self.end:
    272 334   raise StopIteration
    273 335   value = self.stepper.ptr(self.pos)
    skipped 41 lines
    315 377   #Check if we already parse this
    316 378   if offset in self.type_addr:
    317 379   return
    318  - print "Processing: %x" % offset
     380 + print("Processing: %x" % offset)
    319 381   self.type_addr.append(offset)
    320 382   
    321 383   #Set type and get name
    skipped 3 lines
    325 387   
    326 388   #get kind name
    327 389   kind_name = self.getKindEnumName(offset)
    328  - print kind_name
     390 + print(kind_name)
    329 391   if name[0] == "*" and kind_name != "PTR":
    330 392   name = name[1:]
    331 393   name = Utils.relaxName(name)
    skipped 56 lines
    388 450   self.make_arr(addr, size, sz, "structField")
    389 451   sid_type = ida_struct.get_struc_id("type")
    390 452   size_new_struct = self.getPtr(sid_type, offset, "size")
    391  - for i in xrange(size):
     453 + for i in range(size):
    392 454   self.processStructField(addr, i*sz)
    393 455   name = self.getName(offset)
    394 456   name = Utils.relaxName(name)
    skipped 23 lines
    418 480   fields = []
    419 481   curr_offset = 0
    420 482   idc.set_cmt(addr, name, 0)
    421  - for i in xrange(size):
     483 + for i in range(size):
    422 484   fieldname = self.nameFromOffset(self.getPtr(sid, addr+i*sz,"Name"))
    423 485   type_addr = self.getPtr(sid, addr+i*sz, "typ")
    424 486   typename = self.getType(type_addr)
    skipped 1 lines
    426 488   if fieldname == "" or fieldname is None:
    427 489   fieldname = "unused_"+Utils.id_generator()
    428 490   offset = self.getStructFieldOffset(sid, addr+i*sz)
     491 + print(f"Get offset: {offset:x}")
    429 492   if offset != curr_offset:
    430  - print "Offset missmatch.Got %d expected %d. Adding padding..." % (curr_offset, offset)
     493 + print("Offset missmatch.Got %d expected %d. Adding padding..." % (curr_offset, offset))
    431 494   if offset < curr_offset:
    432 495   raise("Too many bytes already")
    433 496   while offset != curr_offset:
    skipped 3 lines
    437 500   if size != 0:
    438 501   offset_kind = idc.get_member_offset(sid_type, "kind")
    439 502   kind_of_type = self.getKindEnumName(type_addr)
    440  - print kind_of_type
     503 + print(kind_of_type)
    441 504   if kind_of_type == "STRUCT_": #Disabled for now
    442 505   name_type = self.getName(type_addr)
    443 506   while name_type[0] == "*":
    444 507   name_type = name_type[1:]
    445 508   name_type = Utils.relaxName(name_type)
    446 509   name_type = "ut_" + name_type
    447  - #print "setting type %s" % name_type
     510 + #print("setting type %s" % name_type)
    448 511   fields.append((fieldname, name_type))
    449 512   elif kind_of_type == "STRING":
    450 513   fields.append((fieldname, "string"))
    skipped 4 lines
    455 518   else:
    456 519   fields.append((fieldname, "char [%d]" % size))
    457 520   if curr_offset != self_size:
    458  - print "%x: Structure size mismatch: %x" % (addr, curr_offset)
     521 + print("%x: Structure size mismatch: %x" % (addr, curr_offset))
    459 522   if self_size < curr_offset:
    460 523   raise("Too many bytes already")
    461 524   while self_size != curr_offset:
    skipped 4 lines
    466 529   new_type_sid = ida_struct.get_struc_id(name)
    467 530   sz = ida_struct.get_struc_size(new_type_sid)
    468 531   if sz != self_size:
    469  - print "%x" % addr
     532 + print("%x" % addr )
    470 533   raise("Error at creating structure")
    471 534  
    472 535   def getType(self, addr):
    473  - print "%x" % addr
     536 + print("%x" % addr)
    474 537   sid = ida_struct.get_struc_id("type")
    475 538   name = self.getName(addr)
    476 539   if self.getKindEnumName(addr) != "PTR":
    skipped 50 lines
    527 590   super(TypeProcessing17, self).__init__(pos, endpos, step, settings)
    528 591   self.robase = base_type
    529 592   
    530  - def next(self):
     593 + def __next__(self):
    531 594   if self.pos >= self.end:
    532 595   raise StopIteration
    533 596   value = idc.get_wide_dword(self.pos)
    skipped 7 lines
    541 604   
    542 605   def get_str(self, pos, len):
    543 606   out = ""
    544  - for i in xrange(len):
     607 + for i in range(len):
    545 608   out += chr(idc.get_wide_byte(pos+i))
    546 609   return out
    547 610   
    skipped 25 lines
    573 636   def processIMethods(self, offst, size):
    574 637   sz = ida_struct.get_struc_size(ida_struct.get_struc_id("imethod"))
    575 638   comm = []
    576  - for i in xrange(size):
     639 + for i in range(size):
    577 640   comm.append(self.processIMethod(offst + i * sz))
    578 641   idc.set_cmt(offst, "\n".join(comm), 0)
    579 642   return comm
    skipped 36 lines
    616 679   in_size = idc.Word(offset + idc.get_member_offset(sid, "incount"))
    617 680   out_size = idc.Word(offset + idc.get_member_offset(sid, "outcount"))
    618 681   sz = ida_struct.get_struc_size(sid)
    619  - for i in xrange(in_size + out_size):
     682 + for i in range(in_size + out_size):
    620 683   idc.SetType(offset + sz + i * self.stepper.size, "type *")
    621 684   
    622 685   
    skipped 5 lines
    628 691   
    629 692   def getStructFieldOffset(self, sid, addr):
    630 693   return (self.getPtr(sid, addr, "offset") >> 1)
     694 + 
     695 +class TypeProcessing116(TypeProcessing19):
     696 +
     697 + def __init__(self, pos, endpos, step, settings, base_type):
     698 + super(TypeProcessing19, self).__init__(pos, endpos, step, settings, base_type)
     699 + self.robase = base_type
     700 + 
     701 + def getStructFieldOffset(self, sid, addr):
     702 + return (self.getPtr(sid, addr, "offset") >> 1)
     703 +
     704 + def makeMap(self, offset):
     705 + idc.SetType(offset, "mapType")
     706 + sid = ida_struct.get_struc_id("mapType")
     707 + addr = self.getPtr(sid, offset, "key")
     708 + self.handle_offset(addr)
     709 + addr = self.getPtr(sid, offset, "elem")
     710 + self.handle_offset(addr)
     711 + addr = self.getPtr(sid, offset, "bucket")
     712 + self.handle_offset(addr)
  • ■ ■ ■ ■ ■ ■
    GO_Utils/Utils.py
    skipped 85 lines
    86 86   res = idc.add_struc_member(sid, i[0], -1, i1, i2, i3)
    87 87   use_name = i[0]
    88 88   if res == -1: #Bad name
    89  - #print "Bad name %s for struct member" % i[0]
     89 + #print("Bad name %s for struct member" % i[0])
    90 90   use_name = i[0] + "_autogen_"+id_generator()
    91 91   idc.add_struc_member(sid, use_name, -1, i1, i2, i3)
    92 92   if new_type is not None:
    93 93   offset = idc.get_member_offset(sid, use_name)
    94  - #print "Setting %s as %s" % (i[0], new_type)
     94 + #print("Setting %s as %s" % (i[0], new_type))
    95 95   idc.SetType(idc.get_member_id(sid, offset), new_type)
    96 96   
    97 97   def makeStruct(self, i):
    98  - print "Creating structure %s" % (i[0])
     98 + print("Creating structure %s" % (i[0]))
    99 99   sid = self.createStruct(i[0])
    100 100   self.fillStruct(sid, i[1])
    101 101   
    skipped 19 lines
  • ■ ■ ■ ■ ■ ■
    GO_Utils/__init__.py
    1 1  import idaapi
    2  -import Gopclntab
    3  -import Utils
    4  -import Firstmoduledata
    5  -import Types
     2 +from . import Gopclntab
     3 +from . import Utils
     4 +from . import Firstmoduledata
     5 +from . import Types
    6 6  import idc
    7 7  import idautils
    8 8  import ida_ida
    skipped 8 lines
    17 17   self.structCreator = Utils.StructCreator(self.bt_obj)
    18 18   self.processor = None
    19 19   self.typer = None
     20 + self.is116 = False
    20 21   
    21 22   def getVal(self, key):
    22 23   if key in self.storage:
    skipped 7 lines
    30 31   gopcln_addr = self.getVal("gopcln")
    31 32   if gopcln_addr is None:
    32 33   gopcln_addr = Gopclntab.findGoPcLn()
     34 + print("Saving gopclntab entry")
    33 35   self.setVal("gopcln", gopcln_addr)
    34 36   return gopcln_addr
    35 37   
    36 38   def findModuleData(self):
    37 39   gopcln_addr = self.getGopcln()
    38  - fmd = Firstmoduledata.findFirstModuleData(gopcln_addr, self.bt_obj)
    39  - self.setVal("firstModData", fmd)
     40 + if gopcln_addr is not None:
     41 + fmd = Firstmoduledata.findFirstModuleData(gopcln_addr, self.bt_obj)
     42 + self.setVal("firstModData", fmd)
    40 43   return
    41 44   
    42 45   def tryFindGoVersion(self):
    skipped 5 lines
    48 51   vers = "go1.7"
    49 52   elif Firstmoduledata.isGo18_10(fmd, self.bt_obj) is True:
    50 53   vers = "go1.8 or go1.9 or go1.10"
     54 + elif Firstmoduledata.isGo116(fmd, self.bt_obj) is True:
     55 + vers = "go1.16"
     56 + self.is116 = True
    51 57   return "According to moduleData struct is should be %s" % (vers)
    52 58   
    53 59   def renameFunctions(self):
    54 60   gopcln_tab = self.getGopcln()
    55  - Gopclntab.rename(gopcln_tab, self.bt_obj)
     61 + if self.is116:
     62 + Gopclntab.rename16(gopcln_tab, self.bt_obj)
     63 + else:
     64 + Gopclntab.rename(gopcln_tab, self.bt_obj)
    56 65   
    57 66   def getVersionByString(self):
    58 67   # pos = idautils.Functions().next()
    59 68   end_ea = idc.get_segm_end(0)
    60  -
     69 + if ida_search.find_binary(0, end_ea, "67 6f 31 2e 31 36", 16, idc.SEARCH_DOWN) != idc.BADADDR:
     70 + return 'Go 1.16'
    61 71   if ida_search.find_binary(0, end_ea, "67 6f 31 2e 31 33", 16, idc.SEARCH_DOWN) != idc.BADADDR:
    62 72   return 'Go 1.13'
    63 73   if ida_search.find_binary(0, end_ea, "67 6f 31 2e 31 32", 16, idc.SEARCH_DOWN) != idc.BADADDR:
    skipped 34 lines
    98 108   self.typer = Types.Go17Types(self.structCreator)
    99 109   elif typ == 7: #1.10
    100 110   self.typer = Types.Go17Types(self.structCreator)
     111 + elif typ == 8: #1.10
     112 + self.typer = Types.Go116Types(self.structCreator)
    101 113   
    102 114   def typesModuleData(self, typ):
    103 115   if typ < 2:
    skipped 18 lines
    122 134   elif typ == 7:
    123 135   beg, end, robase = Firstmoduledata.getTypeinfo18(fmd, self.bt_obj)
    124 136   self.processor = Types.TypeProcessing19(beg, end, self.bt_obj, self, robase)
     137 + elif typ == 8:
     138 + beg, end, robase = Firstmoduledata.getTypeinfo116(fmd, self.bt_obj)
     139 + self.processor = Types.TypeProcessing116(beg, end, self.bt_obj, self, robase)
    125 140   else:
    126 141   beg, end = Firstmoduledata.getTypeinfo(fmd, self.bt_obj)
    127 142   self.processor = Types.TypeProcessing(beg, end, self.bt_obj, self)
    128  - print "%x %x %x" % (beg, end, robase)
     143 + print("%x %x %x" % (beg, end, robase))
    129 144   for i in self.processor:
    130 145   pass
    131 146   return
  • ■ ■ ■ ■ ■ ■
    go_entry.py
    skipped 33 lines
    34 34  <Go1.7:{r7}>
    35 35  <Go1.8:{r8}>
    36 36  <Go1.9:{r9}>
    37  -<Go1.10:{r10}>{cGoVers}>
     37 +<Go1.10:{r10}>
     38 +<Go1.16:{r16}>{cGoVers}>
    38 39  <##Add standard go types:{iButton4}>
    39 40  <##Parse types by moduledata:{iButton5}>
    40 41  """, {
    skipped 2 lines
    43 44   'iButton3': Form.ButtonInput(self.OnButton3),
    44 45   'iButton4': Form.ButtonInput(self.OnButton4),
    45 46   'iButton5': Form.ButtonInput(self.OnButton5),
    46  - 'cGoVers': Form.RadGroupControl(("r2", "r3","r4","r5","r6","r7", "r8", "r9", "r10")),
     47 + 'cGoVers': Form.RadGroupControl(("r2", "r3","r4","r5","r6","r7", "r8", "r9", "r10", "r16")),
    47 48   'FormChangeCb': Form.FormChangeCb(self.OnFormChange),
    48 49   })
    49 50   
    50 51   
    51 52   def OnButton1(self, code=0):
    52 53   GO_SETTINGS.findModuleData()
    53  - print GO_SETTINGS.tryFindGoVersion()
     54 + print(GO_SETTINGS.tryFindGoVersion())
    54 55   
    55 56   
    56 57   def OnButton3(self, code=0):
    57 58   GO_SETTINGS.renameFunctions()
    58 59   
    59 60   def OnButton2(self, code=0):
    60  - print GO_SETTINGS.getVersionByString()
     61 + print(GO_SETTINGS.getVersionByString())
    61 62   
    62 63   def OnButton4(self, code=0):
    63 64   typ = self.GetControlValue(self.cGoVers)
    skipped 37 lines
Please wait...
Page is in error, reload to recover