diff --git a/ETS_Data/ETS_Data.csproj b/ETS_Data/ETS_Data.csproj index 0f2fe16..7b6f2ac 100644 --- a/ETS_Data/ETS_Data.csproj +++ b/ETS_Data/ETS_Data.csproj @@ -114,6 +114,7 @@ True DS_WebScip.xsd + diff --git a/ETS_Data/NLog.config b/ETS_Data/NLog.config index a4d889d..7c0b2b7 100644 --- a/ETS_Data/NLog.config +++ b/ETS_Data/NLog.config @@ -20,10 +20,8 @@ - - - + + + \ No newline at end of file diff --git a/ETS_Data/enomerazioni.cs b/ETS_Data/enomerazioni.cs new file mode 100644 index 0000000..1466be2 --- /dev/null +++ b/ETS_Data/enomerazioni.cs @@ -0,0 +1,26 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Text; + +namespace ETS_Data +{ + /// + /// enumeratore modalità login + /// + public enum loginMode + { + /// + /// login AD normale + /// + normale, + /// + /// forza utente fornendo password + /// + forceUser, + /// + /// forza ad un utente standard scelto dall'elenco + /// + standardUser + } +} diff --git a/ETS_Data/obj/Debug/ETS_Data.dll b/ETS_Data/obj/Debug/ETS_Data.dll index 92d9f12..2b28038 100644 Binary files a/ETS_Data/obj/Debug/ETS_Data.dll and b/ETS_Data/obj/Debug/ETS_Data.dll differ diff --git a/ETS_Data/user_std.cs b/ETS_Data/user_std.cs index b56b205..05fc33d 100644 --- a/ETS_Data/user_std.cs +++ b/ETS_Data/user_std.cs @@ -628,27 +628,6 @@ namespace ETS_Data rigaUtente = _rigaUtenteAnagGen; } /// - /// Procedura da chiamare DOPO aver messo in session i dati utente/dominio x caricare gli altri dati CON I DIRITTI SOLO per il CDC indicato - /// - /// - /// - /// - /// - public bool startUpUtente(string _dominio, string _username, string cdc) - { - bool risultato = false; - clearAllUserData(); - if (_username != "" && _dominio != "") - { - utente = _username; - dominio = _dominio; - setupRiga(); - setupDirittiPermessi(cdc); - risultato = true; - } - return risultato; - } - /// /// verifica nella tab diritti se l'utente abbia il right richiesto e fornisce bool in risposta /// /// diff --git a/PROJ-ETS/PROJ-ETS/Login.aspx b/PROJ-ETS/PROJ-ETS/Login.aspx new file mode 100644 index 0000000..1346693 --- /dev/null +++ b/PROJ-ETS/PROJ-ETS/Login.aspx @@ -0,0 +1,20 @@ +<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="Login.aspx.cs" Inherits="PROJ_ETS.Login" %> + +<%@ Register src="WebUserControls/mod_login.ascx" tagname="mod_login" tagprefix="uc1" %> + + + + + + + + +
+
+ + + +
+
+ + diff --git a/PROJ-ETS/PROJ-ETS/Login.aspx.cs b/PROJ-ETS/PROJ-ETS/Login.aspx.cs new file mode 100644 index 0000000..096cd66 --- /dev/null +++ b/PROJ-ETS/PROJ-ETS/Login.aspx.cs @@ -0,0 +1,54 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Web; +using System.Web.UI; +using System.Web.UI.WebControls; +using ETS_Data; + +namespace PROJ_ETS +{ + public partial class Login : System.Web.UI.Page + { + protected string _nextPage + { + get + { + string pagina = utils.obj.StringSessionObj("nextPage"); + if (pagina == "") + { + pagina = "menu.aspx"; + } + return pagina; + } + } + + protected void Page_Load(object sender, EventArgs e) + { + mod_login1.modoLogin = loginMode.normale; + } + + protected override void OnInit(EventArgs e) + { + base.OnInit(e); + mod_login1.Login_ok += new EventHandler(Mod_login1_Login_ok); + mod_login1.Login_Error += new EventHandler(Mod_login1_Login_Error); + } + + void Mod_login1_Login_Error(object sender, EventArgs e) + { + Response.Redirect("unauthorized.aspx"); + } + + void Mod_login1_Login_ok(object sender, EventArgs e) + { + Response.Redirect(_nextPage); + } + protected override void OnUnload(EventArgs e) + { + base.OnUnload(e); + mod_login1.Login_ok -= new EventHandler(Mod_login1_Login_ok); + mod_login1.Login_Error -= new EventHandler(Mod_login1_Login_Error); + } + } +} \ No newline at end of file diff --git a/PROJ-ETS/PROJ-ETS/Login.aspx.designer.cs b/PROJ-ETS/PROJ-ETS/Login.aspx.designer.cs new file mode 100644 index 0000000..b50fadc --- /dev/null +++ b/PROJ-ETS/PROJ-ETS/Login.aspx.designer.cs @@ -0,0 +1,33 @@ +//------------------------------------------------------------------------------ +// +// This code was generated by a tool. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +// +//------------------------------------------------------------------------------ + +namespace PROJ_ETS { + + + public partial class Login { + + /// + /// form1 control. + /// + /// + /// Auto-generated field. + /// To modify move field declaration from designer file to code-behind file. + /// + protected global::System.Web.UI.HtmlControls.HtmlForm form1; + + /// + /// mod_login1 control. + /// + /// + /// Auto-generated field. + /// To modify move field declaration from designer file to code-behind file. + /// + protected global::mod_login mod_login1; + } +} diff --git a/PROJ-ETS/PROJ-ETS/NLog.config b/PROJ-ETS/PROJ-ETS/NLog.config index 3bb347b..b3b2330 100644 --- a/PROJ-ETS/PROJ-ETS/NLog.config +++ b/PROJ-ETS/PROJ-ETS/NLog.config @@ -20,10 +20,8 @@ - - - + + + \ No newline at end of file diff --git a/PROJ-ETS/PROJ-ETS/PROJ-ETS.csproj b/PROJ-ETS/PROJ-ETS/PROJ-ETS.csproj index 9653903..7707cea 100644 --- a/PROJ-ETS/PROJ-ETS/PROJ-ETS.csproj +++ b/PROJ-ETS/PROJ-ETS/PROJ-ETS.csproj @@ -264,6 +264,7 @@ + @@ -285,12 +286,14 @@ + + @@ -403,6 +406,13 @@ Help.aspx + + Login.aspx + ASPXCodeBehind + + + Login.aspx + Menu.aspx ASPXCodeBehind @@ -443,6 +453,13 @@ Test.aspx + + unauthorized.aspx + ASPXCodeBehind + + + unauthorized.aspx + Progetti.master ASPXCodeBehind @@ -513,6 +530,13 @@ mod_fornitori.ascx + + mod_login.ascx + ASPXCodeBehind + + + mod_login.ascx + mod_menu.ascx ASPXCodeBehind diff --git a/PROJ-ETS/PROJ-ETS/Web.config b/PROJ-ETS/PROJ-ETS/Web.config index 9b47008..5248862 100644 --- a/PROJ-ETS/PROJ-ETS/Web.config +++ b/PROJ-ETS/PROJ-ETS/Web.config @@ -41,6 +41,8 @@ + + diff --git a/PROJ-ETS/PROJ-ETS/WebUserControls/mod_login.ascx b/PROJ-ETS/PROJ-ETS/WebUserControls/mod_login.ascx new file mode 100644 index 0000000..783f03f --- /dev/null +++ b/PROJ-ETS/PROJ-ETS/WebUserControls/mod_login.ascx @@ -0,0 +1,57 @@ +<%@ Control Language="C#" AutoEventWireup="true" Inherits="mod_login" CodeBehind="mod_login.ascx.cs" %> +<% if (false) + { %> + +<% } %> + + + + + +
+ +
+ + + + + + + + + + + + + + + + +
+ + + +
+ + + +
+ + + +
+ +
+
+ + + + + + + +
+ +
+ +
diff --git a/PROJ-ETS/PROJ-ETS/WebUserControls/mod_login.ascx.cs b/PROJ-ETS/PROJ-ETS/WebUserControls/mod_login.ascx.cs new file mode 100644 index 0000000..f319270 --- /dev/null +++ b/PROJ-ETS/PROJ-ETS/WebUserControls/mod_login.ascx.cs @@ -0,0 +1,232 @@ +using System; +using System.Data; +using System.Configuration; +using System.Collections; +using System.Web; +using System.Web.Security; +using System.Web.UI; +using System.Web.UI.WebControls; +using System.Web.UI.WebControls.WebParts; +using System.Web.UI.HtmlControls; +using ETS_Data; +using NLog; + +/// +/// classe gestione login e forzatura login +/// +public partial class mod_login : System.Web.UI.UserControl +{ + #region area protected/private + + protected Logger lg = LogManager.GetCurrentClassLogger(); + + #region area proprietà + + private loginMode _isForceUser = loginMode.normale; + + #endregion + + #region area metodi + + /// + /// imposta la modalità di login tra normale / forceUser + /// + private void setLoginMode() + { + if (_isForceUser == loginMode.forceUser) + { + pnlForceUser.Visible = true; + } + else + { + pnlForceUser.Visible = false; + } + } + + + /// + /// prova a verificare se l'utente sia ok x AD credentials + /// + private void AdLogin() + { + if (Page.User.Identity.IsAuthenticated) + { + //recupera user windows se c'è... + string ad_name = Page.User.Identity.Name; + string delimStr = "\\"; + char[] delimiter = delimStr.ToCharArray(); + string[] dom_user = ad_name.Split(delimiter, 2); + // passo al controllo di verifica ADuserOk... + user_std _utente = new user_std(); + if (_utente.ADuserOk(dom_user[0], dom_user[1])) + { + bool fatto = _utente.startUpUtente(ad_name); + if (fatto) + { + lg.Info(string.Format("L'utente {0} ({1}) ha effettuato il login correttamente", _utente.CognomeNome, _utente.userNameAD)); + if (Login_ok != null) + { + Login_ok(this, new EventArgs()); + } + } + else + { + lblMessage.Text = String.Format("Accesso fallito! problemi ad inizializzare l'utente: {0}", ad_name); + lg.Error(lblMessage.Text); + if (Login_Error != null) + { + Login_Error(this, new EventArgs()); + } + } + } + else + { + if (utils.obj.confReadBool("autoEnrollEnabled")) + { + // rimando al modulo di auto enroll... + Response.Redirect("autoEnroll.aspx"); + } + else + { + lblMessage.Text = String.Format("Accesso fallito: user non autorizzato e autoenroll non attivo: {0}", ad_name); + lg.Warn(lblMessage.Text); + if (Login_Error != null) + { + Login_Error(this, new EventArgs()); + } + } + } + } + else + { + lblMessage.Text = String.Format("Accesso fallito: user non autorizzato: IP:{0}, user: {1}", Request.UserHostName, utils.obj.currUserAD); + lg.Warn(lblMessage.Text); + if (Login_Error != null) + { + Login_Error(this, new EventArgs()); + } + } + } + + /// + /// effettua verifiche e se concesso permette di forzare l'accesso utente + /// + private void ForceUserIdentity() + { + if (Page.User.Identity.IsAuthenticated) + { + bool _allowForceUser = false; + try + { + _allowForceUser = utils.obj.confReadBool("_allowForceUser"); + } + catch + { + _allowForceUser = false; + } + if (_allowForceUser) + { + if (authKey.Text == "triplete") // verifica passphrase... + { + user_std _utente = new user_std(); + user_std.UtSn.isForcedUser = true; + bool fatto = _utente.startUpUtente(string.Format(@"{0}\{1}", dominio.Text, user.Text)); + if (fatto) + { + string _rigaLog = String.Format("User {0} has forced user identity ok: logged as \t {1}\\{2}", Page.User.Identity.Name, dominio.Text, user.Text); + lg.Info(_rigaLog); + if (Login_ok != null) + { + Login_ok(this, new EventArgs()); + } + } + } + else + { + lblMessage.Text = "Accesso fallito
key foce login non valida!!! tentativo registrata!!!"; + //mandaEmail(_fromEmail, _adminEmail, "Attenzione: tentativo di accesso non autorizzato!", String.Format("Tentativo di forcing user non autorizzato!
L'utente {0} ha tentato di accedere a {1} forzando l'utente ma la sua key autorizzativa e' sbagliata...", Page.User.Identity.Name, user_std.UtSn.Traduci(SteamWare.memLayer.ML.confReadString("defaultApp")))); + string _rigaLog = String.Format("User {0}\t tried to force user - wrong password - he tried to log as \t {1}\\{2}", Page.User.Identity.Name, dominio.Text, user.Text); + lg.Warn(_rigaLog); + if (Login_Error != null) + { + Login_Error(this, new EventArgs()); + } + } + } + else + { + //mandaEmail(_fromEmail, _adminEmail, "Attenzione: tentativo di accesso non autorizzato!", String.Format("Tentativo di forcing user non autorizzato!
L'utente {0} ha tentato di accedere a {1} forzando l'utente ma la funzione e' disabilitata...", Page.User.Identity.Name, user_std.UtSn.Traduci(SteamWare.memLayer.ML.confReadString("defaultApp")))); + string _rigaLog = String.Format("User {0}\t tried to force user - access disabled - he tried to log as \t {1}\\{2}", Page.User.Identity.Name, dominio.Text, user.Text); + lg.Warn(_rigaLog); + if (Login_Error != null) + { + Login_Error(this, new EventArgs()); + } + } + } + else + { + lblMessage.Text = "Accesso fallito!
user not authenticated!"; + if (Login_Error != null) + { + Login_Error(this, new EventArgs()); + } + string _rigaLog = String.Format("\t Someone tried to force user - real user: \t - not autenticated - \t tried to log as \t {0}\\{1}", dominio.Text, user.Text); + lg.Warn(_rigaLog); + } + } + + protected void btnOk_Click(object sender, EventArgs e) + { + ForceUserIdentity(); + } + + #endregion + + #endregion + + #region area public + + #region eventi pubblici esposti + + public event EventHandler Login_ok; + public event EventHandler Login_Error; + + #endregion + + #region area proprietà + + /// + /// modalità funzionamento controllo tra normale (ActiveDirectory e user auth di default) e forceUser + /// + public loginMode modoLogin + { + get + { + return _isForceUser; + } + set + { + _isForceUser = value; + } + } + + #endregion + + + /// + /// avvio pagina + /// + protected void Page_Load(object sender, EventArgs e) + { + // procedo... + setLoginMode(); + Session.RemoveAll(); + if (_isForceUser == loginMode.normale) + { + AdLogin(); + } + } + + #endregion +} diff --git a/PROJ-ETS/PROJ-ETS/WebUserControls/mod_login.ascx.designer.cs b/PROJ-ETS/PROJ-ETS/WebUserControls/mod_login.ascx.designer.cs new file mode 100644 index 0000000..7d2f20b --- /dev/null +++ b/PROJ-ETS/PROJ-ETS/WebUserControls/mod_login.ascx.designer.cs @@ -0,0 +1,112 @@ +//------------------------------------------------------------------------------ +// +// This code was generated by a tool. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +// +//------------------------------------------------------------------------------ + + + +public partial class mod_login { + + /// + /// pnlForceUser control. + /// + /// + /// Auto-generated field. + /// To modify move field declaration from designer file to code-behind file. + /// + protected global::System.Web.UI.WebControls.Panel pnlForceUser; + + /// + /// lblTitolo control. + /// + /// + /// Auto-generated field. + /// To modify move field declaration from designer file to code-behind file. + /// + protected global::System.Web.UI.WebControls.Label lblTitolo; + + /// + /// lblPwd control. + /// + /// + /// Auto-generated field. + /// To modify move field declaration from designer file to code-behind file. + /// + protected global::System.Web.UI.WebControls.Label lblPwd; + + /// + /// authKey control. + /// + /// + /// Auto-generated field. + /// To modify move field declaration from designer file to code-behind file. + /// + protected global::System.Web.UI.WebControls.TextBox authKey; + + /// + /// lblDominio control. + /// + /// + /// Auto-generated field. + /// To modify move field declaration from designer file to code-behind file. + /// + protected global::System.Web.UI.WebControls.Label lblDominio; + + /// + /// dominio control. + /// + /// + /// Auto-generated field. + /// To modify move field declaration from designer file to code-behind file. + /// + protected global::System.Web.UI.WebControls.TextBox dominio; + + /// + /// lblUser control. + /// + /// + /// Auto-generated field. + /// To modify move field declaration from designer file to code-behind file. + /// + protected global::System.Web.UI.WebControls.Label lblUser; + + /// + /// user control. + /// + /// + /// Auto-generated field. + /// To modify move field declaration from designer file to code-behind file. + /// + protected global::System.Web.UI.WebControls.TextBox user; + + /// + /// btnOk control. + /// + /// + /// Auto-generated field. + /// To modify move field declaration from designer file to code-behind file. + /// + protected global::System.Web.UI.WebControls.Button btnOk; + + /// + /// lblMessage control. + /// + /// + /// Auto-generated field. + /// To modify move field declaration from designer file to code-behind file. + /// + protected global::System.Web.UI.WebControls.Label lblMessage; + + /// + /// HypLinkSSO control. + /// + /// + /// Auto-generated field. + /// To modify move field declaration from designer file to code-behind file. + /// + protected global::System.Web.UI.WebControls.HyperLink HypLinkSSO; +} diff --git a/PROJ-ETS/PROJ-ETS/WebUserControls/mod_testata.ascx.cs b/PROJ-ETS/PROJ-ETS/WebUserControls/mod_testata.ascx.cs index 69a0aeb..c9dcc4f 100644 --- a/PROJ-ETS/PROJ-ETS/WebUserControls/mod_testata.ascx.cs +++ b/PROJ-ETS/PROJ-ETS/WebUserControls/mod_testata.ascx.cs @@ -30,7 +30,7 @@ namespace PROJ_ETS.WebUserControls { if (!Page.IsPostBack) { - //SetUpByUserRight(); + SetUpByUserRight(); } lblUser.Text = string.Format("{0} ({1})", utils.obj.currUserCognomeNome, utils.obj.currUserId); lblPostazione.Text = Request.UserHostName; @@ -74,7 +74,7 @@ namespace PROJ_ETS.WebUserControls Response.Redirect("login.aspx"); } // verifica i permessi dell'utente per almeno vedere la pagina corrente SSE non è una common page... - if (!user_std.UtSn.isPageEnabled(_paginaCorrente) && utils.obj.confReadString("_commonPages").IndexOf(_paginaCorrente) == -1) + if (!user_std.UtSn.isPageEnabled(_paginaCorrente.Replace(".aspx","")) && utils.obj.confReadString("_commonPages").IndexOf(_paginaCorrente) == -1) { lg.Info(string.Format("Errore in SetUpByUserRight: utente {0} non autorizzato per la pagina {1}", user_std.UtSn.utente, _paginaCorrente)); Response.Redirect("unauthorized.aspx"); diff --git a/PROJ-ETS/PROJ-ETS/bin/ETS_Data.dll b/PROJ-ETS/PROJ-ETS/bin/ETS_Data.dll index 73a0121..2b28038 100644 Binary files a/PROJ-ETS/PROJ-ETS/bin/ETS_Data.dll and b/PROJ-ETS/PROJ-ETS/bin/ETS_Data.dll differ diff --git a/PROJ-ETS/PROJ-ETS/bin/NLog.config b/PROJ-ETS/PROJ-ETS/bin/NLog.config index 3bb347b..b3b2330 100644 --- a/PROJ-ETS/PROJ-ETS/bin/NLog.config +++ b/PROJ-ETS/PROJ-ETS/bin/NLog.config @@ -20,10 +20,8 @@ - - - + + + \ No newline at end of file diff --git a/PROJ-ETS/PROJ-ETS/bin/PROJ-ETS.dll b/PROJ-ETS/PROJ-ETS/bin/PROJ-ETS.dll index d0527e0..c1174f3 100644 Binary files a/PROJ-ETS/PROJ-ETS/bin/PROJ-ETS.dll and b/PROJ-ETS/PROJ-ETS/bin/PROJ-ETS.dll differ diff --git a/PROJ-ETS/PROJ-ETS/logs/2013-05-23.log b/PROJ-ETS/PROJ-ETS/logs/2013-05-23.log new file mode 100644 index 0000000..42d9ca7 --- /dev/null +++ b/PROJ-ETS/PROJ-ETS/logs/2013-05-23.log @@ -0,0 +1,64 @@ +2013-05-23 14:46:14.6537 [INFO] User login: Locatelli Samuele (STEAMWAREWIN\samuele) +2013-05-23 14:46:14.8397 [WARN] Accesso fallito: user non autorizzato e autoenroll non attivo: STEAMWAREWIN\samuele +2013-05-23 14:52:09.5068 [INFO] User login: Locatelli Samuele (STEAMWAREWIN\samuele) +2013-05-23 14:52:09.5248 [WARN] Accesso fallito: user non autorizzato e autoenroll non attivo: STEAMWAREWIN\samuele +2013-05-23 14:52:17.1219 [INFO] User login: Locatelli Samuele (STEAMWAREWIN\samuele) +2013-05-23 14:52:17.3379 [WARN] Accesso fallito: user non autorizzato e autoenroll non attivo: STEAMWAREWIN\samuele +2013-05-23 14:53:20.4073 [INFO] User login: Locatelli Samuele (STEAMWAREWIN\samuele) +2013-05-23 14:56:56.8955 [WARN] Accesso fallito: user non autorizzato e autoenroll non attivo: STEAMWAREWIN\samuele +2013-05-23 14:57:16.0214 [INFO] User login: Locatelli Samuele (STEAMWAREWIN\samuele) +2013-05-23 15:00:34.6279 [WARN] Accesso fallito: user non autorizzato e autoenroll non attivo: STEAMWAREWIN\samuele +2013-05-23 15:00:43.5693 [INFO] User login: Locatelli Samuele (STEAMWAREWIN\samuele) +2013-05-23 15:00:43.7443 [INFO] L'utente Locatelli Samuele (STEAMWAREWIN\samuele) ha effettuato il login correttamente +2013-05-23 15:00:43.7513 [INFO] Errore in SetUpByUserRight: utente samuele non autorizzato per la pagina menu.aspx +2013-05-23 15:00:53.2687 [INFO] User login: Locatelli Samuele (STEAMWAREWIN\samuele) +2013-05-23 15:01:15.7090 [INFO] L'utente Locatelli Samuele (STEAMWAREWIN\samuele) ha effettuato il login correttamente +2013-05-23 15:01:18.3904 [INFO] Errore in SetUpByUserRight: utente samuele non autorizzato per la pagina menu.aspx +2013-05-23 15:03:00.5136 [INFO] User login: Locatelli Samuele (STEAMWAREWIN\samuele) +2013-05-23 15:03:00.5246 [INFO] Errore in SetUpByUserRight: utente samuele non autorizzato per la pagina Menu.aspx +2013-05-23 15:03:06.5755 [INFO] User login: Locatelli Samuele (STEAMWAREWIN\samuele) +2013-05-23 15:03:06.5755 [INFO] Errore in SetUpByUserRight: utente samuele non autorizzato per la pagina Menu.aspx +2013-05-23 15:05:14.0315 [INFO] User login: Locatelli Samuele (STEAMWAREWIN\samuele) +2013-05-23 15:05:14.0315 [INFO] Errore in SetUpByUserRight: utente samuele non autorizzato per la pagina Menu.aspx +2013-05-23 15:05:30.1129 [INFO] User login: Locatelli Samuele (STEAMWAREWIN\samuele) +2013-05-23 15:05:41.5706 [INFO] L'utente Locatelli Samuele (STEAMWAREWIN\samuele) ha effettuato il login correttamente +2013-05-23 15:05:56.6628 [INFO] Errore in SetUpByUserRight: utente samuele non autorizzato per la pagina Menu +2013-05-23 15:06:14.0824 [INFO] Errore in SetUpByUserRight: utente samuele non autorizzato per la pagina Progetti +2013-05-23 15:06:58.9041 [INFO] User login: Locatelli Samuele (STEAMWAREWIN\samuele) +2013-05-23 15:06:59.3782 [INFO] L'utente Locatelli Samuele (STEAMWAREWIN\samuele) ha effettuato il login correttamente +2013-05-23 15:09:04.6388 [INFO] Errore in SetUpByUserRight: utente samuele non autorizzato per la pagina Menu +2013-05-23 15:12:32.0907 [INFO] User login: Locatelli Samuele (STEAMWAREWIN\samuele) +2013-05-23 15:12:32.2987 [INFO] L'utente Locatelli Samuele (STEAMWAREWIN\samuele) ha effettuato il login correttamente +2013-05-23 15:12:46.2938 [INFO] Errore in SetUpByUserRight: utente samuele non autorizzato per la pagina DatiCommessa +2013-05-23 15:12:46.3338 [ERROR] Errore di accesso alla pagina DatiCommessa +2013-05-23 15:13:26.5128 [INFO] Errore in SetUpByUserRight: utente samuele non autorizzato per la pagina DatiCommessa +2013-05-23 15:13:26.5188 [ERROR] Errore di accesso alla pagina DatiCommessa +2013-05-23 15:13:47.7019 [INFO] Errore in SetUpByUserRight: utente samuele non autorizzato per la pagina DatiCommessa +2013-05-23 15:13:47.7019 [ERROR] Errore di accesso alla pagina DatiCommessa +2013-05-23 15:13:50.2673 [INFO] L'utente Locatelli Samuele (STEAMWAREWIN\samuele) ha effettuato il login correttamente +2013-05-23 15:13:54.8060 [INFO] Errore in SetUpByUserRight: utente samuele non autorizzato per la pagina DatiCommessa +2013-05-23 15:13:54.8060 [ERROR] Errore di accesso alla pagina DatiCommessa +2013-05-23 15:14:45.8646 [INFO] Errore in SetUpByUserRight: utente samuele non autorizzato per la pagina DatiCommessa +2013-05-23 15:14:45.8646 [ERROR] Errore di accesso alla pagina DatiCommessa +2013-05-23 15:14:53.2347 [INFO] Errore in SetUpByUserRight: utente samuele non autorizzato per la pagina DatiCommessa +2013-05-23 15:14:53.2417 [ERROR] Errore di accesso alla pagina DatiCommessa +2013-05-23 15:15:00.5238 [INFO] L'utente Locatelli Samuele (STEAMWAREWIN\samuele) ha effettuato il login correttamente +2013-05-23 15:15:01.2859 [INFO] L'utente Locatelli Samuele (STEAMWAREWIN\samuele) ha effettuato il login correttamente +2013-05-23 15:15:09.8732 [INFO] Errore in SetUpByUserRight: utente samuele non autorizzato per la pagina FasiCommessa +2013-05-23 15:15:09.8732 [ERROR] Errore di accesso alla pagina FasiCommessa +2013-05-23 15:15:30.9543 [INFO] Errore in SetUpByUserRight: utente samuele non autorizzato per la pagina FornitoriCommessa +2013-05-23 15:15:30.9613 [ERROR] Errore di accesso alla pagina FornitoriCommessa +2013-05-23 15:16:02.9971 [INFO] Errore in SetUpByUserRight: utente samuele non autorizzato per la pagina RiepilogoCommessa +2013-05-23 15:16:02.9971 [ERROR] Errore di accesso alla pagina RiepilogoCommessa +2013-05-23 15:16:19.3855 [INFO] L'utente Locatelli Samuele (STEAMWAREWIN\samuele) ha effettuato il login correttamente +2013-05-23 15:16:22.9830 [INFO] Errore in SetUpByUserRight: utente samuele non autorizzato per la pagina FasiCommessa +2013-05-23 15:16:22.9900 [ERROR] Errore di accesso alla pagina FasiCommessa +2013-05-23 15:16:30.3651 [INFO] L'utente Locatelli Samuele (STEAMWAREWIN\samuele) ha effettuato il login correttamente +2013-05-23 15:16:31.0042 [INFO] L'utente Locatelli Samuele (STEAMWAREWIN\samuele) ha effettuato il login correttamente +2013-05-23 15:16:36.0470 [INFO] Errore in SetUpByUserRight: utente samuele non autorizzato per la pagina FasiCommessa +2013-05-23 15:16:36.0470 [ERROR] Errore di accesso alla pagina FasiCommessa +2013-05-23 15:19:08.4757 [INFO] User login: Locatelli Samuele (STEAMWAREWIN\samuele) +2013-05-23 15:19:08.7057 [INFO] L'utente Locatelli Samuele (STEAMWAREWIN\samuele) ha effettuato il login correttamente +2013-05-23 15:19:21.4486 [INFO] Errore in SetUpByUserRight: utente samuele non autorizzato per la pagina FasiCommessa +2013-05-23 15:19:21.4876 [ERROR] Errore di accesso alla pagina FasiCommessa +2013-05-23 15:27:35.9792 [INFO] L'utente Locatelli Samuele (STEAMWAREWIN\samuele) ha effettuato il login correttamente diff --git a/PROJ-ETS/PROJ-ETS/obj/Debug/DesignTimeResolveAssemblyReferencesInput.cache b/PROJ-ETS/PROJ-ETS/obj/Debug/DesignTimeResolveAssemblyReferencesInput.cache index ac44c12..92a5c3f 100644 Binary files a/PROJ-ETS/PROJ-ETS/obj/Debug/DesignTimeResolveAssemblyReferencesInput.cache and b/PROJ-ETS/PROJ-ETS/obj/Debug/DesignTimeResolveAssemblyReferencesInput.cache differ diff --git a/PROJ-ETS/PROJ-ETS/obj/Debug/PROJ-ETS.csprojResolveAssemblyReference.cache b/PROJ-ETS/PROJ-ETS/obj/Debug/PROJ-ETS.csprojResolveAssemblyReference.cache index 0a889bb..0420700 100644 Binary files a/PROJ-ETS/PROJ-ETS/obj/Debug/PROJ-ETS.csprojResolveAssemblyReference.cache and b/PROJ-ETS/PROJ-ETS/obj/Debug/PROJ-ETS.csprojResolveAssemblyReference.cache differ diff --git a/PROJ-ETS/PROJ-ETS/obj/Debug/PROJ-ETS.dll b/PROJ-ETS/PROJ-ETS/obj/Debug/PROJ-ETS.dll index d0527e0..c1174f3 100644 Binary files a/PROJ-ETS/PROJ-ETS/obj/Debug/PROJ-ETS.dll and b/PROJ-ETS/PROJ-ETS/obj/Debug/PROJ-ETS.dll differ diff --git a/PROJ-ETS/PROJ-ETS/unauthorized.aspx b/PROJ-ETS/PROJ-ETS/unauthorized.aspx new file mode 100644 index 0000000..180dc45 --- /dev/null +++ b/PROJ-ETS/PROJ-ETS/unauthorized.aspx @@ -0,0 +1,19 @@ +<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="unauthorized.aspx.cs" Inherits="PROJ_ETS.unauthorized" %> + + + + + + + + +
+
+

Attenzione!

+ Utente non abilitato all'accesso. +
+ +
+
+ + diff --git a/PROJ-ETS/PROJ-ETS/unauthorized.aspx.cs b/PROJ-ETS/PROJ-ETS/unauthorized.aspx.cs new file mode 100644 index 0000000..a992490 --- /dev/null +++ b/PROJ-ETS/PROJ-ETS/unauthorized.aspx.cs @@ -0,0 +1,23 @@ +using System; +using System.Collections.Generic; +using System.Linq; +using System.Web; +using System.Web.UI; +using System.Web.UI.WebControls; +using ETS_Data; +using NLog; + +namespace PROJ_ETS +{ + public partial class unauthorized : System.Web.UI.Page + { + + protected Logger lg = LogManager.GetCurrentClassLogger(); + + protected void Page_Load(object sender, EventArgs e) + { + pgReq.Text = string.Format("Errore di accesso alla pagina {0}", utils.obj.StringSessionObj("_paginaPrecedente")); + lg.Error(pgReq.Text); + } + } +} \ No newline at end of file diff --git a/PROJ-ETS/PROJ-ETS/unauthorized.aspx.designer.cs b/PROJ-ETS/PROJ-ETS/unauthorized.aspx.designer.cs new file mode 100644 index 0000000..ffe88bc --- /dev/null +++ b/PROJ-ETS/PROJ-ETS/unauthorized.aspx.designer.cs @@ -0,0 +1,33 @@ +//------------------------------------------------------------------------------ +// +// This code was generated by a tool. +// +// Changes to this file may cause incorrect behavior and will be lost if +// the code is regenerated. +// +//------------------------------------------------------------------------------ + +namespace PROJ_ETS { + + + public partial class unauthorized { + + /// + /// form1 control. + /// + /// + /// Auto-generated field. + /// To modify move field declaration from designer file to code-behind file. + /// + protected global::System.Web.UI.HtmlControls.HtmlForm form1; + + /// + /// pgReq control. + /// + /// + /// Auto-generated field. + /// To modify move field declaration from designer file to code-behind file. + /// + protected global::System.Web.UI.WebControls.Label pgReq; + } +}