共用方式為


3.1.5.6.4.1 Common Processing

  1. If the value of UserInformationClass is present in the following table, the message MUST be processed exactly as a call to SamrSetInformationUser2 with UserInformationClass set to UserAllInformation and Buffer of type SAMPR_USER_ALL_INFORMATION.

    UserInformationClass value

    UserPreferencesInformation

    UserLogonHoursInformation

    UserParametersInformation

    UserNameInformation

    UserAccountNameInformation

    UserFullNameInformation

    UserPrimaryGroupInformation

    UserHomeInformation

    UserScriptInformation

    UserProfileInformation

    UserAdminCommentInformation

    UserWorkStationsInformation

    UserControlInformation

    UserExpiresInformation

    UserInternal1Information

    All SAMPR_USER_ALL_INFORMATION fields with the same name as the fields in the incoming structure MUST be set with the same value. Furthermore, the WhichFields field MUST be updated according to the table in section 2.2.1.8. All SAMPR_USER_ALL_INFORMATION fields not covered MUST be zero.

    As an example, the following table shows how a request for UserPreferencesInformation MUST be handled.

    Source UserInformationClass value: UserPreferencesInformation

    Target: SAMPR_USER_ALL_INFORMATION

    Field name

    Value

    WhichFields

    USER_ALL_USERCOMMENT |

    USER_ALL_COUNTRYCODE |

    USER_ALL_CODEPAGE

    UserComment

    Preferences.UserComment

    CountryCode

    Preferences.CountryCode

    CodePage

    Preferences.CodePage

    A request for Internal1Information is a slight exception and thus is shown explicitly in the following table.

    Source UserInformationClass value: UserInternal1Information

    Target: SAMPR_USER_ALL_INFORMATION

    Field name

    Value

    WhichFields

    USER_ALL_NTPASSWORDPRESENT |

    USER_ALL_LMPASSWORDPRESENT |

    USER_ALL_PASSWORDEXPIRED

    NtPasswordPresent

    Internal1.NtPasswordPresent

    LmPasswordPresent

    Internal1.LmPasswordPresent

    PasswordExpired

    Internal1.PasswordExpired

    LmOwfPassword.Length

    0x10

    LmOwfPassword.MaximumLength

    0x10

    LmOwfPassword.Buffer

    Internal1.LmOwfPassword

    NtOwfPassword.Length

    0x10

    NtOwfPassword.MaximumLength

    0x10

    NtOwfPassword.Buffer

    Internal1.NtOwfPassword

  2. If the value of UserInformationClass is UserInternal5InformationNew, the message MUST be processed exactly as a call to SamrSetInformationUser2, with UserInformationClass set to UserInternal4InformationNew and Buffer of type SAMPR_USER_INTERNAL4_INFORMATION_NEW with the fields set as shown in the following table. All SAMPR_USER_INTERNAL4_INFORMATION_NEW fields not covered by the table MUST be zero.

    Source UserInformationClass value: UserInternal5InformationNew

    Target: SAMPR_USER_INTERNAL4_INFORMATION_NEW

    Field name

    Value

    I1.WhichFields

    USER_ALL_NTPASSWORDPRESENT |

    USER_ALL_LMPASSWORDPRESENT |

    USER_ALL_PASSWORDEXPIRED

    I1.PasswordExpired

    Internal5.PasswordExpired

    UserPassword

    Internal5.UserPassword

  3. If the value of UserInformationClass is UserInternal5Information, the message MUST be processed exactly as a call to SamrSetInformationUser2, with UserInformationClass set to UserInternal4Information and Buffer of type SAMPR_USER_INTERNAL4_INFORMATION with the fields set as shown in the following table. All SAMPR_USER_INTERNAL4_INFORMATION fields not covered by the table MUST be zero.

    Source UserInformationClass value: UserInternal5Information

    Target: SAMPR_USER_INTERNAL4_INFORMATION

    Field name

    Value

    I1.WhichFields

    USER_ALL_NTPASSWORDPRESENT |

    USER_ALL_LMPASSWORDPRESENT |

    USER_ALL_PASSWORDEXPIRED

    I1.PasswordExpired

    Internal5.PasswordExpired

    UserPassword

    Internal5.UserPassword

  4. If the value of UserInformationClass (section 2.2.6.28) is UserInternal7Information, the message MUST be processed exactly as a call to SamrSetInformationUser2 (section 3.1.5.6.4), with UserInformationClass set to UserInternal8Information and Buffer of type SAMPR_USER_INTERNAL8_INFORMATION (section 2.2.6.31), and with field settings set as indicated in the following table. All SAMPR_USER_INTERNAL8_INFORMATION fields not specified in the table MUST be set to zero.

    Source UserInformationClass value: UserInternal7Information

    Target: SAMPR_USER_INTERNAL8_INFORMATION

    Field name

    Value

    I1.WhichFields

    USER_ALL_NTPASSWORDPRESENT | USER_ALL_PASSWORDEXPIRED

    I1.PasswordExpired

    Internal7.PasswordExpired

    UserPassword

    Internal7.UserPassword

  5. If the value of UserInformationClass was not found in the previous four constraints, the server MUST return an error.