Thread: [simias-svn] SF.net SVN: simias:[7320] branches/iFolder_3.8.0_updates/src
Brought to you by:
srinidhi_bs
|
From: <he...@us...> - 2010-02-28 06:24:42
|
Revision: 7320
http://simias.svn.sourceforge.net/simias/?rev=7320&view=rev
Author: hegdegg
Date: 2010-02-28 06:24:36 +0000 (Sun, 28 Feb 2010)
Log Message:
-----------
When the ip address is changed from web console, apart from saving it in
the config file its also updated into simias.
Modified Paths:
--------------
branches/iFolder_3.8.0_updates/src/server/setup/iFolderWebSetup.cs
branches/iFolder_3.8.0_updates/src/webservices/iFolderServer.cs
Modified: branches/iFolder_3.8.0_updates/src/server/setup/iFolderWebSetup.cs
===================================================================
--- branches/iFolder_3.8.0_updates/src/server/setup/iFolderWebSetup.cs 2010-02-28 05:28:55 UTC (rev 7319)
+++ branches/iFolder_3.8.0_updates/src/server/setup/iFolderWebSetup.cs 2010-02-28 06:24:36 UTC (rev 7320)
@@ -135,10 +135,30 @@
SetupModMono();
#endif
SetupSsl();
-
+
+ UpdateOwnership();
// CheckConnection();
}
+ /// <summary>
+ /// Change the ownership of web.config to apache user so that iFolder
+ /// server can chnage the values while running.
+ /// </summary>
+ void UpdateOwnership()
+ {
+ string MachineArch = Environment.GetEnvironmentVariable("OS_TYPE");
+ string webpath = (MachineArch.IndexOf("_64") > 0) ? Path.GetFullPath("../lib64/simias/web"): Path.GetFullPath("../lib/simiasweb");
+ string webconfigfile = Path.Combine(webpath, "web.config");
+ if (Execute("chown", "{0}:{1} {2}", apacheUser.Value, apacheGroup.Value, webconfigfile) != 0)
+ {
+ throw new Exception("Unable to set an owner for the log path.");
+ }
+ }
+
+ /// <summary>
+ /// Initialize web-access setup
+ /// </summary>
+
/// <summary>
/// Initialize web-access setup
/// </summary>
Modified: branches/iFolder_3.8.0_updates/src/webservices/iFolderServer.cs
===================================================================
--- branches/iFolder_3.8.0_updates/src/webservices/iFolderServer.cs 2010-02-28 05:28:55 UTC (rev 7319)
+++ branches/iFolder_3.8.0_updates/src/webservices/iFolderServer.cs 2010-02-28 06:24:36 UTC (rev 7320)
@@ -586,7 +586,7 @@
bool UpdateStatus = false;
string ServerSection="Server";
string PublicAddressKey = "PublicAddress";
- string PrivateAddressKey = "PrivateAddress";
+ string PrivateAddressKey = "PrivateAddress";
string MasterAddressKey = "MasterAddress";
if (!privateUrl.ToLower().StartsWith(Uri.UriSchemeHttp))
{
@@ -596,12 +596,15 @@
{
publicUrl = (new UriBuilder(Uri.UriSchemeHttp, publicUrl)).ToString();
}
+ if (MasterUrl != null && !privateUrl.ToLower().StartsWith(Uri.UriSchemeHttp))
+ {
+ MasterUrl = (new UriBuilder(Uri.UriSchemeHttp, MasterUrl)).ToString();
+ }
// adding /simias10
privateUrl = AddVirtualPath( privateUrl );
publicUrl = AddVirtualPath( publicUrl );
-
-
+
string SimiasConfigFilePath = Path.Combine ( Store.StorePath, "Simias.config");
if ( File.Exists( Path.Combine( Store.StorePath, Simias.Configuration.DefaultConfigFileName ) ) == true )
{
@@ -618,6 +621,7 @@
XmlDocument document = new XmlDocument();
document.Load(SimiasConfigFilePath );
+
SetConfigValue( document, ServerSection, PublicAddressKey, publicUrl );
SetConfigValue( document, ServerSection, PrivateAddressKey, privateUrl );
if(MasterUrl != "")
@@ -626,6 +630,12 @@
UpdateStatus = SetConfigValueWithSSL( document, ServerSection, MasterAddressKey, MasterUrl );
if(UpdateStatus == false)
return false;
+ if (MasterUrl != null)
+ {
+ UpdateStatus = UpdateMasterURL(MasterUrl);
+ if(UpdateStatus == false)
+ return false;
+ }
}
// Commit the config file changes.
@@ -636,8 +646,52 @@
{
SmartException.Throw(ex);
}
+ // Also update in the simias.
+ SetOnMasterUpdateUri(RemoveVirtualPath(privateUrl), RemoveVirtualPath(publicUrl));
+
return UpdateStatus;
}
+ /// <summary>
+ /// Update the Master Url in the local store
+ /// </summary>
+ /// <param name="masterUrl">
+ /// A <see cref="System.String"/>
+ /// </param>
+ /// /// <returns>
+ /// A <see cref="System.Boolean"/>
+ /// </returns>
+ private static bool UpdateMasterURL( string masterUrl)
+ {
+ bool retVal = true;;
+ try
+ {
+ Store store = Store.GetStore();
+ Domain domain = store.GetDomain(store.DefaultDomain);
+ HostNode masterNode = HostNode.GetMaster(domain.ID);
+ masterNode.PrivateUrl = masterUrl;
+ domain.Commit(masterNode);
+ }
+ catch (Exception ex)
+ {
+ log.Debug("Exception in UpdateMasterURL" + ex.Message);
+ retVal = false;
+ }
+ return retVal;
+ }
+ /// <summary>
+ /// Adds simias10 into the path
+ /// </summary>
+ /// <param name="path"></param>
+ /// <returns>new path</returns>
+ private static string RemoveVirtualPath(string path)
+ {
+ path = path.TrimEnd('/');
+ if(path.EndsWith("/simias10") == true)
+ {
+ path = path.Substring(0, path.IndexOf("simias10"));
+ }
+ return path;
+ }
/// <summary>
/// Adds simias10 into the path
@@ -746,7 +800,8 @@
{
if (masterAddress.ToLower().StartsWith(Uri.UriSchemeHttps))
{
- string webPath = Path.GetFullPath("../../../../lib/simias/web");
+ string machineArch = Environment.GetEnvironmentVariable("OS_TYPE");
+ string webPath = ( machineArch.IndexOf("_64" ) > 0 ? Path.GetFullPath("../../../../lib64/simias/web"): Path.GetFullPath("../../../../lib/simias/web"));
// swap policy
ServicePointManager.CertificatePolicy = new TrustAllCertificatePolicy();
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <he...@us...> - 2010-03-10 06:10:45
|
Revision: 7326
http://simias.svn.sourceforge.net/simias/?rev=7326&view=rev
Author: hegdegg
Date: 2010-03-10 06:10:38 +0000 (Wed, 10 Mar 2010)
Log Message:
-----------
Error handling for admin setup. Fixed the check of incorrect environment
variable to decide the os architecture.
Modified Paths:
--------------
branches/iFolder_3.8.0_updates/src/server/setup/iFolderWebSetup.cs
branches/iFolder_3.8.0_updates/src/webservices/iFolderServer.cs
Modified: branches/iFolder_3.8.0_updates/src/server/setup/iFolderWebSetup.cs
===================================================================
--- branches/iFolder_3.8.0_updates/src/server/setup/iFolderWebSetup.cs 2010-03-10 03:27:52 UTC (rev 7325)
+++ branches/iFolder_3.8.0_updates/src/server/setup/iFolderWebSetup.cs 2010-03-10 06:10:38 UTC (rev 7326)
@@ -145,13 +145,21 @@
/// </summary>
void UpdateOwnership()
{
- string MachineArch = Environment.GetEnvironmentVariable("OS_TYPE");
- string webpath = (MachineArch.IndexOf("_64") > 0) ? Path.GetFullPath("../lib64/simias/web"): Path.GetFullPath("../lib/simiasweb");
- string webconfigfile = Path.Combine(webpath, "web.config");
+ try
+ {
+ string MachineArch = Environment.GetEnvironmentVariable("HOSTTYPE");
+ string webpath = (MachineArch.IndexOf("_64") > 0) ? Path.GetFullPath("../lib64/simias/web"): Path.GetFullPath("../lib/simiasweb");
+ string webconfigfile = Path.Combine(webpath, "web.config");
- if (Execute("chown", "{0}:{1} {2}", apacheUser.Value, apacheGroup.Value, webconfigfile) != 0)
+ if (Execute("chown", "{0}:{1} {2}", apacheUser.Value, apacheGroup.Value, webconfigfile) != 0)
+ {
+ throw new Exception("Unable to set an owner for the web.config file.");
+ }
+ }
+ catch (Exception ex)
{
- throw new Exception("Unable to set an owner for the log path.");
+ Console.WriteLine("Unable to set an owner for web.config file");
+
}
}
Modified: branches/iFolder_3.8.0_updates/src/webservices/iFolderServer.cs
===================================================================
--- branches/iFolder_3.8.0_updates/src/webservices/iFolderServer.cs 2010-03-10 03:27:52 UTC (rev 7325)
+++ branches/iFolder_3.8.0_updates/src/webservices/iFolderServer.cs 2010-03-10 06:10:38 UTC (rev 7326)
@@ -800,7 +800,7 @@
{
if (masterAddress.ToLower().StartsWith(Uri.UriSchemeHttps))
{
- string machineArch = Environment.GetEnvironmentVariable("OS_TYPE");
+ string machineArch = Environment.GetEnvironmentVariable("HOSTTYPE");
string webPath = ( machineArch.IndexOf("_64" ) > 0 ? Path.GetFullPath("../../../../lib64/simias/web"): Path.GetFullPath("../../../../lib/simias/web"));
// swap policy
ServicePointManager.CertificatePolicy = new TrustAllCertificatePolicy();
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <ra...@us...> - 2010-04-21 05:42:02
|
Revision: 7333
http://simias.svn.sourceforge.net/simias/?rev=7333&view=rev
Author: ravim85
Date: 2010-04-21 05:41:55 +0000 (Wed, 21 Apr 2010)
Log Message:
-----------
These changes are for supporting muti byte chars for Authentication
Creds are encoded ans sent for Auth. If a new client is connecting to
old server, then auth fails and we fall back and send creds in
non_encoded format
Modified Paths:
--------------
branches/iFolder_3.8.0_updates/src/admin/Login.aspx.cs
branches/iFolder_3.8.0_updates/src/core/Common/WebState.cs
branches/iFolder_3.8.0_updates/src/core/Domain/DomainAgent.cs
branches/iFolder_3.8.0_updates/src/core/Sync/Http.cs
branches/iFolder_3.8.0_updates/src/server/Simias.Server/Authentication.cs
branches/iFolder_3.8.0_updates/src/webaccess/Login.aspx.cs
branches/iFolder_3.8.0_updates/src/webservices/iFolderServer.cs
Modified: branches/iFolder_3.8.0_updates/src/admin/Login.aspx.cs
===================================================================
--- branches/iFolder_3.8.0_updates/src/admin/Login.aspx.cs 2010-04-13 04:11:28 UTC (rev 7332)
+++ branches/iFolder_3.8.0_updates/src/admin/Login.aspx.cs 2010-04-21 05:41:55 UTC (rev 7333)
@@ -412,9 +412,16 @@
webUrl.Path = (new Uri(web.Url)).PathAndQuery;
web.Url = webUrl.Uri.ToString();
+ UTF8Encoding utf8Name = new UTF8Encoding();
+ byte[] encodedCredsByteArray = utf8Name.GetBytes(username);
+ string iFolderUserBase64 = Convert.ToBase64String(encodedCredsByteArray);
+
+ encodedCredsByteArray = utf8Name.GetBytes(password);
+ string iFolderPassBase64 = Convert.ToBase64String(encodedCredsByteArray);
+
// credentials
web.PreAuthenticate = true;
- web.Credentials = new NetworkCredential(username, password);
+ web.Credentials = new NetworkCredential(iFolderUserBase64, iFolderPassBase64);
// cookies
web.CookieContainer = new CookieContainer();
@@ -444,9 +451,8 @@
iFolderServer server = web.GetHomeServer();
Session["Version"] = server.Version;
- UTF8Encoding utf8Name = new UTF8Encoding();
- byte[] EncodedUserNameInByte = utf8Name.GetBytes(user.UserName);
- string iFolderUserBase64 = Convert.ToBase64String(EncodedUserNameInByte);
+ encodedCredsByteArray = utf8Name.GetBytes(user.UserName);
+ iFolderUserBase64 = Convert.ToBase64String(encodedCredsByteArray);
// new username cookie for 30 days
Response.Cookies["username"].Value = iFolderUserBase64;
Modified: branches/iFolder_3.8.0_updates/src/core/Common/WebState.cs
===================================================================
--- branches/iFolder_3.8.0_updates/src/core/Common/WebState.cs 2010-04-13 04:11:28 UTC (rev 7332)
+++ branches/iFolder_3.8.0_updates/src/core/Common/WebState.cs 2010-04-21 05:41:55 UTC (rev 7333)
@@ -36,6 +36,7 @@
using System.Collections;
using System.Web;
using System.Net;
+using System.Text;
using System.Web.Services.Protocols;
using Simias.Storage;
@@ -281,7 +282,12 @@
{
member = Store.GetStore().GetDomain( DomainID ).GetMemberByID( UserID );
}
- creds = new BasicCredentials( DomainID, CollectionID, member.Name );
+
+ UTF8Encoding utf8Name = new UTF8Encoding();
+ byte[] encodedCredsByteArray = utf8Name.GetBytes(member.Name);
+ string iFolderUserBase64 = Convert.ToBase64String(encodedCredsByteArray);
+
+ creds = new BasicCredentials( DomainID, CollectionID,iFolderUserBase64);
if ( creds.Cached == true )
{
credentials = creds.GetNetworkCredential();
@@ -289,7 +295,7 @@
else
{
// Get the credentials for this collection.
- creds = new BasicCredentials( DomainID, DomainID, member.Name );
+ creds = new BasicCredentials( DomainID, DomainID, iFolderUserBase64 );
if ( creds.Cached == true )
{
credentials = creds.GetNetworkCredential();
Modified: branches/iFolder_3.8.0_updates/src/core/Domain/DomainAgent.cs
===================================================================
--- branches/iFolder_3.8.0_updates/src/core/Domain/DomainAgent.cs 2010-04-13 04:11:28 UTC (rev 7332)
+++ branches/iFolder_3.8.0_updates/src/core/Domain/DomainAgent.cs 2010-04-21 05:41:55 UTC (rev 7333)
@@ -35,6 +35,7 @@
using System.Collections;
using System.Net;
using System.IO;
+using System.Text;
using System.Threading;
using System.Web;
using System.Xml;
@@ -247,21 +248,7 @@
request.Headers.Add(
Simias.Security.Web.AuthenticationService.Login.BasicEncodingHeader,
-#if MONO
- // bht: Fix for Bug 73324 - Client fails to authenticate if LDAP
- // username has an international character in it.
- //
- // Mono converts the username and password to a byte array
- // without paying attention to the encoding. In NLD, the
- // default encoding is UTF-8. Without this fix, we ended up
- // sending the username and password in 1252 but the server
- // was attempting to decode it as UTF-8. This fix forces the
- // username and password to be sent with Windows-1252 encoding
- // which properly gets decoded on the server.
- System.Text.Encoding.GetEncoding(1252).WebName );
-#else
- System.Text.Encoding.Default.WebName );
-#endif
+ System.Text.Encoding.UTF8.WebName );
request.Method = "POST";
request.ContentLength = 0;
@@ -553,8 +540,16 @@
domainServiceUrl = new Uri( tempUri.Uri , DomainServicePath );
}
+ UTF8Encoding utf8Name = new UTF8Encoding();
+ byte[] encodedCredsByteArray = utf8Name.GetBytes(user);
+ string iFolderUserBase64 = Convert.ToBase64String(encodedCredsByteArray);
+
+ encodedCredsByteArray = utf8Name.GetBytes(password);
+ string iFolderPassBase64 = Convert.ToBase64String(encodedCredsByteArray);
+
// Build a credential from the user name and password.
- NetworkCredential myCred = new NetworkCredential( user, password );
+ NetworkCredential myCred = new NetworkCredential( iFolderUserBase64, iFolderPassBase64 );
+ NetworkCredential myOldCred = new NetworkCredential( user, password );
// Create the domain service web client object.
DomainService domainService = new DomainService();
@@ -598,6 +593,11 @@
string baseUrl = domainServiceUrl.ToString();
baseUrl = baseUrl.Substring(0, baseUrl.LastIndexOf('/'));
+ // This flag is used to identify if server is old and not supporting multi byte login
+ // Then creds are sent with out encoding again.
+
+ bool oldServer = false;
+
//Login to the server mentioned by the user, possible the user is already provisioned and this is a different client that is creating an account
status =
this.Login(
@@ -608,12 +608,24 @@
if ((status.statusCode != SCodes.Success) && (status.statusCode != SCodes.SuccessInGrace) && (status.statusCode != SCodes.UserAlreadyMoved))
{
log.Debug("Got Status {0}", status.statusCode);
- return status;
+ if( status.statusCode == SCodes.InvalidCredentials )
+ {
+ // Post 3.8.0.2, multibyte char support for usernames and password is added
+ // If a new client is connecting to an old server, then auth will fail as creds
+ // are encoded. Hence we try once more without encoding the creds.
+ log.Debug("This might be old server 3.8.0.2 with no multi byte support, trying once more with out encoding the creds");
+ status = this.Login( new Uri( baseUrl ), domainID, myOldCred, false );
+ if ( status.statusCode == SCodes.Success || status.statusCode == SCodes.SuccessInGrace )
+ oldServer = true;
+ else
+ return status;
+ }
}
else
log.Debug("Got else Status {0}", status.statusCode);
// Get the Home Server.
+ domainService.Credentials = oldServer ? myOldCred : myCred ;
string hostID = null;
HostInfo hInfo = new HostInfo();
@@ -635,7 +647,7 @@
DomainService ds = new DomainService();
ds.CookieContainer = cookies;
ds.Url = (new Uri(masterServerURL.TrimEnd(new char[] { '/' }) + DomainService)).ToString();
- ds.Credentials = myCred;
+ ds.Credentials = oldServer ? myOldCred : myCred;
ds.PreAuthenticate = true;
// ds.Proxy = ProxyState.GetProxyState( domainServiceUrl );
ds.AllowAutoRedirect = true;
@@ -690,7 +702,7 @@
this.Login(
new Uri( hInfo.PublicAddress ),
domainID,
- myCred,
+ oldServer ? myOldCred : myCred,
false);
if ( ( status.statusCode != SCodes.Success ) && ( status.statusCode != SCodes.SuccessInGrace ) )
{
@@ -721,7 +733,7 @@
// Save the credentials
CredentialCache myCache = new CredentialCache();
- myCache.Add(new Uri(domainService.Url), "Basic", myCred);
+ myCache.Add(new Uri(domainService.Url), "Basic", oldServer ? myOldCred : myCred);
domainService.Credentials = myCache;
domainService.Timeout = 30000;
@@ -892,7 +904,22 @@
log.Debug( "Login - called" );
log.Debug( " DomainID: " + DomainID );
log.Debug( " Username: " + Username );
+
+ // This flag is used to identify if server is old and not supporting multi byte login
+ // Then creds are sent with out encoding again.
+
+ bool oldServer = false;
+ UTF8Encoding utf8Name = new UTF8Encoding();
+ byte[] encodedCredsByteArray = utf8Name.GetBytes(Username);
+ string iFolderUserBase64 = Convert.ToBase64String(encodedCredsByteArray);
+
+ encodedCredsByteArray = utf8Name.GetBytes(Password);
+ string iFolderPassBase64 = Convert.ToBase64String(encodedCredsByteArray);
+
+ NetworkCredential myCred = new NetworkCredential( iFolderUserBase64, iFolderPassBase64 );
+ NetworkCredential myOldCred = new NetworkCredential( Username, Password );
+
Simias.Authentication.Status status = null;
Domain cDomain = store.GetDomain( DomainID );
if ( cDomain != null )
@@ -911,7 +938,7 @@
this.Login(
tempUri.Uri,
DomainID,
- new NetworkCredential( Username, Password ),
+ myCred,
false );
if ( status.statusCode == SCodes.Success ||
@@ -921,16 +948,36 @@
new BasicCredentials(
DomainID,
DomainID,
- Username,
- Password );
+ iFolderUserBase64,
+ iFolderPassBase64 );
basic.Save( false );
SetDomainState( DomainID, true, true );
}
+ else
+ {
+ // Post 3.8.0.2, multibyte char support for usernames and password is added
+ // If a new client is connecting to an old server, then auth will fail as creds
+ // are encoded. Hence we try once more without encoding the creds.
+ log.Debug("possibly server is 3.8.0.2 not supporting multi byte,trying again without encoding creds ");
+ status = this.Login( tempUri.Uri, DomainID, myOldCred, false);
+ if ( status.statusCode == SCodes.Success || status.statusCode == SCodes.SuccessInGrace )
+ {
+ oldServer = true;
+ BasicCredentials basic =
+ new BasicCredentials(
+ DomainID,
+ DomainID,
+ Username,
+ Password);
+ basic.Save( false );
+ SetDomainState( DomainID, true, true);
+ }
+ }
if (status.statusCode == SCodes.UserAlreadyMoved && Password != null)
{
// Connect to master , and login to new server where user has been moved
- status = ProvisionToNewHomeServer(DomainID, new NetworkCredential(Username, Password));
+ status = ProvisionToNewHomeServer(DomainID, oldServer ? myOldCred : myCred);
return status;
}
}
Modified: branches/iFolder_3.8.0_updates/src/core/Sync/Http.cs
===================================================================
--- branches/iFolder_3.8.0_updates/src/core/Sync/Http.cs 2010-04-13 04:11:28 UTC (rev 7332)
+++ branches/iFolder_3.8.0_updates/src/core/Sync/Http.cs 2010-04-21 05:41:55 UTC (rev 7333)
@@ -294,7 +294,16 @@
WebHeaderCollection headers = request.Headers;
headers.Add(SyncHeaders.SyncVersion, HttpService.version);
headers.Add(SyncHeaders.Method, method.ToString());
- headers.Add(SyncHeaders.UserName, userName);
+ try {
+ headers.Add(SyncHeaders.UserName, userName);
+ }catch
+ {
+ // On Windows client, for some username with multi-byte chars,
+ // Exception occurs. However, we can ignore this as we would already
+ // have the user ID with us
+ log.Debug("Syncing multi byte char user name");
+ }
+
headers.Add(SyncHeaders.UserID, userID);
try {
//TODO: could be removed?
Modified: branches/iFolder_3.8.0_updates/src/server/Simias.Server/Authentication.cs
===================================================================
--- branches/iFolder_3.8.0_updates/src/server/Simias.Server/Authentication.cs 2010-04-13 04:11:28 UTC (rev 7332)
+++ branches/iFolder_3.8.0_updates/src/server/Simias.Server/Authentication.cs 2010-04-21 05:41:55 UTC (rev 7333)
@@ -36,6 +36,7 @@
using System.Reflection;
using System.Net;
using System.Web;
+using System.Text;
using System.Threading;
using Simias;
@@ -387,8 +388,8 @@
if ( credentials.Length == 2 )
{
- this.username = credentials[ 0 ];
- this.password = credentials[ 1 ];
+ this.username = DecodeCreds(credentials[ 0 ], encodingName);
+ this.password = DecodeCreds(credentials[ 1 ], encodingName);
this.authType = "basic";
returnStatus = true;
}
@@ -399,7 +400,30 @@
return returnStatus;
}
+
/// <summary>
+ /// Returns the decoded value of user creds if its encoded. Else will return the same [ Old Client ] .
+ /// </summary>
+ /// <returns>String - User Creds in String</returns>
+ private string DecodeCreds(string creds, string encodingName)
+ {
+ try
+ {
+ byte[] encodedCredsByteArray = Convert.FromBase64String(creds);
+ Encoding encoder = System.Text.Encoding.GetEncoding( encodingName );
+ return encoder.GetString(encodedCredsByteArray, 0, encodedCredsByteArray.Length);
+ }
+ catch(Exception ex)
+ {
+ // Exception occurs when we try to decode string which is not encoded
+ // TODO : Find the right exception and catch it.
+ return creds;
+ }
+
+ }
+
+
+ /// <summary>
/// Returns whether the object has credentials.
/// </summary>
/// <returns></returns>
@@ -454,7 +478,7 @@
defaultBasicEncodingName = Store.Config.Get( Storage.Domain.SectionName, Storage.Domain.Encoding );
if ( defaultBasicEncodingName == null )
{
- defaultBasicEncodingName = "iso-8859-1";
+ defaultBasicEncodingName = "utf-8";
}
store = Store.GetStore();
Modified: branches/iFolder_3.8.0_updates/src/webaccess/Login.aspx.cs
===================================================================
--- branches/iFolder_3.8.0_updates/src/webaccess/Login.aspx.cs 2010-04-13 04:11:28 UTC (rev 7332)
+++ branches/iFolder_3.8.0_updates/src/webaccess/Login.aspx.cs 2010-04-21 05:41:55 UTC (rev 7333)
@@ -450,9 +450,18 @@
loginUrl.Path = (new Uri(weblogin.Url)).PathAndQuery;
weblogin.Url = loginUrl.Uri.ToString();
+ UTF8Encoding utf8Name = new UTF8Encoding();
+ byte[] encodedCredsByteArray = utf8Name.GetBytes(username);
+ string iFolderUserBase64 = Convert.ToBase64String(encodedCredsByteArray);
+
+ encodedCredsByteArray = utf8Name.GetBytes(password);
+ string iFolderPassBase64 = Convert.ToBase64String(encodedCredsByteArray);
+
+
+
// credentials
weblogin.PreAuthenticate = true;
- weblogin.Credentials = new NetworkCredential(username, password);
+ weblogin.Credentials = new NetworkCredential(iFolderUserBase64, iFolderPassBase64);
// cookies
weblogin.CookieContainer = new CookieContainer();
@@ -492,7 +501,7 @@
// credentials
web.PreAuthenticate = true;
- web.Credentials = new NetworkCredential(username, password);
+ web.Credentials = new NetworkCredential(iFolderUserBase64, iFolderPassBase64);
// cookies
web.CookieContainer = new CookieContainer();
@@ -524,9 +533,8 @@
iFolderServer server = web.GetHomeServer();
Session["Server"] = server;
- UTF8Encoding utf8Name = new UTF8Encoding();
- byte[] EncodedUserNameInByte = utf8Name.GetBytes(user.UserName);
- string iFolderUserBase64 = Convert.ToBase64String(EncodedUserNameInByte);
+ encodedCredsByteArray = utf8Name.GetBytes(user.UserName);
+ iFolderUserBase64 = Convert.ToBase64String(encodedCredsByteArray);
// new username cookie for 30 days
Response.Cookies.Remove("username");
Modified: branches/iFolder_3.8.0_updates/src/webservices/iFolderServer.cs
===================================================================
--- branches/iFolder_3.8.0_updates/src/webservices/iFolderServer.cs 2010-04-13 04:11:28 UTC (rev 7332)
+++ branches/iFolder_3.8.0_updates/src/webservices/iFolderServer.cs 2010-04-21 05:41:55 UTC (rev 7333)
@@ -890,7 +890,15 @@
DomainService domainService = new DomainService();
domainService.Url = MasterServer.PublicUrl + "/DomainService.asmx";
- domainService.Credentials = new NetworkCredential(username, password);
+
+ UTF8Encoding utf8Name = new UTF8Encoding();
+ byte[] encodedCredsByteArray = utf8Name.GetBytes(username);
+ string iFolderUserBase64 = Convert.ToBase64String(encodedCredsByteArray);
+
+ encodedCredsByteArray = utf8Name.GetBytes(password);
+ string iFolderPassBase64 = Convert.ToBase64String(encodedCredsByteArray);
+
+ domainService.Credentials = new NetworkCredential(iFolderUserBase64, iFolderPassBase64);
domainService.PreAuthenticate = true;
publicUrl = domainService.GetHomeServer( username ).PublicAddress;
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <mv...@us...> - 2010-07-01 13:17:12
|
Revision: 7416
http://simias.svn.sourceforge.net/simias/?rev=7416&view=rev
Author: mvikash
Date: 2010-07-01 13:17:03 +0000 (Thu, 01 Jul 2010)
Log Message:
-----------
version bump from 3.8.0.3 to 3.8.0.4
Modified Paths:
--------------
branches/iFolder_3.8.0_updates/src/core/POBoxWS/Properties/AssemblyInfo.cs
branches/iFolder_3.8.0_updates/src/core/Properties/AssemblyInfo.cs
branches/iFolder_3.8.0_updates/src/core/SimiasApp/Properties/AssemblyInfo.cs
branches/iFolder_3.8.0_updates/src/core/SimiasClient/Properties/AssemblyInfo.cs
branches/iFolder_3.8.0_updates/src/core/SyncService/Properties/AssemblyInfo.cs
branches/iFolder_3.8.0_updates/src/core/WebService/Properties/AssemblyInfo.cs
branches/iFolder_3.8.0_updates/src/server/Simias.ClientUpdate/mac-version.config
branches/iFolder_3.8.0_updates/src/server/Simias.ClientUpdate/unix-version.config
Modified: branches/iFolder_3.8.0_updates/src/core/POBoxWS/Properties/AssemblyInfo.cs
===================================================================
--- branches/iFolder_3.8.0_updates/src/core/POBoxWS/Properties/AssemblyInfo.cs 2010-06-30 15:26:56 UTC (rev 7415)
+++ branches/iFolder_3.8.0_updates/src/core/POBoxWS/Properties/AssemblyInfo.cs 2010-07-01 13:17:03 UTC (rev 7416)
@@ -28,6 +28,6 @@
// Minor Version
// Build Number
// Revision
-//
-[assembly: AssemblyVersion("3.8.0.3")]
-[assembly: AssemblyFileVersion("3.8.0.3")]
+//
+[assembly: AssemblyVersion("3.8.0.4")]
+[assembly: AssemblyFileVersion("3.8.0.4")]
Modified: branches/iFolder_3.8.0_updates/src/core/Properties/AssemblyInfo.cs
===================================================================
--- branches/iFolder_3.8.0_updates/src/core/Properties/AssemblyInfo.cs 2010-06-30 15:26:56 UTC (rev 7415)
+++ branches/iFolder_3.8.0_updates/src/core/Properties/AssemblyInfo.cs 2010-07-01 13:17:03 UTC (rev 7416)
@@ -28,6 +28,6 @@
// Minor Version
// Build Number
// Revision
-//
-[assembly: AssemblyVersion("3.8.0.3")]
-[assembly: AssemblyFileVersion("3.8.0.3")]
+//
+[assembly: AssemblyVersion("3.8.0.4")]
+[assembly: AssemblyFileVersion("3.8.0.4")]
Modified: branches/iFolder_3.8.0_updates/src/core/SimiasApp/Properties/AssemblyInfo.cs
===================================================================
--- branches/iFolder_3.8.0_updates/src/core/SimiasApp/Properties/AssemblyInfo.cs 2010-06-30 15:26:56 UTC (rev 7415)
+++ branches/iFolder_3.8.0_updates/src/core/SimiasApp/Properties/AssemblyInfo.cs 2010-07-01 13:17:03 UTC (rev 7416)
@@ -28,6 +28,6 @@
// Minor Version
// Build Number
// Revision
-//
-[assembly: AssemblyVersion("3.8.0.3")]
-[assembly: AssemblyFileVersion("3.8.0.3")]
+//
+[assembly: AssemblyVersion("3.8.0.4")]
+[assembly: AssemblyFileVersion("3.8.0.4")]
Modified: branches/iFolder_3.8.0_updates/src/core/SimiasClient/Properties/AssemblyInfo.cs
===================================================================
--- branches/iFolder_3.8.0_updates/src/core/SimiasClient/Properties/AssemblyInfo.cs 2010-06-30 15:26:56 UTC (rev 7415)
+++ branches/iFolder_3.8.0_updates/src/core/SimiasClient/Properties/AssemblyInfo.cs 2010-07-01 13:17:03 UTC (rev 7416)
@@ -28,6 +28,6 @@
// Minor Version
// Build Number
// Revision
-//
-[assembly: AssemblyVersion("3.8.0.3")]
-[assembly: AssemblyFileVersion("3.8.0.3")]
+//
+[assembly: AssemblyVersion("3.8.0.4")]
+[assembly: AssemblyFileVersion("3.8.0.4")]
Modified: branches/iFolder_3.8.0_updates/src/core/SyncService/Properties/AssemblyInfo.cs
===================================================================
--- branches/iFolder_3.8.0_updates/src/core/SyncService/Properties/AssemblyInfo.cs 2010-06-30 15:26:56 UTC (rev 7415)
+++ branches/iFolder_3.8.0_updates/src/core/SyncService/Properties/AssemblyInfo.cs 2010-07-01 13:17:03 UTC (rev 7416)
@@ -28,6 +28,6 @@
// Minor Version
// Build Number
// Revision
-//
-[assembly: AssemblyVersion("3.8.0.3")]
-[assembly: AssemblyFileVersion("3.8.0.3")]
+//
+[assembly: AssemblyVersion("3.8.0.4")]
+[assembly: AssemblyFileVersion("3.8.0.4")]
Modified: branches/iFolder_3.8.0_updates/src/core/WebService/Properties/AssemblyInfo.cs
===================================================================
--- branches/iFolder_3.8.0_updates/src/core/WebService/Properties/AssemblyInfo.cs 2010-06-30 15:26:56 UTC (rev 7415)
+++ branches/iFolder_3.8.0_updates/src/core/WebService/Properties/AssemblyInfo.cs 2010-07-01 13:17:03 UTC (rev 7416)
@@ -28,6 +28,6 @@
// Minor Version
// Build Number
// Revision
-//
-[assembly: AssemblyVersion("3.8.0.3")]
-[assembly: AssemblyFileVersion("3.8.0.3")]
+//
+[assembly: AssemblyVersion("3.8.0.4")]
+[assembly: AssemblyFileVersion("3.8.0.4")]
Modified: branches/iFolder_3.8.0_updates/src/server/Simias.ClientUpdate/mac-version.config
===================================================================
--- branches/iFolder_3.8.0_updates/src/server/Simias.ClientUpdate/mac-version.config 2010-06-30 15:26:56 UTC (rev 7415)
+++ branches/iFolder_3.8.0_updates/src/server/Simias.ClientUpdate/mac-version.config 2010-07-01 13:17:03 UTC (rev 7416)
@@ -7,7 +7,7 @@
<!-- Put Version string here. Should be in the format of
Major Version.Minor Version.Build Version.Revision
Example: <version>1.0.1817.29628</version> -->
- <version>3.8.0.3</version>
+ <version>3.8.0.4</version>
<!-- Put name of Mac ifolder client application file
to be upgraded here. The specified file must be in
Modified: branches/iFolder_3.8.0_updates/src/server/Simias.ClientUpdate/unix-version.config
===================================================================
--- branches/iFolder_3.8.0_updates/src/server/Simias.ClientUpdate/unix-version.config 2010-06-30 15:26:56 UTC (rev 7415)
+++ branches/iFolder_3.8.0_updates/src/server/Simias.ClientUpdate/unix-version.config 2010-07-01 13:17:03 UTC (rev 7416)
@@ -24,7 +24,7 @@
you are doing.
-->
<distribution match="DEFAULT">
- <version>3.8.0.3</version>
+ <version>3.8.0.4</version>
<download-directory>default</download-directory>
</distribution>
@@ -51,17 +51,17 @@
-->
<distribution match="SUSE Linux Enterprise Desktop 10">
- <version>3.8.0.3</version>
+ <version>3.8.0.4</version>
<download-directory>suse-linux-10.0</download-directory>
</distribution>
<distribution match="SUSE Linux Enterprise Desktop 11">
- <version>3.8.0.3</version>
+ <version>3.8.0.4</version>
<download-directory>suse-linux-11.0</download-directory>
</distribution>
<distribution match="openSUSE">
- <version>3.8.0.3</version>
+ <version>3.8.0.4</version>
<download-directory>opensuse-linux</download-directory>
</distribution>
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|
|
From: <mv...@us...> - 2010-10-28 14:23:34
|
Revision: 7541
http://simias.svn.sourceforge.net/simias/?rev=7541&view=rev
Author: mvikash
Date: 2010-10-28 14:23:28 +0000 (Thu, 28 Oct 2010)
Log Message:
-----------
version bump form 3.8.0.5 to 3.8.0.6
Modified Paths:
--------------
branches/iFolder_3.8.0_updates/src/core/FlaimProvider/FlaimWrapper/FlaimWrapper.vcproj
branches/iFolder_3.8.0_updates/src/core/POBoxWS/Properties/AssemblyInfo.cs
branches/iFolder_3.8.0_updates/src/core/Properties/AssemblyInfo.cs
branches/iFolder_3.8.0_updates/src/core/SimiasApp/Properties/AssemblyInfo.cs
branches/iFolder_3.8.0_updates/src/core/SimiasClient/Properties/AssemblyInfo.cs
branches/iFolder_3.8.0_updates/src/core/SyncService/Properties/AssemblyInfo.cs
branches/iFolder_3.8.0_updates/src/core/WebService/Properties/AssemblyInfo.cs
branches/iFolder_3.8.0_updates/src/server/Simias.ClientUpdate/mac-version.config
branches/iFolder_3.8.0_updates/src/server/Simias.ClientUpdate/unix-version.config
branches/iFolder_3.8.0_updates/src/server/Simias.ClientUpdate/version.config
Modified: branches/iFolder_3.8.0_updates/src/core/FlaimProvider/FlaimWrapper/FlaimWrapper.vcproj
===================================================================
--- branches/iFolder_3.8.0_updates/src/core/FlaimProvider/FlaimWrapper/FlaimWrapper.vcproj 2010-10-28 13:46:11 UTC (rev 7540)
+++ branches/iFolder_3.8.0_updates/src/core/FlaimProvider/FlaimWrapper/FlaimWrapper.vcproj 2010-10-28 14:23:28 UTC (rev 7541)
@@ -84,7 +84,7 @@
Name="VCLinkerTool"
AdditionalDependencies="rpcrt4.lib ws2_32.lib odbc32.lib odbccp32.lib flaim.lib msvcrt.lib"
OutputFile=".\Release/FlaimWrapper.dll"
- Version="3.8.0.5"
+ Version="3.8.0.6"
LinkIncremental="1"
SuppressStartupBanner="true"
AdditionalLibraryDirectories=""$(SolutionDir)..\..\dependencies\external\libflaim\win32""
@@ -186,7 +186,7 @@
Name="VCLinkerTool"
AdditionalDependencies="rpcrt4.lib ws2_32.lib odbc32.lib odbccp32.lib dbghelp.lib flaim.lib flaimtk.lib msvcrt.lib"
OutputFile=".\Release/FlaimWrapper.dll"
- Version="3.8.0.5"
+ Version="3.8.0.6"
LinkIncremental="1"
SuppressStartupBanner="true"
AdditionalLibraryDirectories=""$(SolutionDir)..\..\dependencies\external\libflaim\win64""
Modified: branches/iFolder_3.8.0_updates/src/core/POBoxWS/Properties/AssemblyInfo.cs
===================================================================
--- branches/iFolder_3.8.0_updates/src/core/POBoxWS/Properties/AssemblyInfo.cs 2010-10-28 13:46:11 UTC (rev 7540)
+++ branches/iFolder_3.8.0_updates/src/core/POBoxWS/Properties/AssemblyInfo.cs 2010-10-28 14:23:28 UTC (rev 7541)
@@ -29,5 +29,5 @@
// Build Number
// Revision
//
-[assembly: AssemblyVersion("3.8.0.5")]
-[assembly: AssemblyFileVersion("3.8.0.5")]
+[assembly: AssemblyVersion("3.8.0.6")]
+[assembly: AssemblyFileVersion("3.8.0.6")]
Modified: branches/iFolder_3.8.0_updates/src/core/Properties/AssemblyInfo.cs
===================================================================
--- branches/iFolder_3.8.0_updates/src/core/Properties/AssemblyInfo.cs 2010-10-28 13:46:11 UTC (rev 7540)
+++ branches/iFolder_3.8.0_updates/src/core/Properties/AssemblyInfo.cs 2010-10-28 14:23:28 UTC (rev 7541)
@@ -29,5 +29,5 @@
// Build Number
// Revision
//
-[assembly: AssemblyVersion("3.8.0.5")]
-[assembly: AssemblyFileVersion("3.8.0.5")]
+[assembly: AssemblyVersion("3.8.0.6")]
+[assembly: AssemblyFileVersion("3.8.0.6")]
Modified: branches/iFolder_3.8.0_updates/src/core/SimiasApp/Properties/AssemblyInfo.cs
===================================================================
--- branches/iFolder_3.8.0_updates/src/core/SimiasApp/Properties/AssemblyInfo.cs 2010-10-28 13:46:11 UTC (rev 7540)
+++ branches/iFolder_3.8.0_updates/src/core/SimiasApp/Properties/AssemblyInfo.cs 2010-10-28 14:23:28 UTC (rev 7541)
@@ -29,5 +29,5 @@
// Build Number
// Revision
//
-[assembly: AssemblyVersion("3.8.0.5")]
-[assembly: AssemblyFileVersion("3.8.0.5")]
+[assembly: AssemblyVersion("3.8.0.6")]
+[assembly: AssemblyFileVersion("3.8.0.6")]
Modified: branches/iFolder_3.8.0_updates/src/core/SimiasClient/Properties/AssemblyInfo.cs
===================================================================
--- branches/iFolder_3.8.0_updates/src/core/SimiasClient/Properties/AssemblyInfo.cs 2010-10-28 13:46:11 UTC (rev 7540)
+++ branches/iFolder_3.8.0_updates/src/core/SimiasClient/Properties/AssemblyInfo.cs 2010-10-28 14:23:28 UTC (rev 7541)
@@ -29,5 +29,5 @@
// Build Number
// Revision
//
-[assembly: AssemblyVersion("3.8.0.5")]
-[assembly: AssemblyFileVersion("3.8.0.5")]
+[assembly: AssemblyVersion("3.8.0.6")]
+[assembly: AssemblyFileVersion("3.8.0.6")]
Modified: branches/iFolder_3.8.0_updates/src/core/SyncService/Properties/AssemblyInfo.cs
===================================================================
--- branches/iFolder_3.8.0_updates/src/core/SyncService/Properties/AssemblyInfo.cs 2010-10-28 13:46:11 UTC (rev 7540)
+++ branches/iFolder_3.8.0_updates/src/core/SyncService/Properties/AssemblyInfo.cs 2010-10-28 14:23:28 UTC (rev 7541)
@@ -29,5 +29,5 @@
// Build Number
// Revision
//
-[assembly: AssemblyVersion("3.8.0.5")]
-[assembly: AssemblyFileVersion("3.8.0.5")]
+[assembly: AssemblyVersion("3.8.0.6")]
+[assembly: AssemblyFileVersion("3.8.0.6")]
Modified: branches/iFolder_3.8.0_updates/src/core/WebService/Properties/AssemblyInfo.cs
===================================================================
--- branches/iFolder_3.8.0_updates/src/core/WebService/Properties/AssemblyInfo.cs 2010-10-28 13:46:11 UTC (rev 7540)
+++ branches/iFolder_3.8.0_updates/src/core/WebService/Properties/AssemblyInfo.cs 2010-10-28 14:23:28 UTC (rev 7541)
@@ -29,5 +29,5 @@
// Build Number
// Revision
//
-[assembly: AssemblyVersion("3.8.0.5")]
-[assembly: AssemblyFileVersion("3.8.0.5")]
+[assembly: AssemblyVersion("3.8.0.6")]
+[assembly: AssemblyFileVersion("3.8.0.6")]
Modified: branches/iFolder_3.8.0_updates/src/server/Simias.ClientUpdate/mac-version.config
===================================================================
--- branches/iFolder_3.8.0_updates/src/server/Simias.ClientUpdate/mac-version.config 2010-10-28 13:46:11 UTC (rev 7540)
+++ branches/iFolder_3.8.0_updates/src/server/Simias.ClientUpdate/mac-version.config 2010-10-28 14:23:28 UTC (rev 7541)
@@ -7,7 +7,7 @@
<!-- Put Version string here. Should be in the format of
Major Version.Minor Version.Build Version.Revision
Example: <version>1.0.1817.29628</version> -->
- <version>3.8.0.5</version>
+ <version>3.8.0.6</version>
<!-- Put name of Mac ifolder client application file
to be upgraded here. The specified file must be in
Modified: branches/iFolder_3.8.0_updates/src/server/Simias.ClientUpdate/unix-version.config
===================================================================
--- branches/iFolder_3.8.0_updates/src/server/Simias.ClientUpdate/unix-version.config 2010-10-28 13:46:11 UTC (rev 7540)
+++ branches/iFolder_3.8.0_updates/src/server/Simias.ClientUpdate/unix-version.config 2010-10-28 14:23:28 UTC (rev 7541)
@@ -24,7 +24,7 @@
you are doing.
-->
<distribution match="DEFAULT">
- <version>3.8.0.5</version>
+ <version>3.8.0.6</version>
<download-directory>default</download-directory>
</distribution>
@@ -51,17 +51,17 @@
-->
<distribution match="SUSE Linux Enterprise Desktop 10">
- <version>3.8.0.5</version>
+ <version>3.8.0.6</version>
<download-directory>suse-linux-10.0</download-directory>
</distribution>
<distribution match="SUSE Linux Enterprise Desktop 11">
- <version>3.8.0.5</version>
+ <version>3.8.0.6</version>
<download-directory>suse-linux-11.0</download-directory>
</distribution>
<distribution match="openSUSE">
- <version>3.8.0.5</version>
+ <version>3.8.0.6</version>
<download-directory>opensuse-linux</download-directory>
</distribution>
Modified: branches/iFolder_3.8.0_updates/src/server/Simias.ClientUpdate/version.config
===================================================================
--- branches/iFolder_3.8.0_updates/src/server/Simias.ClientUpdate/version.config 2010-10-28 13:46:11 UTC (rev 7540)
+++ branches/iFolder_3.8.0_updates/src/server/Simias.ClientUpdate/version.config 2010-10-28 14:23:28 UTC (rev 7541)
@@ -4,15 +4,15 @@
with the one specified here by 'filename'. -->
<versioninfo>
<distribution match="windows32">
- <version>3.8.0.5</version>
+ <version>3.8.0.6</version>
<filename>ifolder3-windows.exe</filename>
</distribution>
<distribution match="windows64">
- <version>3.8.0.5</version>
+ <version>3.8.0.6</version>
<filename>ifolder3-windows-x64.exe</filename>
</distribution>
<distribution match="DEFAULT">
- <version>3.8.0.5</version>
+ <version>3.8.0.6</version>
<filename>ifolder3-windows.exe</filename>
</distribution>
</versioninfo>
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|