Although I'm not superstitious, it looks good to me.

Source: Internet
Author: User

Today, I finally solved the last issue, an issue that has been bothering me for several days, and an issue that looks bad but disgusting. I thought it was easy, but it took a lot of effort. In fact, it was very simple. An issue that really wanted to yell at TMD was finally completed before I went to bed. For the sake of the two issue, we didn't have a rest this weekend and got on a Monday. Summarize the work of these two days, one is about the Exchange Server issue, one is about the EXT-GWT in IE8 lower bound issue.

Let's talk about the issue on the Exchange Server first,

Problem:

On the server of exchange2010, the Operation permission on the file requires the permission of the domain user. This leads to a problem. When a process is started by the Windows service, it will fail due to insufficient permissions. We all know that the default permission for Windows Services is system users, an account with higher permissions than administrator, but it cannot create files on the server of exchange2010.

Solution:

It may be solved by configuring the domain policy, but this will lead to other problems and increase the complexity of the policy in the domain. It may be feasible to use a domain account to start the service, but there will also be some problems, such as interaction with other system processes. Therefore, a reasonable solution is to use createprocessasuser or createprocesswithlogonw APIs to create the processes for starting user sessions based on the provided user information. The main difference is that logonuser is required before createprocessasuser is used. Speaking of logonuser, I have to say something about it.

Bool logonuser (_ in lptstr login, _ in_opt lptstr lpszdomain, _ in lptstr lpszpassword, _ in DWORD dwlogontype, _ in DWORD dwlogonprovider, _ out phandle phtoken );

The fourth parameter, dwlogontype, is described in msdn as follows:

The type of Logon operation to perform. This parameter can be one of the following values, defined in WINBASE. h.

Value Meaning
Logon32_logon_batch

This logon type is intended for batch servers, where processes may be executing on behalf of a user without their direct intervention. this type is also for higher performance servers that process implements plaintext authentication attempts at a time, such as mail or web servers. theLogonuserFunction does not cache credentials for this logon type.

This parameter is suitable for batch processing, that is, there is no interface, and only backend operations are performed.

Logon32_logon_interactive

This logon type is intended for users who will be interactively using the computer, such as a user being logged on byTerminalServer, remote shell, or similar process. this logon type has the additional expense of caching logon information for disconnected operations; therefore, it is inappropriate for some client/server applications, such as a mail server.

This parameter is suitable for interface processes. If your service needs to interact with the interface, you must use this

Logon32_logon_network

This logon type is intended for High Performance servers to authenticate plaintext passwords.LogonuserFunction does not cache credentials for this logon type.

Logon32_logon_network_cleartext

This logon type preserves the name and password inAuthentication package, Which allows the server to make connections to other network servers while impersonating the client. A server can accept plaintext credentials from a client, callLogonuser, Verify that the user can access the system authentication ss the network, and still communicate with other servers.

Logon32_logon_new_credentials

This logon type allows the caller to clone its current token and specify new credentials for outbound connections. The new logon session has the same local identifier but uses different credentials for other network connections.

This logon type is supported only by the logon32_provider_winnt50 logon provider.

This requires support from windows and later systems.

Logon32_logon_service

Indicates a service-type logon. The account provided must have the Service Privilege enabled.

This parameter is suitable for creating a service

Logon32_logon_unlock

This logon type isGinaDLLs that log on users who will be interactively using the computer. This logon type can generate a unique audit record that shows when the workstation was unlocked.

 

Therefore, you need to pay attention to this parameter to create a process for a specific user session. In addition, remember to call the duplicatetokenex function to copy the token of Logon. Otherwise, you will change the token settings of the current process.

At the same time, it should be emphasized that the interface parameters of DLL should not be transmitted using the type in the C ++ standard library, such as STD: string as the container for passing characters. Otherwise, it would be a dead person, and they do not know how to die. The reason is that the C ++ library is non-multi-thread secure, which means that when your DLL function is used as a multi-thread, the data may be inexplicably modified; the second is that, the object structure of C ++ occurs late. After you detach the DLL module, if the C ++ object structure operation in the original module occurs again, that is, the process should be crash.

 

The second issue,

Problem:

The ComboBox created by the EXT-GWT, when the number of elements exceeds 30, and is nested with multiple layers of layercontainer, the drop-down list cannot pop up in IE8. This is actually a EXT-GWT bug, but it took me 2 days to fix it. All methods are ineffective. The most funny thing is that I manually wrote a list and clicked ComboBox to bring it up. Basically, this should be a layercontainer nested bug. Tracking shows that in this case, the height attribute of the List View is 0. I guess this is because the height of the List View is obtained by calculating the current table height during dynamic generation.

Solution:

Reference gxt. jar of version 2.20.

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.