1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32
| from secret import flag import random
def Cyber_key(LEN): Key = [[] for i in range(row)] for x in range(row): for i in range(LEN): Key[x].append(random.randint(0, 2023)) return Key
def Punk_enc(Key, msg): out = [] for l in Key: s = 0 for x, y in zip(l, msg): s += (x * y) % P s %= P out.append(s) return out
if __name__ == '__main__': P = 2048 row = 66 key = Cyber_key(len(flag)) c = Punk_enc(key, flag) print(key) print(c)
''' [[505, 469, 528, 1798, 373, 987, 981, 438, 1438, 1918, 768, 980, 720, 336, 1763, 585, 1582, 1020, 601, 1543, 1374, 1904, 340, 326, 947, 639, 1143, 371, 359, 953, 74, 657, 13, 359, 280, 1903, 687, 371, 114, 1232, 1573, 743], [1310, 205, 491, 137, 1743, 1185, 74, 1797, 867, 755, 967, 454, 800, 568, 625, 492, 1835, 1586, 1462, 619, 760, 1144, 98, 1764, 1356, 991, 1392, 816, 849, 259, 1305, 842, 1250, 1983, 1339, 752, 1170, 1976, 958, 1710, 1216, 1927], [1507, 1699, 1536, 1708, 739, 902, 1169, 1352, 886, 680, 1400, 1011, 132, 1561, 1001, 772, 1809, 208, 1161, 1691, 2015, 1099, 166, 1571, 551, 847, 663, 749, 1634, 1487, 960, 1675, 1017, 109, 63, 1714, 1540, 1515, 1382, 1569, 851, 985], [451, 1919, 680, 76, 707, 1283, 933, 658, 945, 1801, 352, 673, 1072, 48, 1994, 1923, 1685, 1684, 1374, 28, 1774, 1769, 1388, 1541, 604, 107, 1290, 787, 1622, 711, 323, 1846, 317, 1519, 1426, 123, 2015, 861, 544, 1401, 1869, 1833], [862, 1316, 393, 1190, 2012, 687, 78, 61, 1391, 1238, 1282, 866, 1385, 1200, 292, 1702, 1599, 712, 1108, 653, 1711, 745, 100, 275, 322, 1671, 1723, 895, 661, 1726, 497, 342, 1010, 47, 1204, 1911, 1734, 1567, 1892, 954, 386, 1996], [1333, 1928, 191, 1502, 1106, 579, 779, 512, 313, 308, 1277, 1547, 1814, 1434, 1867, 670, 543, 404, 1570, 179, 555, 1896, 289, 492, 1874, 1190, 1885, 748, 1375, 401, 1685, 618, 1614, 288, 2017, 571, 670, 873, 98, 563, 180, 749], [262, 1072, 1188, 864, 960, 1069, 1931, 870, 573, 44, 38, 1525, 41, 1197, 1618, 857, 187, 804, 1828, 1525, 96, 204, 1565, 419, 1397, 1487, 1902, 1150, 650, 1562, 151, 564, 1836, 826, 95, 158, 495, 1357, 2005, 819, 783, 880], [636, 985, 809, 1165, 1478, 998, 408, 1897, 988, 421, 743, 1210, 1128, 1901, 943, 512, 1587, 1784, 911, 857, 434, 367, 1345, 104, 143, 357, 426, 1169, 1876, 1111, 1355, 371, 219, 1056, 432, 780, 1798, 151, 210, 1293, 807, 620], [29, 440, 1323, 1960, 1791, 1084, 777, 1314, 709, 1014, 1721, 108, 3, 961, 1253, 245, 862, 1899, 1519, 563, 347, 870, 820, 1787, 1323, 1113, 150, 1108, 1547, 1438, 845, 788, 1221, 1680, 795, 923, 1308, 1114, 153, 1985, 573, 132], [1979, 1831, 1374, 601, 1736, 1778, 1390, 138, 1295, 1582, 1777, 362, 647, 753, 627, 142, 1732, 994, 1911, 227, 1069, 1943, 1206, 1266, 1605, 827, 1153, 1375, 486, 1222, 1938, 794, 909, 629, 1232, 756, 935, 1374, 1148, 1312, 584, 901], [631, 136, 1835, 686, 1779, 1298, 1471, 1009, 107, 906, 4, 201, 859, 1808, 1743, 1286, 305, 266, 1374, 992, 531, 389, 1482, 362, 873, 533, 341, 1357, 85, 424, 207, 995, 275, 857, 1239, 770, 1355, 516, 178, 1560, 228, 1843], [1863, 1423, 786, 209, 1565, 1735, 1662, 1571, 749, 326, 1258, 1099, 1780, 1240, 865, 810, 7, 301, 1926, 692, 67, 978, 1172, 641, 839, 505, 1106, 423, 827, 1838, 388, 1749, 483, 880, 454, 773, 1961, 1153, 858, 963, 92, 829], [2009, 66, 520, 1027, 1804, 882, 42, 1826, 1732, 1093, 78, 1826, 1948, 734, 1486, 1285, 28, 1092, 174, 292, 1412, 24, 1454, 1015, 1560, 1154, 1168, 704, 1224, 1422, 784, 1353, 799, 1591, 613, 1318, 1623, 1151, 968, 297, 953, 1178], [1889, 727, 1189, 160, 1198, 1338, 970, 168, 1737, 1356, 1525, 590, 1773, 1397, 105, 1368, 401, 1569, 287, 1757, 801, 1818, 309, 1416, 1721, 1403, 1086, 583, 1203, 172, 1030, 647, 1497, 1222, 1581, 432, 1199, 1279, 5, 570, 556, 1936], [1514, 1162, 130, 1023, 538, 1772, 1525, 1709, 774, 1904, 1489, 837, 742, 797, 446, 1240, 847, 624, 1629, 2011, 867, 1097, 1814, 231, 381, 46, 363, 1560, 786, 1706, 800, 112, 748, 745, 407, 1290, 1093, 1268, 1536, 129, 1632, 1200], [698, 1238, 1100, 591, 1166, 1320, 620, 1044, 984, 744, 453, 1927, 1019, 1488, 1586, 1428, 412, 42, 776, 548, 2006, 409, 1767, 506, 1153, 1398, 391, 1597, 1794, 1203, 1034, 180, 433, 989, 1308, 1342, 1041, 1461, 782, 1284, 225, 492], [342, 15, 324, 551, 329, 1427, 186, 932, 774, 275, 311, 1562, 1557, 455, 329, 66, 0, 856, 792, 849, 878, 1362, 304, 1004, 1093, 1768, 793, 366, 965, 932, 1548, 759, 990, 1033, 720, 1344, 1438, 481, 1546, 985, 51, 1915], [1737, 1934, 1414, 131, 1328, 919, 569, 1731, 1771, 43, 1622, 322, 2000, 1918, 384, 995, 1282, 1380, 449, 1566, 1981, 286, 981, 704, 640, 551, 5, 1019, 598, 1079, 1150, 209, 464, 1555, 2, 1988, 1305, 127, 152, 701, 553, 1030], [817, 176, 737, 657, 1507, 514, 1453, 1656, 1229, 315, 368, 332, 460, 933, 1553, 1409, 1137, 1910, 209, 1906, 1487, 571, 996, 1489, 2011, 245, 1510, 115, 1155, 349, 67, 620, 759, 699, 1034, 1030, 984, 70, 1585, 1580, 121, 2], [526, 1875, 273, 1552, 641, 532, 613, 1092, 72, 1518, 600, 1380, 1088, 1371, 143, 1764, 1695, 1747, 1693, 2006, 614, 305, 1784, 1474, 1761, 730, 1968, 1803, 520, 917, 1976, 838, 525, 1769, 2005, 1625, 128, 728, 1729, 440, 288, 1530], [17, 1580, 403, 1813, 1514, 1603, 559, 1845, 408, 1942, 966, 1393, 544, 272, 1400, 1940, 412, 1968, 837, 945, 503, 409, 154, 264, 379, 218, 1847, 966, 1103, 125, 1935, 1381, 1552, 126, 1379, 397, 735, 1165, 162, 1696, 44, 238], [1401, 75, 99, 633, 922, 1093, 831, 1422, 1489, 46, 728, 1191, 292, 473, 640, 423, 766, 1991, 1561, 1897, 583, 385, 409, 1814, 1684, 879, 1414, 160, 1870, 577, 1394, 1088, 1248, 1425, 405, 1726, 77, 726, 1070, 642, 935, 1105], [1156, 765, 913, 323, 888, 727, 1826, 744, 54, 1009, 1790, 185, 1498, 1599, 1069, 62, 59, 32, 1280, 274, 728, 1831, 1879, 175, 708, 1466, 589, 263, 707, 1542, 1790, 1816, 1854, 992, 1402, 1354, 1501, 1200, 1653, 1067, 1756, 573], [645, 378, 356, 1474, 837, 1664, 45, 259, 289, 231, 1640, 244, 1864, 1022, 741, 1741, 1594, 1353, 991, 2002, 1969, 1522, 1852, 1031, 1296, 347, 1005, 1506, 760, 630, 462, 1302, 454, 466, 163, 488, 1239, 1554, 1482, 1918, 1394, 1244], [199, 1336, 969, 526, 2009, 801, 1762, 1185, 645, 1577, 1303, 707, 1731, 1212, 341, 121, 1984, 1108, 1794, 1078, 404, 248, 36, 42, 1757, 1051, 1485, 1542, 442, 666, 1596, 335, 1527, 1707, 1035, 1924, 386, 1566, 1509, 998, 977, 328], [1802, 1664, 1315, 607, 95, 477, 1534, 834, 1199, 1330, 738, 1339, 1313, 294, 1860, 1693, 2014, 1663, 549, 298, 1076, 618, 59, 749, 995, 1369, 558, 1703, 656, 1745, 1813, 1428, 612, 12, 624, 111, 850, 456, 596, 817, 383, 630], [221, 207, 1253, 1353, 992, 1732, 1038, 325, 1696, 662, 771, 1437, 1616, 396, 1568, 476, 232, 220, 1945, 1500, 1865, 1477, 1540, 1608, 823, 255, 342, 1912, 733, 1450, 1600, 1838, 69, 32, 1392, 1647, 820, 492, 1479, 1172, 993, 1412], [1207, 930, 69, 289, 1770, 162, 1442, 1071, 1598, 1900, 1409, 433, 1248, 1668, 314, 1201, 425, 334, 1373, 789, 975, 177, 1526, 49, 29, 174, 885, 264, 437, 287, 167, 1332, 1870, 1330, 1789, 372, 140, 1697, 1018, 642, 1894, 1829], [1710, 1301, 511, 1837, 116, 1749, 1727, 1479, 950, 951, 1104, 866, 838, 1248, 911, 988, 1275, 637, 1636, 250, 1603, 1783, 1821, 149, 388, 1474, 1366, 1788, 1038, 4, 201, 1003, 1246, 1914, 233, 1625, 1041, 1979, 649, 665, 1381, 1522], [855, 35, 317, 97, 400, 800, 107, 91, 1444, 1063, 552, 1363, 600, 767, 1313, 1117, 769, 541, 1466, 848, 935, 1918, 555, 1218, 1750, 1953, 1103, 1969, 1289, 634, 1310, 182, 1071, 1959, 544, 462, 377, 1696, 1597, 1936, 1285, 367], [598, 1990, 750, 584, 227, 1392, 1493, 748, 1671, 224, 1360, 1094, 1994, 1792, 1140, 779, 1939, 361, 289, 1235, 213, 517, 1485, 1390, 804, 132, 920, 536, 1235, 837, 298, 1139, 961, 1521, 431, 76, 2019, 884, 1991, 522, 342, 1609], [114, 1608, 1127, 722, 97, 140, 218, 617, 475, 1680, 214, 1595, 1373, 2021, 1031, 1243, 1526, 1562, 134, 684, 1178, 951, 1470, 1293, 1562, 744, 424, 336, 932, 897, 42, 1968, 1144, 195, 686, 46, 1032, 230, 1285, 132, 1514, 169], [1870, 622, 830, 283, 713, 1893, 270, 573, 732, 1233, 246, 1408, 1890, 119, 1529, 396, 1522, 486, 1371, 211, 1196, 671, 200, 1390, 1790, 547, 567, 1315, 1782, 1661, 756, 6, 1864, 626, 1318, 694, 1632, 1177, 1128, 1327, 405, 1283], [1714, 277, 1154, 369, 1472, 417, 541, 1244, 638, 1332, 512, 492, 1272, 929, 551, 34, 954, 362, 75, 1009, 725, 1481, 952, 1297, 1612, 289, 1684, 817, 112, 1731, 837, 1820, 1457, 1411, 1836, 454, 1984, 178, 46, 552, 282, 720], [1602, 921, 919, 637, 25, 1052, 1246, 831, 1332, 1664, 260, 1387, 1660, 19, 839, 844, 1934, 1606, 970, 539, 992, 1401, 1804, 1879, 297, 1325, 1671, 128, 667, 1169, 808, 1238, 366, 1409, 1369, 1997, 1775, 1586, 746, 278, 1134, 464], [1441, 1529, 415, 494, 1784, 1042, 799, 1701, 985, 404, 734, 1123, 1206, 1493, 1446, 562, 161, 1737, 1943, 753, 1782, 1341, 794, 333, 891, 973, 1656, 1995, 228, 523, 882, 228, 1010, 212, 262, 1948, 1573, 104, 767, 1607, 1333, 650], [918, 1741, 1195, 247, 2001, 1290, 1640, 1655, 1209, 1171, 1686, 1565, 1347, 1245, 350, 1234, 1271, 724, 213, 1994, 974, 677, 415, 1728, 1465, 222, 425, 616, 1649, 1114, 285, 753, 593, 1795, 552, 192, 247, 1286, 1995, 304, 402, 240], [1870, 843, 803, 905, 1256, 1668, 1850, 592, 1745, 1551, 957, 1095, 1492, 1413, 1604, 1944, 1424, 543, 169, 1811, 240, 996, 524, 556, 1189, 746, 1166, 157, 303, 965, 1848, 472, 1559, 419, 932, 2022, 966, 943, 1507, 1126, 1179, 1316], [1984, 296, 1135, 779, 530, 1212, 1122, 113, 805, 108, 990, 897, 1372, 774, 940, 633, 999, 1113, 873, 1933, 233, 236, 1006, 1767, 1575, 736, 1530, 843, 1373, 526, 1863, 2022, 189, 291, 1746, 1804, 769, 1355, 1745, 1355, 368, 666], [1714, 1278, 333, 2002, 379, 1788, 75, 174, 1369, 376, 1881, 553, 928, 1269, 1930, 622, 223, 278, 528, 1001, 918, 1018, 903, 1133, 420, 1389, 1796, 488, 410, 481, 1499, 228, 811, 1539, 91, 499, 1715, 249, 809, 1040, 1862, 1284], [560, 156, 1508, 1302, 194, 1062, 49, 1000, 1670, 1094, 1565, 1982, 1848, 204, 1846, 1565, 186, 1701, 1233, 855, 555, 938, 1489, 945, 1205, 1036, 1093, 47, 416, 1832, 173, 801, 684, 10, 1729, 1931, 27, 461, 1619, 1468, 1069, 1455], [270, 476, 948, 1474, 1209, 1968, 1193, 1683, 223, 1220, 730, 1122, 825, 1479, 922, 1684, 1526, 1532, 474, 1444, 1509, 1176, 1069, 1505, 1024, 1845, 1114, 762, 428, 893, 2012, 182, 1288, 851, 780, 228, 1393, 1834, 314, 402, 349, 189], [1677, 1049, 606, 1404, 1606, 164, 251, 1134, 893, 834, 680, 1260, 1428, 1743, 1658, 298, 705, 1450, 1064, 207, 787, 1094, 545, 559, 131, 1110, 1402, 1671, 545, 1885, 241, 525, 1333, 268, 710, 1602, 925, 1713, 1390, 458, 292, 1982], [1928, 173, 1894, 177, 1485, 2019, 1602, 1975, 1394, 813, 695, 998, 451, 859, 1913, 1307, 1200, 1900, 193, 1288, 509, 1568, 1664, 698, 1737, 1310, 1582, 634, 630, 1773, 315, 1225, 955, 195, 364, 1952, 1514, 107, 1103, 851, 194, 782], [264, 1210, 1424, 774, 1867, 33, 1584, 76, 1170, 1217, 1404, 218, 419, 1478, 1780, 600, 480, 1559, 1687, 418, 963, 164, 1276, 1606, 1443, 1141, 461, 586, 378, 1949, 0, 224, 552, 1828, 904, 804, 1040, 938, 821, 2006, 109, 304], [2005, 266, 213, 970, 1085, 1140, 1224, 1869, 554, 1495, 1256, 1662, 1671, 283, 281, 1432, 1107, 1460, 1535, 640, 755, 1295, 1764, 1638, 1929, 1592, 724, 1120, 1132, 728, 914, 930, 25, 1540, 689, 1661, 1814, 1974, 1594, 1634, 1954, 1322], [1672, 888, 1165, 368, 1940, 1662, 525, 1544, 1080, 1406, 637, 415, 159, 634, 309, 533, 608, 1102, 1054, 1297, 1460, 471, 1199, 613, 334, 1351, 1244, 333, 290, 395, 829, 1531, 565, 1405, 418, 1490, 279, 1690, 1435, 460, 729, 139], [49, 660, 1653, 4, 1984, 169, 1900, 437, 1182, 1834, 855, 335, 1494, 313, 1077, 776, 61, 1220, 593, 1938, 350, 1641, 295, 147, 335, 1894, 86, 639, 1958, 1730, 2021, 221, 1307, 1658, 103, 1697, 1900, 176, 1400, 1286, 271, 744], [856, 299, 1704, 1169, 1947, 426, 2020, 518, 218, 437, 731, 705, 33, 455, 1382, 270, 1512, 1120, 1425, 1225, 1360, 1071, 1092, 896, 1296, 1062, 1264, 396, 855, 1537, 1879, 173, 1567, 1548, 228, 897, 1534, 323, 744, 1564, 950, 20], [1309, 958, 2023, 811, 114, 1500, 77, 1031, 1204, 1811, 1178, 877, 1304, 308, 1898, 1763, 890, 1009, 631, 849, 1906, 376, 1214, 426, 171, 1096, 1157, 1704, 1060, 1332, 1811, 800, 712, 835, 169, 1598, 1948, 1384, 1143, 1209, 1431, 574], [1324, 725, 652, 99, 1910, 522, 871, 1609, 756, 1763, 1230, 1931, 487, 624, 1036, 1506, 114, 575, 800, 1054, 1027, 1309, 1506, 417, 1517, 270, 1610, 614, 219, 1512, 882, 1457, 1798, 1262, 655, 1271, 1066, 827, 1767, 1754, 1054, 345], [221, 1642, 258, 1504, 1569, 67, 57, 938, 1773, 218, 1635, 1514, 1038, 884, 1686, 508, 1050, 1104, 1121, 666, 887, 280, 1566, 384, 1328, 1336, 1906, 1477, 1969, 760, 447, 1887, 480, 92, 1959, 1917, 1132, 717, 741, 1876, 579, 132], [596, 286, 1471, 1206, 1778, 1982, 835, 566, 1347, 1842, 200, 675, 1659, 278, 1166, 172, 1985, 316, 724, 419, 1210, 800, 1637, 337, 218, 2020, 1207, 1992, 1339, 1096, 331, 836, 154, 854, 1242, 1069, 1290, 1428, 1024, 217, 350, 281], [1451, 1601, 1392, 472, 1165, 1190, 280, 653, 953, 350, 1309, 1981, 574, 1513, 1184, 2023, 1947, 591, 1745, 1305, 234, 1673, 2015, 1522, 187, 1921, 32, 1185, 29, 1394, 1297, 1880, 1381, 348, 622, 729, 1584, 813, 937, 808, 131, 1789], [1022, 1877, 831, 1567, 408, 1465, 1073, 1942, 1418, 268, 1267, 1806, 998, 6, 1366, 584, 92, 1137, 529, 659, 1085, 758, 2004, 384, 1099, 160, 998, 1311, 1914, 1002, 308, 1399, 1325, 2023, 1357, 23, 740, 223, 1865, 1, 2021, 1144], [101, 1226, 644, 128, 299, 631, 139, 55, 771, 409, 121, 609, 966, 823, 901, 556, 1396, 981, 365, 339, 1373, 154, 147, 1279, 1886, 1194, 1587, 311, 115, 1909, 1164, 1589, 1699, 1838, 1809, 1191, 536, 1686, 476, 390, 322, 1541], [874, 903, 917, 1557, 831, 1959, 1773, 930, 1513, 12, 1283, 156, 606, 10, 824, 1903, 1583, 752, 391, 73, 1733, 296, 1958, 1206, 989, 1151, 1123, 103, 1910, 1386, 940, 1522, 1883, 2009, 305, 1258, 134, 353, 49, 91, 1220, 124], [387, 1884, 286, 1704, 1453, 676, 543, 1445, 1130, 1136, 2010, 1428, 1146, 1190, 1355, 435, 1676, 1209, 139, 1614, 1758, 726, 1139, 1050, 372, 1877, 706, 1634, 881, 1067, 576, 1354, 260, 848, 821, 1390, 1754, 1117, 1449, 1683, 1949, 454], [441, 1929, 845, 2013, 618, 1070, 808, 836, 966, 401, 1437, 1209, 387, 1093, 1339, 1748, 190, 1947, 954, 1232, 1210, 1525, 724, 55, 980, 1943, 1107, 1053, 1791, 1514, 306, 8, 1344, 264, 140, 838, 802, 424, 1540, 1747, 891, 1020], [1048, 203, 1424, 469, 1786, 591, 1997, 1687, 539, 253, 278, 717, 1347, 1804, 279, 806, 912, 1837, 1566, 1135, 486, 1648, 1341, 1008, 637, 1699, 1396, 336, 1689, 330, 1033, 128, 1161, 1647, 669, 1788, 1711, 1980, 1882, 259, 138, 1467], [861, 228, 1485, 1832, 1658, 262, 1207, 719, 1982, 1108, 236, 92, 1894, 669, 437, 1976, 344, 2009, 1697, 874, 1486, 190, 1252, 1018, 561, 375, 1908, 45, 1934, 608, 1615, 658, 1234, 457, 409, 26, 1388, 1959, 1126, 656, 193, 507], [1324, 508, 1862, 1516, 693, 1819, 1583, 1472, 671, 1295, 1526, 1094, 518, 1189, 1583, 1345, 1054, 1788, 661, 960, 975, 927, 423, 380, 791, 1282, 1239, 756, 199, 1686, 745, 754, 1417, 1347, 1581, 626, 1772, 1465, 1985, 968, 1728, 1641], [1280, 392, 1695, 882, 1225, 1766, 683, 633, 1065, 1605, 1086, 500, 23, 1836, 583, 589, 1075, 810, 652, 1105, 511, 1756, 20, 756, 988, 1175, 134, 630, 320, 343, 213, 1885, 550, 146, 1121, 1650, 1101, 895, 294, 1710, 1995, 1022], [340, 1498, 491, 1964, 993, 1479, 1752, 263, 1156, 493, 1812, 1892, 595, 1919, 897, 1520, 1503, 1102, 809, 1374, 1693, 538, 1310, 372, 543, 245, 1912, 1193, 356, 14, 6, 1336, 821, 1111, 1678, 163, 298, 410, 740, 1039, 258, 1256], [542, 1181, 1683, 1782, 1355, 1598, 853, 1372, 1016, 1416, 466, 502, 528, 1428, 1742, 1748, 963, 1967, 844, 596, 996, 37, 201, 525, 147, 1576, 741, 532, 583, 192, 535, 762, 521, 198, 1204, 1460, 1848, 494, 1704, 43, 1437, 1946], [1308, 47, 975, 1577, 762, 1978, 0, 562, 1373, 1, 1046, 229, 542, 695, 582, 1455, 360, 245, 1343, 458, 1365, 1859, 1722, 1967, 19, 447, 1545, 1190, 1278, 675, 1992, 1769, 1435, 358, 10, 796, 155, 1000, 1615, 927, 1789, 823]] [644, 915, 892, 1015, 1876, 1611, 925, 334, 36, 41, 629, 1829, 1939, 1681, 224, 646, 502, 1284, 663, 1592, 1890, 1097, 1499, 1927, 30, 1202, 2012, 985, 1393, 106, 1220, 1687, 1712, 1077, 1957, 1418, 555, 514, 1552, 968, 1645, 1850, 919, 587, 463, 963, 1503, 1251, 3, 1251, 1711, 114, 190, 1891, 740, 1358, 1698, 295, 1313, 1812, 1067, 455, 1622, 541, 155, 1083] '''
|