Skip to content

Instantly share code, notes, and snippets.

Simon Ser emersion

Block or report user

Report or block emersion

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile

What does a mailing list need to do to reflect a message?

Method 1

Keep the original From header. Add a Sender header field with the list's address. Broadcast message with MAIL FROM set to the list's address.


View dup.c
#include <fcntl.h>
#include <unistd.h>
#include <stdio.h>
int main() {
int dupfd = dup(STDOUT_FILENO);
if (dupfd < 0) {
return 1;
View compositor-cursor-unstable-v1.xml
<?xml version="1.0" encoding="UTF-8"?>
<protocol name="wp_compositor_cursor_unstable_v1">
<interface name="zwp_compositor_cursor_manager_v1" version="1">
<request name="destroy" type="destructor"></request>
<enum name="device_type">
<entry name="pointer" value="1" summary="Pointer"/>
<entry name="tablet_tool" value="2" summary="Tablet tool"/>
View my_list.c
struct list {
void *value;
struct list *prev, *next;
void list_init(struct list *l) {
assert(l->prev == NULL && l->next == NULL);
l->prev = l;
l->next = l;
emersion / security-headers.conf
Created Jul 30, 2018
Caddy strict security headers
View security-headers.conf
header / {
X-XSS-Protection "1; mode=block"
X-Content-Type-Options "nosniff"
X-Frame-Options "DENY"
Referrer-Policy "no-referrer"
Content-Security-Policy "default-src 'none'; object-src 'none'; base-uri 'self'; frame-ancestors 'none'; img-src https:; font-src 'self'; style-src 'self' 'unsafe-inline'; script-src 'none'; form-action 'self'; worker-src 'none'; frame-src;"
Feature-Policy "accelerometer 'none'; ambient-light-sensor 'none'; autoplay 'none'; camera 'none'; encrypted-media 'none'; fullscreen 'self'; geolocation 'none'; gyroscope 'none'; magnetometer 'none'; microphone 'none'; midi 'none'; payment 'none'; picture-in-picture 'self'; speaker 'none'; usb 'none'; vr 'none';"
View extract-vdso.c
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
int main(int argc, char **argv)
char buf[256], *mem;
const char *range_name;
FILE *rd, *wr;
long long start_addr, end_addr;
View my_array.c
#include <assert.h>
#include <stdlib.h>
#include <string.h>
#include <stdio.h>
struct my_array {
void *data;
size_t cap;
size_t len, elem_size;
emersion /
Created Jun 5, 2018
Download a whole pipermail archive into a single mbox file
wget -r -np -l 1 -n d -A gz
gunzip *.gz
cat * > all.mbox
emersion /
Last active Jun 5, 2018 — forked from extremecoders-re/
Installing debian stretch mips64el on qemu
emersion / fullscreen-client-unmapped.c
Last active Apr 19, 2018
Creates a client that sends a fullscreen request while unmapped
View fullscreen-client-unmapped.c
#include <GLES2/gl2.h>
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
#include <wayland-client.h>
#include <wayland-egl.h>
#include <wlr/render/egl.h>
#include "xdg-shell-unstable-v6-client-protocol.h"
#include "idle-inhibit-unstable-v1-client-protocol.h"
You can’t perform that action at this time.