segunda-feira, 24 de outubro de 2016

Códigos de Autenticação do OpenAM


Authentication Codes


IdLog LevelDescriptionDataTriggersActions
AUTHENTICATION-100 INFO Authentication is Successful message User authenticated with valid credentials   
AUTHENTICATION-101 INFO User based authentication is successful message
authentication type
user name 
User authenticated with valid credentials   
AUTHENTICATION-102 INFO Role based authentication is successful message
authentication type
role name 
User belonging to role authenticated with valid credentials    
AUTHENTICATION-103 INFO Service based authentication is successful message
authentication type
service name 
User authenticated with valid credentials to a configured service under realm   
AUTHENTICATION-104 INFO Authentication level based authentication is successful message
authentication type
authentication level value 
User authenticated with valid credentials to one or more authentication modules having authentication level value greater than or equal to specified authentication level   
AUTHENTICATION-105 INFO Module based authentication is successful message
authentication type
module name 
User authenticated with valid credentials to authentication module under realm   
AUTHENTICATION-200 INFO Authentication Failed error message Incorrect/invalid credentials presented
User locked out/not active 
Enter correct/valid credentials to required authentication module 
AUTHENTICATION-201 INFO Authentication Failed error message Invalid credentials entered.  Enter the correct password. 
AUTHENTICATION-202 INFO Authentication Failed error message Named Configuration (Auth Chain) does not exist.  Create and configure a named config for this org. 
AUTHENTICATION-203 INFO Authentication Failed error message No user profile found for this user.  User does not exist in the datastore plugin configured and hence configure the datastore plugin for this realm/org correctly.  
AUTHENTICATION-204 INFO Authentication Failed error message This user is not active.  Activate the user. 
AUTHENTICATION-205 INFO Authentication Failed error message Max number of failure attempts exceeded. User is Locked out.  Contact system administrator. 
AUTHENTICATION-206 INFO Authentication Failed error message User account has expired.  Contact system administrator. 
AUTHENTICATION-207 INFO Authentication Failed error message Login timed out.  Try to login again. 
AUTHENTICATION-208 INFO Authentication Failed error message Authentication module is denied.  Configure this module or use some other module. 
AUTHENTICATION-209 INFO Authentication Failed error message Limit for maximum number of allowed session has been reached.  Logout of a session or increase the limit. 
AUTHENTICATION-210 INFO Authentication Failed error message Org/Realm does not exists.  Use a valid Org/Realm. 
AUTHENTICATION-211 INFO Authentication Failed error message Org/Realm is not active.  Activate the Org/Realm. 
AUTHENTICATION-212 INFO Authentication Failed error message Cannot create a session.  Ensure that session service is configured and maxsession is not reached. 
AUTHENTICATION-213 INFO User based authentication failed error message
authentication type
user name 
No authentication configuration (chain of one or more authentication modules) configured for user
Incorrect/invalid credentials presented
User locked out/not active 
Configure authentication configuration (chain of one or more authentication modules) for user
Enter correct/valid credentials to required authentication module 
AUTHENTICATION-214 INFO Authentication Failed error message
authentication type
user name 
User based Auth. Invalid credentials entered.  Enter the correct password. 
AUTHENTICATION-215 INFO Authentication Failed error message
authentication type
user name 
Named Configuration (Auth Chain) does not exist for this user  Create and configure a named config for this user 
AUTHENTICATION-216 INFO Authentication Failed error message
authentication type
user name 
User based Auth. No user profile found for this user.  User does not exist in the datastore plugin configured and hence configure the datastore plugin for this realm/org correctly.  
AUTHENTICATION-217 INFO Authentication Failed error message
authentication type
user name 
User based Auth. This user is not active.  Activate the user. 
AUTHENTICATION-218 INFO Authentication Failed error message
authentication type
user name 
User based Auth. Max number of failure attempts exceeded. User is Locked out. Contact system administrator. 
AUTHENTICATION-219 INFO Authentication Failed error message
authentication type
user name 
User based Auth. User account has expired.  Contact system administrator. 
AUTHENTICATION-220 INFO Authentication Failed error message
authentication type
user name 
User based Auth. Login timed out.  Try to login again. 
AUTHENTICATION-221 INFO Authentication Failed error message
authentication type
user name 
User based Auth. Authentication module is denied.  Configure this module or use some other module. 
AUTHENTICATION-222 INFO Authentication Failed error message
authentication type
user name 
User based auth. Limit for maximum number of allowed session has been reached. Logout of a session or increase the limit. 
AUTHENTICATION-223 INFO Authentication Failed error message
authentication type
user name 
User based auth. Org/Realm does not exists.  Use a valid Org/Realm. 
AUTHENTICATION-224 INFO Authentication Failed error message
authentication type
user name 
User based auth. Org/Realm is not active.  Activate the Org/Realm. 
AUTHENTICATION-225 INFO Authentication Failed error message
authentication type
user name 
User based auth. Cannot create a session.  Ensure that session service is configured and maxsession is not reached. 
AUTHENTICATION-226 INFO Role based authentication failed error message
authentication type
role name 
No authentication configuration (chain of one or more authentication modules) configured for role
Incorrect/invalid credentials presented
User does not belong to this role
User locked out/not active 
Configure authentication configuration (chain of one or more authentication modules) for role
Enter correct/valid credentials to required authentication module
Assign this role to the authenticating user 
AUTHENTICATION-227 INFO Authentication Failed error message
authentication type
role name 
Role based Auth. Invalid credentials entered.  Enter the correct password. 
AUTHENTICATION-228 INFO Authentication Failed error message
authentication type
role name 
Named Configuration (Auth Chain) does not exist for this role. Create and configure a named config for this role. 
AUTHENTICATION-229 INFO Authentication Failed error message
authentication type
role name 
Role based Auth. No user profile found for this user.  User does not exist in the datastore plugin configured and hence configure the datastore plugin for this realm/org correctly.  
AUTHENTICATION-230 INFO Authentication Failed error message
authentication type
role name 
Role based Auth. This user is not active.  Activate the user. 
AUTHENTICATION-231 INFO Authentication Failed error message
authentication type
role name 
Role based Auth. Max number of failure attempts exceeded. User is Locked out. Contact system administrator. 
AUTHENTICATION-232 INFO Authentication Failed error message
authentication type
role name 
Role based Auth. User account has expired.  Contact system administrator. 
AUTHENTICATION-233 INFO Authentication Failed error message
authentication type
role name 
Role based Auth. Login timed out.  Try to login again. 
AUTHENTICATION-234 INFO Authentication Failed error message
authentication type
role name 
Role based Auth. Authentication module is denied.  Configure this module or use some other module. 
AUTHENTICATION-235 INFO Authentication Failed error message
authentication type
role name 
Role based auth. Limit for maximum number of allowed session has been reached. Logout of a session or increase the limit. 
AUTHENTICATION-236 INFO Authentication Failed error message
authentication type
role name 
Role based auth. Org/Realm does not exists.  Use a valid Org/Realm. 
AUTHENTICATION-237 INFO Authentication Failed error message
authentication type
role name 
Role based auth. Org/Realm is not active.  Activate the Org/Realm. 
AUTHENTICATION-238 INFO Authentication Failed error message
authentication type
role name 
Role based auth. Cannot create a session.  Ensure that session service is configured and maxsession is not reached. 
AUTHENTICATION-239 INFO Authentication Failed error message
authentication type
role name 
Role based auth. User does not belong to this role.  Add the user to this role. 
AUTHENTICATION-240 INFO Service based authentication failed error message
authentication type
service name 
No authentication configuration (chain of one or more authentication modules) configured for service
Incorrect/invalid credentials presented
User locked out/not active 
Configure authentication configuration (chain of one or more authentication modules) for service
Enter correct/valid credentials to required authentication module 
AUTHENTICATION-241 INFO Authentication Failed error message
authentication type
service name 
Service based Auth. Invalid credentials entered.  Enter the correct password. 
AUTHENTICATION-242 INFO Authentication Failed error message
authentication type
service name 
Named Configuration (Auth Chain) does not exist with this service name.  Create and configure a named config. 
AUTHENTICATION-243 INFO Authentication Failed error message
authentication type
service name 
Service based Auth. No user profile found for this user.  User does not exist in the datastore plugin configured and hence configure the datastore plugin for this realm/org correctly.  
AUTHENTICATION-244 INFO Authentication Failed error message
authentication type
service name 
Service based Auth. This user is not active.  Activate the user. 
AUTHENTICATION-245 INFO Authentication Failed error message
authentication type
service name 
Service based Auth. Max number of failure attempts exceeded. User is Locked out. Contact system administrator. 
AUTHENTICATION-246 INFO Authentication Failed error message
authentication type
service name 
Service based Auth. User account has expired.  Contact system administrator. 
AUTHENTICATION-247 INFO Authentication Failed error message
authentication type
service name 
Service based Auth. Login timed out.  Try to login again. 
AUTHENTICATION-248 INFO Authentication Failed error message
authentication type
service name 
Service based Auth. Authentication module is denied.  Configure this module or use some other module. 
AUTHENTICATION-249 INFO Authentication Failed error message
authentication type
service name 
Service based Auth. Service does not exist.  Please use only valid Service. 
AUTHENTICATION-250 INFO Authentication Failed error message
authentication type
service name 
Service based auth. Limit for maximum number of allowed session has been reached. Logout of a session or increase the limit. 
AUTHENTICATION-251 INFO Authentication Failed error message
authentication type
service name 
Service based auth. Org/Realm does not exists.  Use a valid Org/Realm. 
AUTHENTICATION-252 INFO Authentication Failed error message
authentication type
service name 
Service based auth. Org/Realm is not active.  Activate the Org/Realm. 
AUTHENTICATION-253 INFO Authentication Failed error message
authentication type
service name 
Service based auth. Cannot create a session.  Ensure that session service is configured and maxsession is not reached. 
AUTHENTICATION-254 INFO Authentication level based authentication failed error message
authentication type
authentication level value 
There are no authentication module(s) having authentication level value greater than or equal to specified authentication level
Incorrect/invalid credentials presented to one or more authentication modules having authentication level greater than or equal to specified authentication level
User locked out/not active 
Configure one or more authentication modules having authentication level value greater than or equal to required authentication level
Enter correct/valid credentials to one or more authentication modules having authentication level greater than or equal to specified authentication level 
AUTHENTICATION-255 INFO Authentication Failed error message
authentication type
authentication level value 
Level based Auth. Invalid credentials entered.  Enter the correct password. 
AUTHENTICATION-256 INFO Authentication Failed error message
authentication type
authentication level value 
Level based Auth. No Auth Configuration available.  Create an auth configuration. 
AUTHENTICATION-257 INFO Authentication Failed error message
authentication type
authentication level value 
Level based Auth. No user profile found for this user.  User does not exist in the datastore plugin configured and hence configure the datastore plugin for this realm/org correctly.  
AUTHENTICATION-258 INFO Authentication Failed error message
authentication type
authentication level value 
Level based Auth. This user is not active.  Activate the user. 
AUTHENTICATION-259 INFO Authentication Failed error message
authentication type
authentication level value 
Level based Auth. Max number of failure attempts exceeded. User is Locked out. Contact system administrator. 
AUTHENTICATION-260 INFO Authentication Failed error message
authentication type
authentication level value 
Level based Auth. User account has expired.  Contact system administrator. 
AUTHENTICATION-261 INFO Authentication Failed error message
authentication type
authentication level value 
Level based Auth. Login timed out.  Try to login again. 
AUTHENTICATION-262 INFO Authentication Failed error message
authentication type
authentication level value 
Level based Auth. Authentication module is denied.  Configure this module or use some other module. 
AUTHENTICATION-263 INFO Authentication Failed error message
authentication type
authentication level value 
Level based Auth. Invalid Authg Level.  Please specify valid auth level. 
AUTHENTICATION-264 INFO Authentication Failed error message
authentication type
authentication level value 
Level based auth. Limit for maximum number of allowed session has been reached. Logout of a session or increase the limit. 
AUTHENTICATION-265 INFO Authentication Failed error message
authentication type
authentication level value 
Level based auth. Org/Realm does not exists.  Use a valid Org/Realm. 
AUTHENTICATION-266 INFO Authentication Failed error message
authentication type
authentication level value 
Level based auth. Org/Realm is not active.  Activate the Org/Realm. 
AUTHENTICATION-267 INFO Authentication Failed error message
authentication type
authentication level value 
Level based auth. Cannot create a session.  Ensure that session service is configured and maxsession is not reached. 
AUTHENTICATION-268 INFO Module based authentication failed error message
authentication type
module name 
Module is not registered/configured under realm
Incorrect/invalid credentials presented
User locked out/not active 
Register/configure authentication module under realm
Enter correct/valid credentials to authentication module  
AUTHENTICATION-269 INFO Authentication Failed error message
authentication type
module name 
Module based Auth. Invalid credentials entered.  Enter the correct password. 
AUTHENTICATION-270 INFO Authentication Failed error message
authentication type
module name 
Module based Auth. No user profile found for this user.  User does not exist in the datastore plugin configured and hence configure the datastore plugin for this realm/org correctly.  
AUTHENTICATION-271 INFO Authentication Failed error message
authentication type
module name 
Module based Auth. This user is not active.  Activate the user. 
AUTHENTICATION-272 INFO Authentication Failed error message
authentication type
module name 
Module based Auth. Max number of failure attempts exceeded. User is Locked out. Contact system administrator. 
AUTHENTICATION-273 INFO Authentication Failed error message
authentication type
module name 
Module based Auth. User account has expired.  Contact system administrator. 
AUTHENTICATION-274 INFO Authentication Failed error message
authentication type
module name 
Module based Auth. Login timed out.  Try to login again. 
AUTHENTICATION-275 INFO Authentication Failed error message
authentication type
module name 
Module based Auth. Authentication module is denied.  Configure this module or use some other module. 
AUTHENTICATION-276 INFO Authentication Failed error message
authentication type
module name 
Module based auth. Limit for maximum number of allowed session has been reached. Logout of a session or increase the limit. 
AUTHENTICATION-277 INFO Authentication Failed error message
authentication type
module name 
Module based auth. Org/Realm does not exists.  Use a valid Org/Realm. 
AUTHENTICATION-278 INFO Authentication Failed error message
authentication type
module name 
Module based auth. Org/Realm is not active.  Activate the Org/Realm. 
AUTHENTICATION-279 INFO Authentication Failed error message
authentication type
module name 
Module based auth. Cannot create a session.  Ensure that session service is configured and maxsession is not reached. 
AUTHENTICATION-300 INFO User logout is Successful message User logged out   
AUTHENTICATION-301 INFO User logout is successful from user based authentication message
authentication type
user name 
User logged out   
AUTHENTICATION-302 INFO User logout is successful from role based authentication message
authentication type
role name 
User belonging to this role logged out   
AUTHENTICATION-303 INFO User logout is successful from service based authentication message
authentication type
service name 
User logged out of a configured service under realm   
AUTHENTICATION-304 INFO User logout is successful from authentication level based authentication message
authentication type
authentication level value 
User logged out of one or more authentication modules having authentication level value greater than or equal to specified authentication level   
AUTHENTICATION-305 INFO User logout is successful from module based authentication message
authentication type
module name 
User logged out of authentication module under realm   

Fonte: https://docs.oracle.com/cd/E19575-01/820-3886/gdhxz/index.html
            https://backstage.forgerock.com/#!/docs/openam/13.5/reference#log-messages

quinta-feira, 20 de agosto de 2015

Linux - Autenticando com LDAP

Antes de mais nada

Verificar se o ldap possui os auxiliary objectClass posixAccount e posixGroup
caso não tenha

cria-las com base no link abaixo

http://www.zytrax.com/books/ldap/ape/nis.html

Depois para cada usuário que deseja autenticar no linux, o registro dele no ldap deve possuir

 - acrescentar a um grupo que será utilizado no linux
gidNumber: 666
objectClass: posixGroup

- acrescentar ao usuário que se será utilizado  no linux
gidNumber: 666
homeDirectory: /home/rodrigo.teste
objectClass: posixAccount
sn: sobrenome
uid: login
uidNumber: 666

Agora sim podemos começar

Instalar o pacote authconfig
# yum install authconfig

executar o authconfig-gtk
#authconfig-gtk


configure:
User Account DataBase: LDAP
LDAP Serach Base DN: o base dn que contenha os usuarios e os grupos
LDAP Server: basta colcoar o host/ip e a porta localhost:1389
OBS: (alerta de bug) caso a url nao seja ldaps, selecione outro user account e depois volte para o LDAP, irá permitir salvar

Authentication Method: LDAP Password

[Apply]

Para verificar os usuarios
# getent passwd <<uid do ldap>>
ou 
# id <<uid do ldap>>

para testar o login
# su - <<uid do ldap>>

terça-feira, 7 de julho de 2015

Alterando resolução (DPI) do mouse


$ xinput list
⎡ Virtual core pointer                          id=2    [master pointer  (3)]
⎜   ↳ Virtual core XTEST pointer                id=4    [slave  pointer  (2)]
⎜   ↳ SynPS/2 Synaptics TouchPad                id=10   [slave  pointer  (2)]
⎣ Virtual core keyboard                         id=3    [master keyboard (2)]
    ↳ Virtual core XTEST keyboard               id=5    [slave  keyboard (3)]
    ↳ AT Translated Set 2 keyboard              id=9    [slave  keyboard (3)]

$ xinput list-props 10
Device 'SynPS/2 Synaptics TouchPad':
    Device Enabled (144):   1
    Device Accel Profile (266):     1
    Device Accel Constant Deceleration (267):       2.500000
    Device Accel Adaptive Deceleration (268):       1.000000
    Device Accel Velocity Scaling (269):    12.500000
  [ many more settings omitted ] 
$ xinput set-prop 10 267 5.0

Fonte: http://unix.stackexchange.com/questions/90572/how-can-i-set-mouse-sensitivity-not-just-mouse-acceleration

sexta-feira, 6 de fevereiro de 2015

Desvinculando processos e jobs do terminal

Processo que prende o terminal

exec command
[user@localhost ~]$ system-config-users

ctrl + z para parar o processo
^Z
[1]+  Stopped                 system-config-users

bg para colocar ele em segundo plano
[user@localhost ~]$ bg
[1]+ system-config-users &

use o jobs para verificar os processos
[user@localhost ~]$ jobs
[1]+  Running                 system-config-users &

user o disown %<process number> para desvincular do terminal
[smart@localhost ~]$ disown %1


Processo direto desvinculado

execute o comando com o nohup e o "&" no final para colocar em segundo plano
[user@localhost ~]$ nohup system-config-users &


Processo já em andamento

Use o ps para localizar o PID
[user@localhost ~]$ ps ax | grep system-config-user
 4019 pts/2    Sl     0:00 /usr/bin/python /usr/share/system-config-users/system-config-users.py
 4092 pts/2    S+     0:00 grep --color=auto system-config-user

execute um kill -18 <PID> para desvincular ele da sessão do terminal
[user@localhost ~]$ kill -18 4019

segunda-feira, 10 de novembro de 2014

Includindo versão do maven em um projeto

Inclua como recurso do maven uma path do projeto no pom.xml
<properties>
    <system.version>1.2.3.4</system.version>
</properties>

<build>
    <resources>
        <resource>
            <directory>src/main/resources</directory>
            <filtering>true</filtering>
        </resource>
    </resources>
</build>
Agora qualquer aquivo dentro de src/main/resources pode ser substituido por ${some.property}, onde some.propertysão propriedades dentro do pom.xml, que será subsistido durante a build, por exemplo
file.properties
projet.version=${project.version}
o maven ira filtrar este  arquivo e substituir por
system.version=1.2.3.4
Ai é utilizar a chavem com a versão do projeto onde for necessário.

quarta-feira, 15 de outubro de 2014

trocando texto com css

<html>
<head><title>trocando texto html</title>
<style>
button {
  position: absolute;
  visibility: hidden;
}

button:before {
  content: "novo texto";
  visibility: visible;
}
</style>
</head>
<body>
<button>texto original</button>
</body>
</html>


Fonte: http://stackoverflow.com/questions/7896402/how-can-i-replace-text-through-css

segunda-feira, 1 de setembro de 2014

Recuperar boot UEFI sem formatar

ativar partiçoes lvm
# vgchange -a y

listando particoes lvm 
# lvscan

montando estrutura de dados no mnt do live
sudo mount /dev/fedora/root /mnt #caso seja uma particao lvm
sudo mount /dev/sda2 /mnt/boot/efi #sda2 e a particao com o boot UEFI
for i in /dev /dev/pts /proc /sys; do sudo mount -B $i /mnt$i; done;
modprobe efivars # make sure this is loaded
sudo chroot /mnt
apos mudar estrutura de dados
# efibootmgr -c -L Fedora -d /dev/sda -p 2 -l \\EFI\\fedora\\shim.efi -g -w
OBS: para gravar as informacoes no MBR  necessario que o -w esteja na linha que faz a craicao do boot

-c = informa que vai ser criado um boot
-L = nome do Boot a ser criado
-d = dispositivo
-p = particao que contem o UEFI Boot
** importante,  necessario qie seja informado os parametros -d e -p sempre que for feito alguma alreacao no boot, pois sao atraves deles que o bootmamager identifica a particao que devera alterar, se nao for informado as modificaoes ficaram apenas em memoria.
-l = caminho dento do /boot/efi que comtem os arquivos de boot... no linux deve-se utilizar as duas \\
-g = forca a gravacao no mbr
-w = grava as alteracoes feitas


Outra Solucao para resolver o problema,seria alterar o grub.conf dentro do pendrive com o live-fedora e acrescentar o menuentry apontando para a sua maquina, assim quando o pendrive iniciar, aparecera a opcao de boot para o equipamento fisico, mas atencao, quando copiamos o menuentry os discos podem nao bater a numeracao, certifique-se que estejam apontando para o mesmo ...

menuentry 'Fedora (3.15.4-200.fc20.x86_64) 20 (Heisenbug)' --class fedora --class gnu-linux --class gnu --class os $menuentry_id_option 'gnulinux-3.12.10-300.fc20.x86_64-advanced-139e31ae-e78c-4984-bc6f-7b0614326537' {
load_video
set gfxpayload=keep
insmod gzio
insmod part_gpt
insmod ext2
set root='hd0,gpt6'
if [ x$feature_platform_search_hint = xy ]; then
  search --no-floppy --fs-uuid --set=root --hint-bios=hd0,gpt6 --hint-efi=hd0,gpt6 --hint-baremetal=ahci0,gpt6  14622b3b-ff28-4162-b4f6-158695bedc22
else
  search --no-floppy --fs-uuid --set=root 14622b3b-ff28-4162-b4f6-158695bedc22
fi
linuxefi /vmlinuz-3.15.4-200.fc20.x86_64 root=/dev/mapper/fedora-root ro rd.lvm.lv=fedora/swap vconsole.font=latarcyrheb-sun16 rd.lvm.lv=fedora/root  rhgb biosdevname=0 quiet LANG=en_US.UTF-8
initrdefi /initramfs-3.15.4-200.fc20.x86_64.img
}

no exemplo acima, eu tive que alterar todos os hd0 por hd1, para identificar qual o numero do dispositivo, durante o boot do live-fedora, entre no console (C) e digite >ls, assim ira listar dos os dispositivos encontrados pelo boot

Fontes: http://linuxwave.blogspot.com.br/2007/11/mounting-lvm-disk-using-ubuntu-livecd.html
http://superuser.com/questions/376470/how-to-reinstall-grub2-efi