最近遇到一个 ROM 包,需要获取其中的 APK,因此产生了解包的需求。

首先使用 file 命令查看文件格式:

1
2
$ file unkown.img
unkown.img: data

发现为 data 类型,即未知格式,接下来使用 010Editor 查看,发现文件头有 IMAGEWTY 标志:

阅读全文 »

本文内容来自:https://sysprog21.github.io/lkmpg/ ,使用 Immersive Translate 进行翻译。

简介

The Linux Kernel Module Programming Guide is a free book; you may reproduce and/or modify it under the terms of the Open Software License, version 3.0.
《Linux 内核模块编程指南》是一本免费书籍;您可以根据开放软件许可证 3.0 版的条款复制和/或修改它。

This book is distributed in the hope that it would be useful, but without any warranty, without even the implied warranty of merchantability or fitness for a particular purpose.
分发本书的目的是希望它有用,但没有任何保证,甚至没有对适销性或针对特定用途的适用性的默示保证。

The author encourages wide distribution of this book for personal or commercial use, provided the above copyright notice remains intact and the method adheres to the provisions of the Open Software License. In summary, you may copy and distribute this book free of charge or for a profit. No explicit permission is required from the author for reproduction of this book in any medium, physical or electronic.
作者鼓励将本书广泛分发用于个人或商业用途,前提是上述版权声明保持完整并且方法遵守开放软件许可证的规定。总之,您可以免费或以营利为目的复制和分发本书。以任何物理或电子媒介复制本书无需获得作者的明确许可。

阅读全文 »

代码

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
33
34
35
36
37
38
39
40
// main.cpp
class Base
{
protected:
int n;

public:
int foo(int p)
{
return n + p;
}

virtual int bar(int p){
return n + p;
}
};

struct Point
{
double cx, cy;
};

class Derived : public Base
{
public:
int foo(int p)
{
return n + a + p;
}

protected:
int a, b;
Point a_point;
char c;
};

int main(int argc, char **argv)
{
return sizeof(Derived);
}

msvc

命令格式:

  • 查看单个类的内存布局: cl <FileName> /d1reportSingleClassLayout[ClassName]
  • 查看所有类的内存布局: cl <FileName> /d1reportAllClassLayout
阅读全文 »

本文转自 https://lvwenhan.com/sort/tech-epic 中“软件工程师需要了解的网络知识:从铜线到 HTTP”的一系列文章。

前言

写作目标

本文面向中国互联网界众多的“应用软件工程师”,确切地说,面向 web 后端工程师(Java、PHP),web 前端工程师,移动开发工程师(iOS、Android)。本文将从铜线讲起,一路讲到 HTTP,为大家剖析出一个真实的“网络”。

写作由来

阅读全文 »
0%