Skip to content

Instantly share code, notes, and snippets.

@azmeuk
azmeuk / populate_gtg.py
Created June 14, 2023 10:58
Populate Getting Things Gnome
import faker
import uuid
import random
fake = faker.Faker()
DATASET = "random"
NB_TAGS = 0
NB_TASKS = 206
@azmeuk
azmeuk / rspamd-whitelisting.md
Created February 3, 2023 10:57 — forked from ThomasLeister/rspamd-whitelisting.md
How to whitelist IP addresses or domains in Rspamd

Whitelist IP addresses based on pre-filter policy

/etc/rspamd/local.d/multimap.conf:

  IP_WHITELIST {
      type = "ip";
      prefilter = true;
      map = "/${LOCAL_CONFDIR}/local.d/ip_whitelist.map";
 action = "accept";
@azmeuk
azmeuk / aioxmpp.log
Created January 2, 2017 16:39
Firebase Cloud Messaging and aioxmpp
2017-01-02 17:37:46,605 selector_events:53 DEBUG Using selector: EpollSelector
2017-01-02 17:37:46,606 callbacks:478 DEBUG connecting <bound method PresenceManagedClient._handle_stream_established of <aioxmpp.node.PresenceManagedClient object at 0x7f34ea043d30>> with mode <bound method AdHocSignal.STRONG of <class 'aioxmpp.callbacks.AdHocSignal'>>
2017-01-02 17:37:46,607 callbacks:478 DEBUG connecting <Future pending> with mode <bound method AdHocSignal.AUTO_FUTURE of <class 'aioxmpp.callbacks.AdHocSignal'>>
2017-01-02 17:37:46,607 callbacks:478 DEBUG connecting <Future pending> with mode <bound method AdHocSignal.AUTO_FUTURE of <class 'aioxmpp.callbacks.AdHocSignal'>>
2017-01-02 17:37:46,607 callbacks:478 DEBUG connecting <bound method AbstractClient._stream_failure of <aioxmpp.node.PresenceManagedClient object at 0x7f34ea043d30>> with mode <bound method AdHocSignal.STRONG of <class 'aioxmpp.callbacks.AdHocSignal'>>
2017-01-02 17:37:46,607 callbacks:478
@azmeuk
azmeuk / aioxmpp.log
Created January 2, 2017 15:54
Firebase Cloud Messaging and aioxmpp
2017-01-02 16:44:24,038 selector_events:53 DEBUG Using selector: EpollSelector
2017-01-02 16:44:24,040 callbacks:478 DEBUG connecting <bound method PresenceManagedClient._handle_stream_established of <aioxmpp.node.PresenceManagedClient object at 0x7f70e4ea7128>> with mode <bound method AdHocSignal.STRONG of <class 'aioxmpp.callbacks.AdHocSignal'>>
2017-01-02 16:44:24,040 callbacks:478 DEBUG connecting <Future pending> with mode <bound method AdHocSignal.AUTO_FUTURE of <class 'aioxmpp.callbacks.AdHocSignal'>>
2017-01-02 16:44:24,040 callbacks:478 DEBUG connecting <Future pending> with mode <bound method AdHocSignal.AUTO_FUTURE of <class 'aioxmpp.callbacks.AdHocSignal'>>
2017-01-02 16:44:24,041 callbacks:478 DEBUG connecting <bound method AbstractClient._stream_failure of <aioxmpp.node.PresenceManagedClient object at 0x7f70e4ea7128>> with mode <bound method AdHocSignal.STRONG of <class 'aioxmpp.callbacks.AdHocSignal'>>
2017-01-02 16:44:24,041 callbacks:478
@azmeuk
azmeuk / aioxmpp.log
Created September 1, 2016 08:50
Firebase Cloud Messaging aioxmpp output
2016-09-01 10:46:34,754 selector_events:53 DEBUG Using selector: EpollSelector
2016-09-01 10:46:34,760 callbacks:431 DEBUG connecting <bound method PresenceManagedClient._handle_stream_established of <aioxmpp.node.PresenceManagedClient object at 0x7f3b650ba518>> with mode <bound method AdHocSignal.STRONG of <class 'aioxmpp.callbacks.AdHocSignal'>>
2016-09-01 10:46:34,761 callbacks:431 DEBUG connecting <Future pending created at /home/eloi/dev/push-server/local.virtualenv/lib/python3.5/site-packages/aioxmpp/node.py:1019> with mode <bound method AdHocSignal.AUTO_FUTURE of <class 'aioxmpp.callbacks.AdHocSignal'>>
2016-09-01 10:46:34,761 callbacks:431 DEBUG connecting <Future pending created at /home/eloi/dev/push-server/local.virtualenv/lib/python3.5/site-packages/aioxmpp/node.py:1019> with mode <bound method AdHocSignal.AUTO_FUTURE of <class 'aioxmpp.callbacks.AdHocSignal'>>
2016-09-01 10:46:34,761 callbacks:431 DEBUG connecting <bound method AbstractClient._stream_f
@azmeuk
azmeuk / aioxmpp.py
Created September 1, 2016 08:48
Firebase Cloud Messaging aioxmpp script
import asyncio, datetime, uuid, json, aioxmpp.xso, aioxmpp.utils, aioxmpp.node, aioxmpp.security_layer, aioxmpp.structs, aioxmpp.stanza, colorlog
class FCMPayload(aioxmpp.xso.XSO):
TAG = ("google:mobile:data", "gcm")
text = aioxmpp.xso.Text(default=None)
async def main(jid, password, recipient):
@asyncio.coroutine
def get_password(client_jid, nattempt):
return None if nattempt > 1 else password
DEBUG selector_events:53 Using selector: EpollSelector
DEBUG callbacks:431 connecting <bound method PresenceManagedClient._handle_stream_established of <aioxmpp.node.PresenceManagedClient object at 0x7f52a4c94ba8>> with mode <bound method AdHocSignal.STRONG of <class 'aioxmpp.callbacks.AdHocSignal'>>
DEBUG callbacks:431 connecting <Future pending> with mode <bound method AdHocSignal.AUTO_FUTURE of <class 'aioxmpp.callbacks.AdHocSignal'>>
DEBUG callbacks:431 connecting <Future pending> with mode <bound method AdHocSignal.AUTO_FUTURE of <class 'aioxmpp.callbacks.AdHocSignal'>>
DEBUG callbacks:431 connecting <bound method AbstractClient._stream_failure of <aioxmpp.node.PresenceManagedClient object at 0x7f52a4c94ba8>> with mode <bound method AdHocSignal.STRONG of <class 'aioxmpp.callbacks.AdHocSignal'>>
DEBUG callbacks:431 connecting <bound method AbstractClient._stream_destroyed of <aioxmpp.node.PresenceManagedClient object at 0x7f52a4c94ba8>> with mode <bound method AdHocSignal.STRONG of <cla
@azmeuk
azmeuk / gist:7371031
Created November 8, 2013 13:27
Xorg.0.log on Fedora 19 with AMD proprietary drivers, trying to make my Radeon HD 7470/8470 work.
[ 460.410]
X.Org X Server 1.14.3
Release Date: 2013-09-12
[ 460.415] X Protocol Version 11, Revision 0
[ 460.417] Build Operating System: 3.10.9-200.fc19.x86_64
[ 460.418] Current Operating System: Linux pc-eloi.cap-sciences.h20 3.11.7-200.fc19.x86_64 #1 SMP Mon Nov 4 14:09:03 UTC 2013 x86_64
[ 460.418] Kernel command line: BOOT_IMAGE=/vmlinuz-3.11.7-200.fc19.x86_64 root=/dev/mapper/fedora_pc--eloi-root ro rd.lvm.lv=fedora_pc-eloi/swap rd.md=0 rd.dm=0 vconsole.font=latarcyrheb-sun16 vconsole.keymap=fr rd.luks=0 rd.lvm.lv=fedora_pc-eloi/root rhgb quiet LANG=fr_FR.UTF-8 radeon.modeset=0 rd.driver.blacklist=radeon
[ 460.423] Build Date: 23 October 2013 06:12:49AM
[ 460.425] Build ID: xorg-x11-server 1.14.3-2.fc19
[ 460.426] Current version of pixman: 0.30.0
@azmeuk
azmeuk / IOIO Console Dump
Created October 24, 2013 11:56
IOIO Console Dump
[D/IOIOConnectionRegistry] Successfully added bootstrap class: ioio.lib.pc.SerialPortIOIOConnectionBootstrap
[D/SerialPortIOIOConnectionBootstrap] Adding serial port /dev/IOIO0
[D/IOIOImpl] Waiting for IOIO connection
[V/IOIOImpl] Waiting for underlying connection
log: instantiating jtermios.linux.JTermiosImpl
log: < open('/dev/IOIO0',00000902) => 9
log: < close(9) => 0
log: < open('/dev/IOIO0',00000902) => 9
log: < fcntl(9, 3, 0) => 34818
log: < fcntl(9, 4, 32770) => 0
@azmeuk
azmeuk / Denemo GUB buid fail
Last active December 26, 2015 05:19
Gub fails to build denemo
* Starting build: Tue Oct 22 14:31:18 2013
must rebuild: mingw::lilypondcairo
*** Checksum mismatch: diff (lilypondcairo, mingw)
--- /home/eloi/jjbenhamgub/target/mingw/packages/lilypondcairo.checksum 0000
+++ THIS BUILD Tue Oct 22 14:31:16 2013
@@ -1 +1,415 @@