UNDERCODE COMMUNITY
2.67K subscribers
1.23K photos
31 videos
2.65K files
79.8K links
πŸ¦‘ Undercode Cyber World!
@UndercodeCommunity


1️⃣ World first platform which Collect & Analyzes every New hacking method.
+ AI Pratice
@Undercode_Testing

2️⃣ Cyber & Tech NEWS:
@Undercode_News

3️⃣ CVE @Daily_CVE

✨ Web & Services:
β†’ Undercode.help
Download Telegram
▁ β–‚ β–„ ο½•π•Ÿπ”»β’Ίπ«Δ†π”¬π““β“” β–„ β–‚ ▁

πŸ¦‘ Part 3 android develop;

1) As can be seen from this file, R is a static final class. The public static final class layout represents the contents of the res / layout folder, and each integer constant of the layout class represents an XML layout file under the folder.

2) For example, public static final int main represents the main.xml file, and 0x7f030000 is an integer value generated by the system's main.xml file. Find the main.xml file based on this value in the Android project. public static final class string represents the res / values ​​/ strings.xml file, and each integer constant member in the string class represents a variable defined in the strings.xml file. For example, public static final int app_name represents the app_name variable defined in strings.xml, and public static final int hello represents the hello variable defined in the sts.xml file.

3) During project development, you can access any resource defined in R through [<package_name>.] R. <resource_type>. <Resource_name>. among them:
package_name is the package path where the resource file is placed, and can be omitted in general.
resource_type is the resource type, such as layout, string, color, drawable, menu, etc.
resource_name refers to the name of the integer constant defined in the class for the resource file.

4) Consider the following example:
setContentView (R.layout.main);

5) In this line of code, the layout file main.xml is found through R.layout.main, and it is set as the view of the current Activity through the setContentView method. To find a component from a view, you need to use the findViewById method to get the component's object by the component ID.

6) For example, to get the TextView component object in main.xml, you need to execute the following code:
TextView textview = (TextView) findViewById (R.id.textView1);
πŸ¦‘ Keep tunning with undercode we have all parts ready to sent later

Written by UndercOde
▁ β–‚ β–„ ο½•π•Ÿπ”»β’Ίπ«Δ†π”¬π““β“” β–„ β–‚ ▁
▁ β–‚ β–„ ο½•π•Ÿπ”»β’Ίπ«Δ†π”¬π““β“” β–„ β–‚ ▁

πŸ¦‘Lets send some gd scripts for beginers
2020 updqated script :You can use setupTermuxArch.bash , to install Arch Linux in Amazon, Android, Chromebook and Windows
instagram.com/UndercOdeTestingCompany

π•€π•Ÿπ•€π•₯π•’π•π•π•šπ•€π•’π•₯π•šπ• π•Ÿ & β„π•¦π•Ÿ :

1) git clone https://github.com/SDRausty/TermuxArch

2) cd TermuxArch

3) setupTermuxArch.bash

4) startarch
THats all!
▁ β–‚ β–„ ο½•π•Ÿπ”»β’Ίπ«Δ†π”¬π““β“” β–„ β–‚ ▁
▁ β–‚ β–„ ο½•π•Ÿπ”»β’Ίπ«Δ†π”¬π““β“” β–„ β–‚ ▁

πŸ¦‘Five Android layouts: FrameLayout, LinearLayout, AbsoluteLayout, RelativeLayout, and TableLayout: Part 1
>The Android SDK defines multiple layouts to facilitate user design of the UI. The various layout methods are subclasses of the ViewGroup class, and the structure is shown in picture after this chat
twitter.com/UndercOdeTC

πŸ¦‘ π•ƒπ”Όπ•‹π•Š π•Šπ•‹π”Έβ„π•‹

1) FrameLayout

> FrameLayout, also known as single frame layout, is the simplest layout among the layout methods provided by Android. It specifies a blank area on the screen and fills a single object in the area. For example pictures, text, buttons, etc.

2) Application developers cannot specify specific fill positions for components filled in FrameLayout. By default, these components will be fixed in the upper left corner of the screen, and components placed later will be placed on the previous component to cover and fill, forming a part. Block or block all.

3) Developers can make appropriate modifications to the component location through the component's android: layout_gravity property.

4) An example FrameLayoutDemo demonstrates the layout effect of FrameLayout. There are 4 TextView components in the layout. The first 3 components are placed in the layout by default. The fourth component is placed in the layout after modifying the gravity property

πŸ¦‘Part of code of the layout file main.xml in the example FrameLayoutDemo is as follows:
Plain Text Copy
<? xml version = "1.0" encoding = "utf-8"?>
<FrameLayout xmlns: android = "http://schemas.android.com/apk/res/android"
android: layout_height = "fill_parent"
android: layout_width = "fill_parent" >

<TextView
android: id = "@ + id / text1"
android: layout_width = "wrap_content"
android: layout_height = "wrap_content"
android: textColor = "# 00ff00"
android: textsize = "1OOdip"
android: text = "@ string / first" />
<TextView
android: id = "@ + id / text2"
android: layout_width = "wrap_content"
android: layout_height = "wrap_content"
android: textColor = "# 00ffff"
android: textsize = "70dip"
android: text = "@ string / second" />
<TextView
android: id = "@ + id / text3"
android: layout_width = "wrap_content"
android: layout_height = "wrap_content"
android: textColor = "# ffOOOO"
.....
...
</ FrameLayout>
among them:
android: layout_width = "wrap_content"
....

πŸ¦‘ LinearLayout

> LinearLayout, also known as linear layout, should be the most commonly used layout in Android view design. This layout allows the components placed in it to be arranged neatly horizontally or vertically. The specific arrangement is specified by the android: orientation property, and the weight of each component in the layout is set by the weight property.

>The strings.xml file code in the example LinearLayoutDemo is as f ollows:
Plain Text Copy
<? xml version = "1.0" encoding = "UTF-8"?>
<resources>
<string name = "app_name" > LinearLayoutDemo </ string>
<string name = "red" > red </ string>
<string name = "yellow" > yellow </ string
...

Written by UndercOde
▁ β–‚ β–„ ο½•π•Ÿπ”»β’Ίπ«Δ†π”¬π““β“” β–„ β–‚ ▁
▁ β–‚ β–„ ο½•π•Ÿπ”»β’Ίπ«Δ†π”¬π““β“” β–„ β–‚ ▁

πŸ¦‘PART 2 Five Android layouts: FrameLayout, LinearLayout, AbsoluteLayout, RelativeLayout, and TableLayout:
twitter.com/UndercOdeTC

πŸ¦‘ π•ƒπ”Όπ•‹π•Š π•Šπ•‹π”Έβ„π•‹


1) The first LinearLayout layout sets the layout to a horizontal linear arrangement via the android: orientation = "horizontal" attribute.

2) The second LinearLayout layout sets the layout to vertical linear arrangement via the android: orientation = "vertical" attribute.

3) Four TextViews are placed in each LinearLayout layout, and the proportion of each component in the layout is set by the android: layout_weight property, that is, the components are the same size.

> layout_weight is used to define the importance of a component in a linear layout. All components have a layout_weight value, which defaults to 0.
> This means how much screen space is needed to display as many views as possible. If the value is greater than 0, the available space is divided. The size of the division depends on the ratio of the current layout_weight value to the layout_weight value of other spaces.

4) For example, if there are two buttons in the horizontal direction, and the layout_weight value of each button is set to 1, then the two buttons divide the width equally; if the first is 1, and the second is 2, then one third of the space Give the first and two-thirds to the second

πŸ¦‘RelativeLayout :

1) RelativeLayout is also called relative layout. As can be seen from the name, this layout is a layout that allows components to be placed relative to the container or to another component in the container.

2) The RelativeLayout layout provides some commonly used layout setting properties to determine the relative position of the component in the view. The following lists the RelativeLayout related properties and their meanings.

RelativeLayout layout common properties
Attributes description
android: layout_above = "@ id / xxx" Place the control on top of the given ID control
android: layout_below = "@ id / xxx" Place the control under the given ID control
android: layout_toLeftOf = "@ id / xxx" Align the right edge of the control to the left edge of the given ID control
android: layout_toRightOf = "@ id / xxx" Align the left edge of the control with the right edge of the given ID control
android: layout_alignBaseline = "@ id / xxx" Align the baseline of the control to the baseline of the given ID
android: layout_alignTop = "@ id / xxx" Align the top edge of the control to the top edge of the given ID control
android: layout_alignBottom = "@ id / xxx" Align the bottom edge of the control to the bottom edge of the given ID control
android: layout_alignLeft = "@ id / xxx" Align the left edge of the control with the left edge of the given ID control
android: layout_alignRight = "@ id / xxx" Align the right edge of the control with the right edge of the given ID control
android: layout_alignParentLeft = "true" Align the left edge of the control to the left edge of the parent control
android: layout_alignParentTop = "true" Align the top edge of the control to the top edge of the parent control
android: layout_alignParentRight = "true" Align the right edge of the control to the right edge of the parent control
android: layout_alignParentBottom = "true" Align the bottom edge of the control with the bottom edge of the parent control
android: layout_centerInParent = "true" Place the control in the center of the parent control
android: layout_centerHorizontal = "true" Center the control in the horizontal direction
android: layout_centerVertical = "true" Center the control in the vertical direction

Written by UndercOde
▁ β–‚ β–„ ο½•π•Ÿπ”»β’Ίπ«Δ†π”¬π““β“” β–„ β–‚ ▁
▁ β–‚ β–„ ο½•π•Ÿπ”»β’Ίπ«Δ†π”¬π““β“” β–„ β–‚ ▁

πŸ¦‘ Android developpements part 4:
instagram.com/UndercOdeTestingCompany

πŸ¦‘ π•ƒπ”Όπ•‹π•Š π•Šπ•‹π”Έβ„π•‹

πŸ¦‘ AbsoluteLayout:

1) AbsoluteLayout is also called absolute layout. Components placed in this layout need to specify their exact coordinate values ​​through the two properties android: layout_x and android: layout_y and display them on the screen.

2) In theory, AbsoluteLayout can be used to complete any layout design, and it has great flexibility, but it is not recommended in actual engineering applications. Because using this layout not only needs to accurately calculate the size of each component, increase the amount of calculation, but also produces different effects when the application runs on mobile phones with different screen sizes.

3) An example AbsoluteLayoutDemo demonstrates the use of AbsoluteLayout layout
> check picture about this chat

πŸ¦‘ The TableLayout layout provides several special properties that can achieve the following special effects.

1) android: shrinkColumns property: This property is used to set shrinkable columns. When the collapsible column is too wide for other columns in the layout to display completely, the collapsible column will stretch vertically, compressing the space it takes up so that the other columns can be fully displayed. android: shrinkColumns = "1" means that the second column is set as a shrinkable column and the number of columns starts from 0.

2) android: stretchColumns property: This property is used to set stretchable columns. Stretchable columns automatically expand to fill all available space. android: stretchColumns = "1" means set the second column as a stretchable column.

3) android: collapseColumns property: This property is used to set hidden columns. android: collapseColumns = "1" means the second column is hidden and not displayed.

Written by UndercOde
▁ β–‚ β–„ ο½•π•Ÿπ”»β’Ίπ«Δ†π”¬π““β“” β–„ β–‚ ▁
▁ β–‚ β–„ ο½•π•Ÿπ”»β’Ίπ«Δ†π”¬π““β“” β–„ β–‚ ▁

πŸ¦‘Adnroid developpements Customize views :
> Here is a brief introduction to the units of size types commonly used in the Android system.



1) Pixel: Abbreviated as px. Represents physical pixels on the screen.

2) Pounds: points, abbreviated as pt. 1pt equals 1/72 of an inch and is often used in the printing industry.

3) Zoom in on pixels: sp. It is mainly used for font display. Android uses sp as the font size unit by default.

4) Density Independent Pixel: Abbreviated as dip or dp. This size uses a 160dp screen as a reference, and then uses this screen to map to the actual screen. There will be corresponding scaling effects on screens with different resolutions to apply to screens with different resolutions. If you use px, 320px occupies the width of HVGA. On WVGA, you can only take up less than half of the screen. It must not be what you want.
Millimeter: mm.

πŸ¦‘ WebView

1) The WebView component is a subclass of AbsoluteLayout and is used to display Web pages. With WebView, you can easily develop your own web browser. Only the basic usage of WebView is introduced here, and it will be further explained in the later study of Web App.

2) Create a project WebViewDemo and add Internet access to it in the AndroidManifest.xml file:
<uses-permission android: name = "android.permission.INTERNET" />

2) Add a WebView component to the layout file main.xml. The content of Main.xml is as follows:
<? xml version = "1.0" encoding = "utf-8"?>
<LinearLayout xmlns: android = "http://schemas.android.com/apk/res/android"
android: layout_width = "fill_parent"
android: layout_height = "fill_parent"
android: orientation = "vertical" >
<WebView
android: id = "@ + id / webView1"
android: layout_width = "match_parent"
android: layout_height = "match_parent" />
</ LinearLayout>
The code of the Activity file WebViewDemoActivity.java in the example WebViewDemo is as follows:
Plain Text Copy
package introduction . android . webView ;
import android . app . Activity ;
import android . os . Bundle ;
Import Android . WebKit . WebView ;
public class WebViewDemoActivity extends Activity {
private WebView webView ;
/ **
* Called when the acctivity is first crested .
* /
@Override
public void onCreate ( Bundle saveInstanceState ) {
super . onCreate ( saveInstanceState );
the setContentView ( R & lt . layout . main );
the webView = ( the WebView ) the findViewById ( R & lt . ID . webView1 );
webView . getSettings (). set JavaScript Enabled ( true );
webView . loadUrl ( "http://www.google.com" );
}
}
Written by UndercOde
▁ β–‚ β–„ ο½•π•Ÿπ”»β’Ίπ«Δ†π”¬π““β“” β–„ β–‚ ▁
▁ β–‚ β–„ ο½•π•Ÿπ”»β’Ίπ«Δ†π”¬π““β“” β–„ β–‚ ▁


πŸ¦‘ 2020 Exploite tool: Kali-Parrot-debian
T.me/UndercOdeTesting
hackerEnv is an automation tool that quickly and easily sweep IPs and scan ports, vulnerabilities and exploit them. Then, it hands you an interactive shell for further testing. Also, it generates HTML and docx reports. It uses other tools such as nmap, nikto, metasploit and hydra.

π•€π•Ÿπ•€π•₯π•’π•π•π•šπ•€π•’π•₯π•šπ• π•Ÿ & β„π•¦π•Ÿ:

apt update; apt upgrade -y
1) git clone https://github.com/abdulr7mann/hackerEnv.git

2) cd /opt/hackerEnv

3) chmod +x hackerEnv

If you want to use it anywhere on the system, create a shortcut using:

4) ln -s /opt/hackerEnv/hackerEnv /usr/local/bin/

πŸ¦‘
Usage:
hackerEnv <flag> <argument>

Example:
hackerEnv -t 10.10.10.10
hackerEnv -t "10.10.10.10\n20.20.20.20"
hackerEnv -t 10.10.10.10 -i eth0
hackerEnv -i eth0 -s 24
hackerEnv -s 24

Flages:
hackerEnv -h, --help Display this help message.
hackerEnv --update Update tool.
hackerEnv Scan the entire network.
hackerEnv -t Pass a specific target's IP.
hackerEnv -t Pass mutipule targets' IPs separated by comma Ex: hackerEnv -t "10.10.10.10\n20.20.20.20"
hackerEnv -i To specify an interface.
hackerEnv -a Pass attacker's IP.
hackerEnv -s To specify subNetwork 24 or 23 etc exclude /
hackerEnv -e, --aggressive Enable aggressive port scan
hackerEnv -oA genetrate report in HTML and DOCX format

Written by UndercOde
▁ β–‚ β–„ ο½•π•Ÿπ”»β’Ίπ«Δ†π”¬π““β“” β–„ β–‚ ▁
▁ β–‚ β–„ ο½•π•Ÿπ”»β’Ίπ«Δ†π”¬π““β“” β–„ β–‚ ▁

πŸ¦‘ Web-Pentesting 2019 script:
>ITWSV is automated penetration testing tool which performs information gathering, auditing and reporting.
twitter.com/UndercOdeTc

π•€π•Ÿπ•€π•₯π•’π•π•π•šπ•€π•’π•₯π•šπ• π•Ÿ & β„π•¦π•Ÿ:

1) git clone https://github.com/penetrate2hack/ITWSV.git

2) cd ITWSV

3) chmod +x start.sh

4) chmod +x update.sh (only if required)

5) ./start.sh

▁ β–‚ β–„ ο½•π•Ÿπ”»β’Ίπ«Δ†π”¬π““β“” β–„ β–‚ ▁
▁ β–‚ β–„ ο½•π•Ÿπ”»β’Ίπ«Δ†π”¬π““β“” β–„ β–‚ ▁

πŸ¦‘ How to solve the winodws error recovery by UndercOde:
> generally we will choose to successfully restart the configuration and restart; in fact, this is a cure for the symptoms and not the root cause, and such problems will still occur repeatedly. Winodws error recovery tips are generally caused by recently installed hardware or software, the following editor will share how to solve windows error recovery.
t.me/UndercOdeTesting

πŸ¦‘ π•ƒπ”Όπ•‹π•Š π•Šπ•‹π”Έβ„π•‹

A) Determine when the error occurs

> If the error occurs while setting up a new computer, or after recovering the computer, select "Open Startup Repair (Recommended)" from the error screen and let Windows repair its files.

> If the error persists after the repair, please perform a system recovery to restore the computer to its original configuration. After the recovery is complete, make sure that you have set up Windows and that you can see all the icons and sidebars on the Windows desktop before shutting down your computer.

2) If this error occurs during normal use, or after you recently added software or hardware, follow these steps to recover your Windows desktop.

B) Remove recently added hardware

> Follow these steps to disconnect recently added hardware and check for errors.

Note: If new internal devices (sound cards, hard disks, etc.) are added to the computer before the error occurs, disconnect these internal hardware before performing the following operations.

1) Turn off the computer and unplug the power cord.

2) Disconnect all unnecessary peripherals (printers, scanners, cameras, zip drives, telephone lines, network cables, and other devices). Only mouse, keyboard, and monitor connections remain.

3) Press and hold the "Power" button on the front of the computer. Release after five seconds.

4)Reinsert the power cord.

5)Start the computer.

6)The display shows the information again.

7) If the error recurs, skip to the next step.

8) If the computer successfully enters the Windows desktop instead of restarting with an error message, reconnect a device and wait for Windows to recognize the device.

9) Connect one device at a time and restart the computer after each connection until you find the device that caused the error. Do not use equipment that is known to cause errors.

C) Repair

> In the error screen, select "Open Startup Repair (Recommended)" and let Windows repair its files. If the error recurs, proceed to the next step and use System Restore.

D) Use System Restore


Follow these steps to restore Windows to an earlier time:

1) Shut down the computer.

2) Disconnect all devices except the mouse, keyboard, and monitor.

3)Start the computer and press the "F8" key repeatedly when the logo screen appears. The Windows startup screen appears.

4)Use the up and down arrow keys to highlight "Safe Mode with Command Prompt" and press the "Enter" key. If the error message appears again, skip to the next step and perform a system recovery.

5) When the login screen appears, select "Administrator" and enter the password (if any).

6) Click "Start" β†’ "All Programs" β†’ "Accessories" in turn, and click "Command Prompt". The Command Prompt window opens.

7) Enter in the command prompt:

cd \ windows \ system32 \ restore

Then press the keyboard "Enter"

8) Enter the command again: rstrui

Then press the "Enter" key

9)The system will open the "System Restore" program

Written by UndercOde
▁ β–‚ β–„ ο½•π•Ÿπ”»β’Ίπ«Δ†π”¬π““β“” β–„ β–‚ ▁
▁ β–‚ β–„ ο½•π•Ÿπ”»β’Ίπ«Δ†π”¬π““β“” β–„ β–‚ ▁

πŸ¦‘How to track down a process or potential virus that is eating my bandwidth on Windows 10 ? From Wiki :


1) Start Task Manger (CTRL+SHIFT+ESC)

2) Select the Performance tab

3) Click the Resource Monitor... button at the bottom of the tab

4) When Resource Monitor starts click the Network tab
Investigate all the Processes with Network Activity to locate the offending process

5) If you are unsure about a particular process you can right click on it and Search Online for more information on that process:

▁ β–‚ β–„ ο½•π•Ÿπ”»β’Ίπ«Δ†π”¬π““β“” β–„ β–‚ ▁
▁ β–‚ β–„ ο½•π•Ÿπ”»β’Ίπ«Δ†π”¬π““β“” β–„ β–‚ ▁

πŸ¦‘What is RefRef Malware ?

1) RefRef is a Perl-based DoS attack tool developed by the Hacktivist group β€˜Anonymous’ that uses a vulnerability in MySQL to perform an SQL injection involving the MySQL BENCHMARK() function.

2) RefRef abuses the BENCHMARK () function which allows for the repeated execution of an expression in order to exhaust a targeted server’s resources.
instagram.com/UndercOdeTestingCompany

3) Unlike LOIC (a network stress testing tool whose use to level DDoS attacks was popularized by Anonymous),

4) RefRef does not require a vast number of machines in order to take down a server due to the nature of its attack vector.

5) If the server’s backend uses MySQL and is vulnerable, few machines are needed to cause a significant outage. A 17-second attack from a single machine on 2011 was able to bring Pastebin offline for 42 minutes.

@UndercOdeOfficial
▁ β–‚ β–„ ο½•π•Ÿπ”»β’Ίπ«Δ†π”¬π““β“” β–„ β–‚ ▁
▁ β–‚ β–„ ο½•π•Ÿπ”»β’Ίπ«Δ†π”¬π““β“” β–„ β–‚ ▁

πŸ¦‘ ADB Miner: A Botnet Surfaces FROM 2018 :
Radware’s Emergency Response Team has been monitoring the emergence of a new botnet
pinterest.com/UndercOdeOfficial

> ADB.miner malware takes advantage of Android-based devices that expose debug capabilities to the Internet. When a remote host exposes its Android Debug Bridge (ADB) control port, any Android emulator on the Internet has full install, start, reboot and root shell access without authentication.

>Part of the malware, xmrig binaries (Monero cryptocurrency miners) are executing on the devices.

πŸ¦‘ Bot User Tools

> Getting root shell access using Android SDK platform tools:
C:\bin\android-platform-tools\platform-tools>adb shell "id"
uid=0(root) gid=0(root)

> All ADB connections start with the CNXN fixed string, matching the pattern intercepted by Radware’s honeypots:
0000000: 43 4e 58 4e 00 00 00 01 00 10 00 00 07 00 00 00 CNXN
0000010: 32 02 00 00 bc b1 a7 b1 68 6f 73 74 3a 3a 00 2.......host
Commands performed against a target device:
{ name: "adb"; service: "adb"; host: "100.115.92.2"; port: "5555"; probe: [ "^CNXN" ]; }

>The Monero wallet address that collects the return on the mining investment is 44XT4KvmobTQfeWa6PCQF5RDosr2MLWm43AsaE3o5iNRXXTfDbYk2VPHTVedTQHZyfXNzMn8YYF2466d3FSDT7gJS8gdHAr

πŸ¦‘Hashes/IOC
91f0ffdec958388adab53b5a473265d7ce86d0a3da4622490c9199baecce31b8 xmrig32
a881b27c388448cf9d77443ea23be4d751b3b565b773e1d97a7dbb0702189812 xmrig64
940b47e9b71ba4968cfefd7ae6c374a319f2439e9b71ee0965e20a0ce00dcd67 droidbot
6b973256325b0f93c45a1ae8a964218b6c86aa3c509453f0325754eb2dcfef0e droidbot.apk

πŸ¦‘ Effective DDoS Protection Essentials

1) Hybrid DDoS Protection - On-premise and cloud DDoS protection for real-time DDoS attack prevention that also addresses high volume attacks and protects from pipe saturation

2) Behavioral-Based Detection - Quickly and accurately identify and block anomalies while allowing legitimate traffic through

3) Real-Time Signature Creation - Promptly protect from unknown threats and zero-day attacks

4) A Cyber-Security Emergency Response Plan - A dedicated emergency team of experts who have experience with Internet of Things security and handling IoT outbreaks

5) Intelligence on Active Threat Actors – high fidelity, correlated and analyzed date for preemptive protection against currently active known attackers.

@UndercOdeOfficial
▁ β–‚ β–„ ο½•π•Ÿπ”»β’Ίπ«Δ†π”¬π““β“” β–„ β–‚ ▁
▁ β–‚ β–„ ο½•π•Ÿπ”»β’Ίπ«Δ†π”¬π““β“” β–„ β–‚ ▁

πŸ¦‘ Assembly debugging skills and simple cracking by UndercOde
This post is suitable for students who are interested in assembly debugging or want to get started cracking.

πŸ¦‘ The following uses arm linux (android) as an example.

1) elf introduction

2) For the next crack we are going to make, the most important information is to know that elf is mainly composed of headers, tables, and segments.

3) Some commonly used tools are objdumpand readelf. Of course, gdb is even more essential.

4) To see the distribution of each segment:

> readelf -S a.out

5) To (hexadecimal) output a segment (output here .rodata):

readelf -x .rodata a.out

6) To disassemble the code snippet ( .text
>objdump -d a.out > a.out.dum

πŸ¦‘ Assembly instruction

1) Because the libraries to be cracked are generally stripped and do not see the source code information, they often deal with assembly instructions.

2) Different architectures have different instructions, such as x86, arm. But basically the same is the assembly principle, that is, registers, PC (program pointer), SP (stack pointer), constant / stack / memory read and write. Only by understanding these basic principles, and then looking at the instructions and understanding the architectural differences, can we be more comfortable.

3) Here I want to hack an arm library, so I know some arm instructions in advance, you can refer to arm infocenter .

πŸ¦‘ gdb

1)objdumpInferring the source code directly from the parsed assembly code is a labor-intensive task. You have to force yourself to work like a machine, and imagine the states of various registers and pointers in your brain. (And often the assembly code is -Ooptimized)

2) Therefore, by gdbβ€œdebugging” the target file in the running state, the value of the register can be printed in real time, the calling sequence of the process can be tracked, and the code principle can be quickly clarified.

3)Because the instructions to be debugged are assembly instructions, they are slightly different from regular source-based debugging.

Here are a few commonly used gdb commands.

> Display disassembly code:

layout asm
Step into the assembly code:

si
Step-by-step assembly code:

ni

> Display register information:

info registers

> Print register value:

p /x $r0

> Print the memory value (assuming r0 holds the memory address)

x $r0

Written by UndercOde
▁ β–‚ β–„ ο½•π•Ÿπ”»β’Ίπ«Δ†π”¬π““β“” β–„ β–‚ ▁