--Thanks,Mariska.
You received this message because you are subscribed to the Google Groups "Nexus Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to nexus-users+unsubscribe@glists.sonatype.com.
To post to this group, send email to nexus...@glists.sonatype.com.
To view this discussion on the web visit https://groups.google.com/a/glists.sonatype.com/d/msgid/nexus-users/ec6aa420-0d83-49ac-9d22-5d9a1ebd2014%40glists.sonatype.com.
For more options, visit https://groups.google.com/a/glists.sonatype.com/d/optout.
On Wed, Mar 7, 2018 at 8:09 AM, Mariska <talla...@gmail.com> wrote:I just found out that the NuGet APIKeys in Nexus3 for the build users have changed. I'm not sure what may have caused this.As we mainly pull from Nexus 3 and only sometimes push packages, I don't know when exactly it happened. In any case, some time between now and 3 weeks ago the API Keys have changed as I was able to push packages 3 weeks ago with the old keys. I've upgraded to v3.8.0 in between, but maybe some other activities may have set this off.So, my question: what may cause all NuGet API Keys to be reset?A run of the Delete Orphaned API Keys can cause this if the keys are orphaned. Or if the user account is inside an external LDAP/Crowd server, and the connection information inside Nexus has changed. There is also a found bug if the NuGet API keys were generated while signed in with a RUT Auth token: https://issues.sonatype.org/browse/NEXUS-15422Resetting API keys should not happen on a standard upgrade to a new version. What version of Nexus did you upgrade from to 3.8.0?
Thanks,Mariska.
--
You received this message because you are subscribed to the Google Groups "Nexus Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to nexus-users...@glists.sonatype.com.
I found out the keys were changed because after upgrading the server (to 3.8.0-02), I ran some automated groovy scripts, which updates the local users if there are changes. Although nothing changed, updating the user with the same values, will reset the Nuget APIKey. Changing the user password also resets the Nuget API Key.Is this by design?
Thanks,Mariska
On Wednesday, March 7, 2018 at 1:56:57 PM UTC+1, Peter Lynch wrote:On Wed, Mar 7, 2018 at 8:09 AM, Mariska <talla...@gmail.com> wrote:I just found out that the NuGet APIKeys in Nexus3 for the build users have changed. I'm not sure what may have caused this.As we mainly pull from Nexus 3 and only sometimes push packages, I don't know when exactly it happened. In any case, some time between now and 3 weeks ago the API Keys have changed as I was able to push packages 3 weeks ago with the old keys. I've upgraded to v3.8.0 in between, but maybe some other activities may have set this off.So, my question: what may cause all NuGet API Keys to be reset?A run of the Delete Orphaned API Keys can cause this if the keys are orphaned. Or if the user account is inside an external LDAP/Crowd server, and the connection information inside Nexus has changed. There is also a found bug if the NuGet API keys were generated while signed in with a RUT Auth token: https://issues.sonatype.org/browse/NEXUS-15422Resetting API keys should not happen on a standard upgrade to a new version. What version of Nexus did you upgrade from to 3.8.0?--Thanks,Mariska.
You received this message because you are subscribed to the Google Groups "Nexus Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to nexus-users...@glists.sonatype.com.
To post to this group, send email to nexus...@glists.sonatype.com.
To view this discussion on the web visit https://groups.google.com/a/glists.sonatype.com/d/msgid/nexus-users/ec6aa420-0d83-49ac-9d22-5d9a1ebd2014%40glists.sonatype.com.
For more options, visit https://groups.google.com/a/glists.sonatype.com/d/optout.
--
You received this message because you are subscribed to the Google Groups "Nexus Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to nexus-users+unsubscribe@glists.sonatype.com.
To post to this group, send email to nexus...@glists.sonatype.com.
To view this discussion on the web visit https://groups.google.com/a/glists.sonatype.com/d/msgid/nexus-users/19330e21-3372-418f-9cd3-0b4c8fa89f69%40glists.sonatype.com.
import groovy.json.JsonSlurper
import org.sonatype.nexus.security.user.UserNotFoundException
parsed_args = new JsonSlurper().parseText(args)
log.info('Users {} update', parsed_args)
try {
log.info('Users {} try update', parsed_args)
// update an existing user
user = security.securitySystem.getUser(parsed_args.username)
user.setFirstName(parsed_args.first_name)
user.setLastName(parsed_args.last_name)
user.setEmailAddress(parsed_args.email)
security.securitySystem.updateUser(user)
security.setUserRoles(parsed_args.username, parsed_args.roles)
security.securitySystem.changePassword(parsed_args.username, parsed_args.password)
} catch(UserNotFoundException ignored) {
// create the new user
log.info('Users {} try add', parsed_args)
security.addUser(parsed_args.username, parsed_args.first_name, parsed_args.last_name, parsed_args.email,
true, parsed_args.password, parsed_args.roles)
}
{
"username": "builduser",
To unsubscribe from this group and stop receiving emails from it, send an email to nexus-users+unsubscribe@glists.sonatype.com.
To post to this group, send email to nexus...@glists.sonatype.com.
To view this discussion on the web visit https://groups.google.com/a/glists.sonatype.com/d/msgid/nexus-users/dcc239d3-bc5c-43cf-a9b8-12804801326a%40glists.sonatype.com.
To view this discussion on the web visit https://groups.google.com/a/glists.sonatype.com/d/msgid/nexus-users/CAC16qPj24FKsbwANEz1xDJBBHjw5CoFh-50yfL3dFPX_1OAvEg%40mail.gmail.com.
To view this discussion on the web visit https://groups.google.com/a/glists.sonatype.com/d/msgid/nexus-users/dcc239d3-bc5c-43cf-a9b8-12804801326a%40glists.sonatype.com.
--
You received this message because you are subscribed to the Google Groups "Nexus Users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to nexus-users...@glists.sonatype.com.
To post to this group, send email to nexus...@glists.sonatype.com.
To unsubscribe from this group and stop receiving emails from it, send an email to nexus-users+unsubscribe@glists.sonatype.com.
To post to this group, send email to nexus...@glists.sonatype.com.
To view this discussion on the web visit https://groups.google.com/a/glists.sonatype.com/d/msgid/nexus-users/0f8799e1-f493-474b-9f66-9574818997d5%40glists.sonatype.com.