crt

CRT的来历

◇◆丶佛笑我妖孽 提交于 2019-11-27 02:24:57
之前由于要研究一下VC编译选项对于最终编译出来的模块尺寸的影响,所以就顺便研究了一下Windows的CRT库的相关知识,收集如下: (转载自:http://www.cnblogs.com/chio/archive/2007/11/26/972152.html) [关于CRT]   CRT原先是指Microsoft开发的C Runtime Library,用于操作系统的开发及运行。后来在此基础上开发了C++ Runtime Library,所以现在CRT是指Microsoft开发的C/C++ Runtime Library。在VC的CRT/SRC目录下,可以看到CRT的源码,不仅有C的,也有C++的。   CRT原先的目的就是支持操作系统的运行。因为Windows操作系统除汇编部分外,都是用C/C++编写的,所以内核及许多关键服务都在CRT上运行(它们都采用dll技术动态链接)。此外,用 VC编写的C/C++程序也用到它们(可以动态链接,也可以静态链接,前者运行时需要系统中已安装CRT的dll,后者不需要)。可以说,CRT就是 Microsoft编写Windows时使用的低层类库。然后,它又被当作C++标准库的一个实现包含在了VC系列中;我们在VC中使用的C++标准库, 其实就是CRT的一个真子集(少了C++标准所不包含的代码,特别是大量的低层C代码)。  

How to convert .crt to .pem [duplicate]

我只是一个虾纸丫 提交于 2019-11-26 16:55:28
Possible Duplicate: How to get .pem file from .key and .crt files? How can I convert .crt to .pem? MrEyes You can do this conversion with the OpenSSL library http://www.openssl.org/ Windows binaries can be found here: http://www.slproweb.com/products/Win32OpenSSL.html Once you have the library installed, the command you need to issue is: openssl x509 -in mycert.crt -out mycert.pem -outform PEM NeilG I found the OpenSSL answer given above didn't work for me, but the following did, working with a CRT file sourced from windows. openssl x509 -inform DER -in yourdownloaded.crt -out outcert.pem

How do I get the file HANDLE from the fopen FILE structure?

房东的猫 提交于 2019-11-26 16:49:08
问题 The fopen function returns a pointer to a FILE structure, which should be considered an opaque value, without dealing with its content or meaning. On Windows, the C runtime is a wrapper of the Windows API, and the fopen function relies on the CreateFile function. The CreateFile function returns a HANDLE , which is used by other Windows API. Now, I need to use Windows API deep inside of a library that uses fopen and FILE* . So: is there a way to get the HANDLE from the FILE structure? As this

Should I compile with /MD or /MT?

浪尽此生 提交于 2019-11-26 14:03:41
In Visual Studio, there's the compile flags /MD and /MT which let you choose which kind of C runtime library you want. I understand the difference in implementation, but I'm still not sure which one to use. What are the pros/cons? One advantage to /MD that I've heard, is that this allows someone to update the runtime, (like maybe patch a security problem) and my app will benefit from this update. Although to me, this almost seems like a non-feature: I don't want people changing my runtime without allowing me to test against the new version! Some things I am curious about: How would this affect

【CRT】中国剩余定理简介

旧城冷巷雨未停 提交于 2019-11-26 13:45:26
中国剩余定理(CRT) 中国剩余定理出自中国的某本古书,似乎是孙子兵法?(雾 其中有这样一个问题: 有物不知其数,三三数之剩二,五五数之剩三,七七数之剩二。问物几何? 即,对于这样一个方程组: \[ \begin{cases}x\equiv a_1\pmod{m_1}\\x\equiv a_2\pmod{m_2}\\x\equiv a_3\pmod{m_3}\\\dots\\x\equiv a_i\pmod{m_i}\end{cases} \] 我们已知所有 \(a_i,m_i\) ,求可行解 \(x\) ,可以证明的是, 若所有 \(m_i\) 互质,那么该方程组有唯一解。 可以构造出一个解:如果有 \(k\) 个方程,设 \(M=\prod_{i=1}^k m_i,n_i=\frac{M}{m_i}\) ,则有 \(x=\sum_{i=1}^k a_in_in_i^{-1}\pmod{M}\) 。 扩展中国剩余定理(EXCRT) 扩展中国剩余定理不要求 \(m_i\) 互质,其结论是由数学归纳法得出的,跟CRT实际上没太大关系。这种情况下,方程组的解是不唯一的。 首先考虑两个方程的情况。 假设我们有 \(x\equiv a_1\pmod{m_1},x\equiv a_2\pmod{m_2}\) ,那么显然 \(x+m_1*t_1=a_1,x+m_2*t_2=a_2\) ,其中

api-ms-win-crt-runtime-l1-1-0.dll is missing when opening Microsoft Office file

时光怂恿深爱的人放手 提交于 2019-11-26 06:26:22
I am facing this .dll library missing error: This programme can't start because api-ms-win-crt-runtime-l1-1-0.dll is missing. Try to reinstall this. When I try to open an Microsoft Office file. How do I solve that? alireza valipour The default solution is to install KB2999226 of Microsoft. KeshV While the answer from alireza is correct, it has one gotcha: You can't install Microsoft Visual C++ 2015 redist (runtime) unless you have Windows Update KB2999226 installed (at least on Windows 7 64-bit SP1). Vinayak Shedgeri Recursively update Windows 7 until it shows no more updates, using Windows

How to convert .crt to .pem [duplicate]

試著忘記壹切 提交于 2019-11-26 06:05:04
问题 Possible Duplicate: How to get .pem file from .key and .crt files? How can I convert .crt to .pem? 回答1: You can do this conversion with the OpenSSL library http://www.openssl.org/ Windows binaries can be found here: http://www.slproweb.com/products/Win32OpenSSL.html Once you have the library installed, the command you need to issue is: openssl x509 -in mycert.crt -out mycert.pem -outform PEM 回答2: I found the OpenSSL answer given above didn't work for me, but the following did, working with a

Should I compile with /MD or /MT?

核能气质少年 提交于 2019-11-26 03:48:19
问题 In Visual Studio, there\'s the compile flags /MD and /MT which let you choose which kind of C runtime library you want. I understand the difference in implementation, but I\'m still not sure which one to use. What are the pros/cons? One advantage to /MD that I\'ve heard, is that this allows someone to update the runtime, (like maybe patch a security problem) and my app will benefit from this update. Although to me, this almost seems like a non-feature: I don\'t want people changing my runtime

api-ms-win-crt-runtime-l1-1-0.dll is missing when opening Microsoft Office file

夙愿已清 提交于 2019-11-26 01:57:32
问题 I am facing this .dll library missing error: This programme can\'t start because api-ms-win-crt-runtime-l1-1-0.dll is missing. Try to reinstall this. When I try to open an Microsoft Office file. How do I solve that? 回答1: The default solution is to install KB2999226 of Microsoft. 回答2: While the answer from alireza is correct, it has one gotcha: You can't install Microsoft Visual C++ 2015 redist (runtime) unless you have Windows Update KB2999226 installed (at least on Windows 7 64-bit SP1). 回答3