-
I am Dave Jing Tian, an Assistant Professor in the Department of Computer Science at Purdue University working on system security. My research involves embedded systems, operating systems, trusted and confidential computing, and hardware security and trust. All opinions are my own.
Shoot me:
root@davejingtian.org Categories
Resource
Tags
- ABNF
- agile
- AI/ML
- Alcatel-Lucent
- android
- arp
- asn1c
- assembly
- bash
- ber
- bison
- BNF
- build
- C
- CentOS
- CIS122
- Coverity
- crypto
- csv
- cuda
- DCA
- ddclient
- debugfs
- DH
- Diffie-Hellman
- drd
- drig
- elixir
- fedora
- fedup
- flex
- fsck
- gcc
- gdb
- GFW
- git
- github
- gnome
- gprof
- gpu
- guitar
- gumstix
- helgrind
- intel
- itevad
- Java
- jmgsim
- JVM
- kenai
- kernel
- kill
- ksh
- kvm
- ld
- Linux
- list
- netbeans
- netlink
- nvidia
- OS
- overo
- Python
- relay
- security
- selinux
- sgx
- socket
- ssh
- Ubuntu
- UO
- USB
- valgrind
- x86
- x86_64
- yocto
Blog Stats
- 236,408 hits
-
All blogs on this website are licensed under a Creative Commons Attribution 4.0 International License.
Tag Archives: C
Pitfalls in negative indexing in C
Negative indexing in C, such as a[-1], is legit, although rarely used. There are reasons (pitfalls) why negative indexing is not recommended. This post discusses these pitfalls when using negative indexing (for fun). 1. Negative indexing within the bound In … Continue reading
Retrieve PID from the packet in Unix domain socket – a complete use case for recvmsg()/sendmsg()
The original question was how to retrieve the PID of the packet (sender) in the Unix domain socket. As titled, the answer is recvmsg()/sendmsg(). However, the most useful information I could find online is Michael’s man7.org. People keep talking about … Continue reading
cgpic – Calling GProlog in C
Prolog is a straight-forward way to implement simple logic rules and do the query of the system. GProlog(gprolog) is the GNU version of Prolog implementation. To leverage the power of gprolog into our system code (C/C++), there are usually 2 … Continue reading
timer queue – a way to handle multiple timers using one thread
This post introduces a general way to handle multiple timers using one thread using C. K.R.K.C. -daveti 1. what is timer? The essence of timer is eventually a thread (either Python or Java threads are actually mapped and executed as … Continue reading
Use POSIX regex in C
There is no standard regex lib in glibc. However, almost all UNIXs, Linux and even Mac OS should support POSIX regex, which provides a way to do regex processing in C. Below is the real example under Linux. For Mac … Continue reading
side effect of “++” in C – compiler implemenation with assembly
This post shows a common known side effect of “++” operator in C programming because of different compiler implementation. Assembly code from PowerPC and x86 with gcc is provide to show the key difference and the reason why for this … Continue reading
Auth Lib – with DH Key Exchange Algorithm, MD5 Digest Algorithm and Helper APIs
Finally, I’ve got time to summaries the authentication work I’ve done for MGC:) This post gives a useful C lib on authentication focusing on DH key exchange algorithm and MD5 digest helper APIs. Please note this lib should be built/used … Continue reading
Diffie-Hellman key exchange algorithm – deeper and better
In my last post on D-H algorithm (http://daveti.blog.com/2011/04/21/diffiehellman-key-exchange-dh-algorithm-in-c/), we talked about 2 implementation using C. However, I’ve been thinking about one thing here these days – if there is any potential integer overflow risk in both functions (though for unsigned … Continue reading
Diffie–Hellman key exchange (DH algorithm in C)
I am recently doing feature on authentication between MGC (Media Gateway Controller) and MG (Media Gateway). One important thing involved in Diffie-Hellman key exchange. Not sure if because the key formula ‘g^a mod(P)’ looks simple and stupid, it is hard … Continue reading