Package pype32 :: Module consts |
[hide private]
[frames] | no frames]

# Source Code for Module pype32.consts

      1  #!/usr/bin/python
      2  # -*- coding: utf-8 -*-
      3
      4  # Copyright (c) 2013, Nahuel Riva
      5  # All rights reserved.
      6  #
      7  # Redistribution and use in source and binary forms, with or without
      8  # modification, are permitted provided that the following conditions are met:
      9  #
     10  #     * Redistributions of source code must retain the above copyright notice,
     11  #       this list of conditions and the following disclaimer.
     12  #     * Redistributions in binary form must reproduce the above copyright
     13  #       notice,this list of conditions and the following disclaimer in the
     14  #       documentation and/or other materials provided with the distribution.
     15  #     * Neither the name of the copyright holder nor the names of its
     16  #       contributors may be used to endorse or promote products derived from
     17  #       this software without specific prior written permission.
     18  #
     19  # THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
     20  # AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
     21  # IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
     22  # ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
     23  # LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
     24  # CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
     25  # SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
     26  # INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
     27  # CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
     28  # ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
     29  # POSSIBILITY OF SUCH DAMAGE.
     30
     31  """
     32  Common definitions.
     33  """
     34
     35  __revision__ = "$Id$"
     36
     37  MZ_SIGNATURE = 0x5a4d
     38  PE_SIGNATURE = 0x4550
     39
     40  SECTION_HEADER_LENGTH = 0x28
     41
     42  INTEL386 = 0x014c
     43  COMMON_CHARACTERISTICS = 0x0102 # - file is executable
     44                                  # - 32 bit word machine
     45  PE32 = 0x010b
     46  PE64 = 0x020b
     47  WINDOWSGUI = 2
     48  TERMINAL_SERVER_AWARE = 0x8000
     49
     50  IMAGE_NUMBEROF_DIRECTORY_ENTRIES = 16
     51
     52  EXPORT_DIRECTORY = 0
     53  IMPORT_DIRECTORY = 1
     54  RESOURCE_DIRECTORY = 2
     55  EXCEPTION_DIRECTORY = 3
     56  SECURITY_DIRECTORY = 4
     57  RELOCATION_DIRECTORY = 5
     58  DEBUG_DIRECTORY = 6
     59  ARCHITECTURE_DIRECTORY = 7
     60  RESERVED_DIRECTORY = 8
     61  TLS_DIRECTORY = 9
     62  CONFIGURATION_DIRECTORY = 10
     63  BOUND_IMPORT_DIRECTORY = 11
     64  IAT_DIRECTORY = 12
     65  DELAY_IMPORT_DIRECTORY = 13
     66  NET_METADATA_DIRECTORY = 14
     67  RESERVED_DIRECTORY = 15
     68
     69  IMAGE_DOS_HEADER = 0
     70  IMAGE_NT_HEADERS = 1
     71  IMAGE_FILE_HEADER = 2
     72  IMAGE_OPTIONAL_HEADER = 3
     73  IMAGE_SECTION_HEADER = 4
     74  IMAGE_DATA_DIRECTORY = 5
     75  IMAGE_IMPORT_DESCRIPTOR = 6
     76  NET_DIRECTORY = 7
     77  NET_METADATA_HEADER = 8
     78  IMAGE_COR20_HEADER = 9
     79  NET_METADATA_STREAM_ENTRY = 10
     80  NET_METADATA_STREAMS = 11
     81  NET_METADATA_TABLE_HEADER = 12
     82  NET_METADATA_TABLES = 13
     83  IMAGE_DEBUG_DIRECTORY = 14
     84  IMAGE_DEBUG_DIRECTORIES = 15
     85  IMAGE_IMPORT_DESCRIPTOR_ENTRY = 16
     86  IMPORT_ADDRESS_TABLE_ENTRY = 17
     87  IMPORT_ADDRESS_TABLE = 18
     88  IID_METADATA = 19
     89  EXPORT_TABLE_ENTRY = 20
     90  IMAGE_BASE_RELOCATION_ENTRY = 21
     91  IMAGE_BOUND_IMPORT_DESCRIPTOR_ENTRY = 22
     92  IMAGE_BOUND_FORWARDER_REF_ENTRY = 23
     93  NET_TABLES = 24
     94  IMAGE_OPTIONAL_HEADER64 = 25
     95  TLS_DIRECTORY64 = 26
     96  IMPORT_ADDRESS_TABLE_ENTRY64 = 27
     97  TLS_DIRECTORY64 = 28
     98
     99  SIZEOF_IMAGE_DEBUG_ENTRY32 = 28
    100  SIZEOF_IMAGE_IMPORT_ENTRY32 = 20
    101  SIZEOF_IMAGE_BOUND_IMPORT_ENTRY32 = 8
    102  SIZEOF_IMAGE_BOUND_FORWARDER_REF_ENTRY32 = 8
    103
    104  DEFAULT_FILE_ALIGNMENT = 0x200
    105  DEFAULT_PAGE_SIZE = 0x1000
    106
    107  IMAGE_ORDINAL_FLAG = 0x80000000L
    108  IMAGE_ORDINAL_FLAG64 = 0x8000000000000000L
    109  OPTIONAL_HEADER_MAGIC_PE = 0x10b
    110  OPTIONAL_HEADER_MAGIC_PE_PLUS = 0x20b
    111
    112  IMAGE_FILE_RELOCS_STRIPPED = 0x0001
    113  IMAGE_FILE_EXECUTABLE_IMAGE = 0x0002
    114  IMAGE_FILE_LINE_NUMS_STRIPPED = 0x0004
    115  IMAGE_FILE_LOCAL_SYMS_STRIPPED = 0x0008
    116  IMAGE_FILE_AGGRESIVE_WS_TRIM = 0x0010
    117  IMAGE_FILE_LARGE_ADDRESS_AWARE = 0x0020
    118  IMAGE_FILE_16BIT_MACHINE = 0x0040
    119  IMAGE_FILE_BYTES_REVERSED_LO = 0x0080
    120  IMAGE_FILE_32BIT_MACHINE = 0x0100
    121  IMAGE_FILE_DEBUG_STRIPPED = 0x0200
    122  IMAGE_FILE_REMOVABLE_RUN_FROM_SWAP = 0x0400
    123  IMAGE_FILE_NET_RUN_FROM_SWAP = 0x0800
    124  IMAGE_FILE_SYSTEM = 0x1000
    125  IMAGE_FILE_DLL = 0x2000
    126  IMAGE_FILE_UP_SYSTEM_ONLY = 0x4000
    127  IMAGE_FILE_BYTES_REVERSED_HI = 0x8000
    128
    129  IMAGE_SCN_CNT_CODE = 0x00000020
    130  IMAGE_SCN_CNT_INITIALIZED_DATA = 0x00000040
    131  IMAGE_SCN_CNT_UNINITIALIZED_DATA = 0x00000080
    132  IMAGE_SCN_LNK_OTHER = 0x00000100
    133  IMAGE_SCN_LNK_INFO = 0x00000200
    134  IMAGE_SCN_LNK_REMOVE = 0x00000800
    135  IMAGE_SCN_LNK_COMDAT = 0x00001000
    136  IMAGE_SCN_MEM_FARDATA = 0x00008000
    137  IMAGE_SCN_MEM_PURGEABLE = 0x00020000
    138  IMAGE_SCN_MEM_16BIT = 0x00020000
    139  IMAGE_SCN_MEM_LOCKED = 0x00040000
    140  IMAGE_SCN_MEM_PRELOAD = 0x00080000
    141  IMAGE_SCN_ALIGN_1BYTES = 0x00100000
    142  IMAGE_SCN_ALIGN_2BYTES = 0x00200000
    143  IMAGE_SCN_ALIGN_4BYTES = 0x00300000
    144  IMAGE_SCN_ALIGN_8BYTES = 0x00400000
    145  IMAGE_SCN_ALIGN_16BYTES = 0x00500000
    146  IMAGE_SCN_ALIGN_32BYTES = 0x00600000
    147  IMAGE_SCN_ALIGN_64BYTES = 0x00700000
    148  IMAGE_SCN_ALIGN_128BYTES = 0x00800000
    149  IMAGE_SCN_ALIGN_256BYTES = 0x00900000
    150  IMAGE_SCN_ALIGN_512BYTES = 0x00A00000
    151  IMAGE_SCN_ALIGN_1024BYTES = 0x00B00000
    152  IMAGE_SCN_ALIGN_2048BYTES = 0x00C00000
    153  IMAGE_SCN_ALIGN_4096BYTES = 0x00D00000
    154  IMAGE_SCN_ALIGN_8192BYTES = 0x00E00000
    155  IMAGE_SCN_ALIGN_MASK = 0x00F00000
    156  IMAGE_SCN_LNK_NRELOC_OVFL = 0x01000000
    157  IMAGE_SCN_MEM_DISCARDABLE = 0x02000000
    158  IMAGE_SCN_MEM_NOT_CACHED = 0x04000000
    159  IMAGE_SCN_MEM_NOT_PAGED = 0x08000000
    160  IMAGE_SCN_MEM_SHARED = 0x10000000
    161  IMAGE_SCN_MEM_EXECUTE = 0x20000000
    162  IMAGE_SCN_MEM_READ = 0x40000000
    163  IMAGE_SCN_MEM_WRITE = 0x80000000L
    164
    165  IMAGE_DEBUG_TYPE_UNKNOWN = 0
    166  IMAGE_DEBUG_TYPE_COFF = 1
    167  IMAGE_DEBUG_TYPE_CODEVIEW = 2
    168  IMAGE_DEBUG_TYPE_FPO = 3
    169  IMAGE_DEBUG_TYPE_MISC = 4
    170  IMAGE_DEBUG_TYPE_EXCEPTION = 5
    171  IMAGE_DEBUG_TYPE_FIXUP = 6
    172  IMAGE_DEBUG_TYPE_OMAP_TO_SRC = 7
    173  IMAGE_DEBUG_TYPE_OMAP_FROM_SRC = 8
    174  IMAGE_DEBUG_TYPE_BORLAND = 9
    175  IMAGE_DEBUG_TYPE_RESERVED10 = 10
    176
    177  IMAGE_SUBSYSTEM_UNKNOWN = 0
    178  IMAGE_SUBSYSTEM_NATIVE = 1
    179  IMAGE_SUBSYSTEM_WINDOWS_GUI = 2
    180  IMAGE_SUBSYSTEM_WINDOWS_CUI = 3
    181  IMAGE_SUBSYSTEM_OS2_CUI = 5
    182  IMAGE_SUBSYSTEM_POSIX_CUI = 7
    183  IMAGE_SUBSYSTEM_WINDOWS_CE_GUI = 9
    184  IMAGE_SUBSYSTEM_EFI_APPLICATION = 10
    185  IMAGE_SUBSYSTEM_EFI_BOOT_SERVICE_DRIVER = 11
    186  IMAGE_SUBSYSTEM_EFI_RUNTIME_DRIVER = 12
    187  IMAGE_SUBSYSTEM_EFI_ROM = 13
    188  IMAGE_SUBSYSTEM_XBOX = 14
    189
    190
    191  IMAGE_FILE_MACHINE_UNKNOWN = 0
    192  IMAGE_FILE_MACHINE_AM33 = 0x1d3
    193  IMAGE_FILE_MACHINE_AMD64 = 0x8664
    194  IMAGE_FILE_MACHINE_ARM = 0x1c0
    195  IMAGE_FILE_MACHINE_EBC = 0xebc
    196  IMAGE_FILE_MACHINE_I386 = 0x14c
    197  IMAGE_FILE_MACHINE_IA64 = 0x200
    198  IMAGE_FILE_MACHINE_MR32 = 0x9041
    199  IMAGE_FILE_MACHINE_MIPS16 = 0x266
    200  IMAGE_FILE_MACHINE_MIPSFPU = 0x366
    201  IMAGE_FILE_MACHINE_MIPSFPU16 = 0x466
    202  IMAGE_FILE_MACHINE_POWERPC = 0x1f0
    203  IMAGE_FILE_MACHINE_POWERPCFP = 0x1f1
    204  IMAGE_FILE_MACHINE_R4000 = 0x166
    205  IMAGE_FILE_MACHINE_SH3 = 0x1a2
    206  IMAGE_FILE_MACHINE_SH3DSP = 0x1a3
    207  IMAGE_FILE_MACHINE_SH4 = 0x1a6
    208  IMAGE_FILE_MACHINE_SH5 = 0x1a8
    209  IMAGE_FILE_MACHINE_THUMB = 0x1c2
    210  IMAGE_FILE_MACHINE_WCEMIPSV2 = 0x169
    211
    212  IMAGE_REL_BASED_ABSOLUTE = 0
    213  IMAGE_REL_BASED_HIGH = 1
    214  IMAGE_REL_BASED_LOW = 2
    215  IMAGE_REL_BASED_HIGHLOW = 3
    216  IMAGE_REL_BASED_HIGHADJ = 4
    217  IMAGE_REL_BASED_MIPS_JMPADDR = 5
    218  IMAGE_REL_BASED_SECTION = 6
    219  IMAGE_REL_BASED_REL = 7
    220  IMAGE_REL_BASED_MIPS_JMPADDR16 = 9
    221  IMAGE_REL_BASED_IA64_IMM64 = 9
    222  IMAGE_REL_BASED_DIR64 = 10
    223  IMAGE_REL_BASED_HIGH3ADJ = 11
    224
    225  IMAGE_DLL_CHARACTERISTICS_RESERVED_0x0001 = 0x0001
    226  IMAGE_DLL_CHARACTERISTICS_RESERVED_0x0002 = 0x0002
    227  IMAGE_DLL_CHARACTERISTICS_RESERVED_0x0004 = 0x0004
    228  IMAGE_DLL_CHARACTERISTICS_RESERVED_0x0008 = 0x0008
    229  IMAGE_DLL_CHARACTERISTICS_DYNAMIC_BASE = 0x0040
    230  IMAGE_DLL_CHARACTERISTICS_FORCE_INTEGRITY = 0x0080
    231  IMAGE_DLL_CHARACTERISTICS_NX_COMPAT = 0x0100
    232  IMAGE_DLL_CHARACTERISTICS_NO_ISOLATION = 0x0200
    233  IMAGE_DLL_CHARACTERISTICS_NO_SEH = 0x0400
    234  IMAGE_DLL_CHARACTERISTICS_NO_BIND = 0x0800
    235  IMAGE_DLL_CHARACTERISTICS_RESERVED_0x1000 = 0x1000
    236  IMAGE_DLL_CHARACTERISTICS_WDM_DRIVER = 0x2000
    237  IMAGE_DLL_CHARACTERISTICS_TERMINAL_SERVER_AWARE = 0x8000
    238
    239  ADDRESS_MASK32 = 0x7fffffff
    240  ADDRESS_MASK64 = 0x7fffffffffffffff
    241
    242  RT_CURSOR = 1
    243  RT_BITMAP = 2
    244  RT_ICON = 3
    245  RT_MENU = 4
    246  RT_DIALOG = 5
    247  RT_STRING = 6
    248  RT_FONTDIR = 7
    249  RT_FONT = 8
    250  RT_ACCELERATOR = 9
    251  RT_RCDATA = 10
    252  RT_MESSAGETABLE = 11
    253  RT_GROUP_CURSOR = 12
    254  RT_GROUP_ICON = 14
    255  RT_VERSION = 16
    256  RT_DLGINCLUDE = 17
    257  RT_PLUGPLAY = 19
    258  RT_VXD = 20
    259  RT_ANICURSOR = 21
    260  RT_ANIICON = 22
    261  RT_HTML = 23
    262  RT_MANIFEST = 24
    263
    264  LANG_NEUTRAL = 0x00
    265  LANG_INVARIANT = 0x7f
    266  LANG_AFRIKAANS = 0x36
    267  LANG_ALBANIAN = 0x1c
    268  LANG_ARABIC = 0x01
    269  LANG_ARMENIAN = 0x2b
    270  LANG_ASSAMESE = 0x4d
    271  LANG_AZERI = 0x2c
    272  LANG_BASQUE = 0x2d
    273  LANG_BELARUSIAN = 0x23
    274  LANG_BENGALI = 0x45
    275  LANG_BULGARIAN = 0x02
    276  LANG_CATALAN = 0x03
    277  LANG_CHINESE = 0x04
    278  LANG_CROATIAN = 0x1a
    279  LANG_CZECH = 0x05
    280  LANG_DANISH = 0x06
    281  LANG_DIVEHI = 0x65
    282  LANG_DUTCH = 0x13
    283  LANG_ENGLISH = 0x09
    284  LANG_ESTONIAN = 0x25
    285  LANG_FAEROESE = 0x38
    286  LANG_FARSI = 0x29
    287  LANG_FINNISH = 0x0b
    288  LANG_FRENCH = 0x0c
    289  LANG_GALICIAN = 0x56
    290  LANG_GEORGIAN = 0x37
    291  LANG_GERMAN = 0x07
    292  LANG_GREEK = 0x08
    293  LANG_GUJARATI = 0x47
    294  LANG_HEBREW = 0x0d
    295  LANG_HINDI = 0x39
    296  LANG_HUNGARIAN = 0x0e
    297  LANG_ICELANDIC = 0x0f
    298  LANG_INDONESIAN = 0x21
    299  LANG_ITALIAN = 0x10
    300  LANG_JAPANESE = 0x11
    301  LANG_KANNADA = 0x4b
    302  LANG_KASHMIRI = 0x60
    303  LANG_KAZAK = 0x3f
    304  LANG_KONKANI = 0x57
    305  LANG_KOREAN = 0x12
    306  LANG_KYRGYZ = 0x40
    307  LANG_LATVIAN = 0x26
    308  LANG_LITHUANIAN = 0x27
    309  LANG_MACEDONIAN = 0x2f
    310  LANG_MALAY = 0x3e
    311  LANG_MALAYALAM = 0x4c
    312  LANG_MANIPURI = 0x58
    313  LANG_MARATHI = 0x4e
    314  LANG_MONGOLIAN = 0x50
    315  LANG_NEPALI = 0x61
    316  LANG_NORWEGIAN = 0x14
    317  LANG_ORIYA = 0x48
    318  LANG_POLISH = 0x15
    319  LANG_PORTUGUESE = 0x16
    320  LANG_PUNJABI = 0x46
    321  LANG_ROMANIAN = 0x18
    322  LANG_RUSSIAN = 0x19
    323  LANG_SANSKRIT = 0x4f
    324  LANG_SERBIAN = 0x1a
    325  LANG_SINDHI = 0x59
    326  LANG_SLOVAK = 0x1b
    327  LANG_SLOVENIAN = 0x24
    328  LANG_SPANISH = 0x0a
    329  LANG_SWAHILI = 0x41
    330  LANG_SWEDISH = 0x1d
    331  LANG_SYRIAC = 0x5a
    332  LANG_TAMIL = 0x49
    333  LANG_TATAR = 0x44
    334  LANG_TELUGU = 0x4a
    335  LANG_THAI = 0x1e
    336  LANG_TURKISH = 0x1f
    337  LANG_UKRAINIAN = 0x22
    338  LANG_URDU = 0x20
    339  LANG_UZBEK = 0x43
    340  LANG_VIETNAMESE = 0x2a
    341  LANG_GAELIC = 0x3c
    342  LANG_MALTESE = 0x3a
    343  LANG_MAORI = 0x28
    344  LANG_RHAETO_ROMANCE = 0x17
    345  LANG_SAAMI = 0x3b
    346  LANG_SORBIAN = 0x2e
    347  LANG_SUTU = 0x30
    348  LANG_TSONGA = 0x31
    349  LANG_TSWANA = 0x32
    350  LANG_VENDA = 0x33
    351  LANG_XHOSA = 0x34
    352  LANG_ZULU = 0x35
    353  LANG_ESPERANTO = 0x8f
    354  LANG_WALON = 0x90
    355  LANG_CORNISH = 0x91
    356  LANG_WELSH = 0x92
    357  LANG_BRETON = 0x93
    358
    359  SUBLANG_NEUTRAL = 0x00
    360  SUBLANG_DEFAULT = 0x01
    361  SUBLANG_SYS_DEFAULT = 0x02
    362  SUBLANG_ARABIC_SAUDI_ARABIA = 0x01
    363  SUBLANG_ARABIC_IRAQ = 0x02
    364  SUBLANG_ARABIC_EGYPT = 0x03
    365  SUBLANG_ARABIC_LIBYA = 0x04
    366  SUBLANG_ARABIC_ALGERIA = 0x05
    367  SUBLANG_ARABIC_MOROCCO = 0x06
    368  SUBLANG_ARABIC_TUNISIA = 0x07
    369  SUBLANG_ARABIC_OMAN = 0x08
    370  SUBLANG_ARABIC_YEMEN = 0x09
    371  SUBLANG_ARABIC_SYRIA = 0x0a
    372  SUBLANG_ARABIC_JORDAN = 0x0b
    373  SUBLANG_ARABIC_LEBANON = 0x0c
    374  SUBLANG_ARABIC_KUWAIT = 0x0d
    375  SUBLANG_ARABIC_UAE = 0x0e
    376  SUBLANG_ARABIC_BAHRAIN = 0x0f
    377  SUBLANG_ARABIC_QATAR = 0x10
    378  SUBLANG_AZERI_LATIN = 0x01
    379  SUBLANG_AZERI_CYRILLIC = 0x02
    380  SUBLANG_CHINESE_TRADITIONAL = 0x01
    381  SUBLANG_CHINESE_SIMPLIFIED = 0x02
    382  SUBLANG_CHINESE_HONGKONG = 0x03
    383  SUBLANG_CHINESE_SINGAPORE = 0x04
    384  SUBLANG_CHINESE_MACAU = 0x05
    385  SUBLANG_DUTCH = 0x01
    386  SUBLANG_DUTCH_BELGIAN = 0x02
    387  SUBLANG_ENGLISH_US = 0x01
    388  SUBLANG_ENGLISH_UK = 0x02
    389  SUBLANG_ENGLISH_AUS = 0x03
    390  SUBLANG_ENGLISH_CAN = 0x04
    391  SUBLANG_ENGLISH_NZ = 0x05
    392  SUBLANG_ENGLISH_EIRE = 0x06
    393  SUBLANG_ENGLISH_SOUTH_AFRICA = 0x07
    394  SUBLANG_ENGLISH_JAMAICA = 0x08
    395  SUBLANG_ENGLISH_CARIBBEAN = 0x09
    396  SUBLANG_ENGLISH_BELIZE = 0x0a
    397  SUBLANG_ENGLISH_TRINIDAD = 0x0b
    398  SUBLANG_ENGLISH_ZIMBABWE = 0x0c
    399  SUBLANG_ENGLISH_PHILIPPINES = 0x0d
    400  SUBLANG_FRENCH = 0x01
    401  SUBLANG_FRENCH_BELGIAN = 0x02
    402  SUBLANG_FRENCH_CANADIAN = 0x03
    403  SUBLANG_FRENCH_SWISS = 0x04
    404  SUBLANG_FRENCH_LUXEMBOURG = 0x05
    405  SUBLANG_FRENCH_MONACO = 0x06
    406  SUBLANG_GERMAN = 0x01
    407  SUBLANG_GERMAN_SWISS = 0x02
    408  SUBLANG_GERMAN_AUSTRIAN = 0x03
    409  SUBLANG_GERMAN_LUXEMBOURG = 0x04
    410  SUBLANG_GERMAN_LIECHTENSTEIN = 0x05
    411  SUBLANG_ITALIAN = 0x01
    412  SUBLANG_ITALIAN_SWISS = 0x02
    413  SUBLANG_KASHMIRI_SASIA = 0x02
    414  SUBLANG_KASHMIRI_INDIA = 0x02
    415  SUBLANG_KOREAN = 0x01
    416  SUBLANG_LITHUANIAN = 0x01
    417  SUBLANG_MALAY_MALAYSIA = 0x01
    418  SUBLANG_MALAY_BRUNEI_DARUSSALAM = 0x02
    419  SUBLANG_NEPALI_INDIA = 0x02
    420  SUBLANG_NORWEGIAN_BOKMAL = 0x01
    421  SUBLANG_NORWEGIAN_NYNORSK = 0x02
    422  SUBLANG_PORTUGUESE = 0x02
    423  SUBLANG_PORTUGUESE_BRAZILIAN = 0x01
    424  SUBLANG_SERBIAN_LATIN = 0x02
    425  SUBLANG_SERBIAN_CYRILLIC = 0x03
    426  SUBLANG_SPANISH = 0x01
    427  SUBLANG_SPANISH_MEXICAN = 0x02
    428  SUBLANG_SPANISH_MODERN = 0x03
    429  SUBLANG_SPANISH_GUATEMALA = 0x04
    430  SUBLANG_SPANISH_COSTA_RICA = 0x05
    431  SUBLANG_SPANISH_PANAMA = 0x06
    432  SUBLANG_SPANISH_DOMINICAN_REPUBLIC = 0x07
    433  SUBLANG_SPANISH_VENEZUELA = 0x08
    434  SUBLANG_SPANISH_COLOMBIA = 0x09
    435  SUBLANG_SPANISH_PERU = 0x0a
    436  SUBLANG_SPANISH_ARGENTINA = 0x0b
    437  SUBLANG_SPANISH_ECUADOR = 0x0c
    438  SUBLANG_SPANISH_CHILE = 0x0d
    439  SUBLANG_SPANISH_URUGUAY = 0x0e
    440  SUBLANG_SPANISH_PARAGUAY = 0x0f
    441  SUBLANG_SPANISH_BOLIVIA = 0x10
    442  SUBLANG_SPANISH_EL_SALVADOR = 0x11
    443  SUBLANG_SPANISH_HONDURAS = 0x12
    444  SUBLANG_SPANISH_NICARAGUA = 0x13
    445  SUBLANG_SPANISH_PUERTO_RICO = 0x14
    446  SUBLANG_SWEDISH = 0x01
    447  SUBLANG_SWEDISH_FINLAND = 0x02
    448  SUBLANG_URDU_PAKISTAN = 0x01
    449  SUBLANG_URDU_INDIA = 0x02
    450  SUBLANG_UZBEK_LATIN = 0x01
    451  SUBLANG_UZBEK_CYRILLIC = 0x02
    452  SUBLANG_DUTCH_SURINAM = 0x03
    453  SUBLANG_ROMANIAN = 0x01
    454  SUBLANG_ROMANIAN_MOLDAVIA = 0x02
    455  SUBLANG_RUSSIAN = 0x01
    456  SUBLANG_RUSSIAN_MOLDAVIA = 0x02
    457  SUBLANG_CROATIAN = 0x01
    458  SUBLANG_LITHUANIAN_CLASSIC = 0x02
    459  SUBLANG_GAELIC = 0x01
    460  SUBLANG_GAELIC_SCOTTISH = 0x02
    461  SUBLANG_GAELIC_MANX = 0x03
    462