求教关于Hopper Disassembler反汇编ios deb程序后保存运行的问题

IOS越狱后安装一越狱插件,在安装目录中提取出主程序,通过7Z解压工具可以看到结构如下/:

图片说明

这个文件包含2个文件,我可以理解为一个为32位ARM程序一个64位吗?
通过Hopper Disassembler加载选择了ARM64 ,然后修改了我想修改的地方并保存.

图片说明

保存下载的文件比包含2个文件的原始文件小,和单独解压出来的ARM64部分大小一致,我想应该是只保存了64位的部分吧.
用保存下来的ARM64文件改名为原始文件一致,替换到手机原来APP位置并赋予可执行权限,打开APP会闪退,看了方法不可行~

这里想问问论坛大神,我修改完成后如何才能替换会原来的位置让APP可正常运行?缺少基础知识,从未涉及IOS 开发以及反汇编这块,临时用到一个插件收费的需要破解他,查阅了一些资料完成了反汇编修改却被结构卡住了!!!!!

Csdn user default icon
上传中...
上传图片
插入图片
抄袭、复制答案,以达到刷声望分或其他目的的行为,在CSDN问答是严格禁止的,一经发现立刻封号。是时候展现真正的技术了!
其他相关推荐
A Bug's Life

Description Background Professor Hopper is researching the sexual behavior of a rare species of bugs. He assumes that they feature two different genders and that they only interact with bugs of the opposite gender. In his experiment, individual bugs and their interactions were easy to identify, because numbers were printed on their backs. Problem Given a list of bug interactions, decide whether the experiment supports his assumption of two genders with no homosexual bugs or if it contains some bug interactions that falsify it. Input The first line of the input contains the number of scenarios. Each scenario starts with one line giving the number of bugs (at least one, and up to 2000) and the number of interactions (up to 1000000) separated by a single space. In the following lines, each interaction is given in the form of two distinct bug numbers separated by a single space. Bugs are numbered consecutively starting from one. Output The output for every scenario is a line containing "Scenario #i:", where i is the number of the scenario starting at 1, followed by one line saying either "No suspicious bugs found!" if the experiment is consistent with his assumption about the bugs' sexual behavior, or "Suspicious bugs found!" if Professor Hopper's assumption is definitely wrong. Sample Input 2 3 3 1 2 2 3 1 3 4 2 1 2 3 4 Sample Output Scenario #1: Suspicious bugs found! Scenario #2: No suspicious bugs found!

为什么我的程序的for循环只执行了一次 然后就不会接着执行下面的程序了 (程序里只有一个for)

![图片说明](https://img-ask.csdn.net/upload/201907/23/1563896459_241991.png)![图片说明](https://img-ask.csdn.net/upload/201907/23/1563896469_501211.png) #include <iostream> #include <string> #include<iostream> #include<cmath> #include<fstream> #include<algorithm> using namespace std; int main(){ ofstream mycout("temp.txt"); int ii,sa,sb,sc,sd,j,se,k,l; long long cs; cout<<"kāi fā zhě:Command_Gojira QQ:1045508196 bilibili:86718355"<<endl; string a[]={"acacia_button","acacia_door","acacia_fence_gate","acacia_pressure_plate","acacia_stairs","acacia_trapdoor","activator_rail","air","anvil","bamboo","bamboo_sapling","barrier","beacon","bed","bedrock","beetroot","birch_button","birch_door","birch_fence_gate","birch_pressure_plate","birch_stairs","birch_trapdoor","black_glazed_terracotta","blue_glazed_terracotta","blue_ice","bone_block","bookshelf","brewing_stand","brick_block","brick_stairs","brown_glazed_terracotta","brown_mushroom","brown_mushroom_block","bubble_column","cactus","cake","carpet","carrots","carved_pumpkin","cauldron","chain_command_block","chemistry_table","chest","chorus_flower","chorus_plant","clay","coal_block","coal_ore","cobblestone","cobblestone_wall","cocoa","command_block","concrete","concretepowder","conduit","coral","coral_block","coral_fan","coral_fan_dead","coral_fan_hang","coral_fan_hang2","coral_fan_hang3","crafting_table","cyan_glazed_terracotta","dark_oak_button","dark_oak_door","dark_oak_fence_gate","dark_oak_pressure_plate","dark_oak_stairs","dark_oak_trapdoor","dark_prismarine_stairs","daylight_detector","daylight_detector_inverted","deadbush","detector_rail","diamond_block","diamond_ore","dirt","dispenser","double_plant","double_stone_slab","double_stone_slab2","double_wooden_slab","dragon_egg","dried_kelp_block","dropper","element_0","element_1","element_2","element_3","element_4","element_5","element_6","element_7","element_8","element_9","element_10","element_11","element_12","element_13","element_14","element_15","element_16","element_17","element_18","element_19","element_20","element_21","element_22","element_23","element_24","element_25","element_26","element_27","element_28","element_29","element_30","element_31","element_32","element_33","element_34","element_35","element_36","element_37","element_38","element_39","element_40","element_41","element_42","element_43","element_44","element_45","element_46","element_47","element_48","element_49","element_50","element_51","element_52","element_53","element_54","element_55","element_56","element_57","element_58","element_59","element_60","element_61","element_62","element_63","element_64","element_65","element_66","element_67","element_68","element_69","element_70","element_71","element_72","element_73","element_74","element_75","element_76","element_77","element_78","element_79","element_80","element_81","element_82","element_83","element_84","element_85","element_86","element_87","element_88","element_89","element_90","element_91","element_92","element_93","element_94","element_95","element_96","element_97","element_98","element_99","element_100","element_101","element_102","element_103","element_104","element_105","element_106","element_107","element_108","element_109","element_110","element_111","element_112","element_113","element_114","element_115","element_116","element_117","element_118","farmland","fence","fence_gate","fire","flower_pot","flowing_lava","flowing_water","frame","furnace","glass","glass_pane","glowstone","gold_block","gold_ore","golden_rail","grass","grass_path","gravel","gray_glazed_terracotta","green_glazed_terracotta","hardened_clay","hay_block","heavy_weighted_pressure_plate","hopper","ice","iron_bars","iron_block","iron_door","iron_ore","iron_trapdoor","jukebox","jungle_button","jungle_door","jungle_fence_gate","jungle_pressure_plate","jungle_stairs","jungle_trapdoor","kelp","ladder","lapis_block","lapis_ore","lava","leaves","leaves2","lever","light_blue_glazed_terracotta","light_weighted_pressure_plate","lime_glazed_terracotta","lit_furnace","lit_pumpkin","lit_redstone_lamp","lit_redstone_ore","magenta_glazed_terracotta","magma","melon_block","melon_stem","mob_spawner","monster_egg","mossy_cobblestone","mycelium","nether_brick","nether_brick_fence","nether_brick_stairs","nether_wart","nether_wart_block","netherrack","noteblock","oak_stairs","observer","obsidian","packed_ice","pink_glazed_terracotta","piston","pistonarmcollision","planks","podzol","portal","portal","powered_comparator","powered_pepeater","prismarine","prismarine_bricks_stairs","prismarine_stairs","pumpkin","pumpkin_stem","purple_glazed_terracotta","purpur_block","purpur_stairs","rail","red_flower","red_glazed_terracotta","red_mushroom","red_mushroom_block","red_nether_brick","red_sandstone","red_sandstone_stairs","redstone_block","redstone_lamp","redstone_ore","redstone_torch","redstone_wire","reeds","repeating_command_block","sand","sandstone","sandstone_stairs","sapling","scaffolding","sea_pickle","seagrass","sealantern","shulker_box","silver_glazed_terracotta","skull","slime","snow","snow","soul_sand","sponge","spruce_button","spruce_door","spruce_fence_gate","spruce_pressure_plate","spruce_pressure_stairs","spruce_trapdoor","stained_glass","stained_glass_pane","stained_hardened_clay","standing_banner","standing_sign","sticky_piston","stone","stone_brick_stairs","stone_button","stone_pressure_plate","stone_slab","stone_slab2","stone_stairs","stonebrick","stonecutter","stripped_acacia_log","stripped_birch_log","stripped_dark_oak_log","stripped_jungle_log","stripped_oak_log","stripped_spruce_log","structure_block","tallgrass","tnt","torch","trapdoor","trapped_chest","tripwire","tripwire_hook","turtle_egg","undyed_shulker_box","unlit_redstone_torch","unpowered_comparator","unpowered_repeater","vine","wall_banner","wall_sign","water","waterlily","web","wheat","white_glazed_terracotta","wooden_button","wooden_door","wooden_pressure_plate","wooden_slab","wool","yellow_flower","yellow_glazed_terracotta"}; string b[]={"execute @e ~ ~ ~ detect ~ ~ ~ ","`"," ","#"," ","kill @s"}; //在{}里输入命令 detect后面的方块ID用`表示 特殊值用#表示 不要输入斜杆 不要输入中文 格式:"execute 选择器 x1 y1 z1 detect x2 y2 z2 ","`"," ","#"," ","命令" sa=sizeof(a)/sizeof(a[0]); sb=sizeof(b)/sizeof(b[0]); string c[]={"air","lava","water"};//输入你b不想被检测的方块 sc=sizeof(c)/sizeof(c[0]); ii=0; j=0; for(ii=0;ii<=sc;ii++){ while(j<=sa){ if (c[ii]==a[j]) a[j]="0"; j++; } j=0; cout<<ii<<endl; } string d[10000]; string e[]={"0","1","2","3,","4","5","6","7","8","9","10","11","12"}; se=sizeof(e)/sizeof(e[0]); cs=(long long) sa*se*sb; cout<<cs<<endl; j=0; ii=0; k=0; l=0; while(ii<=se){ while(j<=sa){ if (a[j]=="0") j++; while(k<=sb){ if(b[k]=="`") d[k]=a[j]; if(b[k]=="#") d[k]=e[ii]; if(b[k]!="#"&&b[k]!="`") d[k]=b[k]; mycout<<d[k]; l++; cout<<l<<"/"<<cs<<endl; k++; } mycout<<endl; k=0; j++; } j=0; ii++; } mycout.close(); return 0; } ``` ```

一只虫子的一生

Description Background Professor Hopper is researching the sexual behavior of a rare species of bugs. He assumes that they feature two different genders and that they only interact with bugs of the opposite gender. In his experiment, individual bugs and their interactions were easy to identify, because numbers were printed on their backs. Problem Given a list of bug interactions, decide whether the experiment supports his assumption of two genders with no homosexual bugs or if it contains some bug interactions that falsify it. Input The first line of the input contains the number of scenarios. Each scenario starts with one line giving the number of bugs (at least one, and up to 2000) and the number of interactions (up to 1000000) separated by a single space. In the following lines, each interaction is given in the form of two distinct bug numbers separated by a single space. Bugs are numbered consecutively starting from one. Output The output for every scenario is a line containing "Scenario #i:", where i is the number of the scenario starting at 1, followed by one line saying either "No suspicious bugs found!" if the experiment is consistent with his assumption about the bugs' sexual behavior, or "Suspicious bugs found!" if Professor Hopper's assumption is definitely wrong. Sample Input 2 3 3 1 2 2 3 1 3 4 2 1 2 3 4 Sample Output Scenario #1: Suspicious bugs found! Scenario #2: No suspicious bugs found!

二分搜索方面的一个复习试题,感觉比较困难,怎么利用 C 语言的办法和方式解决

Problem Description Background Professor Hopper is researching the sexual behavior of a rare species of bugs. He assumes that they feature two different genders and that they only interact with bugs of the opposite gender. In his experiment, individual bugs and their interactions were easy to identify, because numbers were printed on their backs. Problem Given a list of bug interactions, decide whether the experiment supports his assumption of two genders with no homosexual bugs or if it contains some bug interactions that falsify it. Input The first line of the input contains the number of scenarios. Each scenario starts with one line giving the number of bugs (at least one, and up to 2000) and the number of interactions (up to 1000000) separated by a single space. In the following lines, each interaction is given in the form of two distinct bug numbers separated by a single space. Bugs are numbered consecutively starting from one. Output The output for every scenario is a line containing "Scenario #i:", where i is the number of the scenario starting at 1, followed by one line saying either "No suspicious bugs found!" if the experiment is consistent with his assumption about the bugs' sexual behavior, or "Suspicious bugs found!" if Professor Hopper's assumption is definitely wrong. Sample Input 2 3 3 1 2 2 3 1 3 4 2 1 2 3 4 Sample Output Scenario #1: Suspicious bugs found! Scenario #2: No suspicious bugs found!

关于bug的搜索的问题,用C语言的实现方式

Problem Description Background Professor Hopper is researching the sexual behavior of a rare species of bugs. He assumes that they feature two different genders and that they only interact with bugs of the opposite gender. In his experiment, individual bugs and their interactions were easy to identify, because numbers were printed on their backs. Problem Given a list of bug interactions, decide whether the experiment supports his assumption of two genders with no homosexual bugs or if it contains some bug interactions that falsify it. Input The first line of the input contains the number of scenarios. Each scenario starts with one line giving the number of bugs (at least one, and up to 2000) and the number of interactions (up to 1000000) separated by a single space. In the following lines, each interaction is given in the form of two distinct bug numbers separated by a single space. Bugs are numbered consecutively starting from one. Output The output for every scenario is a line containing "Scenario #i:", where i is the number of the scenario starting at 1, followed by one line saying either "No suspicious bugs found!" if the experiment is consistent with his assumption about the bugs' sexual behavior, or "Suspicious bugs found!" if Professor Hopper's assumption is definitely wrong. Sample Input 2 3 3 1 2 2 3 1 3 4 2 1 2 3 4 Sample Output Scenario #1: Suspicious bugs found! Scenario #2: No suspicious bugs found!

A Bug's Life 的问题

Problem Description Background Professor Hopper is researching the sexual behavior of a rare species of bugs. He assumes that they feature two different genders and that they only interact with bugs of the opposite gender. In his experiment, individual bugs and their interactions were easy to identify, because numbers were printed on their backs. Problem Given a list of bug interactions, decide whether the experiment supports his assumption of two genders with no homosexual bugs or if it contains some bug interactions that falsify it. Input The first line of the input contains the number of scenarios. Each scenario starts with one line giving the number of bugs (at least one, and up to 2000) and the number of interactions (up to 1000000) separated by a single space. In the following lines, each interaction is given in the form of two distinct bug numbers separated by a single space. Bugs are numbered consecutively starting from one. Output The output for every scenario is a line containing "Scenario #i:", where i is the number of the scenario starting at 1, followed by one line saying either "No suspicious bugs found!" if the experiment is consistent with his assumption about the bugs' sexual behavior, or "Suspicious bugs found!" if Professor Hopper's assumption is definitely wrong. Sample Input 2 3 3 1 2 2 3 1 3 4 2 1 2 3 4 Sample Output Scenario #1: Suspicious bugs found! Scenario #2: No suspicious bugs found!

C语言 A Bug's Life

Problem Description Background Professor Hopper is researching the sexual behavior of a rare species of bugs. He assumes that they feature two different genders and that they only interact with bugs of the opposite gender. In his experiment, individual bugs and their interactions were easy to identify, because numbers were printed on their backs. Problem Given a list of bug interactions, decide whether the experiment supports his assumption of two genders with no homosexual bugs or if it contains some bug interactions that falsify it. Input The first line of the input contains the number of scenarios. Each scenario starts with one line giving the number of bugs (at least one, and up to 2000) and the number of interactions (up to 1000000) separated by a single space. In the following lines, each interaction is given in the form of two distinct bug numbers separated by a single space. Bugs are numbered consecutively starting from one. Output The output for every scenario is a line containing "Scenario #i:", where i is the number of the scenario starting at 1, followed by one line saying either "No suspicious bugs found!" if the experiment is consistent with his assumption about the bugs' sexual behavior, or "Suspicious bugs found!" if Professor Hopper's assumption is definitely wrong. Sample Input 2 3 3 1 2 2 3 1 3 4 2 1 2 3 4 Sample Output Scenario #1: Suspicious bugs found! Scenario #2: No suspicious bugs found!

A Bug's Life,C编程题

Problem Description Background Professor Hopper is researching the sexual behavior of a rare species of bugs. He assumes that they feature two different genders and that they only interact with bugs of the opposite gender. In his experiment, individual bugs and their interactions were easy to identify, because numbers were printed on their backs. Problem Given a list of bug interactions, decide whether the experiment supports his assumption of two genders with no homosexual bugs or if it contains some bug interactions that falsify it. Input The first line of the input contains the number of scenarios. Each scenario starts with one line giving the number of bugs (at least one, and up to 2000) and the number of interactions (up to 1000000) separated by a single space. In the following lines, each interaction is given in the form of two distinct bug numbers separated by a single space. Bugs are numbered consecutively starting from one. Output The output for every scenario is a line containing "Scenario #i:", where i is the number of the scenario starting at 1, followed by one line saying either "No suspicious bugs found!" if the experiment is consistent with his assumption about the bugs' sexual behavior, or "Suspicious bugs found!" if Professor Hopper's assumption is definitely wrong. Sample Input 2 3 3 1 2 2 3 1 3 4 2 1 2 3 4 Sample Output Scenario #1: Suspicious bugs found! Scenario #2: No suspicious bugs found!

短语查询扩展的最快方法

<div class="post-text" itemprop="text"> <p>I'm using a list of synonyms to direct a process of query expansion. The format looks like this:</p> <pre><code>fu=foo ba=bar etc=etcetera werd=word </code></pre> <p>I'm using a straightforward binary search algorithm to run each of the user input words against this list. The problem is, when it comes to using <em>phrases</em>. </p> <pre><code> quick brown fox=alphabet out of this world=space why hello there=hello </code></pre> <p>Typical input: <code>why hello there, where can I get an out of this world hopper?</code></p> <p>And the desired output is: <code>hello, where can I get an space hopper?</code></p> <p>I don't want to run each word pair or tripple through the search too, and I want to avoid a linear search of the thesaurus list against the input as this is inefficient (although the list should be quite small so this an option). </p> <p>Therefore I'm looking for ways to run binary search on phrases, or to construct the thesaurus in such a way as to compensate for phrases. </p> <p>I'm using PHP for this. Any suggestions most welcome.</p> </div>

Gorename不起作用:“重命名失败:gorename:找不到包含的软件包”

<div class="post-text" itemprop="text"> <p>When trying to change the symbols, VSCode throws the following error:</p> <p><strong>"Rename failed: gorename: can't find package containing /home/hume/projects/go/main.go"</strong></p> <blockquote> <p>vscode 1.22.2 x64</p> <p>go version go1.10.1 linux/amd64</p> <p>go env GOPATH /home/hume/projects/go</p> </blockquote> <p>My <code>settings.json</code> is as follows:</p> <pre><code>{ "go.toolsGopath": "/home/hume/gotools" , "go.autocompleteUnimportedPackages": true , "go.inferGopath": true , "go.formatTool": "gofmt" , "go.vetFlags": [ "/src" ] } </code></pre> <p>Thanks.</p> </div>

Lingo

You are going to participate in the television show 'lingo'. You are very confident that you will make the finals of the show. This is not only because you are well prepared, but also because you managed to find a way to use your pda unnoticed during the contest, and you have already written a program to help you with the bonuswords. In the finals of the show, you first solve as many lingo words as possible within the allowed time. This determines how many balls you may take afterwards. The more balls you may take, the higher your probability is of winning the finals. But it is not easy to see what this probability is. Write a program to help you with this. ![](http://acm.zju.edu.cn/onlinejudge/showImage.do?name=0000%2F2916%2FLingo_1.jpg) For those who don't know the game of lingo, here follows a description of the last part of the finals, where you take the balls. You are given a square grid. Some squares in this grid are covered and the other squares contain numbers. A hopper in front of you contains numbered balls; there is exactly one ball for each numbered grid square. You take a ball at random (without replacement) from this hopper for each lingo word you solved in the first part of the finals. When you take a ball, the corresponding square in the grid becomes covered. You win the finals if an entire row, column or diagonal consist of only covered squares. Input On the first line an integer t (1 <= t <= 100): the number of test cases. Then for each test case: One line with the integers n (1 <= n <= 8) and k (0 <= k), where n is the size of the lingo grid and k is the number of words you solved in the first part of the finals. n lines, with on each line exactly n characters. Each character will be either '*' or '.', representing a covered square and a numbered square respectively. There will be at least k numbered squares on the board, and there is no row, column or diagonal covered yet. Output For each test case: One line with the percentage of getting lingo with either an absolute or a relative error of at most 10-6. Sample Input 1 5 7 .*.*. .**.. .*.*. *.... **..* Sample Output 82.703962704

无法在线程中创建handler

错误: logUser("An error happend while creating graph:"+ getErrorMessage()); `getErrorMessage()`无法在线程中创建handler,线程没有调用`Looper.prepare()`,而logUser 是用来显示toast信息的函数。 void prepareGraph() { logUser("loading graph (" + Helper.VERSION + "|" + Helper.VERSION_FILE + ") ... "); new MyAsyncTask<Void, Void, Path>() { protected Path saveDoInBackground(Void... v) throws Exception { GraphHopper tmpHopp = new GraphHopper().forAndroid(); tmpHopp.contractionHierarchies(true); tmpHopp.load(mapsFolder + currentArea); logUser("found graph with " + tmpHopp.getGraph().nodes() + " nodes"); hopper = tmpHopp; return null; } protected void onPostExecute(Path o) { if (hasError()) { logUser("An error happend while creating graph:" + getErrorMessage()); } else { logUser("Finished loading graph. Touch to route."); calcPath(52.534185, 13.348732, 52.53857, 13.41259); } finishPrepare(); } }.execute(); }

如何在MySQL php echo循环中创建if语句?

<div class="post-text" itemprop="text"> <p>I'm building an Airport Taxi Booking System and as part of the table that holds the bookings there are the following columns along with other data which I don't need for this example:</p> <pre><code>Customer Name Outbound_date Outbound_time Outbound_pickup Outbound_destination Inbound_date Inbound_time Inbound_pickup Inbound_destination </code></pre> <p>I am building a page that displays all bookings between two dates inputted by the user, the results are then displayed in a HTML table with the following headings : Name, pickup, destination, date, time. </p> <p>What I would like to do is build an if statement that asks if the inbound or outbound date is nearest and then displaying the journey information. I need all this in a loop for the HTML table. </p> <p>I'm roughly assuming the statement would ask if <code>outbound_date</code> &lt; <code>inbound_date</code> <code>echo outbound_destination</code> etc... Else <code>echo inbound_destination</code> etc...</p> <p>This is the code I have which selects data and displays it, however it currently selects both the outbound_pickup/destination/date and the inbound versions. What I want to do is just show either the outbound/inbound columns, depending which falls between the two dates submitted by the user.</p> <pre><code>&lt;!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd"&gt; &lt;html lang="en"&gt; &lt;head&gt; &lt;meta http-equiv="Content-Type" content="text/html; charset=utf-8"&gt; &lt;title&gt;Computerised Booking System | Airport Hopper&lt;/title&gt; &lt;meta name="generator" content="TextMate http://macromates.com/"&gt; &lt;meta name="author" content="Daniel Green"&gt; &lt;link rel="stylesheet" type="text/css" href="../css/main.css"/&gt; &lt;!-- Date: 2012-02-27 --&gt; &lt;/head&gt; &lt;body&gt; &lt;div id="wrapper"&gt; &lt;?php include('../includes/header.php');?&gt; &lt;?php include('../includes/cbs_sidebar.php');?&gt; &lt;div class="main-container"&gt; &lt;h2&gt;Airport Hopper CBS&lt;/h2&gt;&lt;hr/&gt; &lt;?php $db_host = 'ahopperintranet.db.8239985.hostedresource.com'; $db_user = 'ahopperintranet'; $db_pwd = '******'; $database = 'ahopperintranet'; $table = 'bookings'; if (!mysql_connect($db_host, $db_user, $db_pwd)) die("Can't connect to database"); if (!mysql_select_db($database)) die("Can't select database"); // sending query $result = mysql_query("SELECT booking_ref, customer_name, outbound_destination, outbound_date, outbound_time, inbound_date FROM {$table} ORDER BY GREATEST(outbound_date, inbound_date)"); if (!$result) { die("Query to show fields from table failed"); } $fields_num = mysql_num_fields($result); echo "&lt;table border='1'&gt;&lt;tr&gt;"; ?&gt; &lt;tr&gt; &lt;td&gt;Booking Ref&lt;/td&gt; &lt;td&gt;Customer Name&lt;/td&gt; &lt;td&gt;Pickup&lt;/td&gt; &lt;td&gt;Destination&lt;/td&gt; &lt;td&gt;Date&lt;/td&gt; &lt;td&gt;Time&lt;/td&gt; &lt;/tr&gt; &lt;?php // printing table rows while($row = mysql_fetch_row($result)) { echo "&lt;tr&gt;"; // $row is array... foreach( .. ) puts every element // of $row to $cell variable foreach($row as $cell) echo "&lt;td&gt;$cell&lt;/td&gt;"; echo "&lt;/tr&gt; "; } mysql_free_result($result); ?&gt; &lt;div class="clear"&gt;&lt;/div&gt; &lt;/body&gt; </code></pre> </div>

Docker-无法从外部访问docker端口

<div class="post-text" itemprop="text"> <p>So i created a new EC2 Instance and installed docker on it.</p> <p>I deployed code from ( <a href="https://github.com/commonsearch/cosr-front/blob/master/INSTALL.md" rel="nofollow">https://github.com/commonsearch/cosr-front/blob/master/INSTALL.md</a> ) and followed install instructions.</p> <p>Install was successfull and i started the server:</p> <pre><code>[ec2-user@ip-172-30-0-127 cosr-front]$ make docker_devserver docker run -e DOCKER_HOST --rm -v "/home/ec2-user/cosr-front:/go/src/github.com/commonsearch/cosr-front:rw" -w /go/src/github.com/commonsearch/cosr-front -p 9700:9700 -i -t commonsearch/local-front make devserver mkdir -p build go build -o build/cosr-front.bin ./server GODEBUG=gctrace=1 COSR_DEBUG=1 ./build/cosr-front.bin 2016/05/28 16:32:38 Using Docker host IP: 172.17.0.1 2016/05/28 16:32:38 Server listening on 127.0.0.1:9700 - You should open http://127.0.0.1:9700 in your browser! </code></pre> <p>Well, now when i want to access it from outside, i cant! Not even curl the local server.</p> <p>When i run <code>docker ps</code> it gives me correct port forwarding: </p> <pre><code>[ec2-user@ip-172-30-0-127 ~]$ docker ps CONTAINER ID IMAGE COMMAND CREATED STATUS PORTS NAMES 1a9f77e1eeb1 commonsearch/local-front "make devserver" 4 minutes ago Up 4 minutes 0.0.0.0:9700-&gt;9700/tcp stoic_hopper 9ff00fe3e70d commonsearch/local-elasticsearch-devindex "/docker-entrypoint.s" 4 minutes ago Up 4 minutes 0.0.0.0:39200-&gt;9200/tcp, 0.0.0.0:39300-&gt;9300/tcp kickass_wilson </code></pre> <p>These are my docker images:</p> <pre><code>REPOSITORY TAG IMAGE ID CREATED VIRTUAL SIZE &lt;none&gt; &lt;none&gt; 3e205118cd3f 17 minutes ago 853.3 MB &lt;none&gt; &lt;none&gt; 1d233da1fa59 2 hours ago 955.7 MB debian jessie ce58426c830c 4 days ago 125.1 MB commonsearch/local-front latest 30de7ab48d43 7 weeks ago 1.024 GB commonsearch/local-elasticsearch-devindex latest b1156ada5a24 11 weeks ago 383.2 MB commonsearch/local-elasticsearch latest 808e72f49b4a 3 months ago 355.2 MB </code></pre> <p>I have tryed disabling ipv6 and all kind of nonsense google offered me, but without success.</p> <p>Any ideas ?</p> <p>EDIT:</p> <p>Also, if i enter the docker container for frontend( using docker exec ), then I CAN PING AND CULR the frontend.</p> <p>But i cant from the outside( nor ssh, not from my home pc using browser ).</p> <p>Also my docker version:</p> <pre><code>Client: Version: 1.9.1 API version: 1.21 Go version: go1.4.2 Git commit: a34a1d5/1.9.1 Built: OS/Arch: linux/amd64 Server: Version: 1.9.1 API version: 1.21 Go version: go1.4.2 Git commit: a34a1d5/1.9.1 Built: OS/Arch: linux/amd64 </code></pre> </div>

在中国程序员是青春饭吗?

今年,我也32了 ,为了不给大家误导,咨询了猎头、圈内好友,以及年过35岁的几位老程序员……舍了老脸去揭人家伤疤……希望能给大家以帮助,记得帮我点赞哦。 目录: 你以为的人生 一次又一次的伤害 猎头界的真相 如何应对互联网行业的「中年危机」 一、你以为的人生 刚入行时,拿着傲人的工资,想着好好干,以为我们的人生是这样的: 等真到了那一天,你会发现,你的人生很可能是这样的: ...

程序员请照顾好自己,周末病魔差点一套带走我。

程序员在一个周末的时间,得了重病,差点当场去世,还好及时挽救回来了。

我以为我学懂了数据结构,直到看了这个导图才发现,我错了

数据结构与算法思维导图

String s = new String(" a ") 到底产生几个对象?

老生常谈的一个梗,到2020了还在争论,你们一天天的,哎哎哎,我不是针对你一个,我是说在座的各位都是人才! 上图红色的这3个箭头,对于通过new产生一个字符串(”宜春”)时,会先去常量池中查找是否已经有了”宜春”对象,如果没有则在常量池中创建一个此字符串对象,然后堆中再创建一个常量池中此”宜春”对象的拷贝对象。 也就是说准确答案是产生了一个或两个对象,如果常量池中原来没有 ”宜春” ,就是两个。...

技术大佬:我去,你写的 switch 语句也太老土了吧

昨天早上通过远程的方式 review 了两名新来同事的代码,大部分代码都写得很漂亮,严谨的同时注释也很到位,这令我非常满意。但当我看到他们当中有一个人写的 switch 语句时,还是忍不住破口大骂:“我擦,小王,你丫写的 switch 语句也太老土了吧!” 来看看小王写的代码吧,看完不要骂我装逼啊。 private static String createPlayer(PlayerTypes p...

Linux面试题(2020最新版)

文章目录Linux 概述什么是LinuxUnix和Linux有什么区别?什么是 Linux 内核?Linux的基本组件是什么?Linux 的体系结构BASH和DOS之间的基本区别是什么?Linux 开机启动过程?Linux系统缺省的运行级别?Linux 使用的进程间通信方式?Linux 有哪些系统日志文件?Linux系统安装多个桌面环境有帮助吗?什么是交换空间?什么是root帐户什么是LILO?什...

将一个接口响应时间从2s优化到 200ms以内的一个案例

一、背景 在开发联调阶段发现一个接口的响应时间特别长,经常超时,囧… 本文讲讲是如何定位到性能瓶颈以及修改的思路,将该接口从 2 s 左右优化到 200ms 以内 。 二、步骤 2.1 定位 定位性能瓶颈有两个思路,一个是通过工具去监控,一个是通过经验去猜想。 2.1.1 工具监控 就工具而言,推荐使用 arthas ,用到的是 trace 命令 具体安装步骤很简单,大家自行研究。 我的使用步骤是...

学历低,无法胜任工作,大佬告诉你应该怎么做

微信上收到一位读者小涛的留言,大致的意思是自己只有高中学历,经过培训后找到了一份工作,但很难胜任,考虑要不要辞职找一份他能力可以胜任的实习工作。下面是他留言的一部分内容: 二哥,我是 2016 年高中毕业的,考上了大学但没去成,主要是因为当时家里经济条件不太允许。 打工了三年后想学一门技术,就去培训了。培训的学校比较垃圾,现在非常后悔没去正规一点的机构培训。 去年 11 月份来北京找到了一份工...

JVM内存结构和Java内存模型别再傻傻分不清了

讲一讲什么是Java内存模型 Java内存模型虽说是一个老生常谈的问题 ,也是大厂面试中绕不过的,甚至初级面试也会问到。但是真正要理解起来,还是相当困难,主要这个东西看不见,摸不着。 这是一个比较开放的题目,面试官主要想考察的是对Java内存模型的了解到了什么程度了,然后根据回答进行进一步的提问 下面,我们就这个问题的回答列一下我们的思路 具体的思路如下: 说一说Java内存模型的缘由 简略辨析...

和黑客斗争的 6 天!

互联网公司工作,很难避免不和黑客们打交道,我呆过的两家互联网公司,几乎每月每天每分钟都有黑客在公司网站上扫描。有的是寻找 Sql 注入的缺口,有的是寻找线上服务器可能存在的漏洞,大部分都...

Google 与微软的浏览器之争

浏览器再现“神仙打架”。整理 | 屠敏头图 | CSDN 下载自东方 IC出品 | CSDN(ID:CSDNnews)从 IE 到 Chrome,再从 Chrome 到 Edge,微软与...

讲一个程序员如何副业月赚三万的真实故事

loonggg读完需要3分钟速读仅需 1 分钟大家好,我是你们的校长。我之前讲过,这年头,只要肯动脑,肯行动,程序员凭借自己的技术,赚钱的方式还是有很多种的。仅仅靠在公司出卖自己的劳动时...

上班一个月,后悔当初着急入职的选择了

最近有个老铁,告诉我说,上班一个月,后悔当初着急入职现在公司了。他之前在美图做手机研发,今年美图那边今年也有一波组织优化调整,他是其中一个,在协商离职后,当时捉急找工作上班,因为有房贷供着,不能没有收入来源。所以匆忙选了一家公司,实际上是一个大型外包公司,主要派遣给其他手机厂商做外包项目。**当时承诺待遇还不错,所以就立马入职去上班了。但是后面入职后,发现薪酬待遇这块并不是HR所说那样,那个HR自...

女程序员,为什么比男程序员少???

昨天看到一档综艺节目,讨论了两个话题:(1)中国学生的数学成绩,平均下来看,会比国外好?为什么?(2)男生的数学成绩,平均下来看,会比女生好?为什么?同时,我又联想到了一个技术圈经常讨...

搜狗输入法也在挑战国人的智商!

故事总是一个接着一个到来...上周写完《鲁大师已经彻底沦为一款垃圾流氓软件!》这篇文章之后,鲁大师的市场工作人员就找到了我,希望把这篇文章删除掉。经过一番沟通我先把这篇文章从公号中删除了...

85后蒋凡:28岁实现财务自由、34岁成为阿里万亿电商帝国双掌门,他的人生底层逻辑是什么?...

蒋凡是何许人也? 2017年12月27日,在入职4年时间里,蒋凡开挂般坐上了淘宝总裁位置。 为此,时任阿里CEO张勇在任命书中力赞: 蒋凡加入阿里,始终保持创业者的冲劲,有敏锐的...

总结了 150 余个神奇网站,你不来瞅瞅吗?

原博客再更新,可能就没了,之后将持续更新本篇博客。

副业收入是我做程序媛的3倍,工作外的B面人生是怎样的?

提到“程序员”,多数人脑海里首先想到的大约是:为人木讷、薪水超高、工作枯燥…… 然而,当离开工作岗位,撕去层层标签,脱下“程序员”这身外套,有的人生动又有趣,马上展现出了完全不同的A/B面人生! 不论是简单的爱好,还是正经的副业,他们都干得同样出色。偶尔,还能和程序员的特质结合,产生奇妙的“化学反应”。 @Charlotte:平日素颜示人,周末美妆博主 大家都以为程序媛也个个不修边幅,但我们也许...

MySQL数据库面试题(2020最新版)

文章目录数据库基础知识为什么要使用数据库什么是SQL?什么是MySQL?数据库三大范式是什么mysql有关权限的表都有哪几个MySQL的binlog有有几种录入格式?分别有什么区别?数据类型mysql有哪些数据类型引擎MySQL存储引擎MyISAM与InnoDB区别MyISAM索引与InnoDB索引的区别?InnoDB引擎的4大特性存储引擎选择索引什么是索引?索引有哪些优缺点?索引使用场景(重点)...

如果你是老板,你会不会踢了这样的员工?

有个好朋友ZS,是技术总监,昨天问我:“有一个老下属,跟了我很多年,做事勤勤恳恳,主动性也很好。但随着公司的发展,他的进步速度,跟不上团队的步伐了,有点...

我入职阿里后,才知道原来简历这么写

私下里,有不少读者问我:“二哥,如何才能写出一份专业的技术简历呢?我总感觉自己写的简历太烂了,所以投了无数份,都石沉大海了。”说实话,我自己好多年没有写过简历了,但我认识的一个同行,他在阿里,给我说了一些他当年写简历的方法论,我感觉太牛逼了,实在是忍不住,就分享了出来,希望能够帮助到你。 01、简历的本质 作为简历的撰写者,你必须要搞清楚一点,简历的本质是什么,它就是为了来销售你的价值主张的。往深...

离职半年了,老东家又发 offer,回不回?

有小伙伴问松哥这个问题,他在上海某公司,在离职了几个月后,前公司的领导联系到他,希望他能够返聘回去,他很纠结要不要回去? 俗话说好马不吃回头草,但是这个小伙伴既然感到纠结了,我觉得至少说明了两个问题:1.曾经的公司还不错;2.现在的日子也不是很如意。否则应该就不会纠结了。 老实说,松哥之前也有过类似的经历,今天就来和小伙伴们聊聊回头草到底吃不吃。 首先一个基本观点,就是离职了也没必要和老东家弄的苦...

男生更看重女生的身材脸蛋,还是思想?

往往,我们看不进去大段大段的逻辑。深刻的哲理,往往短而精悍,一阵见血。问:产品经理挺漂亮的,有点心动,但不知道合不合得来。男生更看重女生的身材脸蛋,还是...

什么时候跳槽,为什么离职,你想好了么?

都是出来打工的,多为自己着想

程序员为什么千万不要瞎努力?

本文作者用对比非常鲜明的两个开发团队的故事,讲解了敏捷开发之道 —— 如果你的团队缺乏统一标准的环境,那么即使勤劳努力,不仅会极其耗时而且成果甚微,使用...

为什么程序员做外包会被瞧不起?

二哥,有个事想询问下您的意见,您觉得应届生值得去外包吗?公司虽然挺大的,中xx,但待遇感觉挺低,马上要报到,挺纠结的。

当HR压你价,说你只值7K,你该怎么回答?

当HR压你价,说你只值7K时,你可以流畅地回答,记住,是流畅,不能犹豫。 礼貌地说:“7K是吗?了解了。嗯~其实我对贵司的面试官印象很好。只不过,现在我的手头上已经有一份11K的offer。来面试,主要也是自己对贵司挺有兴趣的,所以过来看看……”(未完) 这段话主要是陪HR互诈的同时,从公司兴趣,公司职员印象上,都给予对方正面的肯定,既能提升HR的好感度,又能让谈判气氛融洽,为后面的发挥留足空间。...

面试:第十六章:Java中级开发(16k)

HashMap底层实现原理,红黑树,B+树,B树的结构原理 Spring的AOP和IOC是什么?它们常见的使用场景有哪些?Spring事务,事务的属性,传播行为,数据库隔离级别 Spring和SpringMVC,MyBatis以及SpringBoot的注解分别有哪些?SpringMVC的工作原理,SpringBoot框架的优点,MyBatis框架的优点 SpringCould组件有哪些,他们...

面试阿里p7,被按在地上摩擦,鬼知道我经历了什么?

面试阿里p7被问到的问题(当时我只知道第一个):@Conditional是做什么的?@Conditional多个条件是什么逻辑关系?条件判断在什么时候执...

终于懂了TCP和UDP协议区别

终于懂了TCP和UDP协议区别

无代码时代来临,程序员如何保住饭碗?

编程语言层出不穷,从最初的机器语言到如今2500种以上的高级语言,程序员们大呼“学到头秃”。程序员一边面临编程语言不断推陈出新,一边面临由于许多代码已存在,程序员编写新应用程序时存在重复“搬砖”的现象。 无代码/低代码编程应运而生。无代码/低代码是一种创建应用的方法,它可以让开发者使用最少的编码知识来快速开发应用程序。开发者通过图形界面中,可视化建模来组装和配置应用程序。这样一来,开发者直...

面试了一个 31 岁程序员,让我有所触动,30岁以上的程序员该何去何从?

最近面试了一个31岁8年经验的程序猿,让我有点感慨,大龄程序猿该何去何从。

大三实习生,字节跳动面经分享,已拿Offer

说实话,自己的算法,我一个不会,太难了吧

程序员垃圾简历长什么样?

已经连续五年参加大厂校招、社招的技术面试工作,简历看的不下于万份 这篇文章会用实例告诉你,什么是差的程序员简历! 疫情快要结束了,各个公司也都开始春招了,作为即将红遍大江南北的新晋UP主,那当然要为小伙伴们做点事(手动狗头)。 就在公众号里公开征简历,义务帮大家看,并一一点评。《启舰:春招在即,义务帮大家看看简历吧》 一石激起千层浪,三天收到两百多封简历。 花光了两个星期的所有空闲时...

《经典算法案例》01-08:如何使用质数设计扫雷(Minesweeper)游戏

我们都玩过Windows操作系统中的经典游戏扫雷(Minesweeper),如果把质数当作一颗雷,那么,表格中红色的数字哪些是雷(质数)?您能找出多少个呢?文中用列表的方式罗列了10000以内的自然数、质数(素数),6的倍数等,方便大家观察质数的分布规律及特性,以便对算法求解有指导意义。另外,判断质数是初学算法,理解算法重要性的一个非常好的案例。

立即提问
相关内容推荐