{% load static otree %} {% block content %}
Welcome! Please read the following instructions very carefully.
In this study, you and another participant have been matched together to form a two-member team - think of yourself as the worker and your team member as your boss. You, as worker, will work on a button-pressing task (to be described below) for upto 10 minutes. Both you and your boss will earn $1 simply for participating in this study. You may each earn additional bonus amounts based on the decisions you and your boss take. Your respective earnings will be transferred to your accounts within 24 hours.
Once you start working on the button-pressing task, your team will earn $0.10 for every 100 points you score. However, before you start the task, your boss will decide and announce how he/she will split the $0.10 between you and him/her. Your share (out of $0.10) will be your bonus rate for working on the task. Of course, the bigger the bonus rate your boss chooses for you, the less his/her own bonus will be.
Specifically, your boss must select a bonus rate of either 0, 3, 6 or 9 cents for every 100 points scored by you. For example, if your boss chose 3 cents per 100 points for you, he/she will keep 7 cents for himself/herself.
The point at which your boss decided the bonus rate for you, he/she did not know anything about your identity. He/she will observe the points scored by you once you have finished working on the task.
To summarize, your boss has selected a bonus rate of either 0, 3, 6 or 9 cents for every 100 points scored by you on a button-pressing task. On the next screen, you will see the bonus rate selected and you will then work on the task for upto 10 minutes. Bonus payments will be determined once you have finished working on the task.
Below is an example of how the task will work. Try pressing "a" and "b" alternately to score points. Below we have limited the maximum number of points you can score to 30 as this is just practice, but the actual task will not have a point limit. In the actual task, you will have 10 minutes to score as many points as you can. You may stop anytime before the 10-minute mark is up. Of course, the longer you work on the task, the more points you will score.
Press 'a' then 'b'


| Top |
| void | gtk_tooltip_set_markup () |
| void | gtk_tooltip_set_text () |
| void | gtk_tooltip_set_icon () |
| void | gtk_tooltip_set_icon_from_stock () |
| void | gtk_tooltip_set_icon_from_icon_name () |
| void | gtk_tooltip_set_icon_from_gicon () |
| void | gtk_tooltip_set_custom () |
| void | gtk_tooltip_trigger_tooltip_query () |
| void | gtk_tooltip_set_tip_area () |
Basic tooltips can be realized simply by using gtk_widget_set_tooltip_text()
or gtk_widget_set_tooltip_markup()
without any explicit tooltip object.
When you need a tooltip with a little more fancy contents, like adding an image, or you want the tooltip to have different contents per GtkTreeView row or cell, you will have to do a little more work:
Set the “has-tooltip” property to TRUE
, this will make GTK+
monitor the widget for motion and related events which are needed to
determine when and where to show a tooltip.
Connect to the “query-tooltip” signal. This signal will be
emitted when a tooltip is supposed to be shown. One of the arguments passed
to the signal handler is a GtkTooltip object. This is the object that we
are about to display as a tooltip, and can be manipulated in your callback
using functions like gtk_tooltip_set_icon()
. There are functions for setting
the tooltip’s markup, setting an image from a named icon, or even putting in
a custom widget.
Return TRUE
from your query-tooltip handler. This causes the tooltip to be
show. If you return FALSE
, it will not be shown.
In the probably rare case where you want to have even more control over the tooltip that is about to be shown, you can set your own GtkWindow which will be used as tooltip window. This works as follows:
Set “has-tooltip” and connect to “query-tooltip” as before.
Use gtk_widget_set_tooltip_window()
to set a GtkWindow created by you as
tooltip window.
In the “query-tooltip” callback you can access your window using
gtk_widget_get_tooltip_window()
and manipulate as you wish. The semantics of
the return value are exactly as before, return TRUE
to show the window,
FALSE
to not show it.
void gtk_tooltip_set_markup (GtkTooltip *tooltip
,const gchar *markup
);
Sets the text of the tooltip to be markup
, which is marked up
with the Pango text markup language.
If markup
is NULL
, the label will be hidden.
Since: 2.12
void gtk_tooltip_set_text (GtkTooltip *tooltip
,const gchar *text
);
Sets the text of the tooltip to be text
. If text
is NULL
, the label
will be hidden. See also gtk_tooltip_set_markup()
.
Since: 2.12
void gtk_tooltip_set_icon (GtkTooltip *tooltip
,GdkPixbuf *pixbuf
);
Sets the icon of the tooltip (which is in front of the text) to be
pixbuf
. If pixbuf
is NULL
, the image will be hidden.
Since: 2.12
void gtk_tooltip_set_icon_from_stock (GtkTooltip *tooltip
,const gchar *stock_id
,GtkIconSize size
);
gtk_tooltip_set_icon_from_stock
has been deprecated since version 3.10 and should not be used in newly-written code.
Use gtk_tooltip_set_icon_from_icon_name()
instead.
Sets the icon of the tooltip (which is in front of the text) to be
the stock item indicated by stock_id
with the size indicated
by size
. If stock_id
is NULL
, the image will be hidden.
tooltip |
||
stock_id |
a stock id, or |
[allow-none] |
size |
a stock icon size (GtkIconSize). |
[type int] |
Since: 2.12
void gtk_tooltip_set_icon_from_icon_name (GtkTooltip *tooltip
,const gchar *icon_name
,GtkIconSize size
);
Sets the icon of the tooltip (which is in front of the text) to be
the icon indicated by icon_name
with the size indicated
by size
. If icon_name
is NULL
, the image will be hidden.
tooltip |
||
icon_name |
an icon name, or |
[allow-none] |
size |
a stock icon size (GtkIconSize). |
[type int] |
Since: 2.14
void gtk_tooltip_set_icon_from_gicon (GtkTooltip *tooltip
,GIcon *gicon
,GtkIconSize size
);
Sets the icon of the tooltip (which is in front of the text)
to be the icon indicated by gicon
with the size indicated
by size
. If gicon
is NULL
, the image will be hidden.
Since: 2.20
void gtk_tooltip_set_custom (GtkTooltip *tooltip
,GtkWidget *custom_widget
);
Replaces the widget packed into the tooltip with
custom_widget
. custom_widget
does not get destroyed when the tooltip goes
away.
By default a box with a GtkImage and GtkLabel is embedded in
the tooltip, which can be configured using gtk_tooltip_set_markup()
and gtk_tooltip_set_icon()
.
Since: 2.12
void
gtk_tooltip_trigger_tooltip_query (GdkDisplay *display
);
Triggers a new tooltip query on display
, in order to update the current
visible tooltip, or to show/hide the current tooltip. This function is
useful to call when, for example, the state of the widget changed by a
key press.
Since: 2.12
void gtk_tooltip_set_tip_area (GtkTooltip *tooltip
,const GdkRectangle *rect
);
Sets the area of the widget, where the contents of this tooltip apply,
to be rect
(in widget coordinates). This is especially useful for
properly setting tooltips on GtkTreeView rows and cells, GtkIconViews,
etc.
For setting tooltips on GtkTreeView, please refer to the convenience
functions for this: gtk_tree_view_set_tooltip_row()
and
gtk_tree_view_set_tooltip_cell()
.
Since: 2.12


--- title: 13ty blog description: 3rd entry in the 11ty series date: 2020-06-24T10:54:57+00:00 tags: - 11ty layout: layouts/text.njk heroImage: https://cms.joshuahahn.de/uploads/11ty/originals/c2512c81-db19-462c-a46b-0b7cf89a3afd.jpg ---
Lorem Ipsum


{% extends 'generic/base.html' %} {% load static %} {% block content %} {% if user.is_authenticated %}
If you are not a member, membership is free, so Signup now.If you are already a member please Signin.


JavaScript is disabled on your browser.
Skip navigation links
Overview
Package
Class
Tree
Deprecated
Index
Help
Prev
Next
Frames
No Frames
All Classes
Hierarchy For All Packages
Package Hierarchies:
nsr.loui.playingcards.card
,
nsr.loui.playingcards.card.comparator
,
nsr.loui.playingcards.card.imitator
,
nsr.loui.playingcards.cards
,
nsr.loui.playingcards.contrib
,
nsr.loui.playingcards.exceptions
,
nsr.loui.playingcards.observer
,
nsr.loui.util
Class Hierarchy
java.lang.Object
nsr.loui.playingcards.cards.
BaseCards
nsr.loui.playingcards.cards.
Cards
nsr.loui.playingcards.cards.
AutoSortedCards
nsr.loui.playingcards.cards.
Hand
nsr.loui.playingcards.contrib.
SwitchableAutoSortedCards
<T>
nsr.loui.playingcards.cards.
OrderedCards
nsr.loui.playingcards.cards.
Deck
nsr.loui.playingcards.cards.
Trash
nsr.loui.playingcards.cards.
UnorderedCards
nsr.loui.playingcards.card.
Card
nsr.loui.playingcards.card.
Joker
nsr.loui.playingcards.card.
RankedCard
nsr.loui.playingcards.card.comparator.
CardComparator
(implements java.util.Comparator<T>)
nsr.loui.playingcards.card.comparator.
JokersFirstComparator
nsr.loui.playingcards.card.comparator.
JokersLastComparator
nsr.loui.playingcards.card.comparator.
DefaultCardComparator
nsr.loui.playingcards.cards.
CardOwnerCertificate
nsr.loui.util.
CollectionUtil
nsr.loui.playingcards.card.imitator.
JokerImitator
(implements nsr.loui.playingcards.card.imitator.
IndividualCardImitator
, nsr.loui.playingcards.card.imitator.
WildCardImitator
)
nsr.loui.playingcards.observer.
PrintObserver
(implements nsr.loui.playingcards.observer.
Observer
)
nsr.loui.util.
PyLikePrinter
nsr.loui.playingcards.card.imitator.
RankedCardImitator
(implements nsr.loui.playingcards.card.imitator.
IndividualCardImitator
)
nsr.loui.playingcards.card.imitator.
RankImitator
(implements nsr.loui.playingcards.card.imitator.
WildCardImitator
)
nsr.loui.playingcards.card.imitator.
SuitImitator
(implements nsr.loui.playingcards.card.imitator.
WildCardImitator
)
java.lang.Throwable (implements java.io.Serializable)
java.lang.Exception
java.lang.RuntimeException
nsr.loui.playingcards.exceptions.
CardNotEnoughException
nsr.loui.playingcards.exceptions.
CardNotFoundException
nsr.loui.playingcards.exceptions.
OwnerCertificateImproperException
nsr.loui.playingcards.exceptions.
ProhibitedOperationException
nsr.loui.playingcards.card.imitator.
UnitedImitator
(implements nsr.loui.playingcards.card.imitator.
WildCardImitator
)
Interface Hierarchy
nsr.loui.playingcards.card.imitator.
CardImitator
nsr.loui.playingcards.card.imitator.
IndividualCardImitator
nsr.loui.playingcards.card.imitator.
WildCardImitator
nsr.loui.playingcards.observer.
Observer
Enum Hierarchy
java.lang.Object
java.lang.Enum<E> (implements java.lang.Comparable<T>, java.io.Serializable)
nsr.loui.playingcards.card.
Suit
nsr.loui.playingcards.observer.
Observer.Type
Skip navigation links
Overview
Package
Class
Tree
Deprecated
Index
Help
Prev
Next
Frames
No Frames
All Classes


CRemoteAccessService - Fixed a bug, thanks to Richard Wirth (r.wirth@wirthware.da-net.de), where the Open() method could go into an endless loop.
CPing - Fixed a bug, thanks to
Curits Yanko (cyanko@ziplink.net),
where I was not thunking the call to
inet_addr()
.
CRegistry - Fixed a bug, thanks to George Koukoulommatis (gemasoft@hol.gr), where I was not calculating the size of a string buffer correctly. I was incorrectly assuming that a character was only one byte wide which is not UNICODE correct. This bug was in the SetStringArrayValue() function.
CSimpleSocket - Fixed a bug in SetAddress() where the name and address properties weren't being set if there was no DNS entry for an IP address.
Map2Def - This is a sample utility that converts a MAP file to a DEF file. I fixed it where it was not including the timestamp in the resulting DEF file.
XMLCheck - This is a new sample utility that loads an XML file and tells you if it is valid or not. If it is not a valid file it will tell you exactly where it failed (line number and column number).
Sam Blackburn Internet<EMAIL_ADDRESS>Return to Sam's Home Page


Malaysia’s Very Last Sumatran Rhinoceros Dies Due to Cancer
by Roxanne TaiTap to listen to this article instead: 🔊 Listen to Post
A piece of sad news had struck us when the last Sumatran Rhinoceros in Malaysia lost its life to cancer at the Borneo Rhino Sanctuary yesterday (23 November).
Iman, the lovely female Sumatran rhino was under the best care and attention of her keepers since March 2014, right until the moment she passed away. According to the Sabah Wildlife Department (SWD), her immediate cause of death was categorised as shock.
Although Iman had been suffering from the significant pain caused by a growing tumour in her bladder, Austine Tuuga, the director of Sabah Wildlife Department mentioned that her death arrived sooner than they expected. Datuk Christina Liew, Sabah’s Tourism, Culture and Environment Minister stated that apart from the tumour in her bladder, Iman was also suffering from uterine cancer.
“No one could have done more. She was actually quite close to death when sudden massive blood loss from the uterine tumours occurred on several occasions over the past few years.”
Datuk Christina Liew had also said the state government has plans to fertilise Iman’s egg with Indonesia’s male rhino and surrogate female rhino, which was why the Memorandum of Understanding is still pending to be signed, as reported on Malay Mail.
“I would like to inform our counterparts in Indonesia that I am keen to pursue the MoU (Memorandum of Understanding). Iman’s death is a tragedy but this is one event in a bigger picture. There are still ways in which our twin countries can usefully collaborate based on our different experience over the past decade.”
We’re glad and grateful that the Sabah government is putting a lot of effort to conserve Malaysia’s wildlife. Rest in peace, Iman.
Also read: Malaysia’s Last Sumatran Rhino, Iman, May Die of Cancer Very Soon


Bold: The bold means the first place result of all methods compared.
*The * means the dependent variable of the corresponding data was transformed by log function to be more asymptotically normal.
The best RBF’s RMSE was significantly less than the second best RF using Wilcoxon Matched-Pairs Signed-Ranks Test ( p-value = 0.007185).


Survey Form
Let us know how we can improve freeCodeCamp
* Name
* Email
* Age
Which option describes your current role?
Student
Full time job
Other
How likely is that you would recommend freeCodeCamp to a friend?
Definitely
Maybe
Not Sure
Things that should be improved in the future (Check all that apply):
Front-end Projects
Back-end Projects
Data Visualization
Challenges
Open Source Community
Gitter help rooms
Any Comments or Suggestions?
Submit


The web was invented in the 1990's and is made up of pages written in HTML or Hypertext Markup Language. The components to accessing the web are: you, a computer and browser, internet access using HTTP, and servers.
HTML can be:
Text - what you see
Markup Elements - what it looks like - (uses Tags like b for bold) Elements can be inline or block.
References to other docs like images and videos
Links to other pages


ABOUT ME
Original Sketches
Animals In My Eyes
Sketches
Free My Mind
Spiritual Deer
Mouse Magician
Unicorn Dream
Tattooed Wolf
Surfing Penguin
Travelling Rabbit


fancyBox - Changelog
Version 2.1.3 - October 23, 2012
- Fixed #426 - Broken IE7
- Fixed #423 - Background flickering on iOS
- Fixed #418 - Automatically Grow/Shrink and Center
- Updated the script to work with jQuery 1.6
- Media helper supports YouTube video series
Version 2.1.2 - October 15, 2012
- Fixed #414 - Don’t allow nextClick if there is only one item
- Fixed #397 - Button helper ‘Menu’ not visible in IE7
- Overlay can be opened/closed manually:
- $.fancybox.helpers.overlay.open();
- $.fancybox.helpers.overlay.open({closeClick : false});
- $.fancybox.helpers.overlay.close();
- Optimized for Internet Explorer 10 (Windows 8)
Version 2.1.1 - October 01, 2012
- Fixed #357 - Converting values like ‘auto’ in getScalar()
- Fixed #358 - Updated overlay background image
- New “fancybox-href” and “fancybox-title” HTML5 data-attributes (#317)
- Improved helpers:
- now they can have a property ‘defaults’ that contains default settings
- updated vimeo and youtube parsers for media helper
- Content locking now can be turned off
Version 2.1.0 - August 20, 2012
- Fixed #103 - DOM element re-injection after closing
- Fixed #188 - navigation keys inside editable content
- New animation directions (see https://github.com/fancyapps/fancyBox/issues/233#issuecomment-5512453)
- New option “iframe” - it is now possible to separate scrolling for iframe and wrapping element; choose to preload
- New option “swf” - brings back functionality from fancyBox v1
- Improved media helper - better support for vimeo and youtube; links are now configurable
- Rewritten overlay helper:
- new option “showEarly” - toggles if should be open before of after content is loaded
-
- Option “padding” accepts array (e.g., padding: [15, 50, 10, 5])
- One of dimensions (width or height) can now be set to “auto” (option “autoSize” needs to be “false”)
- Updated callbacks:
- “beforeClose” is now called only once
- “afterLoad” receives current and previous object as arguments
- Method “$.fancybox.update();” recalculates content width/height
- Updated to work with jQuery v1.8
Version 2.0.6 - April 16, 2012
- Fixed #188 - keystrokes in contenteditable
- Fixed #171 - non-images should not be preloaded
- Fixed #158 - ‘closeClick: true’ breaks gallery navigation
- New “media” helper - detects and displays various media types
- New option “groupAttr” - name of group selector attribute, default is “data-fancybox-group”
- New feature - selector expressions in URLs, see #170
- Improved ‘overlay’ helper to use “position: fixed”
- Improved autoSize, fixed wrong height in some cases
- Improved centering and iframe scrolling for iOS
- Updated markup, new element ‘.fancybox-skin’ is now used for styling
Version 2.0.5 - February 21, 2012
- Fixed #155 - easing for prev/next animations
- Fixed #153 - overriding “keys” options
- Fixed #147 - IE7 problem with #hash links
- Fixed #130 - changing dynamically data-fancybox-group
- Fixed #126 - obey minWidth/minHeight
- Fixed #118 - placement of loading icon and navigation arrows
- Fixed #101 - “index” option not working
- Fixed #94 - “orig” option not working
- Fixed #80 - does not work on IE6
- Fixed #72 - can’t set overlay opacity to 0
- Fixed #63 - properly set gallery index
- New option “autoCenter” - toggles centering on window resize or scroll, disabled for mobile devices by default
- New option “autoResize” - toggles responsivity, disabled for mobile devices by default
- New option “preload” - number of images to preload
- New feature to target mobile/desktop browsers using CSS, see #108
- Changed ajax option defaults to “{ dataType: ‘html’, headers: { ‘X-fancyBox’: true } }”, see #150 and #128
- Updated loading icon for IE7, IE8
- Calculates height of the iframe if ‘autoSize’ is set to ‘true’ and the iframe is on the same domain as the main page
Version 2.0.4 - December 12, 2011
- Fixed #47 - fix overriding properties
- New option “position” to thumbnail and button helpers
Version 2.0.3 - November 29, 2011
- Fixed #29 - broken elastic transitions
Version 2.0.2 - November 28, 2011
- Fixed slideshow
- Fixed scrollbars issue when displayed a very tall image
- New option “nextClick” - navigate to next gallery item when user clicks the content
- New option “modal” - to disable navigation and closing
- Add ‘metadata’ plugin support
- Add ability to create groups using ‘data-fancybox-group’ attribute
- Updated manual usage to match earlier releases
Version 2.0.1 - November 23, 2011
- Fixed keyboard events inside form elements
- Fixed manual usage
Version 2.0.0 - November 21, 2011
First release - completely rewritten, many new features and updated graphics.


Video Server
OVERVIEW
I enjoy watching videos off of my computer, however I disliked constantly having to move all of my laptop components to and from my TV area. The easy solution was to build a dedicated computer that was always hooked up to my TV, that way I would never have to move my components around. The next problem that I faced was interfacing with whatever video player I was using for my videos. For a while I used a mouse and keyboard from my couch to navigate my desktop, however the using the peripherals without a hard surface tend to hurt my wrists after a while. In fear of the dreaded carpal tunnel, I decided that using a tablet as an interface to my media player would be better for my wrists.
VLC vs MPV
There are thousands of discussions online about which media players are the best so I'm not going to go into detail here. I initially used VLC as my media player since it worked on linux and I was familiar with the tool. After the initial implementation I unfortunately found out that opengl was not enabled by default when launching an instance of VLC from the provided library. Additionally I was not able to find anywhere in the libvlc documentation about how to enable opengl via the API. This was a problem since I purposefully underprovisioned my server since I was going to use opengl to handle most of the video rendering. Around this time mpc had announced that maintenance was going to be slowing down due to lack of developers. Given this news, mpv users began to provide a lot of help for people making the switch. That was when I looked into using libmpv since it offered an easy way to enable opengl along with many other useful configurations.
User Interface
Keeping with the common trend of "minimalism" the UI is very plain. Files are presented similar to a file browser with folders populating themselves with their contents when accessed. The video player displays basic information about the progress of the video along with some playback options. A lot could be added to the interface but this is all I really need to watch most of the videos that I have. My favorite thing about the interface is that it keeps track of key points in the video whenever I click on the "Timestamp" button. This allows me to watch the video all the way through the first time and then go back easily to screenshot anything I want.Overall the system works very well. Only downside is that I've put off adding features since I'm too busy using my software.


Start Bootstrap has everything you need to get your new website up and running in no time! All of the templates and themes on Start Bootstrap are open source, free to download, and easy to use. No strings attached!
ContactWe work directly with our customers to discover the perfect website for you!
Pick one of our custom templates or build something more customizable to your taste
We show you all the customizable areas for your webstie and you provide us the custom content to build them
How do customers find your website??
When all information is recieved, we usually complete and publish you're website within 24 hours
Check Out Idea42. A professional IT consulting group with decades of expirence!
ContactReady to start your next project with us? That's great! Give us a call or send us an email and we will get back to you as soon as possible!
123-456-6789


I am a young entrepreneur as I do what I love the most taking care of
dogs and cats.

Since I was a little girl my biggest love in life was caring for
animals. I love and understand each one with their different
personalities (dogs and cats are my favorites of course!)
To me, Happy Tail LLC is not just a company, it is my passion and
dream come true. I love and care for others. Throughout my life I have
learned so much thanks to all the pets I have been around. I started
company during July of 2015, but I have been working with animals since
my childhood. Back then, I would ask my neighbors to walk their dogs or
pet sit their cats.
I am happy to have started this business. By doing what I love, I
can keep meeting wonderful dogs and cats!
Insured, licensed, and bonded. We perform background checks on every employee.
Our mission is to provide peace of mind to our client and assure the best care for you and your best friend
We carry out the vision of a happy environment where your four-legged friend will live to the fullest in a safe environment.
If you have any questions or concerns, or for reservations and further information on caring for your dog, please contact:
Ellery Circle
Falls Church VA
Fiorella Gambini
703-303-7099
703-890-2653
*photos removed for privacy


--- layout: page permalink: "/personal/between/" ---
Together with artist Claire Christie Sadler we held an exhibition at West Ox Arts, Bampton, November 2011.
I tried to capture images that showed places, people and things whose existence may be transient, unpredictable, strange or mysterious-floating and held in those spaces between.
Claire's focus in her drawings was the place between two spaces-an edge, a boundary, a defining line and the relationship between the two areas it divides.


Hero View
NPC View
Player
Mouse
Item01
Item02
Basic Data
Advanced Data
This is a brief message
Grass
Road
Place
No Place
Base
NPC
Normal
Hero View
NPC View
Edit Mode
Buttons


The parsing of PRWM file is especially fast when the endianness of the
file is the same as the endianness of the client platform. The loader
will automatically replace the
* in the model url by
either
le or
be depending on the
client platform's endianness to download the most appropriate file.
Specifications and implementations
This platform endianness is
.
See your console for stats.


FooTel
Home
(current)
User Data
Name: Marcus Singh
Username: Marcus@007
Email<EMAIL_ADDRESS>Country: Mahismati
Add Hotel Data


Accelerate your CRM and sales skills with our tailored tutorials.
Jump right in with our quick start modules:Grow your skills to grow your business...
We've created a suite of training courses to help you get the most out of Act!
From taking your first steps, to taking your business to the next level, our training will give you the skills to succeed.
Each course takes less than 30 minutes, and will give you the tools you need to use Act's powerful features to their fullest.
Our Training Courses
0%
Basic Contact Management
Explore the Contacts section at the heart of Act!  Determine what data users can see, and what actions they can take.
~40 minutes
Start Course


[BF3][BF4][BFH][MOHW][v1.0] Comcenter Remover [08.01.2016] - Better Battlelog Forums #147542
Sitemap
08. January 2016 17:29
Post edited 2 x times, last by
I-MrFixIt-I
Plugin Developer
09. January 2016 10:56
Topicstarter
I-MrFixIt-I
Plugin Developer
Name: Comcenter Remover
Author: I-MrFixIt-I
Version: 1.0
This plugin was request:
https://getbblog.com/en/board/topic/146826/1/Hide-the-Chat-Friends-Window-Click-opens-from-the-side
☰ Description:
Some people are not using the comcenter (chat and friendlist), so the comcenter takes a lot of space which could be removed. This plugin will remove the comcenter and repositioning the whole website for you.
☰ Options:
- "Use Comcenter Remover" (default: on): Toggle the plugin
☰ Changelog:
Click to open/close:
v1.0:
- Initial release
Source code can be found here:
https://getbblog.com/plugins/user/147544.js?m=204
Any suggestions or ideas I could add? Anwser here and I'll respond :)
03. February 2016 19:08
Battlenat0r
I think you should add the option to hide the Comcenter also. I can't receive messages when it's removed. :-(


psq v0.1.0 PSQ
PSQ provides a purely-functional implementation of priority search queues. A
priority search queue is a data structure that efficiently supports both
associative operations (like those for Map
) and priority-queue operations
(akin to heaps in imperative languages). The implementation is based on the
Haskell
PSQueue
package and the associated paper.
PSQs can be created from lists in O(n log n) time. Once created, the minimum
element (min/1
and size (Enum.count/1
) can be accessed in O(1) time; most
other basic operations (including get/2
, pop/1
, and put/2
, and
delete/2
are in O(log n).
PSQs implement Enumerable
and Collectable
, so all your favorite functions
from Enum
and Stream
should work as expected.
Each entry in a PSQ has an associated priority and key. Map-like
operations, such as get/2
, use keys to find the entry; all entries in a PSQ
are unique by key. Ordered operations, such as pop/1
and Enum.to_list/1
,
use priority to determine order (with minimum first). Priorities need not be
unique by entry; entries with the same priority will be popped in unspecified
order.
Examples
There are two primary ways to determine a value’s priority and key in a
queue. The simplest is to start with an empty queue and input values with
priorities and keys directly, through put/4
:
iex> q = PSQ.new |> PSQ.put(:a, "foo", 2) |> PSQ.put(:b, "bar", 1)
iex> q |> PSQ.get(:a)
"foo"
iex> q |> PSQ.min
"bar"
Alternatively, you can specify mapper functions to determine key and priority for all entries in the queue. This is particularly useful for determining custom priorities. For example, here’s a simple method to use PSQs for max-queues:
iex> q = PSQ.new(&(-&1))
iex> q = [?a, ?b, ?c, ?d, ?e] |> Enum.into(q)
iex> q |> Enum.to_list
[?e, ?d, ?c, ?b, ?a]
Here’s a queue that orders strings by size, using downcased strings as keys:
iex> q = PSQ.new(&String.length/1, &String.downcase/1)
iex> q = ["How", "is", "your", "ocelot"] |> Enum.into(q)
iex> q |> Enum.to_list
["is", "How", "your", "ocelot"]
iex> q |> PSQ.get("how")
"How"
iex> q |> PSQ.get("How")
nil
Priority and key mappers are also useful if you’re inputting entries that are structs or maps and want to use particular fields as keys or priorities. For example:
iex> q = PSQ.new(&(&1[:priority]), &(&1[:key]))
iex> q = PSQ.put(q, %{priority: 5, key: 1})
iex> q = PSQ.put(q, %{priority: 2, key: 2})
iex> q = PSQ.put(q, %{priority: 1, key: 1})
iex> q |> PSQ.min
%{priority: 1, key: 1}
iex> q |> PSQ.get(1)
%{priority: 1, key: 1}
Summary
Functions
Returns a list of all values from q
where the value’s priority is less than
or equal to priority
Deletes the value associated with key
from q
Fetches the value for specified key
and returns in a tuple. Returns
:error
if the key does not exist
Fetches the value for specified key
Returns a new PSQ from list
Gets the value for specified key
. If the key does not exist, returns nil
Returns the value with the minimum priority from q
Returns a new empty PSQ
Returns and removes the value with the minimum priority from q
. The value
will be nil
if the queue is empty
Puts the given value
into the queue, using priority_mapper
and
key_mapper
to determine uniqueness/order (see new
)
Puts the given value
into the queue with specified key
and
priority
Types
key :: any
key_mapper :: (value -> key)
priority :: any
priority_mapper :: (value -> priority)
t :: %PSQ{key_mapper: key_mapper, priority_mapper: priority_mapper, tree: PSQ.Winner.t}
value :: any
Functions
Returns a list of all values from q
where the value’s priority is less than
or equal to priority
.
Examples
iex> PSQ.from_list([1, 3, 2, 5, 4]) |> PSQ.at_most(3)
[1, 2, 3]
Deletes the value associated with key
from q
.
If key
does not exist, returns q
unchanged.
Examples
iex> PSQ.from_list([3,1,2]) |> PSQ.delete(2) |> Enum.to_list
[1, 3]
iex> PSQ.from_list([3,1,2]) |> PSQ.delete(4) |> Enum.to_list
[1, 2, 3]
Fetches the value for specified key
and returns in a tuple. Returns
:error
if the key does not exist.
Examples
iex> PSQ.new |> PSQ.put(:a, 3, 1) |> PSQ.fetch(:a)
{:ok, 3}
iex> PSQ.new |> PSQ.put(:a, 3, 1) |> PSQ.fetch(:b)
:error
Fetches the value for specified key
.
If key
does not exist, a KeyError
is raised.
Examples
iex> PSQ.new |> PSQ.put(:a, 3, 1) |> PSQ.fetch!(:a)
3
iex> PSQ.new |> PSQ.put(:a, 3, 1) |> PSQ.fetch!(:b)
** (KeyError) key :b not found in: #PSQ<min:3 size:1>
Specs
from_list([value], priority_mapper, key_mapper) :: t
Returns a new PSQ from list
.
priority_mapper
and key_mapper
behave the same way as for new/2
.
Examples
iex> [2, 5, 4, 1, 3] |> PSQ.from_list |> Enum.to_list
[1, 2, 3, 4, 5]
Gets the value for specified key
. If the key does not exist, returns nil
.
Examples
iex> PSQ.new |> PSQ.put(:a, 3, 1) |> PSQ.get(:a)
3
iex> PSQ.new |> PSQ.put(:a, 3, 1) |> PSQ.get(:b)
nil
Returns the value with the minimum priority from q
.
Raises Enum.EmptyError
if the queue is empty.
Examples
iex> PSQ.from_list([-2, 3, -5]) |> PSQ.min
-5
iex> PSQ.from_list([-2, 3, -5], &(-&1)) |> PSQ.min
3
iex> PSQ.new |> PSQ.min
** (Enum.EmptyError) empty error
Specs
new(priority_mapper, key_mapper) :: t
Returns a new empty PSQ.
Optional params priority_mapper
and key_mapper
are functions to determine
keys and priorities from values. For example, to create a max-queue of numbers
instead of a min-queue, pass in &(-&1)
for priority_mapper
:
iex> PSQ.new(&(-&1)) |> PSQ.put(3) |> PSQ.put(5) |> PSQ.put(1) |> Enum.to_list
[5, 3, 1]
key_mapper
is useful if your values are structs where particular fields are
considered a unique key:
iex> q = PSQ.new(&(&1[:priority]), &(&1[:key]))
iex> q = q |> PSQ.put(%{key: 1, priority: 1})
iex> q = q |> PSQ.put(%{key: 1, priority: 3})
iex> q |> PSQ.get(1)
%{key: 1, priority: 3}
priority_mapper
and key_mapper
both default to the identity function.
Returns and removes the value with the minimum priority from q
. The value
will be nil
if the queue is empty.
Examples
iex> q = PSQ.from_list([3, 1])
iex> {min, q} = PSQ.pop(q)
iex> min
1
iex> {min, q} = PSQ.pop(q)
iex> min
3
iex> {min, q} = PSQ.pop(q)
iex> min
nil
iex> Enum.empty?(q)
true
Puts the given value
into the queue, using priority_mapper
and
key_mapper
to determine uniqueness/order (see new
).
If a value with the same key already exits in the queue, it will be replaced by the new value.
Examples
iex> q = PSQ.new(&(&1), &trunc/1)
iex> q = PSQ.put(q, 3.89)
iex> q = PSQ.put(q, 2.71)
iex> q = PSQ.put(q, 3.14)
iex> Enum.to_list(q)
[2.71, 3.14]
Puts the given value
into the queue with specified key
and
priority
.
When using this function (as opposed to put/2
, the queue’s
priority_mapper
and key_mapper
will be ignored. It is not recommended to
use both mappers and direct keys/priorities for the same queue.
Examples
iex> PSQ.new |> PSQ.put(:a, 1, 1) |> PSQ.put(:a, 2, 1) |> PSQ.get(:a)
2
iex> PSQ.new |> PSQ.put(:a, 1, 2) |> PSQ.put(:b, 2, 1) |> Enum.to_list
[2, 1]


public static final class R.attr
extends java.lang.Object
| Modifier and Type | Field and Description |
|---|---|
static int |
angle
May be a reference to another resource, in the form "
@[+][package:]type:name "
or to a theme attribute in the form "? |
static int |
drawer
Must be one or more (separated by '|') of the following constant values.
|
static int |
evaluator
May be a string value, using '\\;' to escape characters such as '\\n' or '\\uxxxx' for a unicode character.
|
static int |
generator
May be a string value, using '\\;' to escape characters such as '\\n' or '\\uxxxx' for a unicode character.
|
static int |
images_array
Must be a reference to another resource, in the form "
@[+][package:]type:name "
or to a theme attribute in the form "? |
static int |
loop
Must be a boolean value, either "
true " or "false ". |
static int |
maxAngle
May be a reference to another resource, in the form "
@[+][package:]type:name "
or to a theme attribute in the form "? |
static int |
maxZoom
May be a reference to another resource, in the form "
@[+][package:]type:name "
or to a theme attribute in the form "? |
static int |
minAngle
May be a reference to another resource, in the form "
@[+][package:]type:name "
or to a theme attribute in the form "? |
static int |
minZoom
May be a reference to another resource, in the form "
@[+][package:]type:name "
or to a theme attribute in the form "? |
static int |
speed
May be a reference to another resource, in the form "
@[+][package:]type:name "
or to a theme attribute in the form "? |
static int |
still_image_duration_millis
May be a reference to another resource, in the form "
@[+][package:]type:name "
or to a theme attribute in the form "? |
static int |
transition_duration_millis
May be a reference to another resource, in the form "
@[+][package:]type:name "
or to a theme attribute in the form "? |
static int |
zoom
May be a reference to another resource, in the form "
@[+][package:]type:name "
or to a theme attribute in the form "? |
| Constructor and Description |
|---|
R.attr() |
public static int angle
May be a reference to another resource, in the form "@[+][package:]type:name
"
or to a theme attribute in the form "?[package:][type:]name
".
May be a floating point value, such as "1.2
".
public static int drawer
Must be one or more (separated by '|') of the following constant values.
| Constant | Value | Description |
|---|---|---|
scale | 0 | |
translate | 1 | |
rotate | 2 |
public static int evaluator
May be a string value, using '\\;' to escape characters such as '\\n' or '\\uxxxx' for a unicode character.
This may also be a reference to a resource (in the form
"@[package:]type:name
") or
theme attribute (in the form
"?[package:][type:]name
")
containing a value of this type.
May be one of the following constant values.
| Constant | Value | Description |
|---|---|---|
simple | 0 | |
scrollBased | 1 | |
timeBased | 2 | |
gyroscopeBased | 3 |
public static int generator
May be a string value, using '\\;' to escape characters such as '\\n' or '\\uxxxx' for a unicode character.
This may also be a reference to a resource (in the form
"@[package:]type:name
") or
theme attribute (in the form
"?[package:][type:]name
")
containing a value of this type.
May be one of the following constant values.
| Constant | Value | Description |
|---|---|---|
base | 0 | |
angled | 1 | |
zoomed | 2 |
public static int images_array
Must be a reference to another resource, in the form "@[+][package:]type:name
"
or to a theme attribute in the form "?[package:][type:]name
".
public static int loop
Must be a boolean value, either "true
" or "false
".
This may also be a reference to a resource (in the form
"@[package:]type:name
") or
theme attribute (in the form
"?[package:][type:]name
")
containing a value of this type.
public static int maxAngle
May be a reference to another resource, in the form "@[+][package:]type:name
"
or to a theme attribute in the form "?[package:][type:]name
".
May be a floating point value, such as "1.2
".
public static int maxZoom
May be a reference to another resource, in the form "@[+][package:]type:name
"
or to a theme attribute in the form "?[package:][type:]name
".
May be a floating point value, such as "1.2
".
public static int minAngle
May be a reference to another resource, in the form "@[+][package:]type:name
"
or to a theme attribute in the form "?[package:][type:]name
".
May be a floating point value, such as "1.2
".
public static int minZoom
May be a reference to another resource, in the form "@[+][package:]type:name
"
or to a theme attribute in the form "?[package:][type:]name
".
May be a floating point value, such as "1.2
".
public static int speed
May be a reference to another resource, in the form "@[+][package:]type:name
"
or to a theme attribute in the form "?[package:][type:]name
".
May be a floating point value, such as "1.2
".
public static int still_image_duration_millis
May be a reference to another resource, in the form "@[+][package:]type:name
"
or to a theme attribute in the form "?[package:][type:]name
".
May be an integer value, such as "100
".
public static int transition_duration_millis
May be a reference to another resource, in the form "@[+][package:]type:name
"
or to a theme attribute in the form "?[package:][type:]name
".
May be an integer value, such as "100
".
public static int zoom
May be a reference to another resource, in the form "@[+][package:]type:name
"
or to a theme attribute in the form "?[package:][type:]name
".
May be a floating point value, such as "1.2
".


A Pairing Programming Website
where you can write code with your partner’s observation and suggestions.


Project Jupyter was born out of the IPython Project in 2014 as it evolved to support interactive data science and scientific computing across all programming languages.
Our vibrant community empowers us to create an amazing platform. Dynamic developers, cutting edge scientists as well as everyday users work together to further Jupyter's best-in-class tools.
Our team is primarily led by 10 steering committee members who ultimately make the final decisions.
Robust, community driven development with institutional backing.


Orchard Skills
Orchard Skills specializes in handcrafted Web Solutions utilizing the Orchard Core CMS modular framework.


WITNESS LIST
County Affairs Committee
March 14, 2013 - 10:30 AM or upon final adjourn./recess
For:
LeBouef, Lynn (Self; Tomball Hospital Authority)
Reed, Kevin (Tomball Hospital Authority)
Registering, but not testifying:
For:
Claymon, Jennifer (Smithville Hospital Authority)
McBeath, Don (TORCH)
Williamson (Self)
For:
Del Bosque, Noe (Self; Midland Memorial Hospital)
Registering, but not testifying:
For:
Yanas, Chris (Teaching Hospitals of Texas)
For:
Claymon, Jennifer (Eastland Memorial Hospital District)
Matthews, Ted (Eastland Memorial Hospital District)
Registering, but not testifying:
For:
McBeath, Don (TORCH)
For:
Bridges, Jane Ann (Nacogdoches County Hospital District)
Knight, Beth (Nacogdoches County Hospital District)
Sanaie, Kandice (Texas association of business)
Walker, Larry (Nacogdoches County Hospital District)
Against:
Finch, Dan (Texas Medical Association)
Registering, but not testifying:
For:
McBeath, Don (TORCH)
1
WITNESS LIST
Registering, but not testifying:
For:
McBeath, Don (TORCH)
For:
Boyle, Jim (East Aldine Management District)
Eckstein, Deece (Travis County Commissioners Court)
Frederick, David (Texans against monopolies' excessive rates)
Houston, Joshua (Texas Impact)
Kneeland, Linda (Self; Huntington Estates)
Lee, Donald (Texas Conference of Urban Counties)
Lewis (Self; Pine trails community improvement association)
Lewis, Helen (Self; Pine trails community improvement association)
Millikan (Self; Kerr community action group)
Westfall, Larry (Self; Kerrville south community action group)
Against:
McClellan, John (SouthWest Water Company)
Zeppa, Mark (Self)
On:
Holcomb, Doug (TCEQ)
Registering, but not testifying:
For:
Coelho, Leonardo (Travis County)
Mendez, Mark (Tarrant County)
Thompson, Rick (Texas Association of Counties)
Against:
Scheibelhut, Kurt (Aqua Texas Inc.)
Scheibelhut, Kurt (Aqua Texas, Inc.)
For:
Claymon, Jennifer (McCulloch County Hospital District)
JONES, TIM (McCulloch County Hospital District)
Registering, but not testifying:
For:
McBeath, Don (TORCH)
For:
Claymon, Jennifer (McCamey County Hospital District)
Ramirez, Jaime (Mccamey county hospital district)
2
WITNESS LIST
For:
Ramirez, Jaime (Mccamey county hospital district)
Registering, but not testifying:
For:
McBeath, Don (TORCH)
3


The cool and scary part of Kryo is that you can use it to serialize or deserialize any Java types, not necessarily those that are marked with java.io.Serializable. This makes development a lot easier for many situations, like serializing already existing stuff, or serializing stuff you can’t control.
When you use Kryo to deserialize an object, you must declare which type you're expecting. Here’s an example:
// serializing
Kryo kryo = new Kryo();
AcmeMessage message = buildAcmeMessage(); // some domain object
Output out = new Output(response.getOutputStream())
kryo.writeObject(out, myObject);
// deserializing
Input in = new Input(request.getInputStream());
AcmeMessage message = kryo.readObject(in, AcmeMessage.class);
Bait and Switch
This one was actually easy to get around. In the real world, any domain object that folks send back and forth will have collections -- maps, lists, arrays, or something like that. Let's consider the following example object:
/* AcmeMessage.java */
private List<AcmeRecipient> recipients;
Everywhere that matters, that <AcmeRecipient> bit of code does not exist. The only place it does matter is compile time. I live in the runtime, where exploits occur. This means for our purposes, that code should be understood as this instead:
/* AcmeMessage.java */
private List<Object> recipients;
So, if our target app is deserializing an AcmeMessage type, we can stuff some unexpected, arbitrary types into the recipients field, because all types extend Object. Now, much like with the seriapalooza attacks, the types the attacker uses must still be on the classpath of the victim application, libraries, or server.
Of course, if the app ever tries to use one of those objects as an AcmeMessage, it will blow up -- but our attack should be reaching fruition before that time.
After looking at the code, we appear to only have one rule: the class must have a no-arg constructor. Senses tingling now.
At a high level, Kryo deserializes with this pattern:
Get the zero-arg constructor for the given type
If it’s private, mark it as accessible
Call the constructor
For every field in the type:
Deserialize the field passed in the message (recurse)
Assign the field to the new type created in #3
There are ways to override this existing behavior with even more abusable behavior, but let’s focus on the default settings.
If you let developers specify arbitrary behaviors in their types’ Serializable#readObject() methods, you’ll be able to chain their side effects together so that they eventually add up to disaster. And that’s what happened.
And this isn’t very different.
I can submit an arbitrary class that’s on your classpath, and you (the victim app) will call its constructor. Developers can put whatever they want in their constructors. They’re not guaranteed to avoid having side effects.


Last year we released T-Pot 15.03 as open source and we received lots of positive feedback and naturally feature requests which encouraged us to continue development and share our work as open source and are proud to present to you …
T-Pot 16.03
T-Pot 16.03 is based on
and includes dockerized versions of the following honeypots
Furthermore we use the following tools
- suricata a Network Security Monitoring engine and the
- ELK stack to beautifully visualize all the events captured by T-Pot.
TL;DR
- Meet the system requirements. The T-Pot installation needs at least 4 GB RAM and 64 GB free disk space as well as a working internet connection.
- Download the tpot.iso or create it yourself.
- Install the system in a VM or on physical hardware with internet access.
- Enjoy your favorite beverage - watch and analyze.
-
Table of Contents
- Changelog
- Technical Concept
- System Requirements
- Installation
- Options
- Roadmap
- Disclaimer
- FAQ
- Contact
- Licenses
- Credits
- Stay tuned
- Fun Fact
Changelog
- Docker was updated to the latest 1.10.x release
- ELK was updated to the latest Kibana 4.4.x, Elasticsearch 2.2.x and Logstash 2.2.x releases.
- More than 100 Visualizations compiled to 12 individual Dashboards for every honeypot now allow you to monitor the honeypot events captured on your T-Pot installation; a huge improvement over T-Pot 15.03 which was only capable of showing Suricata NSM events.
-
Thanks to Kibana 4.x SSH port forwarding can now utilize any user defined local port
ssh -p 64295 -l tsec -N -L4711:<IP_ADDRESS>:64296 <yourHoneypotIPaddress>
- IP to AS Lookups are now provided within Kibana dashboard, as well as some smart links to research IP reputation, Suricata Rules or AS information when in Discover mode.
- ElasticSearch indexes will now be kept for <=90 days, the time period may be adjusted in
/etc/crontab
. - Suricata was updated to the latest 3.0 version including the latest Emerging Threats community ruleset.
- P0f is now part of the Suricata container, passively fingerprinting and guessing the involving OS.
- Conpot, ElasticPot and eMobility are being introduced as new honeypots in T-Pot.
- Cowrie replaces Kippo as SSH honeypot since it offers huge improvements over Kippo such as (SFTP-support, exec-support, SSH-tunneling, advanced logging, JSON logging, etc.).
- With Conpot and eMobility we are now offering an experimental Industrial Installation Option.
- T-Pot Image Creator was completely rewritten to offer a more convenient experience for creating your personal T-Pot image (802.1x authentication, proxy support, public key for SSH and pre defined NTP server). Docker images can be preloaded using the experimental
getimages.sh
script and will be exported to the installation image. - T-Pot itself and all of its containers are now based on Ubuntu Server 14.04.4 LTS and thus automatically benefit from the latest features introduced by Cannonical for Ubuntu Server.
- Docker containers are now storing important log data outside the container in
/data/<container-name>
allowing easy access from the host and improving container startup and restart speed. - The upstart scripts have been rewritten to support storing data on the host either volatile (default) or persistent (
/data/persistence.on
). - Depending on the honeypot EWS-Poster now supports extracting some logging information as JSON.
- The
/usr/bin/backup_elk.sh
allows you to backup all ElasticSearch indexes including.kibana
andlogstash
which contain all information to restore your data on a freshly installed machine simply by enteringtar xvfz <backup-name>.tgz -C /
. - The
enable_ssh.sh
script has been removed and is now part of a more convenient2fa_enable.sh
script. - Size limits for the
/data
have been lifted and swap space is now 8 GB. - The number of installation reboots has been reduced to 2. The first to finish the initial Ubuntu Server installation and the second after setting up T-Pot and its dependencies.
- Some packages are now be installed directly from the installation image instead of downloading them.
- [Update 20160313] - T-Pot host
/var/log/syslog
and/var/log/auth.log
will now be forwarded to the ELK-stack.
Technical Concept
T-Pot is based on Ubuntu Server 14.04.4 LTS.
The honeypot daemons as well as other support components being used have been paravirtualized using docker.
This allowed us to run multiple honeypot daemons on the same network interface without problems make the entire system very low maintenance.
The encapsulation of the honeypot daemons in docker provides a good isolation of the runtime environments and easy update mechanisms.
In T-Pot we combine the dockerized honeypots conpot, cowrie, dionaea, elasticpot, emobility, glastopf and honeytrap with suricata a Network Security Monitoring engine and the ELK stack to beautifully visualize all the events captured by T-Pot. Events will be correlated by our own data submission tool ewsposter which also supports Honeynet project hpfeeds honeypot data sharing.
All data in docker is volatile. Once a docker container crashes, all data produced within its environment is gone and a fresh instance is restarted. Hence, for some data that needs to be persistent, i.e. config files, we have a persistent storage /data/
on the host in order to make it available and persistent across container or system restarts.
Important log data is now also stored outside the container in /data/<container-name>
allowing easy access to logs from within the host and. The upstart scripts have been adjusted to support storing data on the host either volatile (default) or persistent (/data/persistence.on
).
Basically, what happens when the system is booted up is the following:
- start host system
- start all the necessary services (i.e. docker-engine)
- start all docker containers (honeypots, nms, elk)
Within the T-Pot project, we provide all the tools and documentation necessary to build your own honeypot system and contribute to our community data view, a separate channel on our Sicherheitstacho that is powered by T-Pot community data.
The source code and configuration files are stored in individual GitHub repositories, which are linked below. The docker images are tailored to be run in this environment. If you want to run the docker images separately, make sure you study the upstart scripts, as they provide an insight on how we configured them.
The individual docker configurations etc. we used can be found here:
System Requirements
Depending on your installation type, whether you install on real hardware or in a virtual machine, make sure your designated T-Pot system meets the following requirements:
T-Pot Installation (Cowrie, Dionaea, ElasticPot, Glastopf, Honeytrap, ELK, Suricata+P0f)
When installing the T-Pot ISO image, make sure the target system (physical/virtual) meets the following minimum requirements:
- 4 GB RAM (6-8 GB recommended)
- 64 GB disk (128 GB SSD recommended)
- Network via DHCP
- A working internet connection
Sensor Installation (Cowrie, Dionaea, ElasticPot, Glastopf, Honeytrap)
This installation type is currently only available via ISO Creator. When installing the T-Pot ISO image, make sure the target system (physical/virtual) meets the following minimum requirements:
- 3 GB RAM (4-6 GB recommended)
- 64 GB disk (64 GB SSD recommended)
- Network via DHCP
- A working internet connection
Industrial Installation (ConPot, eMobility, ELK, Suricata+P0f)
This installation type is currently only available via ISO Creator and remains experimental. When installing the T-Pot ISO image, make sure the target system (physical/virtual) meets the following minimum requirements:
- 4 GB RAM (8 GB recommended)
- 64 GB disk (128 GB SSD recommended)
- Network via DHCP
- A working internet connection
Everything Installation (Everything)
This installation type is currently only available via ISO Creator. When installing the T-Pot ISO image, make sure the target system (physical/virtual) meets the following minimum requirements:
- 8 GB RAM
- 128 GB disk or larger (128 GB SSD or larger recommended)
- Network via DHCP
- A working internet connection
Installation
The installation of T-Pot is straight forward. Please be advised that you should have an internet connection up and running as all all the docker images for the chosen installation type need to be pulled from docker hub.
Firstly, decide if you want to download our prebuilt installation ISO image tpot.iso or create it yourself.
Secondly, decide where you want to let the system run: real hardware or in a virtual machine?
Prebuilt ISO Image
We provide an installation ISO image for download (~600MB), which is created using the same tool you can use yourself in order to create your own image. It will basically just save you some time downloading components and creating the ISO image.
You can download the prebuilt installation image here and jump to the installation section. The ISO image is hosted by our friends from Strato / Cronon.
shasum tpot.iso
7f4c5d91ab620866b661fcaa7c1778f473e2a07d tpot.iso
Create your own ISO Image
For transparency reasons and to give you the ability to customize your install, we provide you the ISO Creator that enables you to create your own ISO installation image.
Requirements to create the ISO image:
- Ubuntu 14.04.4 or newer as host system (others may work, but remain untested)
- 4GB of free memory
- 32GB of free storage
- A working internet connection
How to create the ISO image:
-
Clone the repository and enter it.
git clone https://github.com/dtag-dev-sec/tpotce.git cd tpotce
-
Invoke the script that builds the ISO image. The script will download and install dependencies necessary to build the image on the invoking machine. It will further download the ubuntu base image (~600MB) which T-Pot is based on.
sudo ./makeiso.sh
After a successful build, you will find the ISO image tpot.iso
in your directory.
Running in VM
You may want to run T-Pot in a virtualized environment. The virtual system configuration depends on your virtualization provider.
We successfully tested T-Pot with VirtualBox and VMWare with just little modifications to the default machine configurations.
It is important to make sure you meet the system requirements and assign a virtual harddisk >=64 GB, >=4 GB RAM and bridged networking to T-Pot.
You need to enable promiscuous mode for the network interface for suricata to work properly. Make sure you enable it during configuration.
If you want to use a wifi card as primary NIC for T-Pot, please remind that not all network interface drivers support all wireless cards. E.g. in VirtualBox, you then have to choose the “MT SERVER” model of the NIC.
Lastly, mount the tpot.iso
ISO to the VM and continue with the installation.
You can now jump here.
Running on Hardware
If you decide to run T-Pot on dedicated hardware, just follow these steps:
- Burn a CD from the ISO image or make a bootable USB stick using the image.
 There are various Windows GUI tools available, e.g. this tip might help you.
On Linux or MacOS you can use the tool dd or create the USB stick with T-Pot’s ISO Creator. - Boot from the USB stick and install.
Please note: We will ensure the compatibility with the Intel NUC platform, as we really like the form factor, looks and build quality.
First Run
The installation requires very little interaction, only some locales and keyboard settings have to be answered. Everything else will be configured automatically. The system will reboot two times. Make sure it can access the internet as it needs to download the updates and the dockerized honeypot components. Depending on your network connection and the chosen installation type, the installation may take some time. During our tests (50Mbit down, 10Mbit up), the installation was usually finished within <=30 minutes.
Once the installation is finished, the system will automatically reboot and you will be presented with the T-Pot login screen. The user credentials for the first login are:
- user: tsec
- pass: tsec
You will need to set a new password after first login.
All honeypot services are started automatically.
System Placement
Make sure your system is reachable through the internet. Otherwise it will not capture any attacks, other than the ones from your hostile internal network! We recommend you put it in an unfiltered zone, where all TCP and UDP traffic is forwarded to T-Pot’s network interface.
If you are behind a NAT gateway (e.g. home router), here is a list of ports that should be forwarded to T-Pot.
| Honeypot | Transport | Forwarded ports |
|---|---|---|
| conpot | TCP | 81, 102, 502 |
| conpot | UDP | 161 |
| cowrie | TCP | 22 |
| dionaea | TCP | 21, 42, 135, 443, 445, 1433, 3306, 5060, 5061, 8081 |
| dionaea | UDP | 69, 5060 |
| elasticpot | TCP | 9200 |
| emobility | TCP | 8080 |
| glastopf | TCP | 80 |
| honeytrap | TCP | 25, 110, 139, 3389, 4444, 4899, 5900, 21000 |
Basically, you can forward as many TCP ports as you want, as honeytrap dynamically binds any TCP port that is not covered by the other honeypot daemons.
In case you need external SSH access, forward TCP port 64295 to T-Pot, see below.
T-Pot requires outgoing http and https connections for updates (ubuntu, docker) and attack submission (ewsposter, hpfeeds).
Options
The system is designed to run without any interaction or maintenance and automatically contribute to the community.
We know, for some this may not be enough. So here come some ways to further inspect the system and change configuration parameters.
Enabling 2FA & SSH
By default, the SSH daemon is disabled. However, if you want to be able to login remotely via SSH and / or enable two-factor authentication (2fa) by using an authenticator app i.e. Google Authenticator just run the following script as the user tsec. Do not run it as root or via sudo. Otherwise the setup of the two factor authentication will be bound to the user root who is not permitted to login remotely.
~/2fa_enable.sh
Afterwards you can login via SSH using the password you set for the user tsec and use the authenticator token as the second authentication factor.
The script will also enable the SSH daemon on tcp/64295. It is configured to prevent password login and use pubkey-authentication or challenge-response instead. We recommend using pubkey-authentication; just copy your SSH keyfile to /home/tsec/.ssh/authorized_keys
and set the appropriate permissions (chmod 600 authorized_keys
) as well as the correct ownership (chown tsec:tsec authorized_keys
).
Kibana Dashboard
To access the kibana dashboard, ensure you have enabled SSH on T-Pot. If you have you can use SSH port forwarding to access the kibana dashboard (make sure you leave the terminal open).
ssh -p 64295 -l tsec -N -L8080:<IP_ADDRESS>:64296 <yourHoneypotIPaddress>
Finally, open a web browser and access http://<IP_ADDRESS>:8080. The kibana dashboard can be customized to fit your needs. By default, we haven’t added any filtering, because the filters depend on your setup. E.g. you might want to filter out your incoming administrative ssh connections and connections to update servers.
Maintenance
As mentioned before, the system was designed to be low maintenance. Basically, there is nothing you have to do but let it run. If one of the dockerized daemon fails, it will restart. If this fails, the regarding upstart job will be restarted.
If you run into any problems, a reboot may fix it. ;)
If new versions of the components involved appear, we will test them and build new docker images. Those new docker images will be pushed to docker hub and downloaded to T-Pot and activated accordingly.
Community Data Submission
We provide T-Pot in order to make it accessible to all parties interested in honeypot deployment. By default, the data captured is submitted to a community backend. This community backend uses the data to feed a community data view, a separate channel on our own Sicherheitstacho, which is powered by our own set of honeypots.
You may opt out the submission to our community server by disabling it in the [EWS]
-section of the config file /data/ews/conf/ews.cfg
.
Further we support hpfeeds. It is disabled by default since you need to supply a channel you want to post to and enter your user credentials. To enable hpfeeds, edit the config file /data/ews/conf/ews.cfg
, section [HPFEED]
and set it to true.
Data is submitted in a structured ews-format, a XML stucture. Hence, you can parse out the information that is relevant to you.
We encourage you not to disable the data submission as it is the main purpose of the community approach - as you all know sharing is caring 😍
The /data/ews/conf/ews.cfg
file contains many configuration parameters required for the system to run. You can - if you want - add an email address, that will be included with your submissions, in order to be able to identify your requests later. Further you can add a proxy.
Please do not change anything other than those settings and only if you absolutely need to. Otherwise, the system may not work as expected.
Roadmap
As with every development there is always room for improvements …
- Move to Ubuntu Server 16.04 LTS
- Further improve on JSON logging
- Move from upstart to systemd (only if necessary)
- Bump ELK-stack to 5.0
- Move from Glastopf to SNARE
- Work on a upgrade strategy
- Improve backup script, include restore script
- Tweaking 😎
Some features may be provided with updated docker images, others may require some hands on from your side.
You are always invited to participate in development on our GitHub page.
Disclaimer
- We don’t have access to your system. So we cannot remote-assist when you break your configuration. But you can simply reinstall.
- The software was designed with best effort security, not to be in stealth mode. Because then, we probably would not be able to provide those kind of honeypot services.
 Choose your deployment wisely as a system compromise can never be ruled out.
- Honeypots should - by design - not host any sensitive data. Make sure you don’t add any.
- By default, your data is submitted to the community dashboard. You can disable this in the config. But hey, wouldn’t it be better to contribute to the community?
- By default, hpfeeds submission is disabled. You can enable it in the config section for hpfeeds. This is due to the nature of hpfeeds. We do not want to spam any channel, so you can choose where to post your data and who to share it with.
- Malware submission is enabled by default but malware is currently not processed on the submission backend. This may be added later, but can also be disabled in the
ews.cfg
config file. - The system restarts the docker containers every night to avoid clutter and reduce disk consumption. All data in the container is then reset. The data displayed in kibana is kept for <=90 days.
FAQ
Please report any issues or questions on our GitHub issue list, so the community can participate.
Contact
We provide the software as is in a Community Edition format. T-Pot is designed to run out of the box and with zero maintenance involved.
Please understand that we cannot provide support on an individual basis. We will try to address questions, bugs and problems on our GitHub issue list.
Licenses
The software that T-Pot is built on, uses the following licenses.
 Our thanks are extended but not limited to the following people and organizations:
The developers and development communities of
- conpot
- cowrie
- dionaea
- docker
- elasticpot
- elasticsearch
- emobility
- ewsposter
- glastopf
- heatmap
- honeytrap
- kibana
- logstash
- p0f
- suricata
- tagcloud
- ubuntu
The following companies and organizations
… and of course you for joining the community!
Stay tuned …
We will be releasing a new version of T-Pot about every 6 months.
Fun Fact
Coffee just does not cut it anymore which is why we needed a different caffeine source and consumed 203 bottles of Club Mate during the development of T-Pot 16.03 😇


SHRED(1) User Commands SHRED(1) NAME shred - overwrite a file to hide its contents, and optionally delete it SYNOPSIS shred [OPTION]... FILE... DESCRIPTION Overwrite the specified FILE(s) repeatedly, in order to make it harder for even very expensive hardware probing to recover the data. Mandatory arguments to long options are mandatory for short options too. -f, --force change permissions to allow writing if necessary -n, --iterations=N overwrite N times instead of the default (3) --random-source=FILE get random bytes from FILE -s, --size=N shred this many bytes (suffixes like K, M, G accepted) -u, --remove truncate and remove file after overwriting -v, --verbose show progress -x, --exact do not round file sizes up to the next full block; this is the default for non-regular files -z, --zero add a final overwrite with zeros to hide shredding --help display this help and exit --version output version information and exit If FILE is -, shred standard output. Delete FILE(s) if --remove (-u) is specified. The default is not to remove the files because it is common to operate on device files like /dev/hda, and those files usually should not be removed. When operating on regular files, most people use the --remove option. CAUTION: Note that shred relies on a very important assumption: that the file system overwrites data in place. This is the traditional way to do things, but many modern file system designs do not satisfy this assump‐ tion. The following are examples of file systems on which shred is not effective, or is not guaranteed to be effective in all file system modes: * log-structured or journaled file systems, such as those supplied with AIX and Solaris (and JFS, ReiserFS, XFS, Ext3, etc.) * file systems that write redundant data and carry on even if some writes fail, such as RAID-based file systems * file systems that make snapshots, such as Network Appliance's NFS server * file systems that cache in temporary locations, such as NFS version 3 clients * compressed file systems In the case of ext3 file systems, the above disclaimer applies (and shred is thus of limited effectiveness) only in data=journal mode, which jour‐ nals file data in addition to just metadata. In both the data=ordered (default) and data=writeback modes, shred works as usual. Ext3 journal‐ ing modes can be changed by adding the data=something option to the mount options for a particular file system in the /etc/fstab file, as docu‐ mented in the mount man page (man mount). In addition, file system backups and remote mirrors may contain copies of the file that cannot be removed, and that will allow a shredded file to be recovered later. AUTHOR Written by Colin Plumb. REPORTING BUGS Report shred bugs to<EMAIL_ADDRESS>GNU coreutils home page: <http://www.gnu.org/software/coreutils/> General help using GNU software: <http://www.gnu.org/gethelp/> Report shred translation bugs to <http://translationproject.org/team/> COPYRIGHT Copyright © 2011 Free Software Foundation, Inc. License GPLv3+: GNU GPL version 3 or later <http://gnu.org/licenses/gpl.html>. This is free software: you are free to change and redistribute it. There is NO WARRANTY, to the extent permitted by law. SEE ALSO The full documentation for shred is maintained as a Texinfo manual. If the info and shred programs are properly installed at your site, the com‐ mand info coreutils 'shred invocation' should give you access to the complete manual. GNU coreutils 8.12.197-032bb September 2011 SHRED(1)


Order By
Search Results
{% for author in authors_list %}
Basic
- {{ author.email }}
- {{ author.first_name }}
- {{ author.last_name }}
- Free SSL Certificate
- 1 Included Domain
- 1 Included Domain
- 1 Included Domain
- 1 Included Domain
- 1 Included Domain
{% endfor %}


--- title: How to Become a Data Scientist for Free date: '2015-07-17T19:00:04+05:30' tags: - ml tumblr_url: https://sureshshanmugam.com/post/124324783937/how-to-become-a-data-scientist-for-free --- How to Become a Data Scientist for Free


Ketchup/Ketchdown (2018)
Ketchup packets mounted on wood.
Night Rocker(2013)
Interactive wood sculpture
26"x 23"x 17 ½"
Spare Table(2013)
Found leaves, Found wood
31"x 33"x 22"
Screw The Money(2013)
Wood, $10 in coins, Screws
34"x 27" x 9" (drawer is 1 ¾" deep)
The drawer has coins on the bottom, but isn’t deep enough to get a
hand around the money. Drywall screws are scattered throughout the coins.
Keeping Up with the Joneses(2012)
wood, clothesline, pulleys
Crosses: 7'x 4’ x 4" : spaced 11’ across
Hold‘Um/Fold'um (2011)
Plaster cast of my arms, arms casted using alginate
Brand(2010)
¼" Steel round-stock, Gold-Leaf, Racket grip-tape
19"x 6 ¼"
Jerk/Tug (2013)
Wood
34"x 99"x 24"
Interactive wood sculpture- The dresser was created to be too wide to open in
motion by yourself. The knobs are too far apart, and the drawers can only be cleanly opened when a person is pulling each side.


Camera that uses
[link:https://en.wikipedia.org/wiki/Orthographic_projection orthographic projection].
In this projection mode, an object's size in the rendered image stays
constant regardless of its distance from the camera.
This can be useful for rendering 2D scenes and UI elements, amongst other
things.
const camera = new THREE.OrthographicCamera( width / - 2, width / 2, height / 2, height / - 2, 1, 1000 );
scene.add( camera );
[example:webgl_camera camera ]
[example:webgl_interactive_cubes_ortho interactive / cubes / ortho ]
[example:webgl_materials_cubemap_dynamic materials / cubemap / dynamic]
[example:webgl_postprocessing_advanced postprocessing / advanced ]
[example:webgl_postprocessing_dof2 postprocessing / dof2 ]
[example:webgl_postprocessing_godrays postprocessing / godrays ]
[example:webgl_rtt rtt ]
[example:webgl_shadowmap shadowmap ]
left — Camera frustum left plane.
right — Camera frustum right plane.
top — Camera frustum top plane.
bottom — Camera frustum bottom plane.
near — Camera frustum near plane.
far — Camera frustum far plane.
Together these define the camera's
[link:https://en.wikipedia.org/wiki/Viewing_frustum viewing frustum].
See the base [page:Camera] class for common properties.
Note that after making changes to most of these properties you will have
to call [page:OrthographicCamera.updateProjectionMatrix .updateProjectionMatrix] for the changes to take effect.
Camera frustum bottom plane.
Camera frustum far plane. Default is `2000`.
Must be greater than the current value of [page:.near near] plane.
Read-only flag to check if a given object is of type [name].
Camera frustum left plane.
Camera frustum near plane. Default is `0.1`.
The valid range is between `0` and the current value of the [page:.far far] plane. Note that, unlike for the [page:PerspectiveCamera], `0` is a
valid value for an OrthographicCamera's near plane.
Camera frustum right plane.
Camera frustum top plane.
Set by [page:OrthographicCamera.setViewOffset setViewOffset]. Default is `null`.
Gets or sets the zoom factor of the camera. Default is `1`.
See the base [page:Camera] class for common methods.
fullWidth — full width of multiview setup
fullHeight — full height of multiview setup
x — horizontal offset of subcamera
y — vertical offset of subcamera
width — width of subcamera
height — height of subcamera
Sets an offset in a larger
[link:https://en.wikipedia.org/wiki/Viewing_frustum viewing frustum]. This
is useful for multi-window or multi-monitor/multi-machine setups. For an
example on how to use it see [page:PerspectiveCamera.setViewOffset PerspectiveCamera].
Removes any offset set by the .setViewOffset method.
Updates the camera projection matrix. Must be called after any change of parameters.
meta -- object containing metadata such as textures or images in objects'
descendants.
Convert the camera to three.js
[link:https://github.com/mrdoob/three.js/wiki/JSON-Object-Scene-format-4 JSON Object/Scene format].
[link:https://github.com/mrdoob/three.js/blob/master/src/[path].js src/[path].js]


VW CEO says new ID.3 car 40% cheaper to build than electric Golf
FRANKFURT (Reuters) - Volkswagen’s (VOWG_p.DE) new ID.3 electric vehicle will be 40% cheaper to build than the electric version of its Golf model, Chief Executive Herbert Diess told investors on Monday.
The battery in the new ID.3 can be used to add structural rigidity to the body and the modular layout of the battery allows for advantages in packaging and economies of scale.
“If you focus on an electric platform, all in all it accounts for a 40% reduction against the predecessor electric Golf,” Diess said. “Most of it from cells and the battery system. Around 5-10% comes from dedicating an entire plant to electric vehicles.”
This cost reduction is one of the reasons that Volkswagen is confident it can shift from making combustion-engined to electric cars without eroding the company’s profit margin, VW said.


Painted Desert [av69], desert, in Imperia, peasants: 1068
Last updated Turn #138
Painted Desert [av69], desert, in Imperia, peasants: 1068
------------------------------------------------------------------------
26: Pack of wolves [js4y], wolves, number: 7, arrived from the west.
27: Stack of nazgul [jf1p], nazgul, number: 2, arrived from the west.
28: Pack of wolves [js4y], wolves, number: 7, went west.
29: Stack of nazgul [jf1p], nazgul, number: 2, went north.
29: Stack of nazgul [br4m], nazgul, arrived from the north.
30: The population grows by 31 peasants.
Routes leaving Painted Desert:
North, desert, to Painted Desert [au69], 8 days
East, desert, to Painted Desert [av70], 8 days
Garrison [ed8z], garrison, Imperial Empire, with ten peasants
Border closed.
South, to Ocean [aw69], Crystal Sea, 2 days
West, desert, to Painted Desert [av68], 8 days
Inner locations:
Sand pit [ae4r], sand pit, 1 day
Seen here:
Stack of nazgul [dc5s], nazgul, number: 3
Pack of wolves [js4y], wolves, number: 7
Stack of nazgul [jf1p], nazgul


PgCognition documentation¶
DatabaseClient¶
-
class
PgCognition.
DatabaseClient
(event=None, config={}, client_type='instance')¶ - Keyword Arguments
client_type – (
str
) – “serverless” for Aurora Serverless, otherwise “instance”. Defaults to “instance”event (
list or dict
) – event argument from Lambda function- config (
dict
) – configuration options region – (
str
, optional) aws region. Defaults to us-east-1database – (
str
) database namedatabaseArn – (
str
) arn of the databasedatabaseSecretArn – (optional) Arn of the database secret to use. Defaults to caller’s secret
account – (optional) Account number where secrets live. Defaults to account number resolved by cognition_functions.getCallerAccount()
secretsPath – (optional) Path to AWS secrets. Defaults to rds-db-credentials/
roleOverrides – (
dict
, optional) a dictionary of {<role arn>: <secret name>} to match for authassumedRoleOverrides – (
dict
, optional) a dictionary of {<role name>: <secret name>} to match for auth. Used to auth assumed roles (cli users for instance)
- config (
- Returns
An instance of PgCognition.DatabaseClient
- Return type
- Environment
Options required in config can be omitted if they exist in os.environ. Options to be taken from the environment should have their names specified in all caps.
Example with a standard Postgres database
from PgCognition import DatabaseClient config = { "dbname": "mydb", "user": "myuser", "host": "localhost", "password": "password" } c = DatabaseClient(config=config, client_type="instance") res = c.runQuery("SELECT * FROM mytable", switch_role="less_privileged_role")
Example with a Aurora Serverless
from PgCognition import DatabaseClient config = { "database": "mydb", "account": 12345678, "databaseArn": "arn:aws:rds:us-east-1:123456789:db:mydb", "assumedRoleOverrides": {"administrator": "root-secret", "developer": "root-secret"}, "region": "us-east-1", "secretsPath": "rds-db-credentials" } c = DatabaseClient(event=event, config=config) res = c.runQuery("SELECT * FROM mytable", switch_role="less_privileged_role")
-
cloneSchema
(src, dest)¶ Clones a schema with all objects and permissions
- Parameters
src (str) – The source schema to clone
dest (str) – The name of the destination schema
- Returns
None
- Return type
None
Example
from PgCognition import DatabaseClient config = { "dbname": "mydb", "user": "myuser", "host": "localhost", "password": "password" } c = DatabaseClient(config=config, client_type="instance") c.cloneSchema("tenant_template", "new_tenant")
-
close
()¶ Close the database connection for client_type of “instance”
- Returns
None
- Return type
None
This will throw an AttributeError if client_type is not “instance”
-
createCognitionUser
(email=None)¶ Creates a database user that is tied to an application user in cognition.users table. Normally run as part of Cognito’s PostSignup hook.
- Keyword Arguments
email (
str
) – Override the email address from self.event[“user”][“email”]
- Returns
Dictionary containing new user’s database credentials and corresponding user from cognition.users table
- Return type
dict
This method does not just create a database user/role. It marries a user in the cognition.users table to a new database user. If the email address passed to the method does not exist in the cognition.users table then an Exception will be raised. If you want to create arbitrary users use PgCognition.DatabaseClient.createRole method.
-
createRole
(role, group='NULL', password='NULL')¶ Creates a role, optionally with login, optionally in a group
- Parameters
role (str) – Name of new role
- Keyword Arguments
group (
str
) – Group to add role topassword (
str
) – Give role login privilege with provided password
- Returns
None
- Return type
None
If password kwarg is provided then user will have login privileges with provided password, otherwise the role will not have login. If group kwarg is provided the role will be created inside of that group.
Example adding a user role to a tenant for an instance type client
from PgCognition import DatabaseClient config = { "dbname": "mydb", "user": "myuser", "host": "localhost", "password": "password" } c = DatabaseClient(config=config, client_type="instance") c.createRole("myuser", "my_tenant_users")
-
createSecret
(userid, email, dbpass, upsert=True)¶ Creates an AWS Secret to use for database credentials
- Parameters
userid (str) – The database username to put in the secret
email (str) – The cognito email address for the database user
dbpass (str) – Database password to store
- Keyword Arguments
upsert (
bool
) – If True (default) then update the secret if a secret exists for this email address.
- Returns
ARN of secret
- Return type
str
If upsert=False and a secret already exists for the email address an Exception will be raised.
-
deleteSecret
(user, wait=True)¶ Deletes an AWS Secret :param user: Email address of the user to remove the secret for :type user: str
- Keyword Arguments
wait (
bool
) – Block until delete is complete
-
getSecretFromIdentity
()¶ Get ARN for the secret containing the RDS credentials for the user who called us.
- Secrets for cognito users are constructed as:
arn:aws:secretsmanager:{region}:{account}:{secretsPath}/{event[“identity”][“email”]}
- We will return the first credential found in the order of:
If caller is a Cognito user
If caller is matched in roleOverrides
If caller is matched in assumedRoleOverrides
- Returns
The arn of an AWS secret
- Return type
str
-
getTenantRole
(email, tenant)¶ Get the role for a Cognito user by email within a specific tenant
- Parameters
email (str) – Email address of user
tenant – Name of tenant to retrieve user’s role within
- Returns
The user’s role within a tenant
- Return type
str
Example adding a user role to a tenant for an instance type client
from PgCognition import DatabaseClient config = { "dbname": "mydb", "user": "myuser", "host": "localhost", "password": "password" } c = DatabaseClient(config=config, client_type="instance") role =<EMAIL_ADDRESS>"my_tenant")
-
getTenants
(identifier, identifier_type='email')¶ Get the tenants a user belongs to. Either by email, or database role/user
- Parameters
identifier (str) – Email address or database role of user
- Keyword Arguments
identifier_type (
str
) – Cognito email address or “dbuser”
- Returns
The user’s tenants
- Return type
list
Example adding a user role to a tenant for an instance type client
from PgCognition import DatabaseClient config = { "dbname": "mydb", "user": "myuser", "host": "localhost", "password": "password" } c = DatabaseClient(config=config, client_type="instance") role =<EMAIL_ADDRESS>"my_tenant")
-
groupsOf
(username)¶ Get the database groups a database user belongs to
- Parameters
user (str) – Database username
- Returns
A list of database groups a database user belongs to
- Return type
list
Example
from PgCognition import DatabaseClient config = { "dbname": "mydb", "user": "myuser", "host": "localhost", "password": "password" } c = DatabaseClient(config=config, client_type="instance") groups = c.groupsOf(""myuserid")
-
resolveAppsyncQuery
(schema='', secretArn=None, client_type=None, switch_role=None)¶ Run a query for each item in event
This is a wrapper for DatabaseClient.resolveInstanceAppsyncQuery and DatabaseClient.resolveServerlessAppsyncQuery and will return the result of one of these two methods, depending on whether client_type is “serverless” or “instance”. See PgCognition.DatabaseClient.resolveInstanceAppsyncQuery and PgCognition.DatabaseClient.resolveServerlessAppsyncQuery
- Keyword Arguments
schema (
str
) – Schema name. Boto3 rds-client doesn’t acually honor this right not. It is best to use the full path to your table in your query. Only used if client_type = “serverless”secretArn (
str
) – Override databaseSecretArn from config. Only used if client_type = “serverless”switch_role (
str
) – Excute query as specific user. The current connection must use a user with permission to assume this role. Only used if client_type = “instance”
- Returns
Query results from PgCognition.DatabaseClient.resolveInstanceAppsyncQuery or PgCognition.DatabaseClient.resolveServerlessAppsyncQuery
- Return type
dict or list
Example of an AWS Lambda function used as an Appsync datasource with a serverless database
from os import environ from PgCognition import DatabaseClient def handler(event, context): config = { "database": environ["DATABASE"], "account": environ["ACCOUNT"], "databaseArn": environ["DATABASE_ARN"], "assumedRoleOverrides": {"administrator": "root", "developer": "root"}, # This allows our awscli users calling Appsync "region": environ["AWS_REGION"], "secretsPath": "rds-db-credentials" } dbClient = DatabaseClient(event=event, config=config, client_type="serverless") return dbClient.resolveAppsyncQuery()
-
runQuery
(sql, **kwargs)¶ Run an SQL query HELLO
This method is a convenience wrapper for runInstanceQuery and runServerlessQuery The method called whose return value is returned from this method and whose arguments should be passed will depend on self.client_type
- Keyword Arguments
pretty (
bool
) – format the results as a list of dicts, one per row, with the keys as column names, default Trueparameters (
list
) – a list of parameters to pass to the query in psycopg2’s formatswitch_role (
string
) – Execute as <role>. Only available for “instance” client_typecommit (
bool
) – Commit directly after query. Only available for “instance” client_typesecret (
str
) – override config[“databaseSecretArn”] for serverless clientsdatabase (
str
) – override config[“database”] for serverless clientsdatabaseArn (
str
) – override config[“databaseArn”] for serverless clientsschema (
str
) – schema to use for serverless clients
- Returns
List or Dictionary of query results
- Return type
list or dict
Boto3 does not currently respect the schema argument. Use the full path to your table in the query instead. if pretty=True then query results will be returned after being formatted by auroraPrettyParser.parseResults (serverless clients) or a dict using pyscopg2.extras.DictCursor cast to a dict (instance clients). Otherwise results will be returned using the underlying client’s default formatting. To use with Appsync you would pretty much always want pretty=True
Example with a standard Postgres database
from PgCognition import DatabaseClient config = { "dbname": "mydb", "user": "myuser", "host": "localhost", "password": "password" } c = DatabaseClient(config=config, client_type="instance") res = c.runQuery("SELECT * FROM mytable", switch_role="less_privileged_role")
Cognito¶
-
class
PgCognition.
Cognito
(event=None, config=None, dbClient=None, client_type='instance')¶ Methods useful in building cognito hooks
- Parameters
config (dict, optional) – A database configuration suitable to be passed to DatabaseClient()
dbCLient (PgCognition.DatabaseClient, optional) – An instance of DatabaseClient that will be used for queries
event (dict or list, optional) – AWS Lambda event
- Returns
An instance of Cognito()
- Return type
You can only pass one of config or dbClient. dbClient must be a configured instance of DatabaseClient. If using DatabaseClient then event can be omitted and dbClient.event will be used, otherwise dbClient.event will be replaced with self.event
-
AddClaims
(extraClaims={})¶ Adds claims to Cognito user and returns the object’s event. Intended to be used with Cognito Pre Token Generation. Default is to add role and tenant.
- Parameters
extraClaims (dict, optional) – Extra claims to add to jwt
- Returns
self.event updated with claims
- Return type
dict
-
UserIsActive
()¶ Returns a bool indicating if a user exists and is active. Useful for Cognito Pre Authentication hook
- Returns
bool indicating if user is in active state
- Return type
bool
-
UserIsInvited
()¶ Returns a bool indicating if a user has been invited or not
If called by Cognito Post Signup then DatabaseClient.createDatabaseUser({“user”: user}) can be called afterward to create the user in the database. If using AWS Lambda then the Lambda function that calls createDatabaseUser() should be invoked async after this method since it can take longer than the 5 timeout that applies to Cognito hooks.
If called by Cognito Pre Signup then we will simply prove that a user has been invited before continuing with the signup process.
- Returns
bool indicating if a user has been invited
- Return type
bool
cognition_functions¶
-
PgCognition.cognition_functions.
getCallerAccount
()¶ Gets account number of entity that called the function using sts service
- Returns
Account number
- Return type
str
-
PgCognition.cognition_functions.
validateConfig
(requiredOpts, config, defaults={})¶ Validate the config has all of the required values. For each required value if the option is not set in the config we will attempt to pull it from the environment before throwing an Exception.
- Parameters
requiredOpts (list, required) – A list of required parameters
config (dict, required) – A dictionary of configuration options
defaults (dict, optional) – A dictionary of config options and their defaults to use if missing
- Returns
Dictionary of configuration options
- Return type
dict