
同态加密
同态加密相关知识
隐私保护小白
QQ: 894871364
展开
-
Mac M1芯片同态加密库的安装(TFHE问题)
Mac M1芯片同态加密库的安装(TFHE问题原创 2022-12-30 20:14:09 · 1036 阅读 · 6 评论 -
TFHE同态库的Torus32
Torus32 a = Torus32 b + Torus32 c 为什么代码里可以相加呢?会有自动模运算吗?/ /想法://我们可能想用整数(2^32 3232来表示实环面的一个元素x ——加法、减法和整数组合是native操作——modulo 1映射到mod 2^32,这也是native的!这看起来比使用float/double好得多,因为在float/double中modulo 1完全不是自然的。typedef int32_t Torus32;typedef __int32_t原创 2021-08-23 10:18:48 · 542 阅读 · 1 评论 -
TFHE的电路自举代码运行
源码电路自举: TRLWE——> TRGSW(原理还没有深究)cd circuit-bootstrappingcd srcmakespqlios/spqlios-fft-impl.cpp:350:8: error: passing argument 1 to restrict-qualified parameter aliases with argument 2 [-Werror=restrict] sub4(tmp0,tmp0,tmp3); // re2 ^~~~原创 2021-06-02 09:28:23 · 1529 阅读 · 3 评论 -
TFHE库的安装
TFHE库源码默认是直接make make install这样就可以安装 tfhe 到 /usr/local/lib如果想测试,可以mkdir buildcd buildcmake ../src -DENABLE_TESTS=on -DENABLE_FFTW=on -DCMAKE_BUILD_TYPE=debugmake但是需要自己下载安装FFTW3 library: http://www.fftw.org.我这里-DENABLE_FFTW=on没有成功,见问题FFTW,暂时只使原创 2021-04-22 17:15:41 · 1670 阅读 · 6 评论 -
Security Level of HElib
NC1 circuit:Branch program时间复杂度:O O~O转载 2020-08-07 21:45:15 · 275 阅读 · 0 评论 -
同态加密库 HEAAN效率测试(4)
测试sigmoid函数(不同的degree),看看误差wbq@wbq-virtual-machine:~/HEAAN/HEAAN/run$ ./sigmoid !!! START TEST SIGMOID !!!n=16degree=2------------------Start Sigmoidcipher logq before: 1200 logp: 23cipher logq after polunom: 1177 logp: 23Sigmoid time = 15904.8 ms原创 2020-06-23 12:20:27 · 894 阅读 · 2 评论 -
同态加密库 HEAAN效率测试(3)
!!! START TEST POWER OF 2 !!!------------------Start Power of 2Power of 2 time = 29903.3 ms---------------------------------------mpow2: 0 :(0.20162,0.979464)dpow2: 0 :(0.20162,0.979464)epow2: 0 :(1.83199e-08,-1.12564e-09)------------------------原创 2020-06-23 12:11:30 · 471 阅读 · 0 评论 -
SEAL库 测试效率(例6之6_performance解析)
源码链接测试环境:Ubuntu18.04(4G内存)(仅供个人参考)BFV方案测试:> Run performance test (1 ~ 4) or go back (0): 1+--------------------------------------------------------------------------+| BFV Performance Test with Degrees: 4096, 8192, and 16384 |+-原创 2020-06-22 13:18:33 · 1095 阅读 · 1 评论 -
同态加密库 HEAAN效率测试(2)
源码链接HEAAN 和 TestScheme//参数设置s long logq = 1200; ///< Ciphertext Modulus long logp = 30; ///< Real message will be quantized by multiplying 2^40 long logn = 5; ///< log2(The number of slots(32个slot) //---------------原创 2020-06-21 14:41:16 · 471 阅读 · 0 评论 -
同态加密库 HEAAN效率测试(1)
wbq@wbq-virtual-machine:~/HEAAN/HEAAN/run$ ./TestHEAAN Encrypt!!! START TEST ENCRYPT !!!(0.905108,0.77373)------------------Start EncryptEncrypt time = 6786.23 ms------------------------------------Start Decrypt(0.905108,0.77373)Decrypt time = 4原创 2020-06-21 14:35:29 · 1146 阅读 · 1 评论 -
HElib基准测试结果(2)
HElib基准测试结果:2020-06-21T07:06:22+08:00Running ./helib_benchmarkRun on (1 X 2394.51 MHz CPU )CPU Caches: L1 Data 32 KiB (x1) L1 Instruction 32 KiB (x1) L2 Unified 256 KiB (x1) L3 Unified 3072 KiB (x1)Load Average: 2.76, 3.25, 1.59***WARNING***原创 2020-06-21 09:38:21 · 373 阅读 · 0 评论 -
HElib基准测试结果(1)
Benchmarks测试在这里插入代码片 运行环境Ubuntu18.04可能出现的错误scanning dependencies of target helib_benchmark[ 33%] Building CXX object CMakeFiles/helib_benchmark.dir/bench_thinboot.cpp.o[ 66%] Building CXX object CMakeFiles/helib_benchmark.dir/bench_fatboot.cpp.o/ho原创 2020-06-21 09:36:59 · 780 阅读 · 4 评论 -
HElib测试结果
Total Test time (real) = 792.07 sec100% tests passed, 0 tests failed out of 34安装链接
在之前介绍的HElib使用介绍中,当时学的很迷糊,对make ,cmake,makelists等不是很明白,因为之前并不是很了解Linux,自己这两天在B站上学了点相关知识,如何运行Helib中的example_prpgram文件夹下hello_example.cpp呢?之前的博客,包括转发的一定要看(如何测试)…简单讲:makelists可以将很多gcc命令放在一起,然后make编译,生成...原创 2020-05-04 22:13:47 · 2792 阅读 · 8 评论 -
同态加密的简单应用
The Swiss Army Knife of Cryptography例如,假设您拥有一家小型企业,并将您的销售数据库存储在一些云计算提供商那里。(本博客的编辑可以推荐一个……)由于您的数据是保密的,您希望将其加密存储在服务器上。但现在,当你拿着手机,想要知道你去年的平均销售额是多少,邮编是02142?由于您的数据是加密的,因此似乎需要下载整个数据库,对其进行解密,然后执行搜索,这在某种程度上...翻译 2020-04-05 12:12:51 · 3658 阅读 · 0 评论 -
同态加密的计算模型介绍
声明:个人由相关资料整理而来一、同态加密应用可选择的计算模型(持续补充…)Boolean Circuits ○ Plaintext data represented as bits○ Computations expressed as Boolean circuitsModular (Exact) Arithmetic ○ Plaintext data represented ...原创 2020-04-03 21:47:16 · 2205 阅读 · 0 评论 -
同态加密的发展
声明:该文章由个人整理相关资料+理解而来…全同态加密:简单来讲,对密文的操作对应着对原来明文的操作。同态加密 vs.安全多方计算其中,同态加密在计算代价上较大,主要花费在Bootstrapping上,而多方计算主要耗费在通信代价上。发展1978年首次提出。[Gentry09’] Big breakthrough2009-10: Plausibility:[GH’11] A ...原创 2020-04-01 10:56:32 · 2105 阅读 · 1 评论