Skip to content

Instantly share code, notes, and snippets.

Guillermo gdiazs

Block or report user

Report or block gdiazs

Hide content and notifications from this user.

Learn more about blocking users

Contact Support about this user’s behavior.

Learn more about reporting abuse

Report abuse
View GitHub Profile
View spring-security2.xml
<b:bean id="userDetailService"
class="org.springframework.ejb.access.LocalStatelessSessionProxyFactoryBean">
<b:property name="jndiName"
value="java:global/ErisEAR/ErisWeb/UserDetailServiceImpl!io.gdiazs.eris.security.services.UserDetailServiceImpl" />
<b:property name="businessInterface"
value="org.springframework.security.core.userdetails.UserDetailsService" />
</b:bean>
@gdiazs
gdiazs / spring-security.xml
Last active Dec 10, 2018
spring-security.xml
View spring-security.xml
<b:beans xmlns="http://www.springframework.org/schema/security"
xmlns:b="http://www.springframework.org/schema/beans"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd
http://www.springframework.org/schema/security http://www.springframework.org/schema/security/spring-security.xsd">
<http auto-config="true">
<form-login login-page="/faces/signin/login.xhtml"
login-processing-url="/login" default-target-url="/faces/index.xhtml"
authentication-failure-url="/faces/signin/login.xhtml?error=true" />
@gdiazs
gdiazs / HttpClient.java
Last active Mar 10, 2017
No SSL Verification for apache http client
View HttpClient.java
HttpClient client = HttpClientBuilder.create().setSSLHostnameVerifier(new NoopHostnameVerifier()).build();
View mysql2sqlite.sh
#!/bin/sh
# Converts a mysqldump file into a Sqlite 3 compatible file. It also extracts the MySQL `KEY xxxxx` from the
# CREATE block and create them in separate commands _after_ all the INSERTs.
# Awk is choosen because it's fast and portable. You can use gawk, original awk or even the lightning fast mawk.
# The mysqldump file is traversed only once.
# Usage: $ ./mysql2sqlite mysqldump-opts db-name | sqlite3 database.sqlite
# Example: $ ./mysql2sqlite --no-data -u root -pMySecretPassWord myDbase | sqlite3 database.sqlite
You can’t perform that action at this time.